srikarvar commited on
Commit
73c1092
β€’
1 Parent(s): 527bb2e

Add new SentenceTransformer model.

Browse files
.gitattributes CHANGED
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
 
 
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
36
+ tokenizer.json filter=lfs diff=lfs merge=lfs -text
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,740 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ base_model: intfloat/multilingual-e5-small
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:2871
47
+ - loss:OnlineContrastiveLoss
48
+ widget:
49
+ - source_sentence: Stages of photosynthesis
50
+ sentences:
51
+ - The function helps preprocess your entire dataset at once.
52
+ - You can create an index for your dataset by using [Dataset.add_faiss_index()](/docs/datasets/v2.10.0/en/package_reference/main_classes#datasets.Dataset.add_faiss_index)
53
+ or [Dataset.add_elasticsearch_index()](/docs/datasets/v2.10.0/en/package_reference/main_classes#datasets.Dataset.add_elasticsearch_index)
54
+ depending on the system you want to use.
55
+ - What is photosynthesis?
56
+ - source_sentence: Steps to erase internet history
57
+ sentences:
58
+ - How do I delete my browsing history?
59
+ - Yes, there is a reference section available in πŸ€— Datasets documentation. It covers
60
+ main classes, builder classes, loading methods, table classes, logging methods,
61
+ and task templates.
62
+ - What is the tallest building in New York City?
63
+ - source_sentence: The `StreamingDownloadManager` class is a download manager that
64
+ employs the "::" separator to traverse (possibly remote) compressed files.
65
+ sentences:
66
+ - What is the role of a business plan in entrepreneurship?
67
+ - The Hugging Face datasets library's default handler can be disabled to prevent
68
+ double logging by calling the `datasets.utils.logging.enable_propagation()` function.
69
+ - The `StreamingDownloadManager` class is a download manager that uses the ”::”
70
+ separator to navigate through (possibly remote) compressed archives.
71
+ - source_sentence: Using torch.utils.data.DataLoader, you can package the dataset
72
+ and craft a collate function to group the samples into batches.
73
+ sentences:
74
+ - Why does understanding death philosophical?
75
+ - The `_generate_examples` method is used to access and yield TAR files sequentially,
76
+ and to associate the metadata in `metadata_path` with the audio files in the TAR
77
+ file.
78
+ - You can wrap the dataset in DataLoader using torch.utils.data.DataLoader and create
79
+ a collate function to collate the samples into batches.
80
+ - source_sentence: Top literature about World War II
81
+ sentences:
82
+ - What is the price of an iPhone 12?
83
+ - Best books on World War II
84
+ - When was the Declaration of Independence signed?
85
+ model-index:
86
+ - name: SentenceTransformer based on intfloat/multilingual-e5-small
87
+ results:
88
+ - task:
89
+ type: binary-classification
90
+ name: Binary Classification
91
+ dataset:
92
+ name: pair class dev
93
+ type: pair-class-dev
94
+ metrics:
95
+ - type: cosine_accuracy
96
+ value: 0.9
97
+ name: Cosine Accuracy
98
+ - type: cosine_accuracy_threshold
99
+ value: 0.784720778465271
100
+ name: Cosine Accuracy Threshold
101
+ - type: cosine_f1
102
+ value: 0.926605504587156
103
+ name: Cosine F1
104
+ - type: cosine_f1_threshold
105
+ value: 0.784720778465271
106
+ name: Cosine F1 Threshold
107
+ - type: cosine_precision
108
+ value: 0.8938053097345132
109
+ name: Cosine Precision
110
+ - type: cosine_recall
111
+ value: 0.9619047619047619
112
+ name: Cosine Recall
113
+ - type: cosine_ap
114
+ value: 0.9548853455786228
115
+ name: Cosine Ap
116
+ - type: dot_accuracy
117
+ value: 0.9
118
+ name: Dot Accuracy
119
+ - type: dot_accuracy_threshold
120
+ value: 0.784720778465271
121
+ name: Dot Accuracy Threshold
122
+ - type: dot_f1
123
+ value: 0.926605504587156
124
+ name: Dot F1
125
+ - type: dot_f1_threshold
126
+ value: 0.784720778465271
127
+ name: Dot F1 Threshold
128
+ - type: dot_precision
129
+ value: 0.8938053097345132
130
+ name: Dot Precision
131
+ - type: dot_recall
132
+ value: 0.9619047619047619
133
+ name: Dot Recall
134
+ - type: dot_ap
135
+ value: 0.9548853455786228
136
+ name: Dot Ap
137
+ - type: manhattan_accuracy
138
+ value: 0.896875
139
+ name: Manhattan Accuracy
140
+ - type: manhattan_accuracy_threshold
141
+ value: 9.908977508544922
142
+ name: Manhattan Accuracy Threshold
143
+ - type: manhattan_f1
144
+ value: 0.9241379310344828
145
+ name: Manhattan F1
146
+ - type: manhattan_f1_threshold
147
+ value: 10.13671588897705
148
+ name: Manhattan F1 Threshold
149
+ - type: manhattan_precision
150
+ value: 0.8933333333333333
151
+ name: Manhattan Precision
152
+ - type: manhattan_recall
153
+ value: 0.9571428571428572
154
+ name: Manhattan Recall
155
+ - type: manhattan_ap
156
+ value: 0.9549673053310541
157
+ name: Manhattan Ap
158
+ - type: euclidean_accuracy
159
+ value: 0.9
160
+ name: Euclidean Accuracy
161
+ - type: euclidean_accuracy_threshold
162
+ value: 0.6561694145202637
163
+ name: Euclidean Accuracy Threshold
164
+ - type: euclidean_f1
165
+ value: 0.926605504587156
166
+ name: Euclidean F1
167
+ - type: euclidean_f1_threshold
168
+ value: 0.6561694145202637
169
+ name: Euclidean F1 Threshold
170
+ - type: euclidean_precision
171
+ value: 0.8938053097345132
172
+ name: Euclidean Precision
173
+ - type: euclidean_recall
174
+ value: 0.9619047619047619
175
+ name: Euclidean Recall
176
+ - type: euclidean_ap
177
+ value: 0.9548853455786228
178
+ name: Euclidean Ap
179
+ - type: max_accuracy
180
+ value: 0.9
181
+ name: Max Accuracy
182
+ - type: max_accuracy_threshold
183
+ value: 9.908977508544922
184
+ name: Max Accuracy Threshold
185
+ - type: max_f1
186
+ value: 0.926605504587156
187
+ name: Max F1
188
+ - type: max_f1_threshold
189
+ value: 10.13671588897705
190
+ name: Max F1 Threshold
191
+ - type: max_precision
192
+ value: 0.8938053097345132
193
+ name: Max Precision
194
+ - type: max_recall
195
+ value: 0.9619047619047619
196
+ name: Max Recall
197
+ - type: max_ap
198
+ value: 0.9549673053310541
199
+ name: Max Ap
200
+ - task:
201
+ type: binary-classification
202
+ name: Binary Classification
203
+ dataset:
204
+ name: pair class test
205
+ type: pair-class-test
206
+ metrics:
207
+ - type: cosine_accuracy
208
+ value: 0.90625
209
+ name: Cosine Accuracy
210
+ - type: cosine_accuracy_threshold
211
+ value: 0.8142284154891968
212
+ name: Cosine Accuracy Threshold
213
+ - type: cosine_f1
214
+ value: 0.929245283018868
215
+ name: Cosine F1
216
+ - type: cosine_f1_threshold
217
+ value: 0.8142284154891968
218
+ name: Cosine F1 Threshold
219
+ - type: cosine_precision
220
+ value: 0.9205607476635514
221
+ name: Cosine Precision
222
+ - type: cosine_recall
223
+ value: 0.9380952380952381
224
+ name: Cosine Recall
225
+ - type: cosine_ap
226
+ value: 0.9556341092519267
227
+ name: Cosine Ap
228
+ - type: dot_accuracy
229
+ value: 0.90625
230
+ name: Dot Accuracy
231
+ - type: dot_accuracy_threshold
232
+ value: 0.8142284750938416
233
+ name: Dot Accuracy Threshold
234
+ - type: dot_f1
235
+ value: 0.929245283018868
236
+ name: Dot F1
237
+ - type: dot_f1_threshold
238
+ value: 0.8142284750938416
239
+ name: Dot F1 Threshold
240
+ - type: dot_precision
241
+ value: 0.9205607476635514
242
+ name: Dot Precision
243
+ - type: dot_recall
244
+ value: 0.9380952380952381
245
+ name: Dot Recall
246
+ - type: dot_ap
247
+ value: 0.9556341092519267
248
+ name: Dot Ap
249
+ - type: manhattan_accuracy
250
+ value: 0.903125
251
+ name: Manhattan Accuracy
252
+ - type: manhattan_accuracy_threshold
253
+ value: 9.576812744140625
254
+ name: Manhattan Accuracy Threshold
255
+ - type: manhattan_f1
256
+ value: 0.9270588235294117
257
+ name: Manhattan F1
258
+ - type: manhattan_f1_threshold
259
+ value: 9.576812744140625
260
+ name: Manhattan F1 Threshold
261
+ - type: manhattan_precision
262
+ value: 0.9162790697674419
263
+ name: Manhattan Precision
264
+ - type: manhattan_recall
265
+ value: 0.9380952380952381
266
+ name: Manhattan Recall
267
+ - type: manhattan_ap
268
+ value: 0.9557652464010216
269
+ name: Manhattan Ap
270
+ - type: euclidean_accuracy
271
+ value: 0.90625
272
+ name: Euclidean Accuracy
273
+ - type: euclidean_accuracy_threshold
274
+ value: 0.609528124332428
275
+ name: Euclidean Accuracy Threshold
276
+ - type: euclidean_f1
277
+ value: 0.929245283018868
278
+ name: Euclidean F1
279
+ - type: euclidean_f1_threshold
280
+ value: 0.609528124332428
281
+ name: Euclidean F1 Threshold
282
+ - type: euclidean_precision
283
+ value: 0.9205607476635514
284
+ name: Euclidean Precision
285
+ - type: euclidean_recall
286
+ value: 0.9380952380952381
287
+ name: Euclidean Recall
288
+ - type: euclidean_ap
289
+ value: 0.9556341092519267
290
+ name: Euclidean Ap
291
+ - type: max_accuracy
292
+ value: 0.90625
293
+ name: Max Accuracy
294
+ - type: max_accuracy_threshold
295
+ value: 9.576812744140625
296
+ name: Max Accuracy Threshold
297
+ - type: max_f1
298
+ value: 0.929245283018868
299
+ name: Max F1
300
+ - type: max_f1_threshold
301
+ value: 9.576812744140625
302
+ name: Max F1 Threshold
303
+ - type: max_precision
304
+ value: 0.9205607476635514
305
+ name: Max Precision
306
+ - type: max_recall
307
+ value: 0.9380952380952381
308
+ name: Max Recall
309
+ - type: max_ap
310
+ value: 0.9557652464010216
311
+ name: Max Ap
312
+ ---
313
+
314
+ # SentenceTransformer based on intfloat/multilingual-e5-small
315
+
316
+ This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [intfloat/multilingual-e5-small](https://huggingface.co/intfloat/multilingual-e5-small). 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.
317
+
318
+ ## Model Details
319
+
320
+ ### Model Description
321
+ - **Model Type:** Sentence Transformer
322
+ - **Base model:** [intfloat/multilingual-e5-small](https://huggingface.co/intfloat/multilingual-e5-small) <!-- at revision fd1525a9fd15316a2d503bf26ab031a61d056e98 -->
323
+ - **Maximum Sequence Length:** 512 tokens
324
+ - **Output Dimensionality:** 384 tokens
325
+ - **Similarity Function:** Cosine Similarity
326
+ <!-- - **Training Dataset:** Unknown -->
327
+ <!-- - **Language:** Unknown -->
328
+ <!-- - **License:** Unknown -->
329
+
330
+ ### Model Sources
331
+
332
+ - **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
333
+ - **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
334
+ - **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
335
+
336
+ ### Full Model Architecture
337
+
338
+ ```
339
+ SentenceTransformer(
340
+ (0): Transformer({'max_seq_length': 512, 'do_lower_case': False}) with Transformer model: BertModel
341
+ (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})
342
+ (2): Normalize()
343
+ )
344
+ ```
345
+
346
+ ## Usage
347
+
348
+ ### Direct Usage (Sentence Transformers)
349
+
350
+ First install the Sentence Transformers library:
351
+
352
+ ```bash
353
+ pip install -U sentence-transformers
354
+ ```
355
+
356
+ Then you can load this model and run inference.
357
+ ```python
358
+ from sentence_transformers import SentenceTransformer
359
+
360
+ # Download from the πŸ€— Hub
361
+ model = SentenceTransformer("srikarvar/fine_tuned_model_7")
362
+ # Run inference
363
+ sentences = [
364
+ 'Top literature about World War II',
365
+ 'Best books on World War II',
366
+ 'What is the price of an iPhone 12?',
367
+ ]
368
+ embeddings = model.encode(sentences)
369
+ print(embeddings.shape)
370
+ # [3, 384]
371
+
372
+ # Get the similarity scores for the embeddings
373
+ similarities = model.similarity(embeddings, embeddings)
374
+ print(similarities.shape)
375
+ # [3, 3]
376
+ ```
377
+
378
+ <!--
379
+ ### Direct Usage (Transformers)
380
+
381
+ <details><summary>Click to see the direct usage in Transformers</summary>
382
+
383
+ </details>
384
+ -->
385
+
386
+ <!--
387
+ ### Downstream Usage (Sentence Transformers)
388
+
389
+ You can finetune this model on your own dataset.
390
+
391
+ <details><summary>Click to expand</summary>
392
+
393
+ </details>
394
+ -->
395
+
396
+ <!--
397
+ ### Out-of-Scope Use
398
+
399
+ *List how the model may foreseeably be misused and address what users ought not to do with the model.*
400
+ -->
401
+
402
+ ## Evaluation
403
+
404
+ ### Metrics
405
+
406
+ #### Binary Classification
407
+ * Dataset: `pair-class-dev`
408
+ * Evaluated with [<code>BinaryClassificationEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.BinaryClassificationEvaluator)
409
+
410
+ | Metric | Value |
411
+ |:-----------------------------|:----------|
412
+ | cosine_accuracy | 0.9 |
413
+ | cosine_accuracy_threshold | 0.7847 |
414
+ | cosine_f1 | 0.9266 |
415
+ | cosine_f1_threshold | 0.7847 |
416
+ | cosine_precision | 0.8938 |
417
+ | cosine_recall | 0.9619 |
418
+ | cosine_ap | 0.9549 |
419
+ | dot_accuracy | 0.9 |
420
+ | dot_accuracy_threshold | 0.7847 |
421
+ | dot_f1 | 0.9266 |
422
+ | dot_f1_threshold | 0.7847 |
423
+ | dot_precision | 0.8938 |
424
+ | dot_recall | 0.9619 |
425
+ | dot_ap | 0.9549 |
426
+ | manhattan_accuracy | 0.8969 |
427
+ | manhattan_accuracy_threshold | 9.909 |
428
+ | manhattan_f1 | 0.9241 |
429
+ | manhattan_f1_threshold | 10.1367 |
430
+ | manhattan_precision | 0.8933 |
431
+ | manhattan_recall | 0.9571 |
432
+ | manhattan_ap | 0.955 |
433
+ | euclidean_accuracy | 0.9 |
434
+ | euclidean_accuracy_threshold | 0.6562 |
435
+ | euclidean_f1 | 0.9266 |
436
+ | euclidean_f1_threshold | 0.6562 |
437
+ | euclidean_precision | 0.8938 |
438
+ | euclidean_recall | 0.9619 |
439
+ | euclidean_ap | 0.9549 |
440
+ | max_accuracy | 0.9 |
441
+ | max_accuracy_threshold | 9.909 |
442
+ | max_f1 | 0.9266 |
443
+ | max_f1_threshold | 10.1367 |
444
+ | max_precision | 0.8938 |
445
+ | max_recall | 0.9619 |
446
+ | **max_ap** | **0.955** |
447
+
448
+ #### Binary Classification
449
+ * Dataset: `pair-class-test`
450
+ * Evaluated with [<code>BinaryClassificationEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.BinaryClassificationEvaluator)
451
+
452
+ | Metric | Value |
453
+ |:-----------------------------|:-----------|
454
+ | cosine_accuracy | 0.9062 |
455
+ | cosine_accuracy_threshold | 0.8142 |
456
+ | cosine_f1 | 0.9292 |
457
+ | cosine_f1_threshold | 0.8142 |
458
+ | cosine_precision | 0.9206 |
459
+ | cosine_recall | 0.9381 |
460
+ | cosine_ap | 0.9556 |
461
+ | dot_accuracy | 0.9062 |
462
+ | dot_accuracy_threshold | 0.8142 |
463
+ | dot_f1 | 0.9292 |
464
+ | dot_f1_threshold | 0.8142 |
465
+ | dot_precision | 0.9206 |
466
+ | dot_recall | 0.9381 |
467
+ | dot_ap | 0.9556 |
468
+ | manhattan_accuracy | 0.9031 |
469
+ | manhattan_accuracy_threshold | 9.5768 |
470
+ | manhattan_f1 | 0.9271 |
471
+ | manhattan_f1_threshold | 9.5768 |
472
+ | manhattan_precision | 0.9163 |
473
+ | manhattan_recall | 0.9381 |
474
+ | manhattan_ap | 0.9558 |
475
+ | euclidean_accuracy | 0.9062 |
476
+ | euclidean_accuracy_threshold | 0.6095 |
477
+ | euclidean_f1 | 0.9292 |
478
+ | euclidean_f1_threshold | 0.6095 |
479
+ | euclidean_precision | 0.9206 |
480
+ | euclidean_recall | 0.9381 |
481
+ | euclidean_ap | 0.9556 |
482
+ | max_accuracy | 0.9062 |
483
+ | max_accuracy_threshold | 9.5768 |
484
+ | max_f1 | 0.9292 |
485
+ | max_f1_threshold | 9.5768 |
486
+ | max_precision | 0.9206 |
487
+ | max_recall | 0.9381 |
488
+ | **max_ap** | **0.9558** |
489
+
490
+ <!--
491
+ ## Bias, Risks and Limitations
492
+
493
+ *What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
494
+ -->
495
+
496
+ <!--
497
+ ### Recommendations
498
+
499
+ *What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
500
+ -->
501
+
502
+ ## Training Details
503
+
504
+ ### Training Dataset
505
+
506
+ #### Unnamed Dataset
507
+
508
+
509
+ * Size: 2,871 training samples
510
+ * Columns: <code>sentence2</code>, <code>sentence1</code>, and <code>label</code>
511
+ * Approximate statistics based on the first 1000 samples:
512
+ | | sentence2 | sentence1 | label |
513
+ |:--------|:-----------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------|:------------------------------------------------|
514
+ | type | string | string | int |
515
+ | details | <ul><li>min: 5 tokens</li><li>mean: 20.57 tokens</li><li>max: 177 tokens</li></ul> | <ul><li>min: 6 tokens</li><li>mean: 20.74 tokens</li><li>max: 176 tokens</li></ul> | <ul><li>0: ~34.00%</li><li>1: ~66.00%</li></ul> |
516
+ * Samples:
517
+ | sentence2 | sentence1 | label |
518
+ |:------------------------------------------------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------------------------------------------------------------------------------|:---------------|
519
+ | <code>How do I do to get fuller face?</code> | <code>How can one get a fuller face?</code> | <code>1</code> |
520
+ | <code>The DatasetInfo holds the data of a dataset, which may include its description, characteristics, and size.</code> | <code>A dataset's information is stored inside DatasetInfo and can include information such as the dataset description, features, and dataset size.</code> | <code>1</code> |
521
+ | <code>How do I write a resume?</code> | <code>How do I create a resume?</code> | <code>1</code> |
522
+ * Loss: [<code>OnlineContrastiveLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#onlinecontrastiveloss)
523
+
524
+ ### Evaluation Dataset
525
+
526
+ #### Unnamed Dataset
527
+
528
+
529
+ * Size: 320 evaluation samples
530
+ * Columns: <code>sentence2</code>, <code>sentence1</code>, and <code>label</code>
531
+ * Approximate statistics based on the first 320 samples:
532
+ | | sentence2 | sentence1 | label |
533
+ |:--------|:-----------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------|:------------------------------------------------|
534
+ | type | string | string | int |
535
+ | details | <ul><li>min: 4 tokens</li><li>mean: 19.57 tokens</li><li>max: 135 tokens</li></ul> | <ul><li>min: 6 tokens</li><li>mean: 19.55 tokens</li><li>max: 136 tokens</li></ul> | <ul><li>0: ~34.38%</li><li>1: ~65.62%</li></ul> |
536
+ * Samples:
537
+ | sentence2 | sentence1 | label |
538
+ |:------------------------------------------------------------------------------------------|:---------------------------------------------------------------------------------------|:---------------|
539
+ | <code>Steps to erase internet history</code> | <code>How do I delete my browsing history?</code> | <code>1</code> |
540
+ | <code>How important is it to be the first person to wish someone a happy birthday?</code> | <code>What is the right etiquette for wishing a Jehovah Witness happy birthday?</code> | <code>0</code> |
541
+ | <code>Who directed 'Gone with the Wind'?</code> | <code>Who directed 'Citizen Kane'?</code> | <code>0</code> |
542
+ * Loss: [<code>OnlineContrastiveLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#onlinecontrastiveloss)
543
+
544
+ ### Training Hyperparameters
545
+ #### Non-Default Hyperparameters
546
+
547
+ - `eval_strategy`: epoch
548
+ - `per_device_train_batch_size`: 32
549
+ - `per_device_eval_batch_size`: 32
550
+ - `gradient_accumulation_steps`: 2
551
+ - `num_train_epochs`: 4
552
+ - `warmup_ratio`: 0.1
553
+ - `load_best_model_at_end`: True
554
+ - `optim`: adamw_torch_fused
555
+ - `batch_sampler`: no_duplicates
556
+
557
+ #### All Hyperparameters
558
+ <details><summary>Click to expand</summary>
559
+
560
+ - `overwrite_output_dir`: False
561
+ - `do_predict`: False
562
+ - `eval_strategy`: epoch
563
+ - `prediction_loss_only`: True
564
+ - `per_device_train_batch_size`: 32
565
+ - `per_device_eval_batch_size`: 32
566
+ - `per_gpu_train_batch_size`: None
567
+ - `per_gpu_eval_batch_size`: None
568
+ - `gradient_accumulation_steps`: 2
569
+ - `eval_accumulation_steps`: None
570
+ - `learning_rate`: 5e-05
571
+ - `weight_decay`: 0.0
572
+ - `adam_beta1`: 0.9
573
+ - `adam_beta2`: 0.999
574
+ - `adam_epsilon`: 1e-08
575
+ - `max_grad_norm`: 1.0
576
+ - `num_train_epochs`: 4
577
+ - `max_steps`: -1
578
+ - `lr_scheduler_type`: linear
579
+ - `lr_scheduler_kwargs`: {}
580
+ - `warmup_ratio`: 0.1
581
+ - `warmup_steps`: 0
582
+ - `log_level`: passive
583
+ - `log_level_replica`: warning
584
+ - `log_on_each_node`: True
585
+ - `logging_nan_inf_filter`: True
586
+ - `save_safetensors`: True
587
+ - `save_on_each_node`: False
588
+ - `save_only_model`: False
589
+ - `restore_callback_states_from_checkpoint`: False
590
+ - `no_cuda`: False
591
+ - `use_cpu`: False
592
+ - `use_mps_device`: False
593
+ - `seed`: 42
594
+ - `data_seed`: None
595
+ - `jit_mode_eval`: False
596
+ - `use_ipex`: False
597
+ - `bf16`: False
598
+ - `fp16`: False
599
+ - `fp16_opt_level`: O1
600
+ - `half_precision_backend`: auto
601
+ - `bf16_full_eval`: False
602
+ - `fp16_full_eval`: False
603
+ - `tf32`: None
604
+ - `local_rank`: 0
605
+ - `ddp_backend`: None
606
+ - `tpu_num_cores`: None
607
+ - `tpu_metrics_debug`: False
608
+ - `debug`: []
609
+ - `dataloader_drop_last`: False
610
+ - `dataloader_num_workers`: 0
611
+ - `dataloader_prefetch_factor`: None
612
+ - `past_index`: -1
613
+ - `disable_tqdm`: False
614
+ - `remove_unused_columns`: True
615
+ - `label_names`: None
616
+ - `load_best_model_at_end`: True
617
+ - `ignore_data_skip`: False
618
+ - `fsdp`: []
619
+ - `fsdp_min_num_params`: 0
620
+ - `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
621
+ - `fsdp_transformer_layer_cls_to_wrap`: None
622
+ - `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
623
+ - `deepspeed`: None
624
+ - `label_smoothing_factor`: 0.0
625
+ - `optim`: adamw_torch_fused
626
+ - `optim_args`: None
627
+ - `adafactor`: False
628
+ - `group_by_length`: False
629
+ - `length_column_name`: length
630
+ - `ddp_find_unused_parameters`: None
631
+ - `ddp_bucket_cap_mb`: None
632
+ - `ddp_broadcast_buffers`: False
633
+ - `dataloader_pin_memory`: True
634
+ - `dataloader_persistent_workers`: False
635
+ - `skip_memory_metrics`: True
636
+ - `use_legacy_prediction_loop`: False
637
+ - `push_to_hub`: False
638
+ - `resume_from_checkpoint`: None
639
+ - `hub_model_id`: None
640
+ - `hub_strategy`: every_save
641
+ - `hub_private_repo`: False
642
+ - `hub_always_push`: False
643
+ - `gradient_checkpointing`: False
644
+ - `gradient_checkpointing_kwargs`: None
645
+ - `include_inputs_for_metrics`: False
646
+ - `eval_do_concat_batches`: True
647
+ - `fp16_backend`: auto
648
+ - `push_to_hub_model_id`: None
649
+ - `push_to_hub_organization`: None
650
+ - `mp_parameters`:
651
+ - `auto_find_batch_size`: False
652
+ - `full_determinism`: False
653
+ - `torchdynamo`: None
654
+ - `ray_scope`: last
655
+ - `ddp_timeout`: 1800
656
+ - `torch_compile`: False
657
+ - `torch_compile_backend`: None
658
+ - `torch_compile_mode`: None
659
+ - `dispatch_batches`: None
660
+ - `split_batches`: None
661
+ - `include_tokens_per_second`: False
662
+ - `include_num_input_tokens_seen`: False
663
+ - `neftune_noise_alpha`: None
664
+ - `optim_target_modules`: None
665
+ - `batch_eval_metrics`: False
666
+ - `batch_sampler`: no_duplicates
667
+ - `multi_dataset_batch_sampler`: proportional
668
+
669
+ </details>
670
+
671
+ ### Training Logs
672
+ | Epoch | Step | Training Loss | loss | pair-class-dev_max_ap | pair-class-test_max_ap |
673
+ |:-------:|:------:|:-------------:|:----------:|:---------------------:|:----------------------:|
674
+ | 0 | 0 | - | - | 0.8735 | - |
675
+ | 0.2222 | 10 | 1.3298 | - | - | - |
676
+ | 0.4444 | 20 | 0.8218 | - | - | - |
677
+ | 0.6667 | 30 | 0.642 | - | - | - |
678
+ | 0.8889 | 40 | 0.571 | - | - | - |
679
+ | 1.0 | 45 | - | 0.5321 | 0.9499 | - |
680
+ | 1.1111 | 50 | 0.4828 | - | - | - |
681
+ | 1.3333 | 60 | 0.3003 | - | - | - |
682
+ | 1.5556 | 70 | 0.3331 | - | - | - |
683
+ | 1.7778 | 80 | 0.203 | - | - | - |
684
+ | **2.0** | **90** | **0.3539** | **0.5118** | **0.9558** | **-** |
685
+ | 2.2222 | 100 | 0.1357 | - | - | - |
686
+ | 2.4444 | 110 | 0.1562 | - | - | - |
687
+ | 2.6667 | 120 | 0.0703 | - | - | - |
688
+ | 2.8889 | 130 | 0.0806 | - | - | - |
689
+ | 3.0 | 135 | - | 0.5266 | 0.9548 | - |
690
+ | 3.1111 | 140 | 0.1721 | - | - | - |
691
+ | 3.3333 | 150 | 0.1063 | - | - | - |
692
+ | 3.5556 | 160 | 0.0909 | - | - | - |
693
+ | 3.7778 | 170 | 0.0358 | - | - | - |
694
+ | 4.0 | 180 | 0.1021 | 0.5256 | 0.9550 | 0.9558 |
695
+
696
+ * The bold row denotes the saved checkpoint.
697
+
698
+ ### Framework Versions
699
+ - Python: 3.10.12
700
+ - Sentence Transformers: 3.1.0
701
+ - Transformers: 4.41.2
702
+ - PyTorch: 2.1.2+cu121
703
+ - Accelerate: 0.34.2
704
+ - Datasets: 2.19.1
705
+ - Tokenizers: 0.19.1
706
+
707
+ ## Citation
708
+
709
+ ### BibTeX
710
+
711
+ #### Sentence Transformers
712
+ ```bibtex
713
+ @inproceedings{reimers-2019-sentence-bert,
714
+ title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
715
+ author = "Reimers, Nils and Gurevych, Iryna",
716
+ booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
717
+ month = "11",
718
+ year = "2019",
719
+ publisher = "Association for Computational Linguistics",
720
+ url = "https://arxiv.org/abs/1908.10084",
721
+ }
722
+ ```
723
+
724
+ <!--
725
+ ## Glossary
726
+
727
+ *Clearly define terms in order to be accessible across audiences.*
728
+ -->
729
+
730
+ <!--
731
+ ## Model Card Authors
732
+
733
+ *Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
734
+ -->
735
+
736
+ <!--
737
+ ## Model Card Contact
738
+
739
+ *Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
740
+ -->
config.json ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "intfloat/multilingual-e5-small",
3
+ "architectures": [
4
+ "BertModel"
5
+ ],
6
+ "attention_probs_dropout_prob": 0.1,
7
+ "classifier_dropout": null,
8
+ "hidden_act": "gelu",
9
+ "hidden_dropout_prob": 0.1,
10
+ "hidden_size": 384,
11
+ "initializer_range": 0.02,
12
+ "intermediate_size": 1536,
13
+ "layer_norm_eps": 1e-12,
14
+ "max_position_embeddings": 512,
15
+ "model_type": "bert",
16
+ "num_attention_heads": 12,
17
+ "num_hidden_layers": 12,
18
+ "pad_token_id": 0,
19
+ "position_embedding_type": "absolute",
20
+ "tokenizer_class": "XLMRobertaTokenizer",
21
+ "torch_dtype": "float32",
22
+ "transformers_version": "4.41.2",
23
+ "type_vocab_size": 2,
24
+ "use_cache": true,
25
+ "vocab_size": 250037
26
+ }
config_sentence_transformers.json ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "__version__": {
3
+ "sentence_transformers": "3.1.0",
4
+ "transformers": "4.41.2",
5
+ "pytorch": "2.1.2+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:59f3b341bc463c0db2ab18fc21258e55b2a55a7113cf97830c8816e3ae215977
3
+ size 470637416
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": 512,
3
+ "do_lower_case": false
4
+ }
sentencepiece.bpe.model ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:cfc8146abe2a0488e9e2a0c56de7952f7c11ab059eca145a0a727afce0db2865
3
+ size 5069051
special_tokens_map.json ADDED
@@ -0,0 +1,51 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "bos_token": {
3
+ "content": "<s>",
4
+ "lstrip": false,
5
+ "normalized": false,
6
+ "rstrip": false,
7
+ "single_word": false
8
+ },
9
+ "cls_token": {
10
+ "content": "<s>",
11
+ "lstrip": false,
12
+ "normalized": false,
13
+ "rstrip": false,
14
+ "single_word": false
15
+ },
16
+ "eos_token": {
17
+ "content": "</s>",
18
+ "lstrip": false,
19
+ "normalized": false,
20
+ "rstrip": false,
21
+ "single_word": false
22
+ },
23
+ "mask_token": {
24
+ "content": "<mask>",
25
+ "lstrip": false,
26
+ "normalized": false,
27
+ "rstrip": false,
28
+ "single_word": false
29
+ },
30
+ "pad_token": {
31
+ "content": "<pad>",
32
+ "lstrip": false,
33
+ "normalized": false,
34
+ "rstrip": false,
35
+ "single_word": false
36
+ },
37
+ "sep_token": {
38
+ "content": "</s>",
39
+ "lstrip": false,
40
+ "normalized": false,
41
+ "rstrip": false,
42
+ "single_word": false
43
+ },
44
+ "unk_token": {
45
+ "content": "<unk>",
46
+ "lstrip": false,
47
+ "normalized": false,
48
+ "rstrip": false,
49
+ "single_word": false
50
+ }
51
+ }
tokenizer.json ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ef04f2b385d1514f500e779207ace0f53e30895ce37563179e29f4022d28ca38
3
+ size 17083053
tokenizer_config.json ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "added_tokens_decoder": {
3
+ "0": {
4
+ "content": "<s>",
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": "</s>",
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
+ "250001": {
36
+ "content": "<mask>",
37
+ "lstrip": false,
38
+ "normalized": false,
39
+ "rstrip": false,
40
+ "single_word": false,
41
+ "special": true
42
+ }
43
+ },
44
+ "bos_token": "<s>",
45
+ "clean_up_tokenization_spaces": true,
46
+ "cls_token": "<s>",
47
+ "eos_token": "</s>",
48
+ "mask_token": "<mask>",
49
+ "model_max_length": 512,
50
+ "pad_token": "<pad>",
51
+ "sep_token": "</s>",
52
+ "sp_model_kwargs": {},
53
+ "tokenizer_class": "XLMRobertaTokenizer",
54
+ "unk_token": "<unk>"
55
+ }