File size: 6,684 Bytes
abc9a6e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
---
license: apache-2.0
base_model: google-bert/bert-base-uncased
tags:
- generated_from_trainer
model-index:
- name: bert-base-uncased_legal_ner_finetuned
  results: []
---

<!-- This model card has been generated automatically according to the information the Trainer had access to. You
should probably proofread and complete it, then remove this comment. -->

# bert-base-uncased_legal_ner_finetuned

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.
It achieves the following results on the evaluation set:
- Loss: 0.2878
- Law Precision: 0.7983
- Law Recall: 0.8716
- Law F1: 0.8333
- Law Number: 109
- Violated by Precision: 0.7681
- Violated by Recall: 0.7465
- Violated by F1: 0.7571
- Violated by Number: 71
- Violated on Precision: 0.4143
- Violated on Recall: 0.4143
- Violated on F1: 0.4143
- Violated on Number: 70
- Violation Precision: 0.59
- Violation Recall: 0.6941
- Violation F1: 0.6378
- Violation Number: 425
- Overall Precision: 0.6227
- Overall Recall: 0.6993
- Overall F1: 0.6588
- Overall Accuracy: 0.9462

## Model description

More information needed

## Intended uses & limitations

More information needed

## Training and evaluation data

More information needed

## Training procedure

### Training hyperparameters

The following hyperparameters were used during training:
- learning_rate: 2e-05
- train_batch_size: 8
- eval_batch_size: 8
- seed: 42
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
- lr_scheduler_type: linear
- lr_scheduler_warmup_steps: 500
- num_epochs: 10

### Training results

| 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 |
|:-------------:|:-----:|:----:|:---------------:|:-------------:|:----------:|:------:|:----------:|:---------------------:|:------------------:|:--------------:|:------------------:|:---------------------:|:------------------:|:--------------:|:------------------:|:-------------------:|:----------------:|:------------:|:----------------:|:-----------------:|:--------------:|:----------:|:----------------:|
| 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           |
| 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           |
| 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           |
| 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           |
| 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           |
| 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           |
| 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           |
| 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           |
| 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           |
| 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           |


### Framework versions

- Transformers 4.44.0
- Pytorch 2.4.0
- Datasets 2.21.0
- Tokenizers 0.19.1