MarekMarik commited on
Commit
980729c
·
verified ·
1 Parent(s): 47fcfa5

Add new SentenceTransformer model

Browse files
1_Pooling/config.json ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "word_embedding_dimension": 768,
3
+ "pooling_mode_cls_token": true,
4
+ "pooling_mode_mean_tokens": false,
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,763 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ language:
3
+ - en
4
+ license: apache-2.0
5
+ tags:
6
+ - sentence-transformers
7
+ - sentence-similarity
8
+ - feature-extraction
9
+ - generated_from_trainer
10
+ - dataset_size:6300
11
+ - loss:MatryoshkaLoss
12
+ - loss:MultipleNegativesRankingLoss
13
+ base_model: BAAI/bge-base-en-v1.5
14
+ widget:
15
+ - source_sentence: Health Care Benefits revenue is principally derived from insurance
16
+ premiums and fees billed to customers.
17
+ sentences:
18
+ - How much was the cumulative impairment and downward adjustments for observable
19
+ price changes for the equity investments without readily determinable fair values
20
+ as of December 31, 2023?
21
+ - What are the revenue sources for the Company’s Health Care Benefits Segment?
22
+ - What types of legal issues are generally categorized under Commitments and Contingencies
23
+ in a Form 10-K?
24
+ - source_sentence: Total net sales increased by 7% during the fiscal year ending December
25
+ 30, 2023 compared to the previous fiscal year.
26
+ sentences:
27
+ - What was the percentage increase in Data Center revenue for fiscal year 2023 compared
28
+ to the previous year?
29
+ - What was the percentage increase in total net sales during the fiscal year ending
30
+ December 30, 2023 compared to the previous fiscal year?
31
+ - What were the expenses related to the fair value of restricted stock units (RSUs)
32
+ and stock options for the years 2022, 2021, and 2020?
33
+ - source_sentence: The laws and regulations of the jurisdictions in which our insurance
34
+ and reinsurance subsidiaries are domiciled require among other things that these
35
+ subsidiaries maintain minimum levels of statutory capital, surplus, and liquidity,
36
+ meet solvency standards, and submit to periodic examinations of their financial
37
+ condition.
38
+ sentences:
39
+ - What statutory requirements must insurance and reinsurance subsidiaries meet in
40
+ their domiciled jurisdictions?
41
+ - What activities has the federal government used the FCA to prosecute?
42
+ - How are self-insurance reserves computed and presented in financial statements?
43
+ - source_sentence: Services net sales increased 9% or $7.1 billion during 2023 compared
44
+ to 2022 due to higher net sales across all lines of business.
45
+ sentences:
46
+ - What is the leverage ratio requirement under the company's financial covenant
47
+ as of January 28, 2023?
48
+ - What are the enrollment periods for Medicare Advantage and stand-alone prescription
49
+ drug plans?
50
+ - What was the percentage increase in Services net sales from 2022 to 2023?
51
+ - source_sentence: Certain vendors have been impacted by volatility in the supply
52
+ chain financing market.
53
+ sentences:
54
+ - How have certain vendors been impacted in the supply chain financing market?
55
+ - What was the total value of the company's cash commitments as of December 31,
56
+ 2023?
57
+ - What are the key components used to define free cash flow in financial evaluations?
58
+ pipeline_tag: sentence-similarity
59
+ library_name: sentence-transformers
60
+ metrics:
61
+ - cosine_accuracy@1
62
+ - cosine_accuracy@3
63
+ - cosine_accuracy@5
64
+ - cosine_accuracy@10
65
+ - cosine_precision@1
66
+ - cosine_precision@3
67
+ - cosine_precision@5
68
+ - cosine_precision@10
69
+ - cosine_recall@1
70
+ - cosine_recall@3
71
+ - cosine_recall@5
72
+ - cosine_recall@10
73
+ - cosine_ndcg@10
74
+ - cosine_mrr@10
75
+ - cosine_map@100
76
+ model-index:
77
+ - name: BGE base Financial Matryoshka
78
+ results:
79
+ - task:
80
+ type: information-retrieval
81
+ name: Information Retrieval
82
+ dataset:
83
+ name: dim 768
84
+ type: dim_768
85
+ metrics:
86
+ - type: cosine_accuracy@1
87
+ value: 0.6871428571428572
88
+ name: Cosine Accuracy@1
89
+ - type: cosine_accuracy@3
90
+ value: 0.8171428571428572
91
+ name: Cosine Accuracy@3
92
+ - type: cosine_accuracy@5
93
+ value: 0.8485714285714285
94
+ name: Cosine Accuracy@5
95
+ - type: cosine_accuracy@10
96
+ value: 0.9085714285714286
97
+ name: Cosine Accuracy@10
98
+ - type: cosine_precision@1
99
+ value: 0.6871428571428572
100
+ name: Cosine Precision@1
101
+ - type: cosine_precision@3
102
+ value: 0.2723809523809524
103
+ name: Cosine Precision@3
104
+ - type: cosine_precision@5
105
+ value: 0.16971428571428568
106
+ name: Cosine Precision@5
107
+ - type: cosine_precision@10
108
+ value: 0.09085714285714284
109
+ name: Cosine Precision@10
110
+ - type: cosine_recall@1
111
+ value: 0.6871428571428572
112
+ name: Cosine Recall@1
113
+ - type: cosine_recall@3
114
+ value: 0.8171428571428572
115
+ name: Cosine Recall@3
116
+ - type: cosine_recall@5
117
+ value: 0.8485714285714285
118
+ name: Cosine Recall@5
119
+ - type: cosine_recall@10
120
+ value: 0.9085714285714286
121
+ name: Cosine Recall@10
122
+ - type: cosine_ndcg@10
123
+ value: 0.7960378752604689
124
+ name: Cosine Ndcg@10
125
+ - type: cosine_mrr@10
126
+ value: 0.7603769841269836
127
+ name: Cosine Mrr@10
128
+ - type: cosine_map@100
129
+ value: 0.7640840138316877
130
+ name: Cosine Map@100
131
+ - task:
132
+ type: information-retrieval
133
+ name: Information Retrieval
134
+ dataset:
135
+ name: dim 512
136
+ type: dim_512
137
+ metrics:
138
+ - type: cosine_accuracy@1
139
+ value: 0.6828571428571428
140
+ name: Cosine Accuracy@1
141
+ - type: cosine_accuracy@3
142
+ value: 0.8114285714285714
143
+ name: Cosine Accuracy@3
144
+ - type: cosine_accuracy@5
145
+ value: 0.8528571428571429
146
+ name: Cosine Accuracy@5
147
+ - type: cosine_accuracy@10
148
+ value: 0.9085714285714286
149
+ name: Cosine Accuracy@10
150
+ - type: cosine_precision@1
151
+ value: 0.6828571428571428
152
+ name: Cosine Precision@1
153
+ - type: cosine_precision@3
154
+ value: 0.2704761904761904
155
+ name: Cosine Precision@3
156
+ - type: cosine_precision@5
157
+ value: 0.17057142857142857
158
+ name: Cosine Precision@5
159
+ - type: cosine_precision@10
160
+ value: 0.09085714285714284
161
+ name: Cosine Precision@10
162
+ - type: cosine_recall@1
163
+ value: 0.6828571428571428
164
+ name: Cosine Recall@1
165
+ - type: cosine_recall@3
166
+ value: 0.8114285714285714
167
+ name: Cosine Recall@3
168
+ - type: cosine_recall@5
169
+ value: 0.8528571428571429
170
+ name: Cosine Recall@5
171
+ - type: cosine_recall@10
172
+ value: 0.9085714285714286
173
+ name: Cosine Recall@10
174
+ - type: cosine_ndcg@10
175
+ value: 0.7936620196836198
176
+ name: Cosine Ndcg@10
177
+ - type: cosine_mrr@10
178
+ value: 0.7572222222222219
179
+ name: Cosine Mrr@10
180
+ - type: cosine_map@100
181
+ value: 0.7609298999926937
182
+ name: Cosine Map@100
183
+ - task:
184
+ type: information-retrieval
185
+ name: Information Retrieval
186
+ dataset:
187
+ name: dim 256
188
+ type: dim_256
189
+ metrics:
190
+ - type: cosine_accuracy@1
191
+ value: 0.68
192
+ name: Cosine Accuracy@1
193
+ - type: cosine_accuracy@3
194
+ value: 0.8071428571428572
195
+ name: Cosine Accuracy@3
196
+ - type: cosine_accuracy@5
197
+ value: 0.8485714285714285
198
+ name: Cosine Accuracy@5
199
+ - type: cosine_accuracy@10
200
+ value: 0.8957142857142857
201
+ name: Cosine Accuracy@10
202
+ - type: cosine_precision@1
203
+ value: 0.68
204
+ name: Cosine Precision@1
205
+ - type: cosine_precision@3
206
+ value: 0.26904761904761904
207
+ name: Cosine Precision@3
208
+ - type: cosine_precision@5
209
+ value: 0.16971428571428568
210
+ name: Cosine Precision@5
211
+ - type: cosine_precision@10
212
+ value: 0.08957142857142855
213
+ name: Cosine Precision@10
214
+ - type: cosine_recall@1
215
+ value: 0.68
216
+ name: Cosine Recall@1
217
+ - type: cosine_recall@3
218
+ value: 0.8071428571428572
219
+ name: Cosine Recall@3
220
+ - type: cosine_recall@5
221
+ value: 0.8485714285714285
222
+ name: Cosine Recall@5
223
+ - type: cosine_recall@10
224
+ value: 0.8957142857142857
225
+ name: Cosine Recall@10
226
+ - type: cosine_ndcg@10
227
+ value: 0.7883110340362532
228
+ name: Cosine Ndcg@10
229
+ - type: cosine_mrr@10
230
+ value: 0.7539733560090701
231
+ name: Cosine Mrr@10
232
+ - type: cosine_map@100
233
+ value: 0.7582685695127231
234
+ name: Cosine Map@100
235
+ - task:
236
+ type: information-retrieval
237
+ name: Information Retrieval
238
+ dataset:
239
+ name: dim 128
240
+ type: dim_128
241
+ metrics:
242
+ - type: cosine_accuracy@1
243
+ value: 0.6585714285714286
244
+ name: Cosine Accuracy@1
245
+ - type: cosine_accuracy@3
246
+ value: 0.7942857142857143
247
+ name: Cosine Accuracy@3
248
+ - type: cosine_accuracy@5
249
+ value: 0.83
250
+ name: Cosine Accuracy@5
251
+ - type: cosine_accuracy@10
252
+ value: 0.8842857142857142
253
+ name: Cosine Accuracy@10
254
+ - type: cosine_precision@1
255
+ value: 0.6585714285714286
256
+ name: Cosine Precision@1
257
+ - type: cosine_precision@3
258
+ value: 0.26476190476190475
259
+ name: Cosine Precision@3
260
+ - type: cosine_precision@5
261
+ value: 0.16599999999999998
262
+ name: Cosine Precision@5
263
+ - type: cosine_precision@10
264
+ value: 0.08842857142857141
265
+ name: Cosine Precision@10
266
+ - type: cosine_recall@1
267
+ value: 0.6585714285714286
268
+ name: Cosine Recall@1
269
+ - type: cosine_recall@3
270
+ value: 0.7942857142857143
271
+ name: Cosine Recall@3
272
+ - type: cosine_recall@5
273
+ value: 0.83
274
+ name: Cosine Recall@5
275
+ - type: cosine_recall@10
276
+ value: 0.8842857142857142
277
+ name: Cosine Recall@10
278
+ - type: cosine_ndcg@10
279
+ value: 0.7727884715594033
280
+ name: Cosine Ndcg@10
281
+ - type: cosine_mrr@10
282
+ value: 0.737036848072562
283
+ name: Cosine Mrr@10
284
+ - type: cosine_map@100
285
+ value: 0.7419081242961935
286
+ name: Cosine Map@100
287
+ - task:
288
+ type: information-retrieval
289
+ name: Information Retrieval
290
+ dataset:
291
+ name: dim 64
292
+ type: dim_64
293
+ metrics:
294
+ - type: cosine_accuracy@1
295
+ value: 0.6357142857142857
296
+ name: Cosine Accuracy@1
297
+ - type: cosine_accuracy@3
298
+ value: 0.7628571428571429
299
+ name: Cosine Accuracy@3
300
+ - type: cosine_accuracy@5
301
+ value: 0.8142857142857143
302
+ name: Cosine Accuracy@5
303
+ - type: cosine_accuracy@10
304
+ value: 0.87
305
+ name: Cosine Accuracy@10
306
+ - type: cosine_precision@1
307
+ value: 0.6357142857142857
308
+ name: Cosine Precision@1
309
+ - type: cosine_precision@3
310
+ value: 0.2542857142857142
311
+ name: Cosine Precision@3
312
+ - type: cosine_precision@5
313
+ value: 0.16285714285714287
314
+ name: Cosine Precision@5
315
+ - type: cosine_precision@10
316
+ value: 0.087
317
+ name: Cosine Precision@10
318
+ - type: cosine_recall@1
319
+ value: 0.6357142857142857
320
+ name: Cosine Recall@1
321
+ - type: cosine_recall@3
322
+ value: 0.7628571428571429
323
+ name: Cosine Recall@3
324
+ - type: cosine_recall@5
325
+ value: 0.8142857142857143
326
+ name: Cosine Recall@5
327
+ - type: cosine_recall@10
328
+ value: 0.87
329
+ name: Cosine Recall@10
330
+ - type: cosine_ndcg@10
331
+ value: 0.7501277228250628
332
+ name: Cosine Ndcg@10
333
+ - type: cosine_mrr@10
334
+ value: 0.7121167800453513
335
+ name: Cosine Mrr@10
336
+ - type: cosine_map@100
337
+ value: 0.7171110018302509
338
+ name: Cosine Map@100
339
+ ---
340
+
341
+ # BGE base Financial Matryoshka
342
+
343
+ This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [BAAI/bge-base-en-v1.5](https://huggingface.co/BAAI/bge-base-en-v1.5) on the json dataset. It maps sentences & paragraphs to a 768-dimensional dense vector space and can be used for semantic textual similarity, semantic search, paraphrase mining, text classification, clustering, and more.
344
+
345
+ ## Model Details
346
+
347
+ ### Model Description
348
+ - **Model Type:** Sentence Transformer
349
+ - **Base model:** [BAAI/bge-base-en-v1.5](https://huggingface.co/BAAI/bge-base-en-v1.5) <!-- at revision a5beb1e3e68b9ab74eb54cfd186867f64f240e1a -->
350
+ - **Maximum Sequence Length:** 512 tokens
351
+ - **Output Dimensionality:** 768 dimensions
352
+ - **Similarity Function:** Cosine Similarity
353
+ - **Training Dataset:**
354
+ - json
355
+ - **Language:** en
356
+ - **License:** apache-2.0
357
+
358
+ ### Model Sources
359
+
360
+ - **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
361
+ - **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
362
+ - **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
363
+
364
+ ### Full Model Architecture
365
+
366
+ ```
367
+ SentenceTransformer(
368
+ (0): Transformer({'max_seq_length': 512, 'do_lower_case': True}) with Transformer model: BertModel
369
+ (1): Pooling({'word_embedding_dimension': 768, 'pooling_mode_cls_token': True, 'pooling_mode_mean_tokens': False, 'pooling_mode_max_tokens': False, 'pooling_mode_mean_sqrt_len_tokens': False, 'pooling_mode_weightedmean_tokens': False, 'pooling_mode_lasttoken': False, 'include_prompt': True})
370
+ (2): Normalize()
371
+ )
372
+ ```
373
+
374
+ ## Usage
375
+
376
+ ### Direct Usage (Sentence Transformers)
377
+
378
+ First install the Sentence Transformers library:
379
+
380
+ ```bash
381
+ pip install -U sentence-transformers
382
+ ```
383
+
384
+ Then you can load this model and run inference.
385
+ ```python
386
+ from sentence_transformers import SentenceTransformer
387
+
388
+ # Download from the 🤗 Hub
389
+ model = SentenceTransformer("MarekMarik/bge-base-financial-matryoshka")
390
+ # Run inference
391
+ sentences = [
392
+ 'Certain vendors have been impacted by volatility in the supply chain financing market.',
393
+ 'How have certain vendors been impacted in the supply chain financing market?',
394
+ "What was the total value of the company's cash commitments as of December 31, 2023?",
395
+ ]
396
+ embeddings = model.encode(sentences)
397
+ print(embeddings.shape)
398
+ # [3, 768]
399
+
400
+ # Get the similarity scores for the embeddings
401
+ similarities = model.similarity(embeddings, embeddings)
402
+ print(similarities.shape)
403
+ # [3, 3]
404
+ ```
405
+
406
+ <!--
407
+ ### Direct Usage (Transformers)
408
+
409
+ <details><summary>Click to see the direct usage in Transformers</summary>
410
+
411
+ </details>
412
+ -->
413
+
414
+ <!--
415
+ ### Downstream Usage (Sentence Transformers)
416
+
417
+ You can finetune this model on your own dataset.
418
+
419
+ <details><summary>Click to expand</summary>
420
+
421
+ </details>
422
+ -->
423
+
424
+ <!--
425
+ ### Out-of-Scope Use
426
+
427
+ *List how the model may foreseeably be misused and address what users ought not to do with the model.*
428
+ -->
429
+
430
+ ## Evaluation
431
+
432
+ ### Metrics
433
+
434
+ #### Information Retrieval
435
+
436
+ * Datasets: `dim_768`, `dim_512`, `dim_256`, `dim_128` and `dim_64`
437
+ * Evaluated with [<code>InformationRetrievalEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.InformationRetrievalEvaluator)
438
+
439
+ | Metric | dim_768 | dim_512 | dim_256 | dim_128 | dim_64 |
440
+ |:--------------------|:----------|:-----------|:-----------|:-----------|:-----------|
441
+ | cosine_accuracy@1 | 0.6871 | 0.6829 | 0.68 | 0.6586 | 0.6357 |
442
+ | cosine_accuracy@3 | 0.8171 | 0.8114 | 0.8071 | 0.7943 | 0.7629 |
443
+ | cosine_accuracy@5 | 0.8486 | 0.8529 | 0.8486 | 0.83 | 0.8143 |
444
+ | cosine_accuracy@10 | 0.9086 | 0.9086 | 0.8957 | 0.8843 | 0.87 |
445
+ | cosine_precision@1 | 0.6871 | 0.6829 | 0.68 | 0.6586 | 0.6357 |
446
+ | cosine_precision@3 | 0.2724 | 0.2705 | 0.269 | 0.2648 | 0.2543 |
447
+ | cosine_precision@5 | 0.1697 | 0.1706 | 0.1697 | 0.166 | 0.1629 |
448
+ | cosine_precision@10 | 0.0909 | 0.0909 | 0.0896 | 0.0884 | 0.087 |
449
+ | cosine_recall@1 | 0.6871 | 0.6829 | 0.68 | 0.6586 | 0.6357 |
450
+ | cosine_recall@3 | 0.8171 | 0.8114 | 0.8071 | 0.7943 | 0.7629 |
451
+ | cosine_recall@5 | 0.8486 | 0.8529 | 0.8486 | 0.83 | 0.8143 |
452
+ | cosine_recall@10 | 0.9086 | 0.9086 | 0.8957 | 0.8843 | 0.87 |
453
+ | **cosine_ndcg@10** | **0.796** | **0.7937** | **0.7883** | **0.7728** | **0.7501** |
454
+ | cosine_mrr@10 | 0.7604 | 0.7572 | 0.754 | 0.737 | 0.7121 |
455
+ | cosine_map@100 | 0.7641 | 0.7609 | 0.7583 | 0.7419 | 0.7171 |
456
+
457
+ <!--
458
+ ## Bias, Risks and Limitations
459
+
460
+ *What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
461
+ -->
462
+
463
+ <!--
464
+ ### Recommendations
465
+
466
+ *What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
467
+ -->
468
+
469
+ ## Training Details
470
+
471
+ ### Training Dataset
472
+
473
+ #### json
474
+
475
+ * Dataset: json
476
+ * Size: 6,300 training samples
477
+ * Columns: <code>positive</code> and <code>anchor</code>
478
+ * Approximate statistics based on the first 1000 samples:
479
+ | | positive | anchor |
480
+ |:--------|:-----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|
481
+ | type | string | string |
482
+ | details | <ul><li>min: 8 tokens</li><li>mean: 45.84 tokens</li><li>max: 439 tokens</li></ul> | <ul><li>min: 7 tokens</li><li>mean: 20.62 tokens</li><li>max: 42 tokens</li></ul> |
483
+ * Samples:
484
+ | positive | anchor |
485
+ |:--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:---------------------------------------------------------------------------------------------------------------------------------------------|
486
+ | <code>We adopted SAB 121 during fiscal 2022, with no impact on our consolidated financial statements.</code> | <code>What accounting guidance did the company adopt in fiscal 2022 and what was its impact on the consolidated financial statements?</code> |
487
+ | <code>Mortgage Solutions revenue decreased 18% in 2023 compared to 2022, due to significantly lower mortgage credit inquiry volumes in 2023 compared to the prior year.</code> | <code>What caused the 18% decline in Mortgage Solutions revenue in 2023 compared to 2022?</code> |
488
+ | <code>Adoption of SBTi goals would build on our current science-based goals to reduce Scope 1 and 2 carbon emissions by 2.1% per year, to achieve a 40% reduction by the end of fiscal 2030 and a 50% reduction by the end of fiscal 2035.</code> | <code>What is the company's percentage target for reducing Scope 1 and 2 carbon emissions by end of fiscal 2035?</code> |
489
+ * Loss: [<code>MatryoshkaLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#matryoshkaloss) with these parameters:
490
+ ```json
491
+ {
492
+ "loss": "MultipleNegativesRankingLoss",
493
+ "matryoshka_dims": [
494
+ 768,
495
+ 512,
496
+ 256,
497
+ 128,
498
+ 64
499
+ ],
500
+ "matryoshka_weights": [
501
+ 1,
502
+ 1,
503
+ 1,
504
+ 1,
505
+ 1
506
+ ],
507
+ "n_dims_per_step": -1
508
+ }
509
+ ```
510
+
511
+ ### Training Hyperparameters
512
+ #### Non-Default Hyperparameters
513
+
514
+ - `eval_strategy`: epoch
515
+ - `per_device_eval_batch_size`: 4
516
+ - `gradient_accumulation_steps`: 8
517
+ - `learning_rate`: 2e-05
518
+ - `num_train_epochs`: 4
519
+ - `lr_scheduler_type`: cosine
520
+ - `warmup_ratio`: 0.1
521
+ - `bf16`: True
522
+ - `tf32`: False
523
+ - `load_best_model_at_end`: True
524
+ - `optim`: adamw_torch_fused
525
+ - `batch_sampler`: no_duplicates
526
+
527
+ #### All Hyperparameters
528
+ <details><summary>Click to expand</summary>
529
+
530
+ - `overwrite_output_dir`: False
531
+ - `do_predict`: False
532
+ - `eval_strategy`: epoch
533
+ - `prediction_loss_only`: True
534
+ - `per_device_train_batch_size`: 8
535
+ - `per_device_eval_batch_size`: 4
536
+ - `per_gpu_train_batch_size`: None
537
+ - `per_gpu_eval_batch_size`: None
538
+ - `gradient_accumulation_steps`: 8
539
+ - `eval_accumulation_steps`: None
540
+ - `torch_empty_cache_steps`: None
541
+ - `learning_rate`: 2e-05
542
+ - `weight_decay`: 0.0
543
+ - `adam_beta1`: 0.9
544
+ - `adam_beta2`: 0.999
545
+ - `adam_epsilon`: 1e-08
546
+ - `max_grad_norm`: 1.0
547
+ - `num_train_epochs`: 4
548
+ - `max_steps`: -1
549
+ - `lr_scheduler_type`: cosine
550
+ - `lr_scheduler_kwargs`: {}
551
+ - `warmup_ratio`: 0.1
552
+ - `warmup_steps`: 0
553
+ - `log_level`: passive
554
+ - `log_level_replica`: warning
555
+ - `log_on_each_node`: True
556
+ - `logging_nan_inf_filter`: True
557
+ - `save_safetensors`: True
558
+ - `save_on_each_node`: False
559
+ - `save_only_model`: False
560
+ - `restore_callback_states_from_checkpoint`: False
561
+ - `no_cuda`: False
562
+ - `use_cpu`: False
563
+ - `use_mps_device`: False
564
+ - `seed`: 42
565
+ - `data_seed`: None
566
+ - `jit_mode_eval`: False
567
+ - `use_ipex`: False
568
+ - `bf16`: True
569
+ - `fp16`: False
570
+ - `fp16_opt_level`: O1
571
+ - `half_precision_backend`: auto
572
+ - `bf16_full_eval`: False
573
+ - `fp16_full_eval`: False
574
+ - `tf32`: False
575
+ - `local_rank`: 0
576
+ - `ddp_backend`: None
577
+ - `tpu_num_cores`: None
578
+ - `tpu_metrics_debug`: False
579
+ - `debug`: []
580
+ - `dataloader_drop_last`: False
581
+ - `dataloader_num_workers`: 0
582
+ - `dataloader_prefetch_factor`: None
583
+ - `past_index`: -1
584
+ - `disable_tqdm`: False
585
+ - `remove_unused_columns`: True
586
+ - `label_names`: None
587
+ - `load_best_model_at_end`: True
588
+ - `ignore_data_skip`: False
589
+ - `fsdp`: []
590
+ - `fsdp_min_num_params`: 0
591
+ - `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
592
+ - `fsdp_transformer_layer_cls_to_wrap`: None
593
+ - `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
594
+ - `deepspeed`: None
595
+ - `label_smoothing_factor`: 0.0
596
+ - `optim`: adamw_torch_fused
597
+ - `optim_args`: None
598
+ - `adafactor`: False
599
+ - `group_by_length`: False
600
+ - `length_column_name`: length
601
+ - `ddp_find_unused_parameters`: None
602
+ - `ddp_bucket_cap_mb`: None
603
+ - `ddp_broadcast_buffers`: False
604
+ - `dataloader_pin_memory`: True
605
+ - `dataloader_persistent_workers`: False
606
+ - `skip_memory_metrics`: True
607
+ - `use_legacy_prediction_loop`: False
608
+ - `push_to_hub`: False
609
+ - `resume_from_checkpoint`: None
610
+ - `hub_model_id`: None
611
+ - `hub_strategy`: every_save
612
+ - `hub_private_repo`: None
613
+ - `hub_always_push`: False
614
+ - `gradient_checkpointing`: False
615
+ - `gradient_checkpointing_kwargs`: None
616
+ - `include_inputs_for_metrics`: False
617
+ - `include_for_metrics`: []
618
+ - `eval_do_concat_batches`: True
619
+ - `fp16_backend`: auto
620
+ - `push_to_hub_model_id`: None
621
+ - `push_to_hub_organization`: None
622
+ - `mp_parameters`:
623
+ - `auto_find_batch_size`: False
624
+ - `full_determinism`: False
625
+ - `torchdynamo`: None
626
+ - `ray_scope`: last
627
+ - `ddp_timeout`: 1800
628
+ - `torch_compile`: False
629
+ - `torch_compile_backend`: None
630
+ - `torch_compile_mode`: None
631
+ - `dispatch_batches`: None
632
+ - `split_batches`: None
633
+ - `include_tokens_per_second`: False
634
+ - `include_num_input_tokens_seen`: False
635
+ - `neftune_noise_alpha`: None
636
+ - `optim_target_modules`: None
637
+ - `batch_eval_metrics`: False
638
+ - `eval_on_start`: False
639
+ - `use_liger_kernel`: False
640
+ - `eval_use_gather_object`: False
641
+ - `average_tokens_across_devices`: False
642
+ - `prompts`: None
643
+ - `batch_sampler`: no_duplicates
644
+ - `multi_dataset_batch_sampler`: proportional
645
+
646
+ </details>
647
+
648
+ ### Training Logs
649
+ | Epoch | Step | Training Loss | dim_768_cosine_ndcg@10 | dim_512_cosine_ndcg@10 | dim_256_cosine_ndcg@10 | dim_128_cosine_ndcg@10 | dim_64_cosine_ndcg@10 |
650
+ |:-------:|:-------:|:-------------:|:----------------------:|:----------------------:|:----------------------:|:----------------------:|:---------------------:|
651
+ | 0.1015 | 10 | 0.614 | - | - | - | - | - |
652
+ | 0.2030 | 20 | 0.5098 | - | - | - | - | - |
653
+ | 0.3046 | 30 | 0.426 | - | - | - | - | - |
654
+ | 0.4061 | 40 | 0.3262 | - | - | - | - | - |
655
+ | 0.5076 | 50 | 0.2131 | - | - | - | - | - |
656
+ | 0.6091 | 60 | 0.1892 | - | - | - | - | - |
657
+ | 0.7107 | 70 | 0.3049 | - | - | - | - | - |
658
+ | 0.8122 | 80 | 0.1617 | - | - | - | - | - |
659
+ | 0.9137 | 90 | 0.1214 | - | - | - | - | - |
660
+ | 1.0 | 99 | - | 0.7895 | 0.7919 | 0.7800 | 0.7685 | 0.7361 |
661
+ | 1.0102 | 100 | 0.147 | - | - | - | - | - |
662
+ | 1.1117 | 110 | 0.0938 | - | - | - | - | - |
663
+ | 1.2132 | 120 | 0.1406 | - | - | - | - | - |
664
+ | 1.3147 | 130 | 0.1058 | - | - | - | - | - |
665
+ | 1.4162 | 140 | 0.1072 | - | - | - | - | - |
666
+ | 1.5178 | 150 | 0.0352 | - | - | - | - | - |
667
+ | 1.6193 | 160 | 0.0568 | - | - | - | - | - |
668
+ | 1.7208 | 170 | 0.1283 | - | - | - | - | - |
669
+ | 1.8223 | 180 | 0.066 | - | - | - | - | - |
670
+ | 1.9239 | 190 | 0.038 | - | - | - | - | - |
671
+ | 2.0 | 198 | - | 0.7945 | 0.7945 | 0.7860 | 0.7736 | 0.7462 |
672
+ | 2.0203 | 200 | 0.0544 | - | - | - | - | - |
673
+ | 2.1218 | 210 | 0.0333 | - | - | - | - | - |
674
+ | 2.2234 | 220 | 0.042 | - | - | - | - | - |
675
+ | 2.3249 | 230 | 0.0489 | - | - | - | - | - |
676
+ | 2.4264 | 240 | 0.0498 | - | - | - | - | - |
677
+ | 2.5279 | 250 | 0.0119 | - | - | - | - | - |
678
+ | 2.6294 | 260 | 0.0273 | - | - | - | - | - |
679
+ | 2.7310 | 270 | 0.0719 | - | - | - | - | - |
680
+ | 2.8325 | 280 | 0.0366 | - | - | - | - | - |
681
+ | 2.9340 | 290 | 0.0333 | - | - | - | - | - |
682
+ | **3.0** | **297** | **-** | **0.7927** | **0.7952** | **0.7881** | **0.7743** | **0.7477** |
683
+ | 3.0305 | 300 | 0.0193 | - | - | - | - | - |
684
+ | 3.1320 | 310 | 0.0254 | - | - | - | - | - |
685
+ | 3.2335 | 320 | 0.0252 | - | - | - | - | - |
686
+ | 3.3350 | 330 | 0.039 | - | - | - | - | - |
687
+ | 3.4365 | 340 | 0.0224 | - | - | - | - | - |
688
+ | 3.5381 | 350 | 0.0091 | - | - | - | - | - |
689
+ | 3.6396 | 360 | 0.0356 | - | - | - | - | - |
690
+ | 3.7411 | 370 | 0.042 | - | - | - | - | - |
691
+ | 3.8426 | 380 | 0.038 | - | - | - | - | - |
692
+ | 3.9442 | 390 | 0.0088 | - | - | - | - | - |
693
+ | 3.9645 | 392 | - | 0.7960 | 0.7937 | 0.7883 | 0.7728 | 0.7501 |
694
+
695
+ * The bold row denotes the saved checkpoint.
696
+
697
+ ### Framework Versions
698
+ - Python: 3.12.8
699
+ - Sentence Transformers: 3.3.1
700
+ - Transformers: 4.47.1
701
+ - PyTorch: 2.5.1+cu124
702
+ - Accelerate: 1.2.1
703
+ - Datasets: 3.2.0
704
+ - Tokenizers: 0.21.0
705
+
706
+ ## Citation
707
+
708
+ ### BibTeX
709
+
710
+ #### Sentence Transformers
711
+ ```bibtex
712
+ @inproceedings{reimers-2019-sentence-bert,
713
+ title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
714
+ author = "Reimers, Nils and Gurevych, Iryna",
715
+ booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
716
+ month = "11",
717
+ year = "2019",
718
+ publisher = "Association for Computational Linguistics",
719
+ url = "https://arxiv.org/abs/1908.10084",
720
+ }
721
+ ```
722
+
723
+ #### MatryoshkaLoss
724
+ ```bibtex
725
+ @misc{kusupati2024matryoshka,
726
+ title={Matryoshka Representation Learning},
727
+ author={Aditya Kusupati and Gantavya Bhatt and Aniket Rege and Matthew Wallingford and Aditya Sinha and Vivek Ramanujan and William Howard-Snyder and Kaifeng Chen and Sham Kakade and Prateek Jain and Ali Farhadi},
728
+ year={2024},
729
+ eprint={2205.13147},
730
+ archivePrefix={arXiv},
731
+ primaryClass={cs.LG}
732
+ }
733
+ ```
734
+
735
+ #### MultipleNegativesRankingLoss
736
+ ```bibtex
737
+ @misc{henderson2017efficient,
738
+ title={Efficient Natural Language Response Suggestion for Smart Reply},
739
+ author={Matthew Henderson and Rami Al-Rfou and Brian Strope and Yun-hsuan Sung and Laszlo Lukacs and Ruiqi Guo and Sanjiv Kumar and Balint Miklos and Ray Kurzweil},
740
+ year={2017},
741
+ eprint={1705.00652},
742
+ archivePrefix={arXiv},
743
+ primaryClass={cs.CL}
744
+ }
745
+ ```
746
+
747
+ <!--
748
+ ## Glossary
749
+
750
+ *Clearly define terms in order to be accessible across audiences.*
751
+ -->
752
+
753
+ <!--
754
+ ## Model Card Authors
755
+
756
+ *Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
757
+ -->
758
+
759
+ <!--
760
+ ## Model Card Contact
761
+
762
+ *Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
763
+ -->
config.json ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "BAAI/bge-base-en-v1.5",
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": 768,
12
+ "id2label": {
13
+ "0": "LABEL_0"
14
+ },
15
+ "initializer_range": 0.02,
16
+ "intermediate_size": 3072,
17
+ "label2id": {
18
+ "LABEL_0": 0
19
+ },
20
+ "layer_norm_eps": 1e-12,
21
+ "max_position_embeddings": 512,
22
+ "model_type": "bert",
23
+ "num_attention_heads": 12,
24
+ "num_hidden_layers": 12,
25
+ "pad_token_id": 0,
26
+ "position_embedding_type": "absolute",
27
+ "torch_dtype": "float32",
28
+ "transformers_version": "4.47.1",
29
+ "type_vocab_size": 2,
30
+ "use_cache": true,
31
+ "vocab_size": 30522
32
+ }
config_sentence_transformers.json ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "__version__": {
3
+ "sentence_transformers": "3.3.1",
4
+ "transformers": "4.47.1",
5
+ "pytorch": "2.5.1+cu124"
6
+ },
7
+ "prompts": {},
8
+ "default_prompt_name": null,
9
+ "similarity_fn_name": "cosine"
10
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:2a708bd855c5a056283b18addacd097a24d1849c579acd9d0e819384bb62aa7b
3
+ size 437951328
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": true
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,58 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
+ "extra_special_tokens": {},
49
+ "mask_token": "[MASK]",
50
+ "model_max_length": 512,
51
+ "never_split": null,
52
+ "pad_token": "[PAD]",
53
+ "sep_token": "[SEP]",
54
+ "strip_accents": null,
55
+ "tokenize_chinese_chars": true,
56
+ "tokenizer_class": "BertTokenizer",
57
+ "unk_token": "[UNK]"
58
+ }
vocab.txt ADDED
The diff for this file is too large to render. See raw diff