gonzalez-agirre commited on
Commit
a7be7f3
1 Parent(s): ffbc945

Upload model.

Browse files
README.md CHANGED
@@ -1,3 +1,96 @@
1
  ---
 
 
 
 
 
2
  license: apache-2.0
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+
3
+ language:
4
+
5
+ - ca
6
+
7
  license: apache-2.0
8
+
9
+ tags:
10
+
11
+ - "catalan"
12
+
13
+ - "named entity recognition"
14
+
15
+ - "ner"
16
+
17
+ - "CaText"
18
+
19
+ - "Catalan Textual Corpus"
20
+
21
+ datasets:
22
+
23
+ - "projecte-aina/ancora-ca-ner"
24
+
25
+ metrics:
26
+
27
+ - f1
28
+
29
+ model-index:
30
+ - name: roberta-base-ca-v2-cased-ner
31
+ results:
32
+ - task:
33
+ type: token-classification
34
+ dataset:
35
+ type: projecte-aina/ancora-ca-ner
36
+ name: Ancora-ca-NER
37
+ metrics:
38
+ - name: F1
39
+ type: f1
40
+ value: 0.8945
41
+
42
+ widget:
43
+
44
+ - text: "Em dic Lluïsa i visc a Santa Maria del Camí."
45
+
46
+ - text: "L'Aina, la Berta i la Norma són molt amigues."
47
+
48
+ - text: "El Martí llegeix el Cavall Fort."
49
+
50
  ---
51
+
52
+ # Catalan BERTa-v2 (roberta-base-ca-v2) finetuned for Named Entity Recognition.
53
+
54
+ The **roberta-base-ca-v2-cased-ner** is a Named Entity Recognition (NER) model for the Catalan language fine-tuned from the [roberta-base-ca-v2](https://huggingface.co/projecte-aina/roberta-base-ca-v2) model, a [RoBERTa](https://arxiv.org/abs/1907.11692) base model pre-trained on a medium-size corpus collected from publicly available corpora and crawlers (check the roberta-base-ca-v2 model card for more details).
55
+
56
+ ## Datasets
57
+ We used the NER dataset in Catalan called [Ancora-ca-NER](https://huggingface.co/datasets/projecte-aina/ancora-ca-ner) for training and evaluation.
58
+
59
+ ## Evaluation and results
60
+ We evaluated the _roberta-base-ca-v2-cased-ner_ on the Ancora-ca-ner test set against standard multilingual and monolingual baselines:
61
+
62
+ | Model | Ancora-ca-ner (F1)|
63
+ | ------------|:-------------|
64
+ | roberta-base-ca-v2-cased-ner | **89.45** |
65
+ | roberta-base-ca-cased-ner | 88.94 |
66
+ | mBERT | 87.36 |
67
+ | XLM-RoBERTa | 88.07 |
68
+
69
+ For more details, check the fine-tuning and evaluation scripts in the official [GitHub repository](https://github.com/projecte-aina/club).
70
+
71
+ ## Citing
72
+ If you use any of these resources (datasets or models) in your work, please cite our latest paper:
73
+ ```bibtex
74
+ @inproceedings{armengol-estape-etal-2021-multilingual,
75
+ title = "Are Multilingual Models the Best Choice for Moderately Under-resourced Languages? {A} Comprehensive Assessment for {C}atalan",
76
+ author = "Armengol-Estap{\'e}, Jordi and
77
+ Carrino, Casimiro Pio and
78
+ Rodriguez-Penagos, Carlos and
79
+ de Gibert Bonet, Ona and
80
+ Armentano-Oller, Carme and
81
+ Gonzalez-Agirre, Aitor and
82
+ Melero, Maite and
83
+ Villegas, Marta",
84
+ booktitle = "Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021",
85
+ month = aug,
86
+ year = "2021",
87
+ address = "Online",
88
+ publisher = "Association for Computational Linguistics",
89
+ url = "https://aclanthology.org/2021.findings-acl.437",
90
+ doi = "10.18653/v1/2021.findings-acl.437",
91
+ pages = "4933--4946",
92
+ }
93
+ ```
94
+
95
+ ### Funding
96
+ This work was funded by the [Catalan Government](https://politiquesdigitals.gencat.cat/en/inici/index.html) within the framework of the [AINA project.](https://politiquesdigitals.gencat.cat/ca/economia/catalonia-ai/aina).
config.json ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "projecte-aina/roberta-base-ca-v2-cased-ner",
3
+ "architectures": [
4
+ "RobertaForTokenClassification"
5
+ ],
6
+ "attention_probs_dropout_prob": 0.1,
7
+ "bos_token_id": 0,
8
+ "eos_token_id": 2,
9
+ "finetuning_task": "ner",
10
+ "gradient_checkpointing": false,
11
+ "hidden_act": "gelu",
12
+ "hidden_dropout_prob": 0.1,
13
+ "hidden_size": 768,
14
+ "id2label": {
15
+ "0": "B-LOC",
16
+ "1": "B-MISC",
17
+ "2": "B-ORG",
18
+ "3": "B-PER",
19
+ "4": "I-LOC",
20
+ "5": "I-MISC",
21
+ "6": "I-ORG",
22
+ "7": "I-PER",
23
+ "8": "O"
24
+ },
25
+ "initializer_range": 0.02,
26
+ "intermediate_size": 3072,
27
+ "label2id": {
28
+ "B-LOC": 0,
29
+ "B-MISC": 1,
30
+ "B-ORG": 2,
31
+ "B-PER": 3,
32
+ "I-LOC": 4,
33
+ "I-MISC": 5,
34
+ "I-ORG": 6,
35
+ "I-PER": 7,
36
+ "O": 8
37
+ },
38
+ "layer_norm_eps": 1e-05,
39
+ "max_position_embeddings": 514,
40
+ "model_type": "roberta",
41
+ "num_attention_heads": 12,
42
+ "num_hidden_layers": 12,
43
+ "pad_token_id": 1,
44
+ "position_embedding_type": "absolute",
45
+ "transformers_version": "4.6.1",
46
+ "type_vocab_size": 1,
47
+ "use_cache": true,
48
+ "vocab_size": 50262
49
+ }
50
+
merges.txt ADDED
The diff for this file is too large to render. See raw diff
 
pytorch_model.bin ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:95be96df6bd37f3648672172bf67c39078944d8718add0e1f912ee7a7a1965ad
3
+ size 496323313
special_tokens_map.json ADDED
@@ -0,0 +1 @@
 
 
1
+ {"bos_token": {"content": "<s>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true}, "eos_token": {"content": "</s>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true}, "unk_token": {"content": "<unk>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true}, "sep_token": {"content": "</s>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true}, "pad_token": {"content": "<pad>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true}, "cls_token": {"content": "<s>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true}, "mask_token": {"content": "<mask>", "single_word": false, "lstrip": true, "rstrip": false, "normalized": true}}
tokenizer.json ADDED
The diff for this file is too large to render. See raw diff
 
tokenizer_config.json ADDED
@@ -0,0 +1 @@
 
 
1
+ {"unk_token": {"content": "<unk>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true, "__type": "AddedToken"}, "bos_token": {"content": "<s>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true, "__type": "AddedToken"}, "eos_token": {"content": "</s>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true, "__type": "AddedToken"}, "add_prefix_space": true, "errors": "replace", "sep_token": {"content": "</s>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true, "__type": "AddedToken"}, "cls_token": {"content": "<s>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true, "__type": "AddedToken"}, "pad_token": {"content": "<pad>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true, "__type": "AddedToken"}, "mask_token": {"content": "<mask>", "single_word": false, "lstrip": true, "rstrip": false, "normalized": true, "__type": "AddedToken"}, "max_len": 512, "special_tokens_map_file": null, "name_or_path": "/gpfs/projects/bsc88/BERTs/models/roberta_base_ca_jsc/transformed_lr0.0005"}
vocab.json ADDED
The diff for this file is too large to render. See raw diff