KoichiYasuoka
commited on
Commit
•
a4c7569
1
Parent(s):
91f334c
initial release
Browse files- README.md +39 -0
- config.json +320 -0
- pytorch_model.bin +3 -0
- special_tokens_map.json +37 -0
- supar.model +3 -0
- tokenizer_config.json +67 -0
- vocab.txt +0 -0
README.md
ADDED
@@ -0,0 +1,39 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
language:
|
3 |
+
- "oc"
|
4 |
+
tags:
|
5 |
+
- "occitan"
|
6 |
+
- "token-classification"
|
7 |
+
- "pos"
|
8 |
+
- "dependency-parsing"
|
9 |
+
license: "cc-by-sa-4.0"
|
10 |
+
pipeline_tag: "token-classification"
|
11 |
+
widget:
|
12 |
+
- text: "La mar poiriá encara èsser a la vista."
|
13 |
+
---
|
14 |
+
|
15 |
+
# deberta-small-occitan-upos
|
16 |
+
|
17 |
+
## Model Description
|
18 |
+
|
19 |
+
This is a DeBERTa(V2) model pre-trained with [Tolosa Treebank](https://zenodo.org/records/10569962) for POS-tagging and dependency-parsing, derived from [deberta-small-occitan](https://huggingface.co/KoichiYasuoka/deberta-small-occitan). Every word is tagged by [UPOS](https://universaldependencies.org/u/pos/) (Universal Part-Of-Speech).
|
20 |
+
|
21 |
+
## How to Use
|
22 |
+
|
23 |
+
```py
|
24 |
+
from transformers import AutoTokenizer,AutoModelForTokenClassification
|
25 |
+
tokenizer=AutoTokenizer.from_pretrained("KoichiYasuoka/deberta-small-occitan-upos")
|
26 |
+
model=AutoModelForTokenClassification.from_pretrained("KoichiYasuoka/deberta-small-occitan-upos")
|
27 |
+
```
|
28 |
+
|
29 |
+
or
|
30 |
+
|
31 |
+
```
|
32 |
+
import esupar
|
33 |
+
nlp=esupar.load("KoichiYasuoka/deberta-small-occitan-upos")
|
34 |
+
```
|
35 |
+
|
36 |
+
## See Also
|
37 |
+
|
38 |
+
[esupar](https://github.com/KoichiYasuoka/esupar): Tokenizer POS-tagger and Dependency-parser with BERT/RoBERTa/DeBERTa models
|
39 |
+
|
config.json
ADDED
@@ -0,0 +1,320 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"architectures": [
|
3 |
+
"DebertaV2ForTokenClassification"
|
4 |
+
],
|
5 |
+
"attention_probs_dropout_prob": 0.1,
|
6 |
+
"bos_token_id": 0,
|
7 |
+
"eos_token_id": 2,
|
8 |
+
"hidden_act": "gelu",
|
9 |
+
"hidden_dropout_prob": 0.1,
|
10 |
+
"hidden_size": 256,
|
11 |
+
"id2label": {
|
12 |
+
"0": "ADJ",
|
13 |
+
"1": "ADP",
|
14 |
+
"2": "ADP+DET",
|
15 |
+
"3": "ADV",
|
16 |
+
"4": "AUX",
|
17 |
+
"5": "B-ADJ",
|
18 |
+
"6": "B-ADP",
|
19 |
+
"7": "B-ADP+DET",
|
20 |
+
"8": "B-ADV",
|
21 |
+
"9": "B-AUX",
|
22 |
+
"10": "B-CCONJ",
|
23 |
+
"11": "B-DET",
|
24 |
+
"12": "B-INTJ",
|
25 |
+
"13": "B-NOUN",
|
26 |
+
"14": "B-NUM",
|
27 |
+
"15": "B-PART",
|
28 |
+
"16": "B-PRON",
|
29 |
+
"17": "B-PROPN",
|
30 |
+
"18": "B-PUNCT",
|
31 |
+
"19": "B-SCONJ",
|
32 |
+
"20": "B-VERB",
|
33 |
+
"21": "B-X",
|
34 |
+
"22": "CCONJ",
|
35 |
+
"23": "DET",
|
36 |
+
"24": "I-ADJ",
|
37 |
+
"25": "I-ADP",
|
38 |
+
"26": "I-ADP+DET",
|
39 |
+
"27": "I-ADV",
|
40 |
+
"28": "I-AUX",
|
41 |
+
"29": "I-CCONJ",
|
42 |
+
"30": "I-DET",
|
43 |
+
"31": "I-INTJ",
|
44 |
+
"32": "I-NOUN",
|
45 |
+
"33": "I-NUM",
|
46 |
+
"34": "I-PART",
|
47 |
+
"35": "I-PRON",
|
48 |
+
"36": "I-PROPN",
|
49 |
+
"37": "I-PUNCT",
|
50 |
+
"38": "I-SCONJ",
|
51 |
+
"39": "I-VERB",
|
52 |
+
"40": "I-X",
|
53 |
+
"41": "INTJ",
|
54 |
+
"42": "NOUN",
|
55 |
+
"43": "NUM",
|
56 |
+
"44": "PART",
|
57 |
+
"45": "PRON",
|
58 |
+
"46": "PROPN",
|
59 |
+
"47": "PUNCT",
|
60 |
+
"48": "SCONJ",
|
61 |
+
"49": "SYM",
|
62 |
+
"50": "VERB",
|
63 |
+
"51": "X"
|
64 |
+
},
|
65 |
+
"initializer_range": 0.02,
|
66 |
+
"intermediate_size": 768,
|
67 |
+
"label2id": {
|
68 |
+
"ADJ": 0,
|
69 |
+
"ADP": 1,
|
70 |
+
"ADP+DET": 2,
|
71 |
+
"ADV": 3,
|
72 |
+
"AUX": 4,
|
73 |
+
"B-ADJ": 5,
|
74 |
+
"B-ADP": 6,
|
75 |
+
"B-ADP+DET": 7,
|
76 |
+
"B-ADV": 8,
|
77 |
+
"B-AUX": 9,
|
78 |
+
"B-CCONJ": 10,
|
79 |
+
"B-DET": 11,
|
80 |
+
"B-INTJ": 12,
|
81 |
+
"B-NOUN": 13,
|
82 |
+
"B-NUM": 14,
|
83 |
+
"B-PART": 15,
|
84 |
+
"B-PRON": 16,
|
85 |
+
"B-PROPN": 17,
|
86 |
+
"B-PUNCT": 18,
|
87 |
+
"B-SCONJ": 19,
|
88 |
+
"B-VERB": 20,
|
89 |
+
"B-X": 21,
|
90 |
+
"CCONJ": 22,
|
91 |
+
"DET": 23,
|
92 |
+
"I-ADJ": 24,
|
93 |
+
"I-ADP": 25,
|
94 |
+
"I-ADP+DET": 26,
|
95 |
+
"I-ADV": 27,
|
96 |
+
"I-AUX": 28,
|
97 |
+
"I-CCONJ": 29,
|
98 |
+
"I-DET": 30,
|
99 |
+
"I-INTJ": 31,
|
100 |
+
"I-NOUN": 32,
|
101 |
+
"I-NUM": 33,
|
102 |
+
"I-PART": 34,
|
103 |
+
"I-PRON": 35,
|
104 |
+
"I-PROPN": 36,
|
105 |
+
"I-PUNCT": 37,
|
106 |
+
"I-SCONJ": 38,
|
107 |
+
"I-VERB": 39,
|
108 |
+
"I-X": 40,
|
109 |
+
"INTJ": 41,
|
110 |
+
"NOUN": 42,
|
111 |
+
"NUM": 43,
|
112 |
+
"PART": 44,
|
113 |
+
"PRON": 45,
|
114 |
+
"PROPN": 46,
|
115 |
+
"PUNCT": 47,
|
116 |
+
"SCONJ": 48,
|
117 |
+
"SYM": 49,
|
118 |
+
"VERB": 50,
|
119 |
+
"X": 51
|
120 |
+
},
|
121 |
+
"layer_norm_eps": 1e-07,
|
122 |
+
"max_position_embeddings": 128,
|
123 |
+
"max_relative_positions": -1,
|
124 |
+
"model_type": "deberta-v2",
|
125 |
+
"num_attention_heads": 4,
|
126 |
+
"num_hidden_layers": 12,
|
127 |
+
"pad_token_id": 1,
|
128 |
+
"pooler_dropout": 0,
|
129 |
+
"pooler_hidden_act": "gelu",
|
130 |
+
"pooler_hidden_size": 256,
|
131 |
+
"pos_att_type": [
|
132 |
+
"p2c",
|
133 |
+
"c2p"
|
134 |
+
],
|
135 |
+
"position_biased_input": false,
|
136 |
+
"relative_attention": true,
|
137 |
+
"task_specific_params": {
|
138 |
+
"upos_multiword": {
|
139 |
+
"ADP+DET": {
|
140 |
+
"Al": [
|
141 |
+
"a",
|
142 |
+
"lo"
|
143 |
+
],
|
144 |
+
"Au": [
|
145 |
+
"a",
|
146 |
+
"lo"
|
147 |
+
],
|
148 |
+
"Dau": [
|
149 |
+
"de",
|
150 |
+
"lo"
|
151 |
+
],
|
152 |
+
"Del": [
|
153 |
+
"de",
|
154 |
+
"lo"
|
155 |
+
],
|
156 |
+
"Pel": [
|
157 |
+
"per",
|
158 |
+
"lo"
|
159 |
+
],
|
160 |
+
"Pels": [
|
161 |
+
"per",
|
162 |
+
"los"
|
163 |
+
],
|
164 |
+
"Peu": [
|
165 |
+
"per",
|
166 |
+
"lo"
|
167 |
+
],
|
168 |
+
"Sul": [
|
169 |
+
"sus",
|
170 |
+
"lo"
|
171 |
+
],
|
172 |
+
"Suls": [
|
173 |
+
"sus",
|
174 |
+
"los"
|
175 |
+
],
|
176 |
+
"ai": [
|
177 |
+
"a",
|
178 |
+
"lei"
|
179 |
+
],
|
180 |
+
"ais": [
|
181 |
+
"a",
|
182 |
+
"leis"
|
183 |
+
],
|
184 |
+
"al": [
|
185 |
+
"a",
|
186 |
+
"lo"
|
187 |
+
],
|
188 |
+
"als": [
|
189 |
+
"a",
|
190 |
+
"los"
|
191 |
+
],
|
192 |
+
"ara": [
|
193 |
+
"a",
|
194 |
+
"era"
|
195 |
+
],
|
196 |
+
"ath": [
|
197 |
+
"a",
|
198 |
+
"eth"
|
199 |
+
],
|
200 |
+
"au": [
|
201 |
+
"a",
|
202 |
+
"lo"
|
203 |
+
],
|
204 |
+
"aus": [
|
205 |
+
"a",
|
206 |
+
"los"
|
207 |
+
],
|
208 |
+
"dau": [
|
209 |
+
"de",
|
210 |
+
"lo"
|
211 |
+
],
|
212 |
+
"daus": [
|
213 |
+
"de",
|
214 |
+
"los"
|
215 |
+
],
|
216 |
+
"dei": [
|
217 |
+
"de",
|
218 |
+
"lei"
|
219 |
+
],
|
220 |
+
"del": [
|
221 |
+
"de",
|
222 |
+
"lo"
|
223 |
+
],
|
224 |
+
"dels": [
|
225 |
+
"de",
|
226 |
+
"los"
|
227 |
+
],
|
228 |
+
"dera": [
|
229 |
+
"de",
|
230 |
+
"era"
|
231 |
+
],
|
232 |
+
"deras": [
|
233 |
+
"de",
|
234 |
+
"eras"
|
235 |
+
],
|
236 |
+
"des": [
|
237 |
+
"de",
|
238 |
+
"es"
|
239 |
+
],
|
240 |
+
"deth": [
|
241 |
+
"de",
|
242 |
+
"eth"
|
243 |
+
],
|
244 |
+
"deu": [
|
245 |
+
"de",
|
246 |
+
"lo"
|
247 |
+
],
|
248 |
+
"deus": [
|
249 |
+
"de",
|
250 |
+
"los"
|
251 |
+
],
|
252 |
+
"entau": [
|
253 |
+
"ent\u00e0",
|
254 |
+
"lo"
|
255 |
+
],
|
256 |
+
"entaus": [
|
257 |
+
"ent\u00e0",
|
258 |
+
"los"
|
259 |
+
],
|
260 |
+
"jol": [
|
261 |
+
"jos",
|
262 |
+
"lo"
|
263 |
+
],
|
264 |
+
"jols": [
|
265 |
+
"jos",
|
266 |
+
"los"
|
267 |
+
],
|
268 |
+
"pel": [
|
269 |
+
"per",
|
270 |
+
"lo"
|
271 |
+
],
|
272 |
+
"pels": [
|
273 |
+
"per",
|
274 |
+
"los"
|
275 |
+
],
|
276 |
+
"pera": [
|
277 |
+
"per",
|
278 |
+
"era"
|
279 |
+
],
|
280 |
+
"peth": [
|
281 |
+
"per",
|
282 |
+
"eth"
|
283 |
+
],
|
284 |
+
"peu": [
|
285 |
+
"per",
|
286 |
+
"lo"
|
287 |
+
],
|
288 |
+
"peus": [
|
289 |
+
"per",
|
290 |
+
"los"
|
291 |
+
],
|
292 |
+
"sul": [
|
293 |
+
"sus",
|
294 |
+
"lo"
|
295 |
+
],
|
296 |
+
"suls": [
|
297 |
+
"sus",
|
298 |
+
"los"
|
299 |
+
],
|
300 |
+
"suu": [
|
301 |
+
"sus",
|
302 |
+
"lo"
|
303 |
+
],
|
304 |
+
"tath": [
|
305 |
+
"ta",
|
306 |
+
"eth"
|
307 |
+
],
|
308 |
+
"tau": [
|
309 |
+
"ta",
|
310 |
+
"lo"
|
311 |
+
]
|
312 |
+
}
|
313 |
+
}
|
314 |
+
},
|
315 |
+
"tokenizer_class": "BertTokenizer",
|
316 |
+
"torch_dtype": "float32",
|
317 |
+
"transformers_version": "4.42.4",
|
318 |
+
"type_vocab_size": 0,
|
319 |
+
"vocab_size": 30000
|
320 |
+
}
|
pytorch_model.bin
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:daa0cfbb2240f96bd8366c0c16346822b532021b4ddb8e686afafc3fcfab908f
|
3 |
+
size 69044258
|
special_tokens_map.json
ADDED
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"cls_token": {
|
3 |
+
"content": "[CLS]",
|
4 |
+
"lstrip": false,
|
5 |
+
"normalized": false,
|
6 |
+
"rstrip": false,
|
7 |
+
"single_word": false
|
8 |
+
},
|
9 |
+
"mask_token": {
|
10 |
+
"content": "[MASK]",
|
11 |
+
"lstrip": false,
|
12 |
+
"normalized": false,
|
13 |
+
"rstrip": false,
|
14 |
+
"single_word": false
|
15 |
+
},
|
16 |
+
"pad_token": {
|
17 |
+
"content": "[PAD]",
|
18 |
+
"lstrip": false,
|
19 |
+
"normalized": false,
|
20 |
+
"rstrip": false,
|
21 |
+
"single_word": false
|
22 |
+
},
|
23 |
+
"sep_token": {
|
24 |
+
"content": "[SEP]",
|
25 |
+
"lstrip": false,
|
26 |
+
"normalized": false,
|
27 |
+
"rstrip": false,
|
28 |
+
"single_word": false
|
29 |
+
},
|
30 |
+
"unk_token": {
|
31 |
+
"content": "[UNK]",
|
32 |
+
"lstrip": false,
|
33 |
+
"normalized": false,
|
34 |
+
"rstrip": false,
|
35 |
+
"single_word": false
|
36 |
+
}
|
37 |
+
}
|
supar.model
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:65166e5dd3d9fadc18b907e2b9385fd216b2d751da405f544efc87b8db337c58
|
3 |
+
size 115178818
|
tokenizer_config.json
ADDED
@@ -0,0 +1,67 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"added_tokens_decoder": {
|
3 |
+
"0": {
|
4 |
+
"content": "[CLS]",
|
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": "[SEP]",
|
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 |
+
"4": {
|
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": true,
|
48 |
+
"mask_token": "[MASK]",
|
49 |
+
"max_length": 126,
|
50 |
+
"model_max_length": 128,
|
51 |
+
"never_split": [
|
52 |
+
"[CLS]",
|
53 |
+
"[PAD]",
|
54 |
+
"[SEP]",
|
55 |
+
"[UNK]",
|
56 |
+
"[MASK]"
|
57 |
+
],
|
58 |
+
"pad_token": "[PAD]",
|
59 |
+
"sep_token": "[SEP]",
|
60 |
+
"stride": 0,
|
61 |
+
"strip_accents": false,
|
62 |
+
"tokenize_chinese_chars": true,
|
63 |
+
"tokenizer_class": "BertTokenizer",
|
64 |
+
"truncation_side": "right",
|
65 |
+
"truncation_strategy": "longest_first",
|
66 |
+
"unk_token": "[UNK]"
|
67 |
+
}
|
vocab.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|