mbruton commited on
Commit
cba3c51
1 Parent(s): cfbe788

Create README.md

Browse files
Files changed (1) hide show
  1. README.md +167 -0
README.md ADDED
@@ -0,0 +1,167 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ datasets:
4
+ - mbruton/galician_srl
5
+ - CoNLL-2012
6
+ - PropBank.Br
7
+ language:
8
+ - gl
9
+ - en
10
+ - pt
11
+ metrics:
12
+ - seqeval
13
+ library_name: transformers
14
+ pipeline_tag: token-classification
15
+ ---
16
+
17
+ # Model Card for GalBERT-enpt for Semantic Role Labeling (cased)
18
+
19
+ This model is fine-tuned on a version of [multilingual BERT](https://huggingface.co/bert-base-multilingual-cased) which is pre-trained on the SRL task for English and Portuguese, and is one of 24 models introduced as part of [this project](https://github.com/mbruton0426/GalicianSRL). Prior to this work, there were no published Galician datasets or models for SRL.
20
+
21
+ ## Model Details
22
+
23
+ ### Model Description
24
+
25
+ GalBERT-enpt for Semantic Role Labeling (SRL) is a transformers model, leveraging mBERT's extensive pretraining on 104 languages to achieve better SRL predictions for low-resource Galician. This model is additionally pre-trained on the SRL task for English and Portuguese. This model is cased: it makes a difference between english and English. It was fine-tuned on Galician with the following objectives:
26
+
27
+ - Identify up to 13 verbal roots within a sentence.
28
+ - Identify available arguments for each verbal root. Due to scarcity of data, this model focused solely on the identification of arguments 0, 1, and 2.
29
+
30
+ Labels are formatted as: r#:tag, where r# links the token to a specific verbal root of index #, and tag identifies the token as the verbal root (root) or an individual argument (arg0/arg1/arg2)
31
+
32
+ - **Developed by:** [Micaella Bruton](mailto:micaellabruton@gmail.com)
33
+ - **Model type:** Transformers
34
+ - **Language(s) (NLP):** Galician (gl), English (en), Portuguese (pt)
35
+ - **License:** Apache 2.0
36
+ - **Finetuned from model:** [English & Portuguese pre-trained multilingual BERT](https://huggingface.co/liaad/srl-enpt_mbert-base)
37
+
38
+ ### Model Sources [optional]
39
+
40
+ <!-- Provide the basic links for the model. -->
41
+
42
+ - **Repository:** [GalicianSRL](https://github.com/mbruton0426/GalicianSRL)
43
+ - **Paper:** To be updated
44
+
45
+ ## Uses
46
+
47
+ This model is intended to be used to develop and improve natural language processing tools for Galician.
48
+
49
+ ## Bias, Risks, and Limitations
50
+
51
+ Galician is a low-resource language which prior to this project lacked a semantic role labeling dataset. As such, the dataset used to train this model is extrememly limited and could benefit from the inclusion of additional sentences and manual validation by native speakers.
52
+
53
+
54
+ ## Training Details
55
+
56
+ ### Training Data
57
+
58
+ This model was pre-trained on both the [OntoNotes 5.0 English SRL corpus](http://catalog.ldc.upenn.edu/LDC2013T19) and the [PropBank.Br Portuguese SRL corpus](http://www.nilc.icmc.usp.br/portlex/index.php/en/projects/propbankbringl).
59
+ This model was fine-tuned on the "train" portion of the [GalicianSRL Dataset](https://huggingface.co/datasets/mbruton/galician_srl) produced as part of this same project.
60
+
61
+ #### Training Hyperparameters
62
+
63
+ - **Learning Rate:** 2e-5
64
+ - **Batch Size:** 16
65
+ - **Weight Decay:** 0.01
66
+ - **Early Stopping:** 10 epochs
67
+
68
+ ## Evaluation
69
+
70
+ #### Testing Data
71
+
72
+ This model was tested on the "test" portion of the [GalicianSRL Dataset](https://huggingface.co/datasets/mbruton/galician_srl) produced as part of this same project.
73
+
74
+ #### Metrics
75
+
76
+ [seqeval](https://huggingface.co/spaces/evaluate-metric/seqeval) is a Python framework for sequence labeling evaluation. It can evaluate the performance of chunking tasks such as named-entity recognition, part-of-speech tagging, and semantic role labeling.
77
+ It supplies scoring both overall and per label type.
78
+
79
+ Overall:
80
+ - `accuracy`: the average [accuracy](https://huggingface.co/metrics/accuracy), on a scale between 0.0 and 1.0.
81
+ - `precision`: the average [precision](https://huggingface.co/metrics/precision), on a scale between 0.0 and 1.0.
82
+ - `recall`: the average [recall](https://huggingface.co/metrics/recall), on a scale between 0.0 and 1.0.
83
+ - `f1`: the average [F1 score](https://huggingface.co/metrics/f1), which is the harmonic mean of the precision and recall. It also has a scale of 0.0 to 1.0.
84
+
85
+ Per label type:
86
+ - `precision`: the average [precision](https://huggingface.co/metrics/precision), on a scale between 0.0 and 1.0.
87
+ - `recall`: the average [recall](https://huggingface.co/metrics/recall), on a scale between 0.0 and 1.0.
88
+ - `f1`: the average [F1 score](https://huggingface.co/metrics/f1), on a scale between 0.0 and 1.0.
89
+
90
+ ### Results
91
+
92
+ | Label | Precision | Recall | f1-score | Support |
93
+ | :----------: | :-------: | :----: | :------: | :-----: |
94
+ | 0:arg0 | 0.75 | 0.71 | 0.73 | 485 |
95
+ | 0:arg1 | 0.68 | 0.72 | 0.70 | 483 |
96
+ | 0:arg2 | 0.71 | 0.73 | 0.72 | 264 |
97
+ | 0:root | 0.93 | 0.93 | 0.93 | 948 |
98
+ | 1:arg0 | 0.66 | 0.62 | 0.64 | 348 |
99
+ | 1:arg1 | 0.70 | 0.67 | 0.69 | 443 |
100
+ | 1:arg2 | 0.66 | 0.58 | 0.62 | 211 |
101
+ | 1:root | 0.87 | 0.84 | 0.86 | 802 |
102
+ | 2:arg0 | 0.61 | 0.52 | 0.56 | 240 |
103
+ | 2:arg1 | 0.62 | 0.61 | 0.61 | 331 |
104
+ | 2:arg2 | 0.57 | 0.51 | 0.54 | 156 |
105
+ | 2:root | 0.77 | 0.79 | 0.78 | 579 |
106
+ | 3:arg0 | 0.45 | 0.45 | 0.45 | 137 |
107
+ | 3:arg1 | 0.52 | 0.52 | 0.52 | 216 |
108
+ | 3:arg2 | 0.52 | 0.45 | 0.48 | 110 |
109
+ | 3:root | 0.71 | 0.70 | 0.70 | 374 |
110
+ | 4:arg0 | 0.48 | 0.46 | 0.47 | 70 |
111
+ | 4:arg1 | 0.46 | 0.46 | 0.46 | 109 |
112
+ | 4:arg2 | 0.44 | 0.56 | 0.49 | 66 |
113
+ | 4:root | 0.61 | 0.66 | 0.63 | 206 |
114
+ | 5:arg0 | 0.23 | 0.35 | 0.28 | 20 |
115
+ | 5:arg1 | 0.35 | 0.60 | 0.44 | 57 |
116
+ | 5:arg2 | 0.38 | 0.21 | 0.27 | 28 |
117
+ | 5:root | 0.55 | 0.52 | 0.53 | 102 |
118
+ | 6:arg0 | 0.33 | 0.08 | 0.12 | 13 |
119
+ | 6:arg1 | 0.25 | 0.08 | 0.12 | 25 |
120
+ | 6:arg2 | 0.00 | 0.00 | 0.00 | 8 |
121
+ | 6:root | 0.32 | 0.38 | 0.35 | 42 |
122
+ | 7:arg0 | 0.00 | 0.00 | 0.00 | 3 |
123
+ | 7:arg1 | 0.00 | 0.00 | 0.00 | 8 |
124
+ | 7:arg2 | 0.00 | 0.00 | 0.00 | 5 |
125
+ | 7:root | 0.00 | 0.00 | 0.00 | 16 |
126
+ | 8:arg0 | 0.00 | 0.00 | 0.00 | 1 |
127
+ | 8:arg1 | 0.00 | 0.00 | 0.00 | 2 |
128
+ | 8:arg2 | 0.00 | 0.00 | 0.00 | 1 |
129
+ | 8:root | 0.00 | 0.00 | 0.00 | 7 |
130
+ | 9:arg0 | 0.00 | 0.00 | 0.00 | 1 |
131
+ | 9:arg1 | 0.00 | 0.00 | 0.00 | 2 |
132
+ | 9:arg2 | 0.00 | 0.00 | 0.00 | 1 |
133
+ | 9:root | 0.00 | 0.00 | 0.00 | 3 |
134
+ | 10:arg1 | 0.00 | 0.00 | 0.00 | 1 |
135
+ | 10:root | 0.00 | 0.00 | 0.00 | 2 |
136
+ | micro avg | 0.71 | 0.69 | 0.70 | 6926 |
137
+ | macro avg | 0.36 | 0.35 | 0.35 | 6926 |
138
+ | weighted avg | 0.70 | 0.69 | 0.70 | 6926 |
139
+ | tot root avg | 0.43 | 0.44 | 0.43 | 3081 |
140
+ | tot A0 avg | 0.35 | 0.32 | 0.33 | 1318 |
141
+ | tot A1 avg | 0.33 | 0.33 | 0.32 | 1677 |
142
+ | tot A2 avg | 0.33 | 0.30 | 0.31 | 850 |
143
+ | tot r0 avg | 0.77 | 0.77 | 0.77 | 2180 |
144
+ | tot r1 avg | 0.72 | 0.68 | 0.70 | 1804 |
145
+ | tot r2 avg | 0.64 | 0.61 | 0.62 | 1306 |
146
+ | tot r3 avg | 0.55 | 0.53 | 0.54 | 837 |
147
+ | tot r4 avg | 0.50 | 0.54 | 0.51 | 451 |
148
+ | tot r5 avg | 0.38 | 0.42 | 0.38 | 207 |
149
+ | tot r6 avg | 0.23 | 0.14 | 0.15 | 88 |
150
+ | tot r7 avg | 0.00 | 0.00 | 0.00 | 32 |
151
+ | tot r8 avg | 0.00 | 0.00 | 0.00 | 11 |
152
+ | tot r9 avg | 0.00 | 0.00 | 0.00 | 7 |
153
+ | tot r10 avg | 0.00 | 0.00 | 0.00 | 3 |
154
+
155
+ ## Citation
156
+
157
+ **BibTeX:**
158
+
159
+ ```
160
+ @mastersthesis{bruton-galician-srl-23,
161
+ author = {Bruton, Micaella},
162
+ title = {BERTie Bott's Every Flavor Labels: A Tasty Guide to Developing a Semantic Role Labeling Model for Galician},
163
+ school = {Uppsala University},
164
+ year = {2023},
165
+ type = {Master's thesis},
166
+ }
167
+ ```