khalidrajan commited on
Commit
abc9a6e
1 Parent(s): 8c42e12

End of training

Browse files
README.md ADDED
@@ -0,0 +1,87 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ base_model: google-bert/bert-base-uncased
4
+ tags:
5
+ - generated_from_trainer
6
+ model-index:
7
+ - name: bert-base-uncased_legal_ner_finetuned
8
+ results: []
9
+ ---
10
+
11
+ <!-- This model card has been generated automatically according to the information the Trainer had access to. You
12
+ should probably proofread and complete it, then remove this comment. -->
13
+
14
+ # bert-base-uncased_legal_ner_finetuned
15
+
16
+ This model is a fine-tuned version of [google-bert/bert-base-uncased](https://huggingface.co/google-bert/bert-base-uncased) on an unknown dataset.
17
+ It achieves the following results on the evaluation set:
18
+ - Loss: 0.2878
19
+ - Law Precision: 0.7983
20
+ - Law Recall: 0.8716
21
+ - Law F1: 0.8333
22
+ - Law Number: 109
23
+ - Violated by Precision: 0.7681
24
+ - Violated by Recall: 0.7465
25
+ - Violated by F1: 0.7571
26
+ - Violated by Number: 71
27
+ - Violated on Precision: 0.4143
28
+ - Violated on Recall: 0.4143
29
+ - Violated on F1: 0.4143
30
+ - Violated on Number: 70
31
+ - Violation Precision: 0.59
32
+ - Violation Recall: 0.6941
33
+ - Violation F1: 0.6378
34
+ - Violation Number: 425
35
+ - Overall Precision: 0.6227
36
+ - Overall Recall: 0.6993
37
+ - Overall F1: 0.6588
38
+ - Overall Accuracy: 0.9462
39
+
40
+ ## Model description
41
+
42
+ More information needed
43
+
44
+ ## Intended uses & limitations
45
+
46
+ More information needed
47
+
48
+ ## Training and evaluation data
49
+
50
+ More information needed
51
+
52
+ ## Training procedure
53
+
54
+ ### Training hyperparameters
55
+
56
+ The following hyperparameters were used during training:
57
+ - learning_rate: 2e-05
58
+ - train_batch_size: 8
59
+ - eval_batch_size: 8
60
+ - seed: 42
61
+ - optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
62
+ - lr_scheduler_type: linear
63
+ - lr_scheduler_warmup_steps: 500
64
+ - num_epochs: 10
65
+
66
+ ### Training results
67
+
68
+ | Training Loss | Epoch | Step | Validation Loss | Law Precision | Law Recall | Law F1 | Law Number | Violated by Precision | Violated by Recall | Violated by F1 | Violated by Number | Violated on Precision | Violated on Recall | Violated on F1 | Violated on Number | Violation Precision | Violation Recall | Violation F1 | Violation Number | Overall Precision | Overall Recall | Overall F1 | Overall Accuracy |
69
+ |:-------------:|:-----:|:----:|:---------------:|:-------------:|:----------:|:------:|:----------:|:---------------------:|:------------------:|:--------------:|:------------------:|:---------------------:|:------------------:|:--------------:|:------------------:|:-------------------:|:----------------:|:------------:|:----------------:|:-----------------:|:--------------:|:----------:|:----------------:|
70
+ | No log | 1.0 | 85 | 0.8260 | 0.0 | 0.0 | 0.0 | 109 | 0.0 | 0.0 | 0.0 | 71 | 0.0 | 0.0 | 0.0 | 70 | 0.0 | 0.0 | 0.0 | 425 | 0.0 | 0.0 | 0.0 | 0.7656 |
71
+ | No log | 2.0 | 170 | 0.4451 | 0.0 | 0.0 | 0.0 | 109 | 0.0 | 0.0 | 0.0 | 71 | 0.0 | 0.0 | 0.0 | 70 | 0.1204 | 0.1624 | 0.1383 | 425 | 0.1204 | 0.1022 | 0.1106 | 0.8766 |
72
+ | No log | 3.0 | 255 | 0.3153 | 0.1724 | 0.0917 | 0.1198 | 109 | 0.0 | 0.0 | 0.0 | 71 | 0.0 | 0.0 | 0.0 | 70 | 0.3142 | 0.36 | 0.3355 | 425 | 0.2991 | 0.2415 | 0.2672 | 0.9067 |
73
+ | No log | 4.0 | 340 | 0.2416 | 0.6574 | 0.6514 | 0.6544 | 109 | 0.0 | 0.0 | 0.0 | 71 | 0.16 | 0.0571 | 0.0842 | 70 | 0.4496 | 0.5671 | 0.5016 | 425 | 0.4470 | 0.4681 | 0.4573 | 0.9286 |
74
+ | No log | 5.0 | 425 | 0.2185 | 0.7768 | 0.7982 | 0.7873 | 109 | 0.6491 | 0.5211 | 0.5781 | 71 | 0.3125 | 0.2857 | 0.2985 | 70 | 0.5019 | 0.6329 | 0.5598 | 425 | 0.5371 | 0.6119 | 0.5720 | 0.9412 |
75
+ | 0.5331 | 6.0 | 510 | 0.2399 | 0.6767 | 0.8257 | 0.7438 | 109 | 0.6842 | 0.7324 | 0.7075 | 71 | 0.2841 | 0.3571 | 0.3165 | 70 | 0.5820 | 0.7012 | 0.6361 | 425 | 0.5748 | 0.6889 | 0.6267 | 0.9416 |
76
+ | 0.5331 | 7.0 | 595 | 0.2407 | 0.7603 | 0.8440 | 0.8 | 109 | 0.7286 | 0.7183 | 0.7234 | 71 | 0.4348 | 0.4286 | 0.4317 | 70 | 0.5752 | 0.6753 | 0.6212 | 425 | 0.6061 | 0.6815 | 0.6416 | 0.9441 |
77
+ | 0.5331 | 8.0 | 680 | 0.2610 | 0.7661 | 0.8716 | 0.8155 | 109 | 0.6 | 0.7606 | 0.6708 | 71 | 0.3043 | 0.4 | 0.3457 | 70 | 0.5948 | 0.7012 | 0.6436 | 425 | 0.5886 | 0.7037 | 0.6410 | 0.9428 |
78
+ | 0.5331 | 9.0 | 765 | 0.2790 | 0.744 | 0.8532 | 0.7949 | 109 | 0.8667 | 0.7324 | 0.7939 | 71 | 0.3788 | 0.3571 | 0.3676 | 70 | 0.5812 | 0.6824 | 0.6277 | 425 | 0.6133 | 0.6815 | 0.6456 | 0.9461 |
79
+ | 0.5331 | 10.0 | 850 | 0.2878 | 0.7983 | 0.8716 | 0.8333 | 109 | 0.7681 | 0.7465 | 0.7571 | 71 | 0.4143 | 0.4143 | 0.4143 | 70 | 0.59 | 0.6941 | 0.6378 | 425 | 0.6227 | 0.6993 | 0.6588 | 0.9462 |
80
+
81
+
82
+ ### Framework versions
83
+
84
+ - Transformers 4.44.0
85
+ - Pytorch 2.4.0
86
+ - Datasets 2.21.0
87
+ - Tokenizers 0.19.1
config.json ADDED
@@ -0,0 +1,48 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "google-bert/bert-base-uncased",
3
+ "architectures": [
4
+ "BertForTokenClassification"
5
+ ],
6
+ "attention_probs_dropout_prob": 0.1,
7
+ "classifier_dropout": null,
8
+ "gradient_checkpointing": false,
9
+ "hidden_act": "gelu",
10
+ "hidden_dropout_prob": 0.1,
11
+ "hidden_size": 768,
12
+ "id2label": {
13
+ "0": "O",
14
+ "1": "I-VIOLATED ON",
15
+ "2": "B-VIOLATED BY",
16
+ "3": "B-LAW",
17
+ "4": "I-LAW",
18
+ "5": "I-VIOLATED BY",
19
+ "6": "B-VIOLATED ON",
20
+ "7": "B-VIOLATION",
21
+ "8": "I-VIOLATION"
22
+ },
23
+ "initializer_range": 0.02,
24
+ "intermediate_size": 3072,
25
+ "label2id": {
26
+ "B-LAW": 3,
27
+ "B-VIOLATED BY": 2,
28
+ "B-VIOLATED ON": 6,
29
+ "B-VIOLATION": 7,
30
+ "I-LAW": 4,
31
+ "I-VIOLATED BY": 5,
32
+ "I-VIOLATED ON": 1,
33
+ "I-VIOLATION": 8,
34
+ "O": 0
35
+ },
36
+ "layer_norm_eps": 1e-12,
37
+ "max_position_embeddings": 512,
38
+ "model_type": "bert",
39
+ "num_attention_heads": 12,
40
+ "num_hidden_layers": 12,
41
+ "pad_token_id": 0,
42
+ "position_embedding_type": "absolute",
43
+ "torch_dtype": "float32",
44
+ "transformers_version": "4.44.0",
45
+ "type_vocab_size": 2,
46
+ "use_cache": true,
47
+ "vocab_size": 30522
48
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:94226f271d93c565cd8df828e6c53f17205fe0ca2460cce0f02cd81610661ffb
3
+ size 435617620
runs/Sep06_15-46-41_Khalids-MBP/events.out.tfevents.1725652002.Khalids-MBP.23384.10 ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9b018c2d1b55b77496d0e6f9afd7abe1353d044c6dffd5674d8414a2a8433607
3
+ size 20495
runs/Sep06_15-46-41_Khalids-MBP/events.out.tfevents.1725652939.Khalids-MBP.23384.11 ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ab7c42272d0ffdede599747d9868d40e34f1f42e1c9c42a6245c0683902667d8
3
+ size 1540
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,56 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "add_prefix_space": true,
3
+ "added_tokens_decoder": {
4
+ "0": {
5
+ "content": "[PAD]",
6
+ "lstrip": false,
7
+ "normalized": false,
8
+ "rstrip": false,
9
+ "single_word": false,
10
+ "special": true
11
+ },
12
+ "100": {
13
+ "content": "[UNK]",
14
+ "lstrip": false,
15
+ "normalized": false,
16
+ "rstrip": false,
17
+ "single_word": false,
18
+ "special": true
19
+ },
20
+ "101": {
21
+ "content": "[CLS]",
22
+ "lstrip": false,
23
+ "normalized": false,
24
+ "rstrip": false,
25
+ "single_word": false,
26
+ "special": true
27
+ },
28
+ "102": {
29
+ "content": "[SEP]",
30
+ "lstrip": false,
31
+ "normalized": false,
32
+ "rstrip": false,
33
+ "single_word": false,
34
+ "special": true
35
+ },
36
+ "103": {
37
+ "content": "[MASK]",
38
+ "lstrip": false,
39
+ "normalized": false,
40
+ "rstrip": false,
41
+ "single_word": false,
42
+ "special": true
43
+ }
44
+ },
45
+ "clean_up_tokenization_spaces": true,
46
+ "cls_token": "[CLS]",
47
+ "do_lower_case": true,
48
+ "mask_token": "[MASK]",
49
+ "model_max_length": 512,
50
+ "pad_token": "[PAD]",
51
+ "sep_token": "[SEP]",
52
+ "strip_accents": null,
53
+ "tokenize_chinese_chars": true,
54
+ "tokenizer_class": "BertTokenizer",
55
+ "unk_token": "[UNK]"
56
+ }
training_args.bin ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:025fe6781f5776cf9949381f34ece9b0daa8326141f20badbc1738f14099383d
3
+ size 5240
vocab.txt ADDED
The diff for this file is too large to render. See raw diff