qiuhaoalex commited on
Commit
c52e912
·
verified ·
1 Parent(s): d9e0a2d

Fine-tuned BioGPT on ncbi-disease for BIO NER

Browse files
README.md ADDED
@@ -0,0 +1,88 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ library_name: transformers
3
+ license: mit
4
+ base_model: microsoft/biogpt
5
+ tags:
6
+ - generated_from_trainer
7
+ datasets:
8
+ - ncbi_disease
9
+ metrics:
10
+ - precision
11
+ - recall
12
+ - f1
13
+ - accuracy
14
+ model-index:
15
+ - name: mlma_lab7
16
+ results:
17
+ - task:
18
+ name: Token Classification
19
+ type: token-classification
20
+ dataset:
21
+ name: ncbi_disease
22
+ type: ncbi_disease
23
+ config: ncbi_disease
24
+ split: validation
25
+ args: ncbi_disease
26
+ metrics:
27
+ - name: Precision
28
+ type: precision
29
+ value: 0.474835886214442
30
+ - name: Recall
31
+ type: recall
32
+ value: 0.5514612452350699
33
+ - name: F1
34
+ type: f1
35
+ value: 0.5102880658436214
36
+ - name: Accuracy
37
+ type: accuracy
38
+ value: 0.9598648253994744
39
+ ---
40
+
41
+ <!-- This model card has been generated automatically according to the information the Trainer had access to. You
42
+ should probably proofread and complete it, then remove this comment. -->
43
+
44
+ # mlma_lab7
45
+
46
+ This model is a fine-tuned version of [microsoft/biogpt](https://huggingface.co/microsoft/biogpt) on the ncbi_disease dataset.
47
+ It achieves the following results on the evaluation set:
48
+ - Loss: 0.1390
49
+ - Precision: 0.4748
50
+ - Recall: 0.5515
51
+ - F1: 0.5103
52
+ - Accuracy: 0.9599
53
+
54
+ ## Model description
55
+
56
+ More information needed
57
+
58
+ ## Intended uses & limitations
59
+
60
+ More information needed
61
+
62
+ ## Training and evaluation data
63
+
64
+ More information needed
65
+
66
+ ## Training procedure
67
+
68
+ ### Training hyperparameters
69
+
70
+ The following hyperparameters were used during training:
71
+ - learning_rate: 2e-05
72
+ - train_batch_size: 8
73
+ - eval_batch_size: 8
74
+ - seed: 42
75
+ - optimizer: Use OptimizerNames.ADAMW_TORCH with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
76
+ - lr_scheduler_type: linear
77
+ - num_epochs: 3
78
+
79
+ ### Training results
80
+
81
+
82
+
83
+ ### Framework versions
84
+
85
+ - Transformers 4.51.2
86
+ - Pytorch 2.6.0+cu124
87
+ - Datasets 3.5.0
88
+ - Tokenizers 0.21.1
config.json ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "activation_dropout": 0.0,
3
+ "activation_function": "gelu_new",
4
+ "architectures": [
5
+ "GPT2ForTokenClassification"
6
+ ],
7
+ "attention_probs_dropout_prob": 0.1,
8
+ "attn_pdrop": 0.1,
9
+ "bos_token_id": 0,
10
+ "embd_pdrop": 0.1,
11
+ "eos_token_id": 2,
12
+ "hidden_act": "gelu",
13
+ "hidden_dropout_prob": 0.1,
14
+ "id2label": {
15
+ "0": "LABEL_0",
16
+ "1": "LABEL_1",
17
+ "2": "LABEL_2"
18
+ },
19
+ "initializer_range": 0.02,
20
+ "intermediate_size": 4096,
21
+ "label2id": {
22
+ "LABEL_0": 0,
23
+ "LABEL_1": 1,
24
+ "LABEL_2": 2
25
+ },
26
+ "layer_norm_eps": 1e-12,
27
+ "layer_norm_epsilon": 1e-05,
28
+ "layerdrop": 0.0,
29
+ "model_type": "gpt2",
30
+ "n_embd": 1024,
31
+ "n_head": 16,
32
+ "n_inner": null,
33
+ "n_layer": 24,
34
+ "n_positions": 1024,
35
+ "pad_token_id": 1,
36
+ "reorder_and_upcast_attn": false,
37
+ "resid_pdrop": 0.1,
38
+ "scale_attn_by_inverse_layer_idx": false,
39
+ "scale_attn_weights": true,
40
+ "scale_embedding": true,
41
+ "summary_activation": null,
42
+ "summary_first_dropout": 0.1,
43
+ "summary_proj_to_labels": true,
44
+ "summary_type": "cls_index",
45
+ "summary_use_proj": true,
46
+ "torch_dtype": "float32",
47
+ "transformers_version": "4.51.2",
48
+ "use_cache": true,
49
+ "vocab_size": 42384
50
+ }
merges.txt ADDED
The diff for this file is too large to render. See raw diff
 
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:01c13641bc4486bda02022e1a83dc028f28af45e1a1e2bff8468fb74782658b7
3
+ size 1387087524
runs/Apr12_23-02-53_28c35ca65051/events.out.tfevents.1744498976.28c35ca65051.2402.0 ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:a5a49986592eb7f59cd7b0ebc239740724d1b0266cc982e907753fce496249e7
3
+ size 6679
runs/Apr12_23-02-53_28c35ca65051/events.out.tfevents.1744499777.28c35ca65051.2402.1 ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:4353efc635b7cfbe19a0e9f4ef710c53a5bb8ea4a0bce87f7d72939666afb7f6
3
+ size 560
special_tokens_map.json ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ {
2
+ "bos_token": "<s>",
3
+ "eos_token": "</s>",
4
+ "pad_token": "<pad>",
5
+ "sep_token": "</s>",
6
+ "unk_token": "<unk>"
7
+ }
tokenizer_config.json ADDED
@@ -0,0 +1,45 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "added_tokens_decoder": {
3
+ "0": {
4
+ "content": "<s>",
5
+ "lstrip": false,
6
+ "normalized": false,
7
+ "rstrip": false,
8
+ "single_word": false,
9
+ "special": true
10
+ },
11
+ "1": {
12
+ "content": "<pad>",
13
+ "lstrip": false,
14
+ "normalized": false,
15
+ "rstrip": false,
16
+ "single_word": false,
17
+ "special": true
18
+ },
19
+ "2": {
20
+ "content": "</s>",
21
+ "lstrip": false,
22
+ "normalized": false,
23
+ "rstrip": false,
24
+ "single_word": false,
25
+ "special": true
26
+ },
27
+ "3": {
28
+ "content": "<unk>",
29
+ "lstrip": false,
30
+ "normalized": false,
31
+ "rstrip": false,
32
+ "single_word": false,
33
+ "special": true
34
+ }
35
+ },
36
+ "bos_token": "<s>",
37
+ "clean_up_tokenization_spaces": false,
38
+ "eos_token": "</s>",
39
+ "extra_special_tokens": {},
40
+ "model_max_length": 1000000000000000019884624838656,
41
+ "pad_token": "<pad>",
42
+ "sep_token": "</s>",
43
+ "tokenizer_class": "BioGptTokenizer",
44
+ "unk_token": "<unk>"
45
+ }
training_args.bin ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:869aaa2ecb0b94f16aae6228f437b25a15816d742c49e308532ceb6c0da38d4e
3
+ size 5304
vocab.json ADDED
The diff for this file is too large to render. See raw diff