samuellau0802
commited on
Commit
•
0400a39
1
Parent(s):
791b15d
Add new SentenceTransformer model
Browse files- 1_Pooling/config.json +10 -0
- README.md +691 -0
- config.json +26 -0
- config_sentence_transformers.json +10 -0
- model.safetensors +3 -0
- modules.json +20 -0
- sentence_bert_config.json +4 -0
- special_tokens_map.json +37 -0
- tokenizer.json +0 -0
- tokenizer_config.json +64 -0
- vocab.txt +0 -0
1_Pooling/config.json
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"word_embedding_dimension": 384,
|
3 |
+
"pooling_mode_cls_token": false,
|
4 |
+
"pooling_mode_mean_tokens": true,
|
5 |
+
"pooling_mode_max_tokens": false,
|
6 |
+
"pooling_mode_mean_sqrt_len_tokens": false,
|
7 |
+
"pooling_mode_weightedmean_tokens": false,
|
8 |
+
"pooling_mode_lasttoken": false,
|
9 |
+
"include_prompt": true
|
10 |
+
}
|
README.md
ADDED
@@ -0,0 +1,691 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
base_model: sentence-transformers/all-MiniLM-L6-v2
|
3 |
+
library_name: sentence-transformers
|
4 |
+
metrics:
|
5 |
+
- cosine_accuracy
|
6 |
+
- cosine_accuracy_threshold
|
7 |
+
- cosine_f1
|
8 |
+
- cosine_f1_threshold
|
9 |
+
- cosine_precision
|
10 |
+
- cosine_recall
|
11 |
+
- cosine_ap
|
12 |
+
- dot_accuracy
|
13 |
+
- dot_accuracy_threshold
|
14 |
+
- dot_f1
|
15 |
+
- dot_f1_threshold
|
16 |
+
- dot_precision
|
17 |
+
- dot_recall
|
18 |
+
- dot_ap
|
19 |
+
- manhattan_accuracy
|
20 |
+
- manhattan_accuracy_threshold
|
21 |
+
- manhattan_f1
|
22 |
+
- manhattan_f1_threshold
|
23 |
+
- manhattan_precision
|
24 |
+
- manhattan_recall
|
25 |
+
- manhattan_ap
|
26 |
+
- euclidean_accuracy
|
27 |
+
- euclidean_accuracy_threshold
|
28 |
+
- euclidean_f1
|
29 |
+
- euclidean_f1_threshold
|
30 |
+
- euclidean_precision
|
31 |
+
- euclidean_recall
|
32 |
+
- euclidean_ap
|
33 |
+
- max_accuracy
|
34 |
+
- max_accuracy_threshold
|
35 |
+
- max_f1
|
36 |
+
- max_f1_threshold
|
37 |
+
- max_precision
|
38 |
+
- max_recall
|
39 |
+
- max_ap
|
40 |
+
pipeline_tag: sentence-similarity
|
41 |
+
tags:
|
42 |
+
- sentence-transformers
|
43 |
+
- sentence-similarity
|
44 |
+
- feature-extraction
|
45 |
+
- generated_from_trainer
|
46 |
+
- dataset_size:4505
|
47 |
+
- loss:OnlineContrastiveLoss
|
48 |
+
widget:
|
49 |
+
- source_sentence: Greektown on the Danforth
|
50 |
+
sentences:
|
51 |
+
- Gregarious
|
52 |
+
- Gregarious
|
53 |
+
- Gregarious
|
54 |
+
- source_sentence: Temple of the Emerald Buddha (Wat Phra Kaew)
|
55 |
+
sentences:
|
56 |
+
- Respectful
|
57 |
+
- Uninterested
|
58 |
+
- Respectful
|
59 |
+
- source_sentence: Natureland Liat Towers
|
60 |
+
sentences:
|
61 |
+
- Careless
|
62 |
+
- Disinterested
|
63 |
+
- Aggressive
|
64 |
+
- source_sentence: Old Town
|
65 |
+
sentences:
|
66 |
+
- Reserved
|
67 |
+
- Laid-back
|
68 |
+
- Callous
|
69 |
+
- source_sentence: Khaosan Road
|
70 |
+
sentences:
|
71 |
+
- Adventurous
|
72 |
+
- Adventurous
|
73 |
+
- Reserved
|
74 |
+
model-index:
|
75 |
+
- name: SentenceTransformer based on sentence-transformers/all-MiniLM-L6-v2
|
76 |
+
results:
|
77 |
+
- task:
|
78 |
+
type: binary-classification
|
79 |
+
name: Binary Classification
|
80 |
+
dataset:
|
81 |
+
name: Unknown
|
82 |
+
type: unknown
|
83 |
+
metrics:
|
84 |
+
- type: cosine_accuracy
|
85 |
+
value: 0.9573712255772646
|
86 |
+
name: Cosine Accuracy
|
87 |
+
- type: cosine_accuracy_threshold
|
88 |
+
value: 0.8162947297096252
|
89 |
+
name: Cosine Accuracy Threshold
|
90 |
+
- type: cosine_f1
|
91 |
+
value: 0.958041958041958
|
92 |
+
name: Cosine F1
|
93 |
+
- type: cosine_f1_threshold
|
94 |
+
value: 0.8131216764450073
|
95 |
+
name: Cosine F1 Threshold
|
96 |
+
- type: cosine_precision
|
97 |
+
value: 0.9681978798586572
|
98 |
+
name: Cosine Precision
|
99 |
+
- type: cosine_recall
|
100 |
+
value: 0.9480968858131488
|
101 |
+
name: Cosine Recall
|
102 |
+
- type: cosine_ap
|
103 |
+
value: 0.9909492524224418
|
104 |
+
name: Cosine Ap
|
105 |
+
- type: dot_accuracy
|
106 |
+
value: 0.9573712255772646
|
107 |
+
name: Dot Accuracy
|
108 |
+
- type: dot_accuracy_threshold
|
109 |
+
value: 0.8162947297096252
|
110 |
+
name: Dot Accuracy Threshold
|
111 |
+
- type: dot_f1
|
112 |
+
value: 0.958041958041958
|
113 |
+
name: Dot F1
|
114 |
+
- type: dot_f1_threshold
|
115 |
+
value: 0.8131217360496521
|
116 |
+
name: Dot F1 Threshold
|
117 |
+
- type: dot_precision
|
118 |
+
value: 0.9681978798586572
|
119 |
+
name: Dot Precision
|
120 |
+
- type: dot_recall
|
121 |
+
value: 0.9480968858131488
|
122 |
+
name: Dot Recall
|
123 |
+
- type: dot_ap
|
124 |
+
value: 0.9909492524224418
|
125 |
+
name: Dot Ap
|
126 |
+
- type: manhattan_accuracy
|
127 |
+
value: 0.9609236234458259
|
128 |
+
name: Manhattan Accuracy
|
129 |
+
- type: manhattan_accuracy_threshold
|
130 |
+
value: 9.564813613891602
|
131 |
+
name: Manhattan Accuracy Threshold
|
132 |
+
- type: manhattan_f1
|
133 |
+
value: 0.9619377162629758
|
134 |
+
name: Manhattan F1
|
135 |
+
- type: manhattan_f1_threshold
|
136 |
+
value: 9.564813613891602
|
137 |
+
name: Manhattan F1 Threshold
|
138 |
+
- type: manhattan_precision
|
139 |
+
value: 0.9619377162629758
|
140 |
+
name: Manhattan Precision
|
141 |
+
- type: manhattan_recall
|
142 |
+
value: 0.9619377162629758
|
143 |
+
name: Manhattan Recall
|
144 |
+
- type: manhattan_ap
|
145 |
+
value: 0.9908734681022205
|
146 |
+
name: Manhattan Ap
|
147 |
+
- type: euclidean_accuracy
|
148 |
+
value: 0.9573712255772646
|
149 |
+
name: Euclidean Accuracy
|
150 |
+
- type: euclidean_accuracy_threshold
|
151 |
+
value: 0.6061439514160156
|
152 |
+
name: Euclidean Accuracy Threshold
|
153 |
+
- type: euclidean_f1
|
154 |
+
value: 0.958041958041958
|
155 |
+
name: Euclidean F1
|
156 |
+
- type: euclidean_f1_threshold
|
157 |
+
value: 0.6113559007644653
|
158 |
+
name: Euclidean F1 Threshold
|
159 |
+
- type: euclidean_precision
|
160 |
+
value: 0.9681978798586572
|
161 |
+
name: Euclidean Precision
|
162 |
+
- type: euclidean_recall
|
163 |
+
value: 0.9480968858131488
|
164 |
+
name: Euclidean Recall
|
165 |
+
- type: euclidean_ap
|
166 |
+
value: 0.9909492524224418
|
167 |
+
name: Euclidean Ap
|
168 |
+
- type: max_accuracy
|
169 |
+
value: 0.9609236234458259
|
170 |
+
name: Max Accuracy
|
171 |
+
- type: max_accuracy_threshold
|
172 |
+
value: 9.564813613891602
|
173 |
+
name: Max Accuracy Threshold
|
174 |
+
- type: max_f1
|
175 |
+
value: 0.9619377162629758
|
176 |
+
name: Max F1
|
177 |
+
- type: max_f1_threshold
|
178 |
+
value: 9.564813613891602
|
179 |
+
name: Max F1 Threshold
|
180 |
+
- type: max_precision
|
181 |
+
value: 0.9681978798586572
|
182 |
+
name: Max Precision
|
183 |
+
- type: max_recall
|
184 |
+
value: 0.9619377162629758
|
185 |
+
name: Max Recall
|
186 |
+
- type: max_ap
|
187 |
+
value: 0.9909492524224418
|
188 |
+
name: Max Ap
|
189 |
+
- task:
|
190 |
+
type: binary-classification
|
191 |
+
name: Binary Classification
|
192 |
+
dataset:
|
193 |
+
name: test
|
194 |
+
type: test
|
195 |
+
metrics:
|
196 |
+
- type: cosine_accuracy
|
197 |
+
value: 0.9592198581560284
|
198 |
+
name: Cosine Accuracy
|
199 |
+
- type: cosine_accuracy_threshold
|
200 |
+
value: 0.7969272136688232
|
201 |
+
name: Cosine Accuracy Threshold
|
202 |
+
- type: cosine_f1
|
203 |
+
value: 0.9591474245115454
|
204 |
+
name: Cosine F1
|
205 |
+
- type: cosine_f1_threshold
|
206 |
+
value: 0.7969272136688232
|
207 |
+
name: Cosine F1 Threshold
|
208 |
+
- type: cosine_precision
|
209 |
+
value: 0.9574468085106383
|
210 |
+
name: Cosine Precision
|
211 |
+
- type: cosine_recall
|
212 |
+
value: 0.9608540925266904
|
213 |
+
name: Cosine Recall
|
214 |
+
- type: cosine_ap
|
215 |
+
value: 0.9877694290490489
|
216 |
+
name: Cosine Ap
|
217 |
+
- type: dot_accuracy
|
218 |
+
value: 0.9592198581560284
|
219 |
+
name: Dot Accuracy
|
220 |
+
- type: dot_accuracy_threshold
|
221 |
+
value: 0.7969271540641785
|
222 |
+
name: Dot Accuracy Threshold
|
223 |
+
- type: dot_f1
|
224 |
+
value: 0.9591474245115454
|
225 |
+
name: Dot F1
|
226 |
+
- type: dot_f1_threshold
|
227 |
+
value: 0.7969271540641785
|
228 |
+
name: Dot F1 Threshold
|
229 |
+
- type: dot_precision
|
230 |
+
value: 0.9574468085106383
|
231 |
+
name: Dot Precision
|
232 |
+
- type: dot_recall
|
233 |
+
value: 0.9608540925266904
|
234 |
+
name: Dot Recall
|
235 |
+
- type: dot_ap
|
236 |
+
value: 0.9877694290490489
|
237 |
+
name: Dot Ap
|
238 |
+
- type: manhattan_accuracy
|
239 |
+
value: 0.9556737588652482
|
240 |
+
name: Manhattan Accuracy
|
241 |
+
- type: manhattan_accuracy_threshold
|
242 |
+
value: 9.808526992797852
|
243 |
+
name: Manhattan Accuracy Threshold
|
244 |
+
- type: manhattan_f1
|
245 |
+
value: 0.9557522123893805
|
246 |
+
name: Manhattan F1
|
247 |
+
- type: manhattan_f1_threshold
|
248 |
+
value: 9.917011260986328
|
249 |
+
name: Manhattan F1 Threshold
|
250 |
+
- type: manhattan_precision
|
251 |
+
value: 0.9507042253521126
|
252 |
+
name: Manhattan Precision
|
253 |
+
- type: manhattan_recall
|
254 |
+
value: 0.9608540925266904
|
255 |
+
name: Manhattan Recall
|
256 |
+
- type: manhattan_ap
|
257 |
+
value: 0.9866404317968996
|
258 |
+
name: Manhattan Ap
|
259 |
+
- type: euclidean_accuracy
|
260 |
+
value: 0.9592198581560284
|
261 |
+
name: Euclidean Accuracy
|
262 |
+
- type: euclidean_accuracy_threshold
|
263 |
+
value: 0.6372953653335571
|
264 |
+
name: Euclidean Accuracy Threshold
|
265 |
+
- type: euclidean_f1
|
266 |
+
value: 0.9591474245115454
|
267 |
+
name: Euclidean F1
|
268 |
+
- type: euclidean_f1_threshold
|
269 |
+
value: 0.6372953653335571
|
270 |
+
name: Euclidean F1 Threshold
|
271 |
+
- type: euclidean_precision
|
272 |
+
value: 0.9574468085106383
|
273 |
+
name: Euclidean Precision
|
274 |
+
- type: euclidean_recall
|
275 |
+
value: 0.9608540925266904
|
276 |
+
name: Euclidean Recall
|
277 |
+
- type: euclidean_ap
|
278 |
+
value: 0.9877694290490489
|
279 |
+
name: Euclidean Ap
|
280 |
+
- type: max_accuracy
|
281 |
+
value: 0.9592198581560284
|
282 |
+
name: Max Accuracy
|
283 |
+
- type: max_accuracy_threshold
|
284 |
+
value: 9.808526992797852
|
285 |
+
name: Max Accuracy Threshold
|
286 |
+
- type: max_f1
|
287 |
+
value: 0.9591474245115454
|
288 |
+
name: Max F1
|
289 |
+
- type: max_f1_threshold
|
290 |
+
value: 9.917011260986328
|
291 |
+
name: Max F1 Threshold
|
292 |
+
- type: max_precision
|
293 |
+
value: 0.9574468085106383
|
294 |
+
name: Max Precision
|
295 |
+
- type: max_recall
|
296 |
+
value: 0.9608540925266904
|
297 |
+
name: Max Recall
|
298 |
+
- type: max_ap
|
299 |
+
value: 0.9877694290490489
|
300 |
+
name: Max Ap
|
301 |
+
---
|
302 |
+
|
303 |
+
# SentenceTransformer based on sentence-transformers/all-MiniLM-L6-v2
|
304 |
+
|
305 |
+
This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [sentence-transformers/all-MiniLM-L6-v2](https://huggingface.co/sentence-transformers/all-MiniLM-L6-v2). It maps sentences & paragraphs to a 384-dimensional dense vector space and can be used for semantic textual similarity, semantic search, paraphrase mining, text classification, clustering, and more.
|
306 |
+
|
307 |
+
## Model Details
|
308 |
+
|
309 |
+
### Model Description
|
310 |
+
- **Model Type:** Sentence Transformer
|
311 |
+
- **Base model:** [sentence-transformers/all-MiniLM-L6-v2](https://huggingface.co/sentence-transformers/all-MiniLM-L6-v2) <!-- at revision fa97f6e7cb1a59073dff9e6b13e2715cf7475ac9 -->
|
312 |
+
- **Maximum Sequence Length:** 256 tokens
|
313 |
+
- **Output Dimensionality:** 384 tokens
|
314 |
+
- **Similarity Function:** Cosine Similarity
|
315 |
+
<!-- - **Training Dataset:** Unknown -->
|
316 |
+
<!-- - **Language:** Unknown -->
|
317 |
+
<!-- - **License:** Unknown -->
|
318 |
+
|
319 |
+
### Model Sources
|
320 |
+
|
321 |
+
- **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
|
322 |
+
- **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
|
323 |
+
- **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
|
324 |
+
|
325 |
+
### Full Model Architecture
|
326 |
+
|
327 |
+
```
|
328 |
+
SentenceTransformer(
|
329 |
+
(0): Transformer({'max_seq_length': 256, 'do_lower_case': False}) with Transformer model: BertModel
|
330 |
+
(1): Pooling({'word_embedding_dimension': 384, 'pooling_mode_cls_token': False, 'pooling_mode_mean_tokens': True, 'pooling_mode_max_tokens': False, 'pooling_mode_mean_sqrt_len_tokens': False, 'pooling_mode_weightedmean_tokens': False, 'pooling_mode_lasttoken': False, 'include_prompt': True})
|
331 |
+
(2): Normalize()
|
332 |
+
)
|
333 |
+
```
|
334 |
+
|
335 |
+
## Usage
|
336 |
+
|
337 |
+
### Direct Usage (Sentence Transformers)
|
338 |
+
|
339 |
+
First install the Sentence Transformers library:
|
340 |
+
|
341 |
+
```bash
|
342 |
+
pip install -U sentence-transformers
|
343 |
+
```
|
344 |
+
|
345 |
+
Then you can load this model and run inference.
|
346 |
+
```python
|
347 |
+
from sentence_transformers import SentenceTransformer
|
348 |
+
|
349 |
+
# Download from the 🤗 Hub
|
350 |
+
model = SentenceTransformer("overfitting-co/A2P-constrastive-all")
|
351 |
+
# Run inference
|
352 |
+
sentences = [
|
353 |
+
'Khaosan Road',
|
354 |
+
'Reserved',
|
355 |
+
'Adventurous',
|
356 |
+
]
|
357 |
+
embeddings = model.encode(sentences)
|
358 |
+
print(embeddings.shape)
|
359 |
+
# [3, 384]
|
360 |
+
|
361 |
+
# Get the similarity scores for the embeddings
|
362 |
+
similarities = model.similarity(embeddings, embeddings)
|
363 |
+
print(similarities.shape)
|
364 |
+
# [3, 3]
|
365 |
+
```
|
366 |
+
|
367 |
+
<!--
|
368 |
+
### Direct Usage (Transformers)
|
369 |
+
|
370 |
+
<details><summary>Click to see the direct usage in Transformers</summary>
|
371 |
+
|
372 |
+
</details>
|
373 |
+
-->
|
374 |
+
|
375 |
+
<!--
|
376 |
+
### Downstream Usage (Sentence Transformers)
|
377 |
+
|
378 |
+
You can finetune this model on your own dataset.
|
379 |
+
|
380 |
+
<details><summary>Click to expand</summary>
|
381 |
+
|
382 |
+
</details>
|
383 |
+
-->
|
384 |
+
|
385 |
+
<!--
|
386 |
+
### Out-of-Scope Use
|
387 |
+
|
388 |
+
*List how the model may foreseeably be misused and address what users ought not to do with the model.*
|
389 |
+
-->
|
390 |
+
|
391 |
+
## Evaluation
|
392 |
+
|
393 |
+
### Metrics
|
394 |
+
|
395 |
+
#### Binary Classification
|
396 |
+
|
397 |
+
* Evaluated with [<code>BinaryClassificationEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.BinaryClassificationEvaluator)
|
398 |
+
|
399 |
+
| Metric | Value |
|
400 |
+
|:-----------------------------|:-----------|
|
401 |
+
| cosine_accuracy | 0.9574 |
|
402 |
+
| cosine_accuracy_threshold | 0.8163 |
|
403 |
+
| cosine_f1 | 0.958 |
|
404 |
+
| cosine_f1_threshold | 0.8131 |
|
405 |
+
| cosine_precision | 0.9682 |
|
406 |
+
| cosine_recall | 0.9481 |
|
407 |
+
| cosine_ap | 0.9909 |
|
408 |
+
| dot_accuracy | 0.9574 |
|
409 |
+
| dot_accuracy_threshold | 0.8163 |
|
410 |
+
| dot_f1 | 0.958 |
|
411 |
+
| dot_f1_threshold | 0.8131 |
|
412 |
+
| dot_precision | 0.9682 |
|
413 |
+
| dot_recall | 0.9481 |
|
414 |
+
| dot_ap | 0.9909 |
|
415 |
+
| manhattan_accuracy | 0.9609 |
|
416 |
+
| manhattan_accuracy_threshold | 9.5648 |
|
417 |
+
| manhattan_f1 | 0.9619 |
|
418 |
+
| manhattan_f1_threshold | 9.5648 |
|
419 |
+
| manhattan_precision | 0.9619 |
|
420 |
+
| manhattan_recall | 0.9619 |
|
421 |
+
| manhattan_ap | 0.9909 |
|
422 |
+
| euclidean_accuracy | 0.9574 |
|
423 |
+
| euclidean_accuracy_threshold | 0.6061 |
|
424 |
+
| euclidean_f1 | 0.958 |
|
425 |
+
| euclidean_f1_threshold | 0.6114 |
|
426 |
+
| euclidean_precision | 0.9682 |
|
427 |
+
| euclidean_recall | 0.9481 |
|
428 |
+
| euclidean_ap | 0.9909 |
|
429 |
+
| max_accuracy | 0.9609 |
|
430 |
+
| max_accuracy_threshold | 9.5648 |
|
431 |
+
| max_f1 | 0.9619 |
|
432 |
+
| max_f1_threshold | 9.5648 |
|
433 |
+
| max_precision | 0.9682 |
|
434 |
+
| max_recall | 0.9619 |
|
435 |
+
| **max_ap** | **0.9909** |
|
436 |
+
|
437 |
+
#### Binary Classification
|
438 |
+
* Dataset: `test`
|
439 |
+
* Evaluated with [<code>BinaryClassificationEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.BinaryClassificationEvaluator)
|
440 |
+
|
441 |
+
| Metric | Value |
|
442 |
+
|:-----------------------------|:-----------|
|
443 |
+
| cosine_accuracy | 0.9592 |
|
444 |
+
| cosine_accuracy_threshold | 0.7969 |
|
445 |
+
| cosine_f1 | 0.9591 |
|
446 |
+
| cosine_f1_threshold | 0.7969 |
|
447 |
+
| cosine_precision | 0.9574 |
|
448 |
+
| cosine_recall | 0.9609 |
|
449 |
+
| cosine_ap | 0.9878 |
|
450 |
+
| dot_accuracy | 0.9592 |
|
451 |
+
| dot_accuracy_threshold | 0.7969 |
|
452 |
+
| dot_f1 | 0.9591 |
|
453 |
+
| dot_f1_threshold | 0.7969 |
|
454 |
+
| dot_precision | 0.9574 |
|
455 |
+
| dot_recall | 0.9609 |
|
456 |
+
| dot_ap | 0.9878 |
|
457 |
+
| manhattan_accuracy | 0.9557 |
|
458 |
+
| manhattan_accuracy_threshold | 9.8085 |
|
459 |
+
| manhattan_f1 | 0.9558 |
|
460 |
+
| manhattan_f1_threshold | 9.917 |
|
461 |
+
| manhattan_precision | 0.9507 |
|
462 |
+
| manhattan_recall | 0.9609 |
|
463 |
+
| manhattan_ap | 0.9866 |
|
464 |
+
| euclidean_accuracy | 0.9592 |
|
465 |
+
| euclidean_accuracy_threshold | 0.6373 |
|
466 |
+
| euclidean_f1 | 0.9591 |
|
467 |
+
| euclidean_f1_threshold | 0.6373 |
|
468 |
+
| euclidean_precision | 0.9574 |
|
469 |
+
| euclidean_recall | 0.9609 |
|
470 |
+
| euclidean_ap | 0.9878 |
|
471 |
+
| max_accuracy | 0.9592 |
|
472 |
+
| max_accuracy_threshold | 9.8085 |
|
473 |
+
| max_f1 | 0.9591 |
|
474 |
+
| max_f1_threshold | 9.917 |
|
475 |
+
| max_precision | 0.9574 |
|
476 |
+
| max_recall | 0.9609 |
|
477 |
+
| **max_ap** | **0.9878** |
|
478 |
+
|
479 |
+
<!--
|
480 |
+
## Bias, Risks and Limitations
|
481 |
+
|
482 |
+
*What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
|
483 |
+
-->
|
484 |
+
|
485 |
+
<!--
|
486 |
+
### Recommendations
|
487 |
+
|
488 |
+
*What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
|
489 |
+
-->
|
490 |
+
|
491 |
+
## Training Details
|
492 |
+
|
493 |
+
### Training Dataset
|
494 |
+
|
495 |
+
#### Unnamed Dataset
|
496 |
+
|
497 |
+
|
498 |
+
* Size: 4,505 training samples
|
499 |
+
* Columns: <code>sentence_0</code>, <code>sentence_1</code>, and <code>label</code>
|
500 |
+
* Approximate statistics based on the first 1000 samples:
|
501 |
+
| | sentence_0 | sentence_1 | label |
|
502 |
+
|:--------|:---------------------------------------------------------------------------------|:--------------------------------------------------------------------------------|:------------------------------------------------|
|
503 |
+
| type | string | string | int |
|
504 |
+
| details | <ul><li>min: 3 tokens</li><li>mean: 6.49 tokens</li><li>max: 24 tokens</li></ul> | <ul><li>min: 3 tokens</li><li>mean: 3.79 tokens</li><li>max: 8 tokens</li></ul> | <ul><li>0: ~52.30%</li><li>1: ~47.70%</li></ul> |
|
505 |
+
* Samples:
|
506 |
+
| sentence_0 | sentence_1 | label |
|
507 |
+
|:----------------------------------------|:-------------------------|:---------------|
|
508 |
+
| <code>N Seoul Tower</code> | <code>Laid-back</code> | <code>0</code> |
|
509 |
+
| <code>Magere Brug</code> | <code>Romantic</code> | <code>1</code> |
|
510 |
+
| <code>Polynesian Cultural Center</code> | <code>Adventurous</code> | <code>1</code> |
|
511 |
+
* Loss: [<code>OnlineContrastiveLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#onlinecontrastiveloss)
|
512 |
+
|
513 |
+
### Training Hyperparameters
|
514 |
+
#### Non-Default Hyperparameters
|
515 |
+
|
516 |
+
- `per_device_train_batch_size`: 32
|
517 |
+
- `per_device_eval_batch_size`: 32
|
518 |
+
- `num_train_epochs`: 5
|
519 |
+
- `multi_dataset_batch_sampler`: round_robin
|
520 |
+
|
521 |
+
#### All Hyperparameters
|
522 |
+
<details><summary>Click to expand</summary>
|
523 |
+
|
524 |
+
- `overwrite_output_dir`: False
|
525 |
+
- `do_predict`: False
|
526 |
+
- `eval_strategy`: no
|
527 |
+
- `prediction_loss_only`: True
|
528 |
+
- `per_device_train_batch_size`: 32
|
529 |
+
- `per_device_eval_batch_size`: 32
|
530 |
+
- `per_gpu_train_batch_size`: None
|
531 |
+
- `per_gpu_eval_batch_size`: None
|
532 |
+
- `gradient_accumulation_steps`: 1
|
533 |
+
- `eval_accumulation_steps`: None
|
534 |
+
- `torch_empty_cache_steps`: None
|
535 |
+
- `learning_rate`: 5e-05
|
536 |
+
- `weight_decay`: 0.0
|
537 |
+
- `adam_beta1`: 0.9
|
538 |
+
- `adam_beta2`: 0.999
|
539 |
+
- `adam_epsilon`: 1e-08
|
540 |
+
- `max_grad_norm`: 1
|
541 |
+
- `num_train_epochs`: 5
|
542 |
+
- `max_steps`: -1
|
543 |
+
- `lr_scheduler_type`: linear
|
544 |
+
- `lr_scheduler_kwargs`: {}
|
545 |
+
- `warmup_ratio`: 0.0
|
546 |
+
- `warmup_steps`: 0
|
547 |
+
- `log_level`: passive
|
548 |
+
- `log_level_replica`: warning
|
549 |
+
- `log_on_each_node`: True
|
550 |
+
- `logging_nan_inf_filter`: True
|
551 |
+
- `save_safetensors`: True
|
552 |
+
- `save_on_each_node`: False
|
553 |
+
- `save_only_model`: False
|
554 |
+
- `restore_callback_states_from_checkpoint`: False
|
555 |
+
- `no_cuda`: False
|
556 |
+
- `use_cpu`: False
|
557 |
+
- `use_mps_device`: False
|
558 |
+
- `seed`: 42
|
559 |
+
- `data_seed`: None
|
560 |
+
- `jit_mode_eval`: False
|
561 |
+
- `use_ipex`: False
|
562 |
+
- `bf16`: False
|
563 |
+
- `fp16`: False
|
564 |
+
- `fp16_opt_level`: O1
|
565 |
+
- `half_precision_backend`: auto
|
566 |
+
- `bf16_full_eval`: False
|
567 |
+
- `fp16_full_eval`: False
|
568 |
+
- `tf32`: None
|
569 |
+
- `local_rank`: 0
|
570 |
+
- `ddp_backend`: None
|
571 |
+
- `tpu_num_cores`: None
|
572 |
+
- `tpu_metrics_debug`: False
|
573 |
+
- `debug`: []
|
574 |
+
- `dataloader_drop_last`: False
|
575 |
+
- `dataloader_num_workers`: 0
|
576 |
+
- `dataloader_prefetch_factor`: None
|
577 |
+
- `past_index`: -1
|
578 |
+
- `disable_tqdm`: False
|
579 |
+
- `remove_unused_columns`: True
|
580 |
+
- `label_names`: None
|
581 |
+
- `load_best_model_at_end`: False
|
582 |
+
- `ignore_data_skip`: False
|
583 |
+
- `fsdp`: []
|
584 |
+
- `fsdp_min_num_params`: 0
|
585 |
+
- `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
|
586 |
+
- `fsdp_transformer_layer_cls_to_wrap`: None
|
587 |
+
- `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
|
588 |
+
- `deepspeed`: None
|
589 |
+
- `label_smoothing_factor`: 0.0
|
590 |
+
- `optim`: adamw_torch
|
591 |
+
- `optim_args`: None
|
592 |
+
- `adafactor`: False
|
593 |
+
- `group_by_length`: False
|
594 |
+
- `length_column_name`: length
|
595 |
+
- `ddp_find_unused_parameters`: None
|
596 |
+
- `ddp_bucket_cap_mb`: None
|
597 |
+
- `ddp_broadcast_buffers`: False
|
598 |
+
- `dataloader_pin_memory`: True
|
599 |
+
- `dataloader_persistent_workers`: False
|
600 |
+
- `skip_memory_metrics`: True
|
601 |
+
- `use_legacy_prediction_loop`: False
|
602 |
+
- `push_to_hub`: False
|
603 |
+
- `resume_from_checkpoint`: None
|
604 |
+
- `hub_model_id`: None
|
605 |
+
- `hub_strategy`: every_save
|
606 |
+
- `hub_private_repo`: False
|
607 |
+
- `hub_always_push`: False
|
608 |
+
- `gradient_checkpointing`: False
|
609 |
+
- `gradient_checkpointing_kwargs`: None
|
610 |
+
- `include_inputs_for_metrics`: False
|
611 |
+
- `eval_do_concat_batches`: True
|
612 |
+
- `fp16_backend`: auto
|
613 |
+
- `push_to_hub_model_id`: None
|
614 |
+
- `push_to_hub_organization`: None
|
615 |
+
- `mp_parameters`:
|
616 |
+
- `auto_find_batch_size`: False
|
617 |
+
- `full_determinism`: False
|
618 |
+
- `torchdynamo`: None
|
619 |
+
- `ray_scope`: last
|
620 |
+
- `ddp_timeout`: 1800
|
621 |
+
- `torch_compile`: False
|
622 |
+
- `torch_compile_backend`: None
|
623 |
+
- `torch_compile_mode`: None
|
624 |
+
- `dispatch_batches`: None
|
625 |
+
- `split_batches`: None
|
626 |
+
- `include_tokens_per_second`: False
|
627 |
+
- `include_num_input_tokens_seen`: False
|
628 |
+
- `neftune_noise_alpha`: None
|
629 |
+
- `optim_target_modules`: None
|
630 |
+
- `batch_eval_metrics`: False
|
631 |
+
- `eval_on_start`: False
|
632 |
+
- `eval_use_gather_object`: False
|
633 |
+
- `batch_sampler`: batch_sampler
|
634 |
+
- `multi_dataset_batch_sampler`: round_robin
|
635 |
+
|
636 |
+
</details>
|
637 |
+
|
638 |
+
### Training Logs
|
639 |
+
| Epoch | Step | Training Loss | max_ap | test_max_ap |
|
640 |
+
|:------:|:----:|:-------------:|:------:|:-----------:|
|
641 |
+
| 1.0 | 141 | - | 0.6780 | - |
|
642 |
+
| 2.0 | 282 | - | 0.7538 | - |
|
643 |
+
| 3.0 | 423 | - | 0.8064 | - |
|
644 |
+
| 3.5461 | 500 | 6.7404 | - | - |
|
645 |
+
| 4.0 | 564 | - | 0.9751 | - |
|
646 |
+
| 5.0 | 705 | - | 0.9909 | 0.9878 |
|
647 |
+
|
648 |
+
|
649 |
+
### Framework Versions
|
650 |
+
- Python: 3.10.12
|
651 |
+
- Sentence Transformers: 3.2.1
|
652 |
+
- Transformers: 4.44.2
|
653 |
+
- PyTorch: 2.5.0+cu121
|
654 |
+
- Accelerate: 0.34.2
|
655 |
+
- Datasets: 3.1.0
|
656 |
+
- Tokenizers: 0.19.1
|
657 |
+
|
658 |
+
## Citation
|
659 |
+
|
660 |
+
### BibTeX
|
661 |
+
|
662 |
+
#### Sentence Transformers
|
663 |
+
```bibtex
|
664 |
+
@inproceedings{reimers-2019-sentence-bert,
|
665 |
+
title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
|
666 |
+
author = "Reimers, Nils and Gurevych, Iryna",
|
667 |
+
booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
|
668 |
+
month = "11",
|
669 |
+
year = "2019",
|
670 |
+
publisher = "Association for Computational Linguistics",
|
671 |
+
url = "https://arxiv.org/abs/1908.10084",
|
672 |
+
}
|
673 |
+
```
|
674 |
+
|
675 |
+
<!--
|
676 |
+
## Glossary
|
677 |
+
|
678 |
+
*Clearly define terms in order to be accessible across audiences.*
|
679 |
+
-->
|
680 |
+
|
681 |
+
<!--
|
682 |
+
## Model Card Authors
|
683 |
+
|
684 |
+
*Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
|
685 |
+
-->
|
686 |
+
|
687 |
+
<!--
|
688 |
+
## Model Card Contact
|
689 |
+
|
690 |
+
*Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
|
691 |
+
-->
|
config.json
ADDED
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"_name_or_path": "sentence-transformers/all-MiniLM-L6-v2",
|
3 |
+
"architectures": [
|
4 |
+
"BertModel"
|
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": 384,
|
12 |
+
"initializer_range": 0.02,
|
13 |
+
"intermediate_size": 1536,
|
14 |
+
"layer_norm_eps": 1e-12,
|
15 |
+
"max_position_embeddings": 512,
|
16 |
+
"model_type": "bert",
|
17 |
+
"num_attention_heads": 12,
|
18 |
+
"num_hidden_layers": 6,
|
19 |
+
"pad_token_id": 0,
|
20 |
+
"position_embedding_type": "absolute",
|
21 |
+
"torch_dtype": "float32",
|
22 |
+
"transformers_version": "4.44.2",
|
23 |
+
"type_vocab_size": 2,
|
24 |
+
"use_cache": true,
|
25 |
+
"vocab_size": 30522
|
26 |
+
}
|
config_sentence_transformers.json
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"__version__": {
|
3 |
+
"sentence_transformers": "3.2.1",
|
4 |
+
"transformers": "4.44.2",
|
5 |
+
"pytorch": "2.5.0+cu121"
|
6 |
+
},
|
7 |
+
"prompts": {},
|
8 |
+
"default_prompt_name": null,
|
9 |
+
"similarity_fn_name": null
|
10 |
+
}
|
model.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:57eb9aced9cc99457af46a3aa43c18acf7515d1013a80db844d68947eaaa620c
|
3 |
+
size 90864192
|
modules.json
ADDED
@@ -0,0 +1,20 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
[
|
2 |
+
{
|
3 |
+
"idx": 0,
|
4 |
+
"name": "0",
|
5 |
+
"path": "",
|
6 |
+
"type": "sentence_transformers.models.Transformer"
|
7 |
+
},
|
8 |
+
{
|
9 |
+
"idx": 1,
|
10 |
+
"name": "1",
|
11 |
+
"path": "1_Pooling",
|
12 |
+
"type": "sentence_transformers.models.Pooling"
|
13 |
+
},
|
14 |
+
{
|
15 |
+
"idx": 2,
|
16 |
+
"name": "2",
|
17 |
+
"path": "2_Normalize",
|
18 |
+
"type": "sentence_transformers.models.Normalize"
|
19 |
+
}
|
20 |
+
]
|
sentence_bert_config.json
ADDED
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"max_seq_length": 256,
|
3 |
+
"do_lower_case": false
|
4 |
+
}
|
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 |
+
}
|
tokenizer.json
ADDED
The diff for this file is too large to render.
See raw diff
|
|
tokenizer_config.json
ADDED
@@ -0,0 +1,64 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"added_tokens_decoder": {
|
3 |
+
"0": {
|
4 |
+
"content": "[PAD]",
|
5 |
+
"lstrip": false,
|
6 |
+
"normalized": false,
|
7 |
+
"rstrip": false,
|
8 |
+
"single_word": false,
|
9 |
+
"special": true
|
10 |
+
},
|
11 |
+
"100": {
|
12 |
+
"content": "[UNK]",
|
13 |
+
"lstrip": false,
|
14 |
+
"normalized": false,
|
15 |
+
"rstrip": false,
|
16 |
+
"single_word": false,
|
17 |
+
"special": true
|
18 |
+
},
|
19 |
+
"101": {
|
20 |
+
"content": "[CLS]",
|
21 |
+
"lstrip": false,
|
22 |
+
"normalized": false,
|
23 |
+
"rstrip": false,
|
24 |
+
"single_word": false,
|
25 |
+
"special": true
|
26 |
+
},
|
27 |
+
"102": {
|
28 |
+
"content": "[SEP]",
|
29 |
+
"lstrip": false,
|
30 |
+
"normalized": false,
|
31 |
+
"rstrip": false,
|
32 |
+
"single_word": false,
|
33 |
+
"special": true
|
34 |
+
},
|
35 |
+
"103": {
|
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": 128,
|
50 |
+
"model_max_length": 256,
|
51 |
+
"never_split": null,
|
52 |
+
"pad_to_multiple_of": null,
|
53 |
+
"pad_token": "[PAD]",
|
54 |
+
"pad_token_type_id": 0,
|
55 |
+
"padding_side": "right",
|
56 |
+
"sep_token": "[SEP]",
|
57 |
+
"stride": 0,
|
58 |
+
"strip_accents": null,
|
59 |
+
"tokenize_chinese_chars": true,
|
60 |
+
"tokenizer_class": "BertTokenizer",
|
61 |
+
"truncation_side": "right",
|
62 |
+
"truncation_strategy": "longest_first",
|
63 |
+
"unk_token": "[UNK]"
|
64 |
+
}
|
vocab.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|