ekaterinatao
commited on
Commit
•
a3119a7
1
Parent(s):
66bbe46
Model save
Browse files- README.md +73 -1
- config.json +126 -0
- model.safetensors +3 -0
- special_tokens_map.json +7 -0
- tokenizer.json +0 -0
- tokenizer_config.json +57 -0
- training_args.bin +3 -0
- vocab.txt +0 -0
README.md
CHANGED
@@ -1,3 +1,75 @@
|
|
1 |
---
|
2 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
---
|
2 |
+
base_model: DeepPavlov/rubert-base-cased
|
3 |
+
tags:
|
4 |
+
- generated_from_trainer
|
5 |
+
metrics:
|
6 |
+
- precision
|
7 |
+
- recall
|
8 |
+
- f1
|
9 |
+
- accuracy
|
10 |
+
model-index:
|
11 |
+
- name: nerel-bio-rubert-base
|
12 |
+
results: []
|
13 |
---
|
14 |
+
|
15 |
+
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
16 |
+
should probably proofread and complete it, then remove this comment. -->
|
17 |
+
|
18 |
+
# nerel-bio-rubert-base
|
19 |
+
|
20 |
+
This model is a fine-tuned version of [DeepPavlov/rubert-base-cased](https://huggingface.co/DeepPavlov/rubert-base-cased) on an unknown dataset.
|
21 |
+
It achieves the following results on the evaluation set:
|
22 |
+
- Loss: 0.6122
|
23 |
+
- Precision: 0.7873
|
24 |
+
- Recall: 0.7882
|
25 |
+
- F1: 0.7878
|
26 |
+
- Accuracy: 0.8601
|
27 |
+
|
28 |
+
## Model description
|
29 |
+
|
30 |
+
More information needed
|
31 |
+
|
32 |
+
## Intended uses & limitations
|
33 |
+
|
34 |
+
More information needed
|
35 |
+
|
36 |
+
## Training and evaluation data
|
37 |
+
|
38 |
+
More information needed
|
39 |
+
|
40 |
+
## Training procedure
|
41 |
+
|
42 |
+
### Training hyperparameters
|
43 |
+
|
44 |
+
The following hyperparameters were used during training:
|
45 |
+
- learning_rate: 5e-05
|
46 |
+
- train_batch_size: 6
|
47 |
+
- eval_batch_size: 6
|
48 |
+
- seed: 64
|
49 |
+
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
50 |
+
- lr_scheduler_type: cosine
|
51 |
+
- lr_scheduler_warmup_ratio: 0.1
|
52 |
+
- num_epochs: 10
|
53 |
+
|
54 |
+
### Training results
|
55 |
+
|
56 |
+
| Training Loss | Epoch | Step | Validation Loss | Precision | Recall | F1 | Accuracy |
|
57 |
+
|:-------------:|:-----:|:----:|:---------------:|:---------:|:------:|:------:|:--------:|
|
58 |
+
| No log | 1.0 | 102 | 1.1211 | 0.6196 | 0.5809 | 0.5996 | 0.7125 |
|
59 |
+
| No log | 2.0 | 204 | 0.6800 | 0.7333 | 0.7165 | 0.7248 | 0.8137 |
|
60 |
+
| No log | 3.0 | 306 | 0.5985 | 0.7445 | 0.7488 | 0.7466 | 0.8303 |
|
61 |
+
| No log | 4.0 | 408 | 0.5673 | 0.7608 | 0.7622 | 0.7615 | 0.8402 |
|
62 |
+
| 0.7954 | 5.0 | 510 | 0.5665 | 0.7751 | 0.7702 | 0.7726 | 0.8485 |
|
63 |
+
| 0.7954 | 6.0 | 612 | 0.5934 | 0.7826 | 0.7742 | 0.7784 | 0.8544 |
|
64 |
+
| 0.7954 | 7.0 | 714 | 0.5804 | 0.7795 | 0.7751 | 0.7773 | 0.8527 |
|
65 |
+
| 0.7954 | 8.0 | 816 | 0.6075 | 0.7839 | 0.7878 | 0.7858 | 0.8577 |
|
66 |
+
| 0.7954 | 9.0 | 918 | 0.6139 | 0.7887 | 0.7889 | 0.7888 | 0.8614 |
|
67 |
+
| 0.1024 | 10.0 | 1020 | 0.6122 | 0.7873 | 0.7882 | 0.7878 | 0.8601 |
|
68 |
+
|
69 |
+
|
70 |
+
### Framework versions
|
71 |
+
|
72 |
+
- Transformers 4.37.2
|
73 |
+
- Pytorch 2.1.0+cu121
|
74 |
+
- Datasets 2.17.1
|
75 |
+
- Tokenizers 0.15.2
|
config.json
ADDED
@@ -0,0 +1,126 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"_name_or_path": "DeepPavlov/rubert-base-cased",
|
3 |
+
"architectures": [
|
4 |
+
"BertForTokenClassification"
|
5 |
+
],
|
6 |
+
"attention_probs_dropout_prob": 0.1,
|
7 |
+
"classifier_dropout": null,
|
8 |
+
"directionality": "bidi",
|
9 |
+
"hidden_act": "gelu",
|
10 |
+
"hidden_dropout_prob": 0.1,
|
11 |
+
"hidden_size": 768,
|
12 |
+
"id2label": {
|
13 |
+
"0": "ACTIVITY",
|
14 |
+
"1": "ADMINISTRATION_ROUTE",
|
15 |
+
"2": "ANATOMY",
|
16 |
+
"3": "CHEM",
|
17 |
+
"4": "DEVICE",
|
18 |
+
"5": "DISO",
|
19 |
+
"6": "FINDING",
|
20 |
+
"7": "FOOD",
|
21 |
+
"8": "GENE",
|
22 |
+
"9": "INJURY_POISONING",
|
23 |
+
"10": "HEALTH_CARE_ACTIVITY",
|
24 |
+
"11": "LABPROC",
|
25 |
+
"12": "LIVB",
|
26 |
+
"13": "MEDPROC",
|
27 |
+
"14": "MENTALPROC",
|
28 |
+
"15": "PHYS",
|
29 |
+
"16": "SCIPROC",
|
30 |
+
"17": "AGE",
|
31 |
+
"18": "CITY",
|
32 |
+
"19": "COUNTRY",
|
33 |
+
"20": "DATE",
|
34 |
+
"21": "DISTRICT",
|
35 |
+
"22": "EVENT",
|
36 |
+
"23": "FAMILY",
|
37 |
+
"24": "FACILITY",
|
38 |
+
"25": "LOCATION",
|
39 |
+
"26": "MONEY",
|
40 |
+
"27": "NATIONALITY",
|
41 |
+
"28": "NUMBER",
|
42 |
+
"29": "ORDINAL",
|
43 |
+
"30": "ORGANIZATION",
|
44 |
+
"31": "PERCENT",
|
45 |
+
"32": "PERSON",
|
46 |
+
"33": "PRODUCT",
|
47 |
+
"34": "PROFESSION",
|
48 |
+
"35": "STATE_OR_PROVINCE",
|
49 |
+
"36": "TIME",
|
50 |
+
"37": "AWARD",
|
51 |
+
"38": "CRIME",
|
52 |
+
"39": "IDEOLOGY",
|
53 |
+
"40": "LANGUAGE",
|
54 |
+
"41": "LAW",
|
55 |
+
"42": "PENALTY",
|
56 |
+
"43": "RELIGION",
|
57 |
+
"44": "WORK_OF_ART"
|
58 |
+
},
|
59 |
+
"initializer_range": 0.02,
|
60 |
+
"intermediate_size": 3072,
|
61 |
+
"label2id": {
|
62 |
+
"ACTIVITY": 0,
|
63 |
+
"ADMINISTRATION_ROUTE": 1,
|
64 |
+
"AGE": 17,
|
65 |
+
"ANATOMY": 2,
|
66 |
+
"AWARD": 37,
|
67 |
+
"CHEM": 3,
|
68 |
+
"CITY": 18,
|
69 |
+
"COUNTRY": 19,
|
70 |
+
"CRIME": 38,
|
71 |
+
"DATE": 20,
|
72 |
+
"DEVICE": 4,
|
73 |
+
"DISO": 5,
|
74 |
+
"DISTRICT": 21,
|
75 |
+
"EVENT": 22,
|
76 |
+
"FACILITY": 24,
|
77 |
+
"FAMILY": 23,
|
78 |
+
"FINDING": 6,
|
79 |
+
"FOOD": 7,
|
80 |
+
"GENE": 8,
|
81 |
+
"HEALTH_CARE_ACTIVITY": 10,
|
82 |
+
"IDEOLOGY": 39,
|
83 |
+
"INJURY_POISONING": 9,
|
84 |
+
"LABPROC": 11,
|
85 |
+
"LANGUAGE": 40,
|
86 |
+
"LAW": 41,
|
87 |
+
"LIVB": 12,
|
88 |
+
"LOCATION": 25,
|
89 |
+
"MEDPROC": 13,
|
90 |
+
"MENTALPROC": 14,
|
91 |
+
"MONEY": 26,
|
92 |
+
"NATIONALITY": 27,
|
93 |
+
"NUMBER": 28,
|
94 |
+
"ORDINAL": 29,
|
95 |
+
"ORGANIZATION": 30,
|
96 |
+
"PENALTY": 42,
|
97 |
+
"PERCENT": 31,
|
98 |
+
"PERSON": 32,
|
99 |
+
"PHYS": 15,
|
100 |
+
"PRODUCT": 33,
|
101 |
+
"PROFESSION": 34,
|
102 |
+
"RELIGION": 43,
|
103 |
+
"SCIPROC": 16,
|
104 |
+
"STATE_OR_PROVINCE": 35,
|
105 |
+
"TIME": 36,
|
106 |
+
"WORK_OF_ART": 44
|
107 |
+
},
|
108 |
+
"layer_norm_eps": 1e-12,
|
109 |
+
"max_position_embeddings": 512,
|
110 |
+
"model_type": "bert",
|
111 |
+
"num_attention_heads": 12,
|
112 |
+
"num_hidden_layers": 12,
|
113 |
+
"output_past": true,
|
114 |
+
"pad_token_id": 0,
|
115 |
+
"pooler_fc_size": 768,
|
116 |
+
"pooler_num_attention_heads": 12,
|
117 |
+
"pooler_num_fc_layers": 3,
|
118 |
+
"pooler_size_per_head": 128,
|
119 |
+
"pooler_type": "first_token_transform",
|
120 |
+
"position_embedding_type": "absolute",
|
121 |
+
"torch_dtype": "float32",
|
122 |
+
"transformers_version": "4.37.2",
|
123 |
+
"type_vocab_size": 2,
|
124 |
+
"use_cache": true,
|
125 |
+
"vocab_size": 119547
|
126 |
+
}
|
model.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:04b8c1e01f12c1d813c2b5a3be48d4c82e77325b3ac3ba8c3bbb7026981f894e
|
3 |
+
size 709213172
|
special_tokens_map.json
ADDED
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"cls_token": "[CLS]",
|
3 |
+
"mask_token": "[MASK]",
|
4 |
+
"pad_token": "[PAD]",
|
5 |
+
"sep_token": "[SEP]",
|
6 |
+
"unk_token": "[UNK]"
|
7 |
+
}
|
tokenizer.json
ADDED
The diff for this file is too large to render.
See raw diff
|
|
tokenizer_config.json
ADDED
@@ -0,0 +1,57 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"added_tokens_decoder": {
|
3 |
+
"0": {
|
4 |
+
"content": "[PAD]",
|
5 |
+
"lstrip": false,
|
6 |
+
"normalized": false,
|
7 |
+
"rstrip": false,
|
8 |
+
"single_word": false,
|
9 |
+
"special": true
|
10 |
+
},
|
11 |
+
"100": {
|
12 |
+
"content": "[UNK]",
|
13 |
+
"lstrip": false,
|
14 |
+
"normalized": false,
|
15 |
+
"rstrip": false,
|
16 |
+
"single_word": false,
|
17 |
+
"special": true
|
18 |
+
},
|
19 |
+
"101": {
|
20 |
+
"content": "[CLS]",
|
21 |
+
"lstrip": false,
|
22 |
+
"normalized": false,
|
23 |
+
"rstrip": false,
|
24 |
+
"single_word": false,
|
25 |
+
"special": true
|
26 |
+
},
|
27 |
+
"102": {
|
28 |
+
"content": "[SEP]",
|
29 |
+
"lstrip": false,
|
30 |
+
"normalized": false,
|
31 |
+
"rstrip": false,
|
32 |
+
"single_word": false,
|
33 |
+
"special": true
|
34 |
+
},
|
35 |
+
"103": {
|
36 |
+
"content": "[MASK]",
|
37 |
+
"lstrip": false,
|
38 |
+
"normalized": false,
|
39 |
+
"rstrip": false,
|
40 |
+
"single_word": false,
|
41 |
+
"special": true
|
42 |
+
}
|
43 |
+
},
|
44 |
+
"clean_up_tokenization_spaces": true,
|
45 |
+
"cls_token": "[CLS]",
|
46 |
+
"do_basic_tokenize": true,
|
47 |
+
"do_lower_case": false,
|
48 |
+
"mask_token": "[MASK]",
|
49 |
+
"model_max_length": 1000000000000000019884624838656,
|
50 |
+
"never_split": null,
|
51 |
+
"pad_token": "[PAD]",
|
52 |
+
"sep_token": "[SEP]",
|
53 |
+
"strip_accents": null,
|
54 |
+
"tokenize_chinese_chars": true,
|
55 |
+
"tokenizer_class": "BertTokenizer",
|
56 |
+
"unk_token": "[UNK]"
|
57 |
+
}
|
training_args.bin
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:20330b91e10e32ef02c424109a957253884223c3bd4062ec20f5b527c2b5c82a
|
3 |
+
size 4728
|
vocab.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|