janrodriguez commited on
Commit
615c276
·
0 Parent(s):

Upload MultiClinNER ro/symptom model + card

Browse files
Files changed (6) hide show
  1. .gitattributes +33 -0
  2. README.md +118 -0
  3. config.json +40 -0
  4. model.safetensors +3 -0
  5. tokenizer.json +3 -0
  6. tokenizer_config.json +14 -0
.gitattributes ADDED
@@ -0,0 +1,33 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ *.7z filter=lfs diff=lfs merge=lfs -text
2
+ *.arrow filter=lfs diff=lfs merge=lfs -text
3
+ *.bin filter=lfs diff=lfs merge=lfs -text
4
+ *.bz2 filter=lfs diff=lfs merge=lfs -text
5
+ *.ckpt filter=lfs diff=lfs merge=lfs -text
6
+ *.ftz filter=lfs diff=lfs merge=lfs -text
7
+ *.gz filter=lfs diff=lfs merge=lfs -text
8
+ *.h5 filter=lfs diff=lfs merge=lfs -text
9
+ *.joblib filter=lfs diff=lfs merge=lfs -text
10
+ *.lfs.* filter=lfs diff=lfs merge=lfs -text
11
+ *.mlmodel filter=lfs diff=lfs merge=lfs -text
12
+ *.model filter=lfs diff=lfs merge=lfs -text
13
+ *.msgpack filter=lfs diff=lfs merge=lfs -text
14
+ *.npy filter=lfs diff=lfs merge=lfs -text
15
+ *.npz filter=lfs diff=lfs merge=lfs -text
16
+ *.onnx filter=lfs diff=lfs merge=lfs -text
17
+ *.ot filter=lfs diff=lfs merge=lfs -text
18
+ *.parquet filter=lfs diff=lfs merge=lfs -text
19
+ *.pb filter=lfs diff=lfs merge=lfs -text
20
+ *.pickle filter=lfs diff=lfs merge=lfs -text
21
+ *.pkl filter=lfs diff=lfs merge=lfs -text
22
+ *.pt filter=lfs diff=lfs merge=lfs -text
23
+ *.pth filter=lfs diff=lfs merge=lfs -text
24
+ *.safetensors filter=lfs diff=lfs merge=lfs -text
25
+ *.tar.* filter=lfs diff=lfs merge=lfs -text
26
+ *.tflite filter=lfs diff=lfs merge=lfs -text
27
+ *.tgz filter=lfs diff=lfs merge=lfs -text
28
+ *.wasm filter=lfs diff=lfs merge=lfs -text
29
+ *.xz filter=lfs diff=lfs merge=lfs -text
30
+ *.zip filter=lfs diff=lfs merge=lfs -text
31
+ *.zst filter=lfs diff=lfs merge=lfs -text
32
+ *tfevents* filter=lfs diff=lfs merge=lfs -text
33
+ tokenizer.json filter=lfs diff=lfs merge=lfs -text
README.md ADDED
@@ -0,0 +1,118 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ language:
3
+ - ro
4
+ tags:
5
+ - biomedical
6
+ - clinical
7
+ - EHR
8
+ - NER
9
+ - named-entity-recognition
10
+ - token-classification
11
+ - multiclinner
12
+ - ro
13
+ - symptom
14
+ license: cc-by-4.0
15
+ metrics:
16
+ - f1
17
+ base_model:
18
+ - FacebookAI/xlm-roberta-base
19
+ pipeline_tag: token-classification
20
+ model-index:
21
+ - name: BSC-NLP4BIA/multiclinner-ro-symptom-xlm-roberta
22
+ results:
23
+ - task:
24
+ type: token-classification
25
+ dataset:
26
+ name: MultiClinNER ro symptom (test)
27
+ type: MultiClinNER
28
+ metrics:
29
+ - name: strict F1
30
+ type: f1
31
+ value: 0.5833
32
+ - name: char F1 (gold)
33
+ type: f1
34
+ value: 0.7334
35
+ ---
36
+
37
+ # multiclinner-ro-symptom-xlm-roberta
38
+
39
+ ## Table of contents
40
+ <details>
41
+ <summary>Click to expand</summary>
42
+
43
+ - [Model description](#model-description)
44
+ - [How to use](#how-to-use)
45
+ - [Evaluation](#evaluation)
46
+ - [Limitations and bias](#limitations-and-bias)
47
+ - [Additional information](#additional-information)
48
+ - [Authors](#authors)
49
+ - [Contact information](#contact-information)
50
+ - [Funding](#funding)
51
+ - [Citing information](#citing-information)
52
+ - [Disclaimer](#disclaimer)
53
+
54
+ </details>
55
+
56
+ ## Model description
57
+ A fine-tuned version of [FacebookAI/xlm-roberta-base](https://huggingface.co/FacebookAI/xlm-roberta-base) for **SYMPTOM Named Entity Recognition** in Romanian clinical text. It was developed for MultiClinNER, a subtask of the [MultiClinAI shared task](https://temu.bsc.es/MultiClinAI/) organized by the NLP4BIA team at the Barcelona Supercomputing Center as part of the #SMM4H-HeaRD Workshop at the ACL 2026 conference. The model labels mentions of **SYMPTOM** using the BIO tagging scheme: `O`, `B-SYMPTOM`, `I-SYMPTOM`.
58
+
59
+ ## How to use
60
+
61
+ ⚠ We recommend pre-tokenizing the input text into words instead of providing it directly to the model, as this is how the model was trained. Otherwise, the results and performance might get affected.
62
+
63
+ ```python
64
+ from transformers import pipeline
65
+
66
+ ner = pipeline(
67
+ "token-classification",
68
+ model="BSC-NLP4BIA/multiclinner-ro-symptom-xlm-roberta",
69
+ aggregation_strategy="simple",
70
+ )
71
+ ner("...clinical text in Romanian...")
72
+ ```
73
+
74
+ ## Evaluation
75
+
76
+ Scores were computed with the official [MultiClinAIEval](https://github.com/nlp4bia-bsc/MultiClinAIEval) library on the MultiClinNER **Romanian** gold-standard test documents for **SYMPTOM** (the shared-task gold set for this language and entity type).
77
+
78
+ | Metric | Score | Definition |
79
+ |---|---|---|
80
+ | strict F1 | 0.5833 | exact match of both entity span (start/end) and label |
81
+ | char F1 (gold) | 0.7334 | character-level F1, restricted to the gold-standard documents |
82
+
83
+ See the [MultiClinAI shared task](https://temu.bsc.es/MultiClinAI/) for the full evaluation protocol.
84
+
85
+ ## Limitations and bias
86
+ At the time of submission, no measures have been taken to estimate the bias embedded in the model. However, we are well aware that our models may be biased. We intend to conduct research in these areas in the future, and if completed, this model card will be updated.
87
+
88
+ ## Additional information
89
+
90
+ ### Authors
91
+ NLP4BIA team at the Barcelona Supercomputing Center (nlp4bia@bsc.es).
92
+
93
+ ### Contact information
94
+ jan.rodriguez [at] bsc.es
95
+
96
+ ### Funding
97
+ More information will be available soon.
98
+
99
+ ### Citing information
100
+ Please cite the MultiClinAI shared task overview paper (forthcoming).
101
+
102
+ ```bibtex
103
+
104
+
105
+
106
+
107
+ ```
108
+
109
+ ### Disclaimer
110
+
111
+ The models published in this repository are intended for a generalist purpose and are available to third parties. These models may have bias and/or any other undesirable distortions.
112
+
113
+ When third parties deploy or provide systems and/or services to other parties using any of these models (or using systems based on these models) or become users of the models, they should note that it is their responsibility to mitigate the risks arising from their use and, in any event, to comply with applicable regulations, including regulations regarding the use of artificial intelligence.
114
+
115
+ ---
116
+ Los modelos publicados en este repositorio tienen una finalidad generalista y están a disposición de terceros. Estos modelos pueden tener sesgos y/u otro tipo de distorsiones indeseables.
117
+
118
+ Cuando terceros desplieguen o proporcionen sistemas y/o servicios a otras partes usando alguno de estos modelos (o utilizando sistemas basados en estos modelos) o se conviertan en usuarios de los modelos, deben tener en cuenta que es su responsabilidad mitigar los riesgos derivados de su uso y, en todo caso, cumplir con la normativa aplicable, incluyendo la normativa en materia de uso de inteligencia artificial.
config.json ADDED
@@ -0,0 +1,40 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "add_cross_attention": false,
3
+ "architectures": [
4
+ "XLMRobertaForTokenClassification"
5
+ ],
6
+ "attention_probs_dropout_prob": 0.1,
7
+ "bos_token_id": 0,
8
+ "classifier_dropout": 0.5,
9
+ "dtype": "float32",
10
+ "eos_token_id": 2,
11
+ "hidden_act": "gelu",
12
+ "hidden_dropout_prob": 0.1,
13
+ "hidden_size": 768,
14
+ "id2label": {
15
+ "0": "O",
16
+ "1": "B-SYMPTOM",
17
+ "2": "I-SYMPTOM"
18
+ },
19
+ "initializer_range": 0.02,
20
+ "intermediate_size": 3072,
21
+ "is_decoder": false,
22
+ "label2id": {
23
+ "B-SYMPTOM": 1,
24
+ "I-SYMPTOM": 2,
25
+ "O": 0
26
+ },
27
+ "layer_norm_eps": 1e-05,
28
+ "max_position_embeddings": 514,
29
+ "model_type": "xlm-roberta",
30
+ "num_attention_heads": 12,
31
+ "num_hidden_layers": 12,
32
+ "output_past": true,
33
+ "pad_token_id": 1,
34
+ "position_embedding_type": "absolute",
35
+ "tie_word_embeddings": true,
36
+ "transformers_version": "5.5.4",
37
+ "type_vocab_size": 1,
38
+ "use_cache": false,
39
+ "vocab_size": 250002
40
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:4120326c53deba3267c0df163da9f05f9ba41993d41270588a10621a837f7fad
3
+ size 1109845468
tokenizer.json ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e6c77ee2ef43d82281b6f419aaadb55954ac3faa4ffd2c339b5b33bea9060930
3
+ size 17098186
tokenizer_config.json ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "add_prefix_space": true,
3
+ "backend": "tokenizers",
4
+ "bos_token": "<s>",
5
+ "cls_token": "<s>",
6
+ "eos_token": "</s>",
7
+ "is_local": true,
8
+ "mask_token": "<mask>",
9
+ "model_max_length": 512,
10
+ "pad_token": "<pad>",
11
+ "sep_token": "</s>",
12
+ "tokenizer_class": "XLMRobertaTokenizer",
13
+ "unk_token": "<unk>"
14
+ }