model update
Browse files- README.md +124 -0
- config.json +2 -2
- eval/metric.json +1 -0
- eval/metric_span.json +1 -0
- eval/prediction.validation.json +0 -0
- pytorch_model.bin +2 -2
- tokenizer.json +0 -0
- tokenizer_config.json +1 -1
- trainer_config.json +1 -0
README.md
ADDED
@@ -0,0 +1,124 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
datasets:
|
3 |
+
- conll2003
|
4 |
+
metrics:
|
5 |
+
- f1
|
6 |
+
- precision
|
7 |
+
- recall
|
8 |
+
model-index:
|
9 |
+
- name: tner/deberta-v3-large-conll2003
|
10 |
+
results:
|
11 |
+
- task:
|
12 |
+
name: Token Classification
|
13 |
+
type: token-classification
|
14 |
+
dataset:
|
15 |
+
name: conll2003
|
16 |
+
type: conll2003
|
17 |
+
args: conll2003
|
18 |
+
metrics:
|
19 |
+
- name: F1
|
20 |
+
type: f1
|
21 |
+
value: 0.9222388190844389
|
22 |
+
- name: Precision
|
23 |
+
type: precision
|
24 |
+
value: 0.9154020582592011
|
25 |
+
- name: Recall
|
26 |
+
type: recall
|
27 |
+
value: 0.9291784702549575
|
28 |
+
- name: F1 (macro)
|
29 |
+
type: f1_macro
|
30 |
+
value: 0.9043961692086329
|
31 |
+
- name: Precision (macro)
|
32 |
+
type: precision_macro
|
33 |
+
value: 0.8959854326377331
|
34 |
+
- name: Recall (macro)
|
35 |
+
type: recall_macro
|
36 |
+
value: 0.9135442454672595
|
37 |
+
- name: F1 (entity span)
|
38 |
+
type: f1_entity_span
|
39 |
+
value: 0.960570322126386
|
40 |
+
- name: Precision (entity span)
|
41 |
+
type: precision_entity_span
|
42 |
+
value: 0.9550227511375569
|
43 |
+
- name: Recall (entity span)
|
44 |
+
type: recall_entity_span
|
45 |
+
value: 0.9661827195467422
|
46 |
+
|
47 |
+
pipeline_tag: token-classification
|
48 |
+
widget:
|
49 |
+
- text: "Jacob Collier is a Grammy awarded artist from England."
|
50 |
+
example_title: "NER Example 1"
|
51 |
+
---
|
52 |
+
# tner/deberta-v3-large-conll2003
|
53 |
+
|
54 |
+
This model is a fine-tuned version of [microsoft/deberta-v3-large](https://huggingface.co/microsoft/deberta-v3-large) on the
|
55 |
+
[tner/conll2003](https://huggingface.co/datasets/tner/conll2003) dataset.
|
56 |
+
Model fine-tuning is done via [T-NER](https://github.com/asahi417/tner)'s hyper-parameter search (see the repository
|
57 |
+
for more detail). It achieves the following results on the test set:
|
58 |
+
- F1 (micro): 0.9222388190844389
|
59 |
+
- Precision (micro): 0.9154020582592011
|
60 |
+
- Recall (micro): 0.9291784702549575
|
61 |
+
- F1 (macro): 0.9043961692086329
|
62 |
+
- Precision (macro): 0.8959854326377331
|
63 |
+
- Recall (macro): 0.9135442454672595
|
64 |
+
|
65 |
+
The per-entity breakdown of the F1 score on the test set are below:
|
66 |
+
- location: 0.9407496977025392
|
67 |
+
- organization: 0.9115486335586247
|
68 |
+
- other: 0.7920110192837466
|
69 |
+
- person: 0.9732753262896209
|
70 |
+
|
71 |
+
For F1 scores, the confidence interval is obtained by bootstrap as below:
|
72 |
+
- F1 (micro):
|
73 |
+
- 90%: [0.9157944386463721, 0.9286928993636353]
|
74 |
+
- 95%: [0.9146558483630953, 0.9297919809412201]
|
75 |
+
- F1 (macro):
|
76 |
+
- 90%: [0.9157944386463721, 0.9286928993636353]
|
77 |
+
- 95%: [0.9146558483630953, 0.9297919809412201]
|
78 |
+
|
79 |
+
Full evaluation can be found at [metric file of NER](https://huggingface.co/tner/deberta-v3-large-conll2003/raw/main/eval/metric.json)
|
80 |
+
and [metric file of entity span](https://huggingface.co/tner/deberta-v3-large-conll2003/raw/main/eval/metric_span.json).
|
81 |
+
|
82 |
+
|
83 |
+
### Training hyperparameters
|
84 |
+
|
85 |
+
The following hyperparameters were used during training:
|
86 |
+
- dataset: ['tner/conll2003']
|
87 |
+
- dataset_split: train
|
88 |
+
- dataset_name: None
|
89 |
+
- local_dataset: None
|
90 |
+
- model: microsoft/deberta-v3-large
|
91 |
+
- crf: False
|
92 |
+
- max_length: 128
|
93 |
+
- epoch: 15
|
94 |
+
- batch_size: 16
|
95 |
+
- lr: 1e-05
|
96 |
+
- random_seed: 42
|
97 |
+
- gradient_accumulation_steps: 4
|
98 |
+
- weight_decay: None
|
99 |
+
- lr_warmup_step_ratio: 0.1
|
100 |
+
- max_grad_norm: 10.0
|
101 |
+
|
102 |
+
The full configuration can be found at [fine-tuning parameter file](https://huggingface.co/tner/deberta-v3-large-conll2003/raw/main/trainer_config.json).
|
103 |
+
|
104 |
+
### Reference
|
105 |
+
If you use any resource from T-NER, please consider to cite our [paper](https://aclanthology.org/2021.eacl-demos.7/).
|
106 |
+
|
107 |
+
```
|
108 |
+
|
109 |
+
@inproceedings{ushio-camacho-collados-2021-ner,
|
110 |
+
title = "{T}-{NER}: An All-Round Python Library for Transformer-based Named Entity Recognition",
|
111 |
+
author = "Ushio, Asahi and
|
112 |
+
Camacho-Collados, Jose",
|
113 |
+
booktitle = "Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: System Demonstrations",
|
114 |
+
month = apr,
|
115 |
+
year = "2021",
|
116 |
+
address = "Online",
|
117 |
+
publisher = "Association for Computational Linguistics",
|
118 |
+
url = "https://aclanthology.org/2021.eacl-demos.7",
|
119 |
+
doi = "10.18653/v1/2021.eacl-demos.7",
|
120 |
+
pages = "53--62",
|
121 |
+
abstract = "Language model (LM) pretraining has led to consistent improvements in many NLP downstream tasks, including named entity recognition (NER). In this paper, we present T-NER (Transformer-based Named Entity Recognition), a Python library for NER LM finetuning. In addition to its practical utility, T-NER facilitates the study and investigation of the cross-domain and cross-lingual generalization ability of LMs finetuned on NER. Our library also provides a web app where users can get model predictions interactively for arbitrary text, which facilitates qualitative model evaluation for non-expert programmers. We show the potential of the library by compiling nine public NER datasets into a unified format and evaluating the cross-domain and cross- lingual performance across the datasets. The results from our initial experiments show that in-domain performance is generally competitive across datasets. However, cross-domain generalization is challenging even with a large pretrained LM, which has nevertheless capacity to learn domain-specific features if fine- tuned on a combined dataset. To facilitate future research, we also release all our LM checkpoints via the Hugging Face model hub.",
|
122 |
+
}
|
123 |
+
|
124 |
+
```
|
config.json
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
{
|
2 |
-
"_name_or_path": "
|
3 |
"architectures": [
|
4 |
"DebertaV2ForTokenClassification"
|
5 |
],
|
@@ -51,7 +51,7 @@
|
|
51 |
"relative_attention": true,
|
52 |
"share_att_key": true,
|
53 |
"torch_dtype": "float32",
|
54 |
-
"transformers_version": "4.
|
55 |
"type_vocab_size": 0,
|
56 |
"vocab_size": 128100
|
57 |
}
|
|
|
1 |
{
|
2 |
+
"_name_or_path": "microsoft/deberta-v3-large",
|
3 |
"architectures": [
|
4 |
"DebertaV2ForTokenClassification"
|
5 |
],
|
|
|
51 |
"relative_attention": true,
|
52 |
"share_att_key": true,
|
53 |
"torch_dtype": "float32",
|
54 |
+
"transformers_version": "4.21.1",
|
55 |
"type_vocab_size": 0,
|
56 |
"vocab_size": 128100
|
57 |
}
|
eval/metric.json
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
{"micro/f1": 0.9222388190844389, "micro/f1_ci": {"90": [0.9157944386463721, 0.9286928993636353], "95": [0.9146558483630953, 0.9297919809412201]}, "micro/recall": 0.9291784702549575, "micro/precision": 0.9154020582592011, "macro/f1": 0.9043961692086329, "macro/f1_ci": {"90": [0.8967634601572929, 0.9120550234663798], "95": [0.8951146833014633, 0.9135073150082113]}, "macro/recall": 0.9135442454672595, "macro/precision": 0.8959854326377331, "per_entity_metric": {"location": {"f1": 0.9407496977025392, "f1_ci": {"90": [0.9327218512678329, 0.9484554935162461], "95": [0.9306220735040278, 0.9500172057211348]}, "precision": 0.948780487804878, "recall": 0.9328537170263789}, "organization": {"f1": 0.9115486335586247, "f1_ci": {"90": [0.9022883361987417, 0.9209639524074142], "95": [0.900931069471536, 0.9230338443865153]}, "precision": 0.8903559127439724, "recall": 0.9337748344370861}, "other": {"f1": 0.7920110192837466, "f1_ci": {"90": [0.7703470703328422, 0.8155099589242811], "95": [0.7655908711257591, 0.819674907814652]}, "precision": 0.7666666666666667, "recall": 0.8190883190883191}, "person": {"f1": 0.9732753262896209, "f1_ci": {"90": [0.9666809784122652, 0.9793078490377144], "95": [0.9648667613328867, 0.9802750787465647]}, "precision": 0.9781386633354153, "recall": 0.9684601113172542}}}
|
eval/metric_span.json
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
{"micro/f1": 0.960570322126386, "micro/f1_ci": {"90": [0.9562602448386762, 0.9649430028068969], "95": [0.9549445046545261, 0.965818354349358]}, "micro/recall": 0.9661827195467422, "micro/precision": 0.9550227511375569, "macro/f1": 0.960570322126386, "macro/f1_ci": {"90": [0.9562602448386762, 0.9649430028068969], "95": [0.9549445046545261, 0.965818354349358]}, "macro/recall": 0.9661827195467422, "macro/precision": 0.9550227511375569}
|
eval/prediction.validation.json
ADDED
The diff for this file is too large to render.
See raw diff
|
|
pytorch_model.bin
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
-
size
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:72241d27925a8a7fbdfa8f15e0257b46d094c2122ba5417741dbd38cf7ffb48c
|
3 |
+
size 1736223023
|
tokenizer.json
CHANGED
The diff for this file is too large to render.
See raw diff
|
|
tokenizer_config.json
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
"do_lower_case": false,
|
5 |
"eos_token": "[SEP]",
|
6 |
"mask_token": "[MASK]",
|
7 |
-
"name_or_path": "
|
8 |
"pad_token": "[PAD]",
|
9 |
"sep_token": "[SEP]",
|
10 |
"sp_model_kwargs": {},
|
|
|
4 |
"do_lower_case": false,
|
5 |
"eos_token": "[SEP]",
|
6 |
"mask_token": "[MASK]",
|
7 |
+
"name_or_path": "microsoft/deberta-v3-large",
|
8 |
"pad_token": "[PAD]",
|
9 |
"sep_token": "[SEP]",
|
10 |
"sp_model_kwargs": {},
|
trainer_config.json
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
{"dataset": ["tner/conll2003"], "dataset_split": "train", "dataset_name": null, "local_dataset": null, "model": "microsoft/deberta-v3-large", "crf": false, "max_length": 128, "epoch": 15, "batch_size": 16, "lr": 1e-05, "random_seed": 42, "gradient_accumulation_steps": 4, "weight_decay": null, "lr_warmup_step_ratio": 0.1, "max_grad_norm": 10.0}
|