srikarvar commited on
Commit
4e4dc22
1 Parent(s): a7717a2

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,731 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ base_model: intfloat/multilingual-e5-small
3
+ datasets: []
4
+ language: []
5
+ library_name: sentence-transformers
6
+ metrics:
7
+ - cosine_accuracy
8
+ - cosine_accuracy_threshold
9
+ - cosine_f1
10
+ - cosine_f1_threshold
11
+ - cosine_precision
12
+ - cosine_recall
13
+ - cosine_ap
14
+ - dot_accuracy
15
+ - dot_accuracy_threshold
16
+ - dot_f1
17
+ - dot_f1_threshold
18
+ - dot_precision
19
+ - dot_recall
20
+ - dot_ap
21
+ - manhattan_accuracy
22
+ - manhattan_accuracy_threshold
23
+ - manhattan_f1
24
+ - manhattan_f1_threshold
25
+ - manhattan_precision
26
+ - manhattan_recall
27
+ - manhattan_ap
28
+ - euclidean_accuracy
29
+ - euclidean_accuracy_threshold
30
+ - euclidean_f1
31
+ - euclidean_f1_threshold
32
+ - euclidean_precision
33
+ - euclidean_recall
34
+ - euclidean_ap
35
+ - max_accuracy
36
+ - max_accuracy_threshold
37
+ - max_f1
38
+ - max_f1_threshold
39
+ - max_precision
40
+ - max_recall
41
+ - max_ap
42
+ pipeline_tag: sentence-similarity
43
+ tags:
44
+ - sentence-transformers
45
+ - sentence-similarity
46
+ - feature-extraction
47
+ - generated_from_trainer
48
+ - dataset_size:2332
49
+ - loss:OnlineContrastiveLoss
50
+ widget:
51
+ - source_sentence: Who discovered the structure of DNA?
52
+ sentences:
53
+ - Who discovered the structure of RNA?
54
+ - Steps to apply for a scholarship
55
+ - First human to set foot on the moon
56
+ - source_sentence: Who directed 'Schindler's List'?
57
+ sentences:
58
+ - Who directed 'The Pianist'?
59
+ - What are some high paying jobs for a fresher with an M.Tech in biotechnology?
60
+ - Where can I find gluten-free restaurants?
61
+ - source_sentence: Which is the best shares to purchase and sale daily trading?
62
+ sentences:
63
+ - In Sydney, which company would be the best to get advice for Business Sales &
64
+ Purchases?
65
+ - Steps to adjust phone settings
66
+ - Is a 3.8 GPA sufficient to get into a top school?
67
+ - source_sentence: Nd she is always sad?
68
+ sentences:
69
+ - Where to purchase organic produce
70
+ - Aerodynamically what happens when propellor rotates?
71
+ - How is unsupervised learning used for data insights?
72
+ - source_sentence: How to bake a pie?
73
+ sentences:
74
+ - What is the population of Chicago?
75
+ - Steps to bake a pie
76
+ - 'What is the distribution of traffic between Google organic search results? e.g.
77
+ #1 vs. #2 in rankings, first page vs. second page'
78
+ model-index:
79
+ - name: SentenceTransformer based on intfloat/multilingual-e5-small
80
+ results:
81
+ - task:
82
+ type: binary-classification
83
+ name: Binary Classification
84
+ dataset:
85
+ name: pair class dev
86
+ type: pair-class-dev
87
+ metrics:
88
+ - type: cosine_accuracy
89
+ value: 0.8653846153846154
90
+ name: Cosine Accuracy
91
+ - type: cosine_accuracy_threshold
92
+ value: 0.872760534286499
93
+ name: Cosine Accuracy Threshold
94
+ - type: cosine_f1
95
+ value: 0.8656716417910447
96
+ name: Cosine F1
97
+ - type: cosine_f1_threshold
98
+ value: 0.8200240135192871
99
+ name: Cosine F1 Threshold
100
+ - type: cosine_precision
101
+ value: 0.8285714285714286
102
+ name: Cosine Precision
103
+ - type: cosine_recall
104
+ value: 0.90625
105
+ name: Cosine Recall
106
+ - type: cosine_ap
107
+ value: 0.9322624848213654
108
+ name: Cosine Ap
109
+ - type: dot_accuracy
110
+ value: 0.8653846153846154
111
+ name: Dot Accuracy
112
+ - type: dot_accuracy_threshold
113
+ value: 0.872760534286499
114
+ name: Dot Accuracy Threshold
115
+ - type: dot_f1
116
+ value: 0.8656716417910447
117
+ name: Dot F1
118
+ - type: dot_f1_threshold
119
+ value: 0.8200240135192871
120
+ name: Dot F1 Threshold
121
+ - type: dot_precision
122
+ value: 0.8285714285714286
123
+ name: Dot Precision
124
+ - type: dot_recall
125
+ value: 0.90625
126
+ name: Dot Recall
127
+ - type: dot_ap
128
+ value: 0.9322624848213654
129
+ name: Dot Ap
130
+ - type: manhattan_accuracy
131
+ value: 0.8692307692307693
132
+ name: Manhattan Accuracy
133
+ - type: manhattan_accuracy_threshold
134
+ value: 9.252302169799805
135
+ name: Manhattan Accuracy Threshold
136
+ - type: manhattan_f1
137
+ value: 0.8721804511278196
138
+ name: Manhattan F1
139
+ - type: manhattan_f1_threshold
140
+ value: 9.252302169799805
141
+ name: Manhattan F1 Threshold
142
+ - type: manhattan_precision
143
+ value: 0.8405797101449275
144
+ name: Manhattan Precision
145
+ - type: manhattan_recall
146
+ value: 0.90625
147
+ name: Manhattan Recall
148
+ - type: manhattan_ap
149
+ value: 0.9322911488571455
150
+ name: Manhattan Ap
151
+ - type: euclidean_accuracy
152
+ value: 0.8653846153846154
153
+ name: Euclidean Accuracy
154
+ - type: euclidean_accuracy_threshold
155
+ value: 0.5044240355491638
156
+ name: Euclidean Accuracy Threshold
157
+ - type: euclidean_f1
158
+ value: 0.8656716417910447
159
+ name: Euclidean F1
160
+ - type: euclidean_f1_threshold
161
+ value: 0.5999571084976196
162
+ name: Euclidean F1 Threshold
163
+ - type: euclidean_precision
164
+ value: 0.8285714285714286
165
+ name: Euclidean Precision
166
+ - type: euclidean_recall
167
+ value: 0.90625
168
+ name: Euclidean Recall
169
+ - type: euclidean_ap
170
+ value: 0.9322624848213654
171
+ name: Euclidean Ap
172
+ - type: max_accuracy
173
+ value: 0.8692307692307693
174
+ name: Max Accuracy
175
+ - type: max_accuracy_threshold
176
+ value: 9.252302169799805
177
+ name: Max Accuracy Threshold
178
+ - type: max_f1
179
+ value: 0.8721804511278196
180
+ name: Max F1
181
+ - type: max_f1_threshold
182
+ value: 9.252302169799805
183
+ name: Max F1 Threshold
184
+ - type: max_precision
185
+ value: 0.8405797101449275
186
+ name: Max Precision
187
+ - type: max_recall
188
+ value: 0.90625
189
+ name: Max Recall
190
+ - type: max_ap
191
+ value: 0.9322911488571455
192
+ name: Max Ap
193
+ - task:
194
+ type: binary-classification
195
+ name: Binary Classification
196
+ dataset:
197
+ name: pair class test
198
+ type: pair-class-test
199
+ metrics:
200
+ - type: cosine_accuracy
201
+ value: 0.916
202
+ name: Cosine Accuracy
203
+ - type: cosine_accuracy_threshold
204
+ value: 0.844039261341095
205
+ name: Cosine Accuracy Threshold
206
+ - type: cosine_f1
207
+ value: 0.907488986784141
208
+ name: Cosine F1
209
+ - type: cosine_f1_threshold
210
+ value: 0.8230063319206238
211
+ name: Cosine F1 Threshold
212
+ - type: cosine_precision
213
+ value: 0.8728813559322034
214
+ name: Cosine Precision
215
+ - type: cosine_recall
216
+ value: 0.944954128440367
217
+ name: Cosine Recall
218
+ - type: cosine_ap
219
+ value: 0.96095333014952
220
+ name: Cosine Ap
221
+ - type: dot_accuracy
222
+ value: 0.916
223
+ name: Dot Accuracy
224
+ - type: dot_accuracy_threshold
225
+ value: 0.8440393209457397
226
+ name: Dot Accuracy Threshold
227
+ - type: dot_f1
228
+ value: 0.907488986784141
229
+ name: Dot F1
230
+ - type: dot_f1_threshold
231
+ value: 0.8230063319206238
232
+ name: Dot F1 Threshold
233
+ - type: dot_precision
234
+ value: 0.8728813559322034
235
+ name: Dot Precision
236
+ - type: dot_recall
237
+ value: 0.944954128440367
238
+ name: Dot Recall
239
+ - type: dot_ap
240
+ value: 0.96095333014952
241
+ name: Dot Ap
242
+ - type: manhattan_accuracy
243
+ value: 0.916
244
+ name: Manhattan Accuracy
245
+ - type: manhattan_accuracy_threshold
246
+ value: 8.581160545349121
247
+ name: Manhattan Accuracy Threshold
248
+ - type: manhattan_f1
249
+ value: 0.907488986784141
250
+ name: Manhattan F1
251
+ - type: manhattan_f1_threshold
252
+ value: 9.327116012573242
253
+ name: Manhattan F1 Threshold
254
+ - type: manhattan_precision
255
+ value: 0.8728813559322034
256
+ name: Manhattan Precision
257
+ - type: manhattan_recall
258
+ value: 0.944954128440367
259
+ name: Manhattan Recall
260
+ - type: manhattan_ap
261
+ value: 0.9612698712458685
262
+ name: Manhattan Ap
263
+ - type: euclidean_accuracy
264
+ value: 0.916
265
+ name: Euclidean Accuracy
266
+ - type: euclidean_accuracy_threshold
267
+ value: 0.5584936141967773
268
+ name: Euclidean Accuracy Threshold
269
+ - type: euclidean_f1
270
+ value: 0.907488986784141
271
+ name: Euclidean F1
272
+ - type: euclidean_f1_threshold
273
+ value: 0.594968318939209
274
+ name: Euclidean F1 Threshold
275
+ - type: euclidean_precision
276
+ value: 0.8728813559322034
277
+ name: Euclidean Precision
278
+ - type: euclidean_recall
279
+ value: 0.944954128440367
280
+ name: Euclidean Recall
281
+ - type: euclidean_ap
282
+ value: 0.96095333014952
283
+ name: Euclidean Ap
284
+ - type: max_accuracy
285
+ value: 0.916
286
+ name: Max Accuracy
287
+ - type: max_accuracy_threshold
288
+ value: 8.581160545349121
289
+ name: Max Accuracy Threshold
290
+ - type: max_f1
291
+ value: 0.907488986784141
292
+ name: Max F1
293
+ - type: max_f1_threshold
294
+ value: 9.327116012573242
295
+ name: Max F1 Threshold
296
+ - type: max_precision
297
+ value: 0.8728813559322034
298
+ name: Max Precision
299
+ - type: max_recall
300
+ value: 0.944954128440367
301
+ name: Max Recall
302
+ - type: max_ap
303
+ value: 0.9612698712458685
304
+ name: Max Ap
305
+ ---
306
+
307
+ # SentenceTransformer based on intfloat/multilingual-e5-small
308
+
309
+ 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.
310
+
311
+ ## Model Details
312
+
313
+ ### Model Description
314
+ - **Model Type:** Sentence Transformer
315
+ - **Base model:** [intfloat/multilingual-e5-small](https://huggingface.co/intfloat/multilingual-e5-small) <!-- at revision fd1525a9fd15316a2d503bf26ab031a61d056e98 -->
316
+ - **Maximum Sequence Length:** 512 tokens
317
+ - **Output Dimensionality:** 384 tokens
318
+ - **Similarity Function:** Cosine Similarity
319
+ <!-- - **Training Dataset:** Unknown -->
320
+ <!-- - **Language:** Unknown -->
321
+ <!-- - **License:** Unknown -->
322
+
323
+ ### Model Sources
324
+
325
+ - **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
326
+ - **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
327
+ - **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
328
+
329
+ ### Full Model Architecture
330
+
331
+ ```
332
+ SentenceTransformer(
333
+ (0): Transformer({'max_seq_length': 512, 'do_lower_case': False}) with Transformer model: BertModel
334
+ (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})
335
+ (2): Normalize()
336
+ )
337
+ ```
338
+
339
+ ## Usage
340
+
341
+ ### Direct Usage (Sentence Transformers)
342
+
343
+ First install the Sentence Transformers library:
344
+
345
+ ```bash
346
+ pip install -U sentence-transformers
347
+ ```
348
+
349
+ Then you can load this model and run inference.
350
+ ```python
351
+ from sentence_transformers import SentenceTransformer
352
+
353
+ # Download from the 🤗 Hub
354
+ model = SentenceTransformer("srikarvar/fine_tuned_model_5")
355
+ # Run inference
356
+ sentences = [
357
+ 'How to bake a pie?',
358
+ 'Steps to bake a pie',
359
+ 'What is the population of Chicago?',
360
+ ]
361
+ embeddings = model.encode(sentences)
362
+ print(embeddings.shape)
363
+ # [3, 384]
364
+
365
+ # Get the similarity scores for the embeddings
366
+ similarities = model.similarity(embeddings, embeddings)
367
+ print(similarities.shape)
368
+ # [3, 3]
369
+ ```
370
+
371
+ <!--
372
+ ### Direct Usage (Transformers)
373
+
374
+ <details><summary>Click to see the direct usage in Transformers</summary>
375
+
376
+ </details>
377
+ -->
378
+
379
+ <!--
380
+ ### Downstream Usage (Sentence Transformers)
381
+
382
+ You can finetune this model on your own dataset.
383
+
384
+ <details><summary>Click to expand</summary>
385
+
386
+ </details>
387
+ -->
388
+
389
+ <!--
390
+ ### Out-of-Scope Use
391
+
392
+ *List how the model may foreseeably be misused and address what users ought not to do with the model.*
393
+ -->
394
+
395
+ ## Evaluation
396
+
397
+ ### Metrics
398
+
399
+ #### Binary Classification
400
+ * Dataset: `pair-class-dev`
401
+ * Evaluated with [<code>BinaryClassificationEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.BinaryClassificationEvaluator)
402
+
403
+ | Metric | Value |
404
+ |:-----------------------------|:-----------|
405
+ | cosine_accuracy | 0.8654 |
406
+ | cosine_accuracy_threshold | 0.8728 |
407
+ | cosine_f1 | 0.8657 |
408
+ | cosine_f1_threshold | 0.82 |
409
+ | cosine_precision | 0.8286 |
410
+ | cosine_recall | 0.9062 |
411
+ | cosine_ap | 0.9323 |
412
+ | dot_accuracy | 0.8654 |
413
+ | dot_accuracy_threshold | 0.8728 |
414
+ | dot_f1 | 0.8657 |
415
+ | dot_f1_threshold | 0.82 |
416
+ | dot_precision | 0.8286 |
417
+ | dot_recall | 0.9062 |
418
+ | dot_ap | 0.9323 |
419
+ | manhattan_accuracy | 0.8692 |
420
+ | manhattan_accuracy_threshold | 9.2523 |
421
+ | manhattan_f1 | 0.8722 |
422
+ | manhattan_f1_threshold | 9.2523 |
423
+ | manhattan_precision | 0.8406 |
424
+ | manhattan_recall | 0.9062 |
425
+ | manhattan_ap | 0.9323 |
426
+ | euclidean_accuracy | 0.8654 |
427
+ | euclidean_accuracy_threshold | 0.5044 |
428
+ | euclidean_f1 | 0.8657 |
429
+ | euclidean_f1_threshold | 0.6 |
430
+ | euclidean_precision | 0.8286 |
431
+ | euclidean_recall | 0.9062 |
432
+ | euclidean_ap | 0.9323 |
433
+ | max_accuracy | 0.8692 |
434
+ | max_accuracy_threshold | 9.2523 |
435
+ | max_f1 | 0.8722 |
436
+ | max_f1_threshold | 9.2523 |
437
+ | max_precision | 0.8406 |
438
+ | max_recall | 0.9062 |
439
+ | **max_ap** | **0.9323** |
440
+
441
+ #### Binary Classification
442
+ * Dataset: `pair-class-test`
443
+ * Evaluated with [<code>BinaryClassificationEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.BinaryClassificationEvaluator)
444
+
445
+ | Metric | Value |
446
+ |:-----------------------------|:-----------|
447
+ | cosine_accuracy | 0.916 |
448
+ | cosine_accuracy_threshold | 0.844 |
449
+ | cosine_f1 | 0.9075 |
450
+ | cosine_f1_threshold | 0.823 |
451
+ | cosine_precision | 0.8729 |
452
+ | cosine_recall | 0.945 |
453
+ | cosine_ap | 0.961 |
454
+ | dot_accuracy | 0.916 |
455
+ | dot_accuracy_threshold | 0.844 |
456
+ | dot_f1 | 0.9075 |
457
+ | dot_f1_threshold | 0.823 |
458
+ | dot_precision | 0.8729 |
459
+ | dot_recall | 0.945 |
460
+ | dot_ap | 0.961 |
461
+ | manhattan_accuracy | 0.916 |
462
+ | manhattan_accuracy_threshold | 8.5812 |
463
+ | manhattan_f1 | 0.9075 |
464
+ | manhattan_f1_threshold | 9.3271 |
465
+ | manhattan_precision | 0.8729 |
466
+ | manhattan_recall | 0.945 |
467
+ | manhattan_ap | 0.9613 |
468
+ | euclidean_accuracy | 0.916 |
469
+ | euclidean_accuracy_threshold | 0.5585 |
470
+ | euclidean_f1 | 0.9075 |
471
+ | euclidean_f1_threshold | 0.595 |
472
+ | euclidean_precision | 0.8729 |
473
+ | euclidean_recall | 0.945 |
474
+ | euclidean_ap | 0.961 |
475
+ | max_accuracy | 0.916 |
476
+ | max_accuracy_threshold | 8.5812 |
477
+ | max_f1 | 0.9075 |
478
+ | max_f1_threshold | 9.3271 |
479
+ | max_precision | 0.8729 |
480
+ | max_recall | 0.945 |
481
+ | **max_ap** | **0.9613** |
482
+
483
+ <!--
484
+ ## Bias, Risks and Limitations
485
+
486
+ *What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
487
+ -->
488
+
489
+ <!--
490
+ ### Recommendations
491
+
492
+ *What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
493
+ -->
494
+
495
+ ## Training Details
496
+
497
+ ### Training Dataset
498
+
499
+ #### Unnamed Dataset
500
+
501
+
502
+ * Size: 2,332 training samples
503
+ * Columns: <code>sentence1</code>, <code>sentence2</code>, and <code>label</code>
504
+ * Approximate statistics based on the first 1000 samples:
505
+ | | sentence1 | sentence2 | label |
506
+ |:--------|:----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|:------------------------------------------------|
507
+ | type | string | string | int |
508
+ | details | <ul><li>min: 6 tokens</li><li>mean: 12.96 tokens</li><li>max: 66 tokens</li></ul> | <ul><li>min: 5 tokens</li><li>mean: 12.67 tokens</li><li>max: 55 tokens</li></ul> | <ul><li>0: ~52.80%</li><li>1: ~47.20%</li></ul> |
509
+ * Samples:
510
+ | sentence1 | sentence2 | label |
511
+ |:-----------------------------------------------------------------------|:---------------------------------------------------------|:---------------|
512
+ | <code>How to bake a chocolate cake?</code> | <code>Recipe for baking a chocolate cake</code> | <code>1</code> |
513
+ | <code>Why do girls want to be friends with the guy they reject?</code> | <code>How do guys feel after rejecting a girl?</code> | <code>0</code> |
514
+ | <code>How can I stop being afraid of working?</code> | <code>How do you stop being afraid of everything?</code> | <code>0</code> |
515
+ * Loss: [<code>OnlineContrastiveLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#onlinecontrastiveloss)
516
+
517
+ ### Evaluation Dataset
518
+
519
+ #### Unnamed Dataset
520
+
521
+
522
+ * Size: 260 evaluation samples
523
+ * Columns: <code>sentence1</code>, <code>sentence2</code>, and <code>label</code>
524
+ * Approximate statistics based on the first 1000 samples:
525
+ | | sentence1 | sentence2 | label |
526
+ |:--------|:----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|:------------------------------------------------|
527
+ | type | string | string | int |
528
+ | details | <ul><li>min: 6 tokens</li><li>mean: 13.44 tokens</li><li>max: 39 tokens</li></ul> | <ul><li>min: 4 tokens</li><li>mean: 12.99 tokens</li><li>max: 50 tokens</li></ul> | <ul><li>0: ~50.77%</li><li>1: ~49.23%</li></ul> |
529
+ * Samples:
530
+ | sentence1 | sentence2 | label |
531
+ |:-----------------------------------------|:--------------------------------------------------|:---------------|
532
+ | <code>How to cook spaghetti?</code> | <code>Steps to cook spaghetti</code> | <code>1</code> |
533
+ | <code>How to create a mobile app?</code> | <code>How to create a desktop application?</code> | <code>0</code> |
534
+ | <code>How can I update my resume?</code> | <code>Steps to revise and update a resume</code> | <code>1</code> |
535
+ * Loss: [<code>OnlineContrastiveLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#onlinecontrastiveloss)
536
+
537
+ ### Training Hyperparameters
538
+ #### Non-Default Hyperparameters
539
+
540
+ - `eval_strategy`: epoch
541
+ - `per_device_train_batch_size`: 32
542
+ - `per_device_eval_batch_size`: 32
543
+ - `gradient_accumulation_steps`: 2
544
+ - `num_train_epochs`: 4
545
+ - `warmup_ratio`: 0.1
546
+ - `load_best_model_at_end`: True
547
+ - `optim`: adamw_torch_fused
548
+ - `batch_sampler`: no_duplicates
549
+
550
+ #### All Hyperparameters
551
+ <details><summary>Click to expand</summary>
552
+
553
+ - `overwrite_output_dir`: False
554
+ - `do_predict`: False
555
+ - `eval_strategy`: epoch
556
+ - `prediction_loss_only`: True
557
+ - `per_device_train_batch_size`: 32
558
+ - `per_device_eval_batch_size`: 32
559
+ - `per_gpu_train_batch_size`: None
560
+ - `per_gpu_eval_batch_size`: None
561
+ - `gradient_accumulation_steps`: 2
562
+ - `eval_accumulation_steps`: None
563
+ - `learning_rate`: 5e-05
564
+ - `weight_decay`: 0.0
565
+ - `adam_beta1`: 0.9
566
+ - `adam_beta2`: 0.999
567
+ - `adam_epsilon`: 1e-08
568
+ - `max_grad_norm`: 1.0
569
+ - `num_train_epochs`: 4
570
+ - `max_steps`: -1
571
+ - `lr_scheduler_type`: linear
572
+ - `lr_scheduler_kwargs`: {}
573
+ - `warmup_ratio`: 0.1
574
+ - `warmup_steps`: 0
575
+ - `log_level`: passive
576
+ - `log_level_replica`: warning
577
+ - `log_on_each_node`: True
578
+ - `logging_nan_inf_filter`: True
579
+ - `save_safetensors`: True
580
+ - `save_on_each_node`: False
581
+ - `save_only_model`: False
582
+ - `restore_callback_states_from_checkpoint`: False
583
+ - `no_cuda`: False
584
+ - `use_cpu`: False
585
+ - `use_mps_device`: False
586
+ - `seed`: 42
587
+ - `data_seed`: None
588
+ - `jit_mode_eval`: False
589
+ - `use_ipex`: False
590
+ - `bf16`: False
591
+ - `fp16`: False
592
+ - `fp16_opt_level`: O1
593
+ - `half_precision_backend`: auto
594
+ - `bf16_full_eval`: False
595
+ - `fp16_full_eval`: False
596
+ - `tf32`: None
597
+ - `local_rank`: 0
598
+ - `ddp_backend`: None
599
+ - `tpu_num_cores`: None
600
+ - `tpu_metrics_debug`: False
601
+ - `debug`: []
602
+ - `dataloader_drop_last`: False
603
+ - `dataloader_num_workers`: 0
604
+ - `dataloader_prefetch_factor`: None
605
+ - `past_index`: -1
606
+ - `disable_tqdm`: False
607
+ - `remove_unused_columns`: True
608
+ - `label_names`: None
609
+ - `load_best_model_at_end`: True
610
+ - `ignore_data_skip`: False
611
+ - `fsdp`: []
612
+ - `fsdp_min_num_params`: 0
613
+ - `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
614
+ - `fsdp_transformer_layer_cls_to_wrap`: None
615
+ - `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
616
+ - `deepspeed`: None
617
+ - `label_smoothing_factor`: 0.0
618
+ - `optim`: adamw_torch_fused
619
+ - `optim_args`: None
620
+ - `adafactor`: False
621
+ - `group_by_length`: False
622
+ - `length_column_name`: length
623
+ - `ddp_find_unused_parameters`: None
624
+ - `ddp_bucket_cap_mb`: None
625
+ - `ddp_broadcast_buffers`: False
626
+ - `dataloader_pin_memory`: True
627
+ - `dataloader_persistent_workers`: False
628
+ - `skip_memory_metrics`: True
629
+ - `use_legacy_prediction_loop`: False
630
+ - `push_to_hub`: False
631
+ - `resume_from_checkpoint`: None
632
+ - `hub_model_id`: None
633
+ - `hub_strategy`: every_save
634
+ - `hub_private_repo`: False
635
+ - `hub_always_push`: False
636
+ - `gradient_checkpointing`: False
637
+ - `gradient_checkpointing_kwargs`: None
638
+ - `include_inputs_for_metrics`: False
639
+ - `eval_do_concat_batches`: True
640
+ - `fp16_backend`: auto
641
+ - `push_to_hub_model_id`: None
642
+ - `push_to_hub_organization`: None
643
+ - `mp_parameters`:
644
+ - `auto_find_batch_size`: False
645
+ - `full_determinism`: False
646
+ - `torchdynamo`: None
647
+ - `ray_scope`: last
648
+ - `ddp_timeout`: 1800
649
+ - `torch_compile`: False
650
+ - `torch_compile_backend`: None
651
+ - `torch_compile_mode`: None
652
+ - `dispatch_batches`: None
653
+ - `split_batches`: None
654
+ - `include_tokens_per_second`: False
655
+ - `include_num_input_tokens_seen`: False
656
+ - `neftune_noise_alpha`: None
657
+ - `optim_target_modules`: None
658
+ - `batch_eval_metrics`: False
659
+ - `batch_sampler`: no_duplicates
660
+ - `multi_dataset_batch_sampler`: proportional
661
+
662
+ </details>
663
+
664
+ ### Training Logs
665
+ | Epoch | Step | Training Loss | loss | pair-class-dev_max_ap | pair-class-test_max_ap |
666
+ |:-------:|:------:|:-------------:|:----------:|:---------------------:|:----------------------:|
667
+ | 0 | 0 | - | - | 0.6979 | - |
668
+ | 0.2740 | 10 | 1.9007 | - | - | - |
669
+ | 0.5479 | 20 | 1.1616 | - | - | - |
670
+ | 0.8219 | 30 | 0.9094 | - | - | - |
671
+ | 0.9863 | 36 | - | 0.7692 | 0.9117 | - |
672
+ | 1.0959 | 40 | 0.9105 | - | - | - |
673
+ | 1.3699 | 50 | 0.6629 | - | - | - |
674
+ | 1.6438 | 60 | 0.4243 | - | - | - |
675
+ | 1.9178 | 70 | 0.4729 | - | - | - |
676
+ | **2.0** | **73** | **-** | **0.7294** | **0.9306** | **-** |
677
+ | 2.1918 | 80 | 0.4897 | - | - | - |
678
+ | 2.4658 | 90 | 0.3103 | - | - | - |
679
+ | 2.7397 | 100 | 0.2316 | - | - | - |
680
+ | 2.9863 | 109 | - | 0.7807 | 0.9311 | - |
681
+ | 3.0137 | 110 | 0.3179 | - | - | - |
682
+ | 3.2877 | 120 | 0.1975 | - | - | - |
683
+ | 3.5616 | 130 | 0.1477 | - | - | - |
684
+ | 3.8356 | 140 | 0.1034 | - | - | - |
685
+ | 3.9452 | 144 | - | 0.8132 | 0.9323 | 0.9613 |
686
+
687
+ * The bold row denotes the saved checkpoint.
688
+
689
+ ### Framework Versions
690
+ - Python: 3.10.12
691
+ - Sentence Transformers: 3.0.1
692
+ - Transformers: 4.41.2
693
+ - PyTorch: 2.1.2+cu121
694
+ - Accelerate: 0.32.1
695
+ - Datasets: 2.19.1
696
+ - Tokenizers: 0.19.1
697
+
698
+ ## Citation
699
+
700
+ ### BibTeX
701
+
702
+ #### Sentence Transformers
703
+ ```bibtex
704
+ @inproceedings{reimers-2019-sentence-bert,
705
+ title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
706
+ author = "Reimers, Nils and Gurevych, Iryna",
707
+ booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
708
+ month = "11",
709
+ year = "2019",
710
+ publisher = "Association for Computational Linguistics",
711
+ url = "https://arxiv.org/abs/1908.10084",
712
+ }
713
+ ```
714
+
715
+ <!--
716
+ ## Glossary
717
+
718
+ *Clearly define terms in order to be accessible across audiences.*
719
+ -->
720
+
721
+ <!--
722
+ ## Model Card Authors
723
+
724
+ *Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
725
+ -->
726
+
727
+ <!--
728
+ ## Model Card Contact
729
+
730
+ *Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
731
+ -->
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.0.1",
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:c0ea587c193a9c81dab3dd26fd3a48a49962b049a8333517b93edb4b484c49cf
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
+ }