krumeto commited on
Commit
5e1186f
·
verified ·
1 Parent(s): ac4199d

Add new SentenceTransformer model.

Browse files
1_Pooling/config.json ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "word_embedding_dimension": 384,
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,580 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ base_model: Snowflake/snowflake-arctic-embed-xs
3
+ datasets: []
4
+ language:
5
+ - en
6
+ library_name: sentence-transformers
7
+ license: apache-2.0
8
+ metrics:
9
+ - cosine_accuracy
10
+ - dot_accuracy
11
+ - manhattan_accuracy
12
+ - euclidean_accuracy
13
+ - max_accuracy
14
+ pipeline_tag: sentence-similarity
15
+ tags:
16
+ - sentence-transformers
17
+ - sentence-similarity
18
+ - feature-extraction
19
+ - generated_from_trainer
20
+ - dataset_size:100000
21
+ - loss:MultipleNegativesRankingLoss
22
+ widget:
23
+ - source_sentence: 'Represent this sentence for searching relevant passages: what
24
+ is spider silk made of'
25
+ sentences:
26
+ - Arachnid Pictures. Spider's silk is made up of chains of amino acids. In other
27
+ words, it is simply a protein (see How Food Works for details on amino acids and
28
+ proteins). The two primary amino acids are glycine and alanine. Spider silk is
29
+ extremely strong -- it is about five times stronger than steel and twice as strong
30
+ as Kevlar of the same weight.
31
+ - Spider silk is made of several kinds of proteins. These proteins are processed
32
+ and stored within the spider's abdomen. Spiders typically have six or eight spinnerets,
33
+ organs at the rear of their abdomen, through which they extrude the silk proteins.
34
+ - Neon is the second lightest noble gas, after helium, and it has an atomic number
35
+ of 10. On the periodic table, it is identified with the symbol Ne. The noble gases
36
+ were recognized in the late 1800s, when scientists realized that an entire class
37
+ of gases was missing from the periodic table of elements.
38
+ - source_sentence: 'Represent this sentence for searching relevant passages: what
39
+ is a caring community of learners'
40
+ sentences:
41
+ - 'A couple of my friends and I made hot ice for our school science fair. We used
42
+ sodium acetate. This project won first place at my schools science fair!!! Materials:
43
+ Stove. Pot. A spoon. A glass cup. and Sodium acetate (you can find it online or
44
+ in certain heat packs). How to do it: You heat water in a pot and put the sodium
45
+ acetate in the water.'
46
+ - Caring Community of Learners. A group or classroom in which children and adults
47
+ engage in warm, positive relationships; treat each other with respect; and learn
48
+ from and with each other. Self-concept. Children's stable perceptions about themselves
49
+ despite variations in their behavior.
50
+ - 'Transcript of Creating a Caring Community of Caring Learners: - Caring Community
51
+ of Learners: Group or classroom in which children and adults have positive, respectful
52
+ relationships and learn from each other. - attachment theory: children''s ability
53
+ to learn depends on trusting relationships with caregivers.'
54
+ - source_sentence: 'Represent this sentence for searching relevant passages: what
55
+ does dark circles around deep set eyes mean'
56
+ sentences:
57
+ - Production Planner, Manufacturing Salary. (United States). The average salary
58
+ for a Production Planner, Manufacturing is $51,962 per year. A skill in SAP Enterprise
59
+ Resource Planning (ERP) is associated with high pay for this job. People in this
60
+ job generally don't have more than 20 years' experience.
61
+ - Symptoms & Signs. Dark circles under the eyes are a common complaint of both men
62
+ and women, although they can occasionally be seen in children. As people age,
63
+ the skin becomes thinner and collagen is lost, sometimes enhancing the appearance
64
+ of blood vessels beneath the eyes and making the area appear darker.
65
+ - What are dark circles under the eyes? Dark circles under the eyes, sometimes called
66
+ shadows or dark rings under the eyes, are the appearance of dark skin between
67
+ the lower eyelid and the top of the cheek. Dark circles under the eyes can occur
68
+ in infants, children, adolescents and adults, and to men and women alike. It is
69
+ commonly assumed that dark circles under the eyes are caused by a lack of sleep,
70
+ and poor quality sleep and insomnia can certainly cause this condition.
71
+ - source_sentence: 'Represent this sentence for searching relevant passages: how big
72
+ is rv access'
73
+ sentences:
74
+ - The average length of bigger RVs is between 7.6 meters to 12 meters or 25 feet
75
+ to 40 feet. These vehicles are usually packed with different interesting features,
76
+ most of which are intended to offer luxury and convenience.
77
+ - Murder, My Sweet (released as Farewell, My Lovely in the United Kingdom) is a
78
+ 1944 American film noir, directed by Edward Dmytryk and starring Dick Powell,
79
+ Claire Trevor, and Anne Shirley. The film is based on Raymond Chandler 's 1940
80
+ novel Farewell, My Lovely. A second film adaptation of the novel was made in 1975
81
+ and released under Chandler's title. Murder, My Sweet turned out to be Anne Shirley's
82
+ final film. She retired from acting in 1944 at age 26.
83
+ - It should be wider then the rv.....lol sorry could not pass that one up. A standard
84
+ RV is normally around 96 inches wide at most, newer larger class A's are around
85
+ 102 inches wide. This width does not include mirrors or other safety equipment.....
86
+ Last edited by rtandc; 10-22-2010 at 05:41 AM..
87
+ - source_sentence: 'Represent this sentence for searching relevant passages: how many
88
+ pitchers used per game'
89
+ sentences:
90
+ - Trackback - A method by which a blogger receives notification which other bloggers
91
+ link to his or her blog entry
92
+ - Accroding to the statistics in the Baseball Reference page showing 2014 Major
93
+ League Baseball Pitching Pitches, 745 pitchers threw 704,983 pitches in 2430 games
94
+ for an average of 290 pitches per game.
95
+ - In modern day baseball, teams generally have five starting pitchers, and they
96
+ take it in turn to start a game every fifth day (hence the phrase rotation). Sometimes,
97
+ if the schedule pans out, a team can get away with a four man rotation, and in
98
+ the distant past some teams managed a three man rotation.
99
+ model-index:
100
+ - name: Fine-tuned snowflake actic xs based on MS-Marco triplets
101
+ results:
102
+ - task:
103
+ type: triplet
104
+ name: Triplet
105
+ dataset:
106
+ name: xs msmarco triplet
107
+ type: xs-msmarco-triplet
108
+ metrics:
109
+ - type: cosine_accuracy
110
+ value: 0.571
111
+ name: Cosine Accuracy
112
+ - type: dot_accuracy
113
+ value: 0.4286
114
+ name: Dot Accuracy
115
+ - type: manhattan_accuracy
116
+ value: 0.5728
117
+ name: Manhattan Accuracy
118
+ - type: euclidean_accuracy
119
+ value: 0.571
120
+ name: Euclidean Accuracy
121
+ - type: max_accuracy
122
+ value: 0.5728
123
+ name: Max Accuracy
124
+ - task:
125
+ type: triplet
126
+ name: Triplet
127
+ dataset:
128
+ name: xs msmarco triplet train
129
+ type: xs-msmarco-triplet-train
130
+ metrics:
131
+ - type: cosine_accuracy
132
+ value: 0.5696
133
+ name: Cosine Accuracy
134
+ - type: dot_accuracy
135
+ value: 0.43
136
+ name: Dot Accuracy
137
+ - type: manhattan_accuracy
138
+ value: 0.5674
139
+ name: Manhattan Accuracy
140
+ - type: euclidean_accuracy
141
+ value: 0.5696
142
+ name: Euclidean Accuracy
143
+ - type: max_accuracy
144
+ value: 0.5696
145
+ name: Max Accuracy
146
+ ---
147
+
148
+ # Fine-tuned snowflake actic xs based on MS-Marco triplets
149
+
150
+ This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [Snowflake/snowflake-arctic-embed-xs](https://huggingface.co/Snowflake/snowflake-arctic-embed-xs) on the sentence-transformers/msmarco-msmarco-mini_lm-l-6-v3 dataset. 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.
151
+
152
+ ## Model Details
153
+
154
+ ### Model Description
155
+ - **Model Type:** Sentence Transformer
156
+ - **Base model:** [Snowflake/snowflake-arctic-embed-xs](https://huggingface.co/Snowflake/snowflake-arctic-embed-xs) <!-- at revision 236cea8bda4680896324c8058c67e97c135eeb95 -->
157
+ - **Maximum Sequence Length:** 512 tokens
158
+ - **Output Dimensionality:** 384 tokens
159
+ - **Similarity Function:** Cosine Similarity
160
+ - **Training Dataset:**
161
+ - sentence-transformers/msmarco-msmarco-mini_lm-l-6-v3
162
+ - **Language:** en
163
+ - **License:** apache-2.0
164
+
165
+ ### Model Sources
166
+
167
+ - **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
168
+ - **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
169
+ - **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
170
+
171
+ ### Full Model Architecture
172
+
173
+ ```
174
+ SentenceTransformer(
175
+ (0): Transformer({'max_seq_length': 512, 'do_lower_case': False}) with Transformer model: BertModel
176
+ (1): Pooling({'word_embedding_dimension': 384, '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})
177
+ (2): Normalize()
178
+ )
179
+ ```
180
+
181
+ ## Usage
182
+
183
+ ### Direct Usage (Sentence Transformers)
184
+
185
+ First install the Sentence Transformers library:
186
+
187
+ ```bash
188
+ pip install -U sentence-transformers
189
+ ```
190
+
191
+ Then you can load this model and run inference.
192
+ ```python
193
+ from sentence_transformers import SentenceTransformer
194
+
195
+ # Download from the 🤗 Hub
196
+ model = SentenceTransformer("krumeto/snowflake-arctic-embed-xs-ms-marco-triplet")
197
+ # Run inference
198
+ sentences = [
199
+ 'Represent this sentence for searching relevant passages: how many pitchers used per game',
200
+ 'In modern day baseball, teams generally have five starting pitchers, and they take it in turn to start a game every fifth day (hence the phrase rotation). Sometimes, if the schedule pans out, a team can get away with a four man rotation, and in the distant past some teams managed a three man rotation.',
201
+ 'Accroding to the statistics in the Baseball Reference page showing 2014 Major League Baseball Pitching Pitches, 745 pitchers threw 704,983 pitches in 2430 games for an average of 290 pitches per game.',
202
+ ]
203
+ embeddings = model.encode(sentences)
204
+ print(embeddings.shape)
205
+ # [3, 384]
206
+
207
+ # Get the similarity scores for the embeddings
208
+ similarities = model.similarity(embeddings, embeddings)
209
+ print(similarities.shape)
210
+ # [3, 3]
211
+ ```
212
+
213
+ <!--
214
+ ### Direct Usage (Transformers)
215
+
216
+ <details><summary>Click to see the direct usage in Transformers</summary>
217
+
218
+ </details>
219
+ -->
220
+
221
+ <!--
222
+ ### Downstream Usage (Sentence Transformers)
223
+
224
+ You can finetune this model on your own dataset.
225
+
226
+ <details><summary>Click to expand</summary>
227
+
228
+ </details>
229
+ -->
230
+
231
+ <!--
232
+ ### Out-of-Scope Use
233
+
234
+ *List how the model may foreseeably be misused and address what users ought not to do with the model.*
235
+ -->
236
+
237
+ ## Evaluation
238
+
239
+ ### Metrics
240
+
241
+ #### Triplet
242
+ * Dataset: `xs-msmarco-triplet`
243
+ * Evaluated with [<code>TripletEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.TripletEvaluator)
244
+
245
+ | Metric | Value |
246
+ |:-------------------|:-----------|
247
+ | cosine_accuracy | 0.571 |
248
+ | dot_accuracy | 0.4286 |
249
+ | manhattan_accuracy | 0.5728 |
250
+ | euclidean_accuracy | 0.571 |
251
+ | **max_accuracy** | **0.5728** |
252
+
253
+ #### Triplet
254
+ * Dataset: `xs-msmarco-triplet-train`
255
+ * Evaluated with [<code>TripletEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.TripletEvaluator)
256
+
257
+ | Metric | Value |
258
+ |:-------------------|:-----------|
259
+ | cosine_accuracy | 0.5696 |
260
+ | dot_accuracy | 0.43 |
261
+ | manhattan_accuracy | 0.5674 |
262
+ | euclidean_accuracy | 0.5696 |
263
+ | **max_accuracy** | **0.5696** |
264
+
265
+ <!--
266
+ ## Bias, Risks and Limitations
267
+
268
+ *What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
269
+ -->
270
+
271
+ <!--
272
+ ### Recommendations
273
+
274
+ *What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
275
+ -->
276
+
277
+ ## Training Details
278
+
279
+ ### Training Dataset
280
+
281
+ #### sentence-transformers/msmarco-msmarco-mini_lm-l-6-v3
282
+
283
+ * Dataset: sentence-transformers/msmarco-msmarco-mini_lm-l-6-v3
284
+ * Size: 100,000 training samples
285
+ * Columns: <code>query</code>, <code>positive</code>, and <code>negative</code>
286
+ * Approximate statistics based on the first 1000 samples:
287
+ | | query | positive | negative |
288
+ |:--------|:-----------------------------------------------------------------------------------|:------------------------------------------------------------------------------------|:------------------------------------------------------------------------------------|
289
+ | type | string | string | string |
290
+ | details | <ul><li>min: 12 tokens</li><li>mean: 17.05 tokens</li><li>max: 36 tokens</li></ul> | <ul><li>min: 19 tokens</li><li>mean: 78.68 tokens</li><li>max: 212 tokens</li></ul> | <ul><li>min: 16 tokens</li><li>mean: 73.73 tokens</li><li>max: 205 tokens</li></ul> |
291
+ * Samples:
292
+ | query | positive | negative |
293
+ |:---------------------------------------------------------------------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
294
+ | <code>Represent this sentence for searching relevant passages: what are the liberal arts?</code> | <code>liberal arts. 1. the academic course of instruction at a college intended to provide general knowledge and comprising the arts, humanities, natural sciences, and social sciences, as opposed to professional or technical subjects.</code> | <code>Liberal Arts Defined. The liberal arts are a set of academic disciplines that include the sciences and the humanities. When you study a liberal arts curriculum, you don't have to have one specific career goal, although you might. Instead, you'll assemble a broad foundation of knowledge that can be used in a wide spectrum of careers.</code> |
295
+ | <code>Represent this sentence for searching relevant passages: what is the mechanism of action of fibrinolytic or thrombolytic drugs?</code> | <code>Baillière's Clinical Haematology. 6 Mechanism of action of the thrombolytic agents. 6 Mechanism of action of the thrombolytic agents JEFFREY I. WEITZ Fibrin formed during the haemostatic, inflammatory or tissue repair process serves a temporary role, and must be degraded to restore normal tissue function and structure.</code> | <code>Fibrinolytic drug. Fibrinolytic drug, also called thrombolytic drug, any agent that is capable of stimulating the dissolution of a blood clot (thrombus). Fibrinolytic drugs work by activating the so-called fibrinolytic pathway.</code> |
296
+ | <code>Represent this sentence for searching relevant passages: what is normal plat count</code> | <code>78 Followers. A. Platelets are the tiny blood cells that help stop bleeding by binding together to form a clump or plug at sites of injury inside blood vessels. A normal platelet count is between 150,000 and 450,000 platelets per microliter (one-millionth of a liter, abbreviated mcL).The average platelet count is 237,000 per mcL in men and 266,000 per mcL in women.8 Followers. A. Platelets are the tiny blood cells that help stop bleeding by binding together to form a clump or plug at sites of injury inside blood vessels. A normal platelet count is between 150,000 and 450,000 platelets per microliter (one-millionth of a liter, abbreviated mcL).</code> | <code>In the context of blood work, PLT refers to the platelet count. Platelets are the cells that cause blood clotting and control bleeding. The normal range of platelets for adults is 3.5 to 10.5 billion cells per liter of blood, according to the Mayo Clinic. Continue Reading.</code> |
297
+ * Loss: [<code>MultipleNegativesRankingLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#multiplenegativesrankingloss) with these parameters:
298
+ ```json
299
+ {
300
+ "scale": 20.0,
301
+ "similarity_fct": "cos_sim"
302
+ }
303
+ ```
304
+
305
+ ### Evaluation Dataset
306
+
307
+ #### sentence-transformers/msmarco-msmarco-mini_lm-l-6-v3
308
+
309
+ * Dataset: sentence-transformers/msmarco-msmarco-mini_lm-l-6-v3
310
+ * Size: 5,000 evaluation samples
311
+ * Columns: <code>query</code>, <code>positive</code>, and <code>negative</code>
312
+ * Approximate statistics based on the first 1000 samples:
313
+ | | query | positive | negative |
314
+ |:--------|:-----------------------------------------------------------------------------------|:------------------------------------------------------------------------------------|:------------------------------------------------------------------------------------|
315
+ | type | string | string | string |
316
+ | details | <ul><li>min: 12 tokens</li><li>mean: 17.09 tokens</li><li>max: 35 tokens</li></ul> | <ul><li>min: 21 tokens</li><li>mean: 80.07 tokens</li><li>max: 250 tokens</li></ul> | <ul><li>min: 16 tokens</li><li>mean: 76.73 tokens</li><li>max: 341 tokens</li></ul> |
317
+ * Samples:
318
+ | query | positive | negative |
319
+ |:----------------------------------------------------------------------------------------------------------------------------|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
320
+ | <code>Represent this sentence for searching relevant passages: what is the name of the material harder than diamonds</code> | <code>Nano-material is harder than diamonds By Will Knight A material that is harder than diamond has been created in the lab, by packing together tiny “nanorods” of carbon. The new material, known as aggregated carbon nanorods (ACNR), was created by compressing and heating super-strong carbon molecules called buckyballs or carbon-60.</code> | <code>What material is stronger than diamond? Diamonds are famous for their hardness, but not particularly for strength,since they are easily cleaved to create the facets that make the different cuts of diamonds for setting in a ring or necklace. Many materials are stronger than diamonds, only a couple of synthesized materials are harder than diamonds.</code> |
321
+ | <code>Represent this sentence for searching relevant passages: is pink impression a perennial tulip?</code> | <code>Tulip Pink Impression. close video. VIDEO. Tulip Pink Impression. The rich pink blooms of this hybrid are bound to make an impression, whether used in the landscape or as a cut flower. Robust stems and giant blooms characterise the range, and this hybrid is no exception. ‘Pink Impression’ will continue to impress thanks to the perennial potential of this range.</code> | <code>Tulip Pink Impression. The lustrous petals are a deep, rich rose at the center, shading to a delicate pale pink at the edge, while doing amazing things in between that include shades of both melon and sunset. Tall, strong, long-lasting and reliable, like most Darwin hybrids. An absolutely first-class Tulip.</code> |
322
+ | <code>Represent this sentence for searching relevant passages: define: colonization</code> | <code>Colonization. the settlement and economic development of the uninhabited borderlands of a country (internal colonization) or the establishment of settlements (engaging primarily in agricultural activity) beyond the frontiers of a country (external colonization).</code> | <code>Colonization is a process by which a central system of power dominates the surrounding land and its components. The term is derived from the Latin word colere, which means to inhabit. Also, colonization refers strictly to migration, for example, to settler colonies in America or Australia, trading posts, and plantations, while colonialism deals with this, along with ruling the existing indigenous peoples of styled new territories. Colonization was linked to the spread of tens of millions fro</code> |
323
+ * Loss: [<code>MultipleNegativesRankingLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#multiplenegativesrankingloss) with these parameters:
324
+ ```json
325
+ {
326
+ "scale": 20.0,
327
+ "similarity_fct": "cos_sim"
328
+ }
329
+ ```
330
+
331
+ ### Training Hyperparameters
332
+ #### Non-Default Hyperparameters
333
+
334
+ - `eval_strategy`: steps
335
+ - `per_device_train_batch_size`: 16
336
+ - `per_device_eval_batch_size`: 16
337
+ - `num_train_epochs`: 1
338
+ - `warmup_ratio`: 0.1
339
+ - `fp16`: True
340
+ - `batch_sampler`: no_duplicates
341
+
342
+ #### All Hyperparameters
343
+ <details><summary>Click to expand</summary>
344
+
345
+ - `overwrite_output_dir`: False
346
+ - `do_predict`: False
347
+ - `eval_strategy`: steps
348
+ - `prediction_loss_only`: True
349
+ - `per_device_train_batch_size`: 16
350
+ - `per_device_eval_batch_size`: 16
351
+ - `per_gpu_train_batch_size`: None
352
+ - `per_gpu_eval_batch_size`: None
353
+ - `gradient_accumulation_steps`: 1
354
+ - `eval_accumulation_steps`: None
355
+ - `learning_rate`: 5e-05
356
+ - `weight_decay`: 0.0
357
+ - `adam_beta1`: 0.9
358
+ - `adam_beta2`: 0.999
359
+ - `adam_epsilon`: 1e-08
360
+ - `max_grad_norm`: 1.0
361
+ - `num_train_epochs`: 1
362
+ - `max_steps`: -1
363
+ - `lr_scheduler_type`: linear
364
+ - `lr_scheduler_kwargs`: {}
365
+ - `warmup_ratio`: 0.1
366
+ - `warmup_steps`: 0
367
+ - `log_level`: passive
368
+ - `log_level_replica`: warning
369
+ - `log_on_each_node`: True
370
+ - `logging_nan_inf_filter`: True
371
+ - `save_safetensors`: True
372
+ - `save_on_each_node`: False
373
+ - `save_only_model`: False
374
+ - `restore_callback_states_from_checkpoint`: False
375
+ - `no_cuda`: False
376
+ - `use_cpu`: False
377
+ - `use_mps_device`: False
378
+ - `seed`: 42
379
+ - `data_seed`: None
380
+ - `jit_mode_eval`: False
381
+ - `use_ipex`: False
382
+ - `bf16`: False
383
+ - `fp16`: True
384
+ - `fp16_opt_level`: O1
385
+ - `half_precision_backend`: auto
386
+ - `bf16_full_eval`: False
387
+ - `fp16_full_eval`: False
388
+ - `tf32`: None
389
+ - `local_rank`: 0
390
+ - `ddp_backend`: None
391
+ - `tpu_num_cores`: None
392
+ - `tpu_metrics_debug`: False
393
+ - `debug`: []
394
+ - `dataloader_drop_last`: False
395
+ - `dataloader_num_workers`: 0
396
+ - `dataloader_prefetch_factor`: None
397
+ - `past_index`: -1
398
+ - `disable_tqdm`: False
399
+ - `remove_unused_columns`: True
400
+ - `label_names`: None
401
+ - `load_best_model_at_end`: False
402
+ - `ignore_data_skip`: False
403
+ - `fsdp`: []
404
+ - `fsdp_min_num_params`: 0
405
+ - `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
406
+ - `fsdp_transformer_layer_cls_to_wrap`: None
407
+ - `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
408
+ - `deepspeed`: None
409
+ - `label_smoothing_factor`: 0.0
410
+ - `optim`: adamw_torch
411
+ - `optim_args`: None
412
+ - `adafactor`: False
413
+ - `group_by_length`: False
414
+ - `length_column_name`: length
415
+ - `ddp_find_unused_parameters`: None
416
+ - `ddp_bucket_cap_mb`: None
417
+ - `ddp_broadcast_buffers`: False
418
+ - `dataloader_pin_memory`: True
419
+ - `dataloader_persistent_workers`: False
420
+ - `skip_memory_metrics`: True
421
+ - `use_legacy_prediction_loop`: False
422
+ - `push_to_hub`: False
423
+ - `resume_from_checkpoint`: None
424
+ - `hub_model_id`: None
425
+ - `hub_strategy`: every_save
426
+ - `hub_private_repo`: False
427
+ - `hub_always_push`: False
428
+ - `gradient_checkpointing`: False
429
+ - `gradient_checkpointing_kwargs`: None
430
+ - `include_inputs_for_metrics`: False
431
+ - `eval_do_concat_batches`: True
432
+ - `fp16_backend`: auto
433
+ - `push_to_hub_model_id`: None
434
+ - `push_to_hub_organization`: None
435
+ - `mp_parameters`:
436
+ - `auto_find_batch_size`: False
437
+ - `full_determinism`: False
438
+ - `torchdynamo`: None
439
+ - `ray_scope`: last
440
+ - `ddp_timeout`: 1800
441
+ - `torch_compile`: False
442
+ - `torch_compile_backend`: None
443
+ - `torch_compile_mode`: None
444
+ - `dispatch_batches`: None
445
+ - `split_batches`: None
446
+ - `include_tokens_per_second`: False
447
+ - `include_num_input_tokens_seen`: False
448
+ - `neftune_noise_alpha`: None
449
+ - `optim_target_modules`: None
450
+ - `batch_eval_metrics`: False
451
+ - `eval_on_start`: False
452
+ - `batch_sampler`: no_duplicates
453
+ - `multi_dataset_batch_sampler`: proportional
454
+
455
+ </details>
456
+
457
+ ### Training Logs
458
+ | Epoch | Step | Training Loss | loss | xs-msmarco-triplet-train_max_accuracy | xs-msmarco-triplet_max_accuracy |
459
+ |:-----:|:----:|:-------------:|:------:|:-------------------------------------:|:-------------------------------:|
460
+ | 0 | 0 | - | - | - | 0.3648 |
461
+ | 0.016 | 100 | 1.0213 | 1.0078 | - | 0.3672 |
462
+ | 0.032 | 200 | 0.9785 | 0.9630 | - | 0.3764 |
463
+ | 0.048 | 300 | 0.9591 | 0.9190 | - | 0.4014 |
464
+ | 0.064 | 400 | 0.9088 | 0.8906 | - | 0.4392 |
465
+ | 0.08 | 500 | 0.9215 | 0.8707 | - | 0.4598 |
466
+ | 0.096 | 600 | 0.8692 | 0.8681 | - | 0.4874 |
467
+ | 0.112 | 700 | 0.8806 | 0.8538 | - | 0.4964 |
468
+ | 0.128 | 800 | 0.8801 | 0.8477 | - | 0.5106 |
469
+ | 0.144 | 900 | 0.8692 | 0.8414 | - | 0.5228 |
470
+ | 0.16 | 1000 | 0.8624 | 0.8391 | - | 0.5194 |
471
+ | 0.176 | 1100 | 0.8737 | 0.8397 | - | 0.5264 |
472
+ | 0.192 | 1200 | 0.8505 | 0.8344 | - | 0.5214 |
473
+ | 0.208 | 1300 | 0.8818 | 0.8358 | - | 0.5164 |
474
+ | 0.224 | 1400 | 0.8464 | 0.8269 | - | 0.5326 |
475
+ | 0.24 | 1500 | 0.8623 | 0.8291 | - | 0.5232 |
476
+ | 0.256 | 1600 | 0.8203 | 0.8407 | - | 0.5328 |
477
+ | 0.272 | 1700 | 0.8566 | 0.8257 | - | 0.5302 |
478
+ | 0.288 | 1800 | 0.8386 | 0.8198 | - | 0.5364 |
479
+ | 0.304 | 1900 | 0.8587 | 0.8172 | - | 0.5388 |
480
+ | 0.32 | 2000 | 0.8472 | 0.8233 | - | 0.5568 |
481
+ | 0.336 | 2100 | 0.8466 | 0.8188 | - | 0.5468 |
482
+ | 0.352 | 2200 | 0.8273 | 0.8190 | - | 0.5386 |
483
+ | 0.368 | 2300 | 0.8356 | 0.8183 | - | 0.5396 |
484
+ | 0.384 | 2400 | 0.8294 | 0.8156 | - | 0.5538 |
485
+ | 0.4 | 2500 | 0.8274 | 0.8168 | - | 0.5448 |
486
+ | 0.416 | 2600 | 0.8392 | 0.8093 | - | 0.5422 |
487
+ | 0.432 | 2700 | 0.8541 | 0.8087 | - | 0.5426 |
488
+ | 0.448 | 2800 | 0.8218 | 0.8086 | - | 0.5474 |
489
+ | 0.464 | 2900 | 0.8446 | 0.8062 | - | 0.554 |
490
+ | 0.48 | 3000 | 0.8405 | 0.8076 | - | 0.548 |
491
+ | 0.496 | 3100 | 0.8447 | 0.8087 | - | 0.553 |
492
+ | 0.512 | 3200 | 0.8453 | 0.8073 | - | 0.5536 |
493
+ | 0.528 | 3300 | 0.8371 | 0.8089 | - | 0.5504 |
494
+ | 0.544 | 3400 | 0.8548 | 0.8005 | - | 0.5516 |
495
+ | 0.56 | 3500 | 0.8162 | 0.8026 | - | 0.5572 |
496
+ | 0.576 | 3600 | 0.8577 | 0.7994 | - | 0.5558 |
497
+ | 0.592 | 3700 | 0.8289 | 0.7990 | - | 0.5526 |
498
+ | 0.608 | 3800 | 0.824 | 0.7967 | - | 0.562 |
499
+ | 0.624 | 3900 | 0.833 | 0.7959 | - | 0.5608 |
500
+ | 0.64 | 4000 | 0.8362 | 0.7958 | - | 0.5554 |
501
+ | 0.656 | 4100 | 0.8057 | 0.7966 | - | 0.5578 |
502
+ | 0.672 | 4200 | 0.8001 | 0.7943 | - | 0.5646 |
503
+ | 0.688 | 4300 | 0.8215 | 0.7937 | - | 0.5602 |
504
+ | 0.704 | 4400 | 0.8257 | 0.7933 | - | 0.5614 |
505
+ | 0.72 | 4500 | 0.8173 | 0.7942 | - | 0.5648 |
506
+ | 0.736 | 4600 | 0.8002 | 0.7922 | - | 0.5698 |
507
+ | 0.752 | 4700 | 0.8445 | 0.7899 | - | 0.5626 |
508
+ | 0.768 | 4800 | 0.825 | 0.7897 | - | 0.5592 |
509
+ | 0.784 | 4900 | 0.8151 | 0.7870 | - | 0.5696 |
510
+ | 0.8 | 5000 | 0.8223 | 0.7895 | - | 0.5676 |
511
+ | 0.816 | 5100 | 0.8235 | 0.7877 | - | 0.5656 |
512
+ | 0.832 | 5200 | 0.8355 | 0.7866 | - | 0.5688 |
513
+ | 0.848 | 5300 | 0.8218 | 0.7864 | - | 0.5672 |
514
+ | 0.864 | 5400 | 0.8384 | 0.7866 | - | 0.5652 |
515
+ | 0.88 | 5500 | 0.7988 | 0.7860 | - | 0.569 |
516
+ | 0.896 | 5600 | 0.8117 | 0.7867 | - | 0.5684 |
517
+ | 0.912 | 5700 | 0.8113 | 0.7861 | - | 0.5734 |
518
+ | 0.928 | 5800 | 0.8129 | 0.7860 | - | 0.5698 |
519
+ | 0.944 | 5900 | 0.799 | 0.7863 | - | 0.5688 |
520
+ | 0.96 | 6000 | 0.8269 | 0.7858 | - | 0.5708 |
521
+ | 0.976 | 6100 | 0.8066 | 0.7857 | - | 0.572 |
522
+ | 0.992 | 6200 | 0.8302 | 0.7856 | - | 0.5728 |
523
+ | 1.0 | 6250 | - | - | 0.5696 | - |
524
+
525
+
526
+ ### Framework Versions
527
+ - Python: 3.10.12
528
+ - Sentence Transformers: 3.0.1
529
+ - Transformers: 4.42.4
530
+ - PyTorch: 2.3.1+cu121
531
+ - Accelerate: 0.32.1
532
+ - Datasets: 2.20.0
533
+ - Tokenizers: 0.19.1
534
+
535
+ ## Citation
536
+
537
+ ### BibTeX
538
+
539
+ #### Sentence Transformers
540
+ ```bibtex
541
+ @inproceedings{reimers-2019-sentence-bert,
542
+ title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
543
+ author = "Reimers, Nils and Gurevych, Iryna",
544
+ booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
545
+ month = "11",
546
+ year = "2019",
547
+ publisher = "Association for Computational Linguistics",
548
+ url = "https://arxiv.org/abs/1908.10084",
549
+ }
550
+ ```
551
+
552
+ #### MultipleNegativesRankingLoss
553
+ ```bibtex
554
+ @misc{henderson2017efficient,
555
+ title={Efficient Natural Language Response Suggestion for Smart Reply},
556
+ 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},
557
+ year={2017},
558
+ eprint={1705.00652},
559
+ archivePrefix={arXiv},
560
+ primaryClass={cs.CL}
561
+ }
562
+ ```
563
+
564
+ <!--
565
+ ## Glossary
566
+
567
+ *Clearly define terms in order to be accessible across audiences.*
568
+ -->
569
+
570
+ <!--
571
+ ## Model Card Authors
572
+
573
+ *Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
574
+ -->
575
+
576
+ <!--
577
+ ## Model Card Contact
578
+
579
+ *Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
580
+ -->
config.json ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "Snowflake/snowflake-arctic-embed-xs",
3
+ "architectures": [
4
+ "BertModel"
5
+ ],
6
+ "attention_probs_dropout_prob": 0.1,
7
+ "classifier_dropout": null,
8
+ "gradient_checkpointing": false,
9
+ "hidden_act": "gelu",
10
+ "hidden_dropout_prob": 0.1,
11
+ "hidden_size": 384,
12
+ "initializer_range": 0.02,
13
+ "intermediate_size": 1536,
14
+ "layer_norm_eps": 1e-12,
15
+ "max_position_embeddings": 512,
16
+ "model_type": "bert",
17
+ "num_attention_heads": 12,
18
+ "num_hidden_layers": 6,
19
+ "pad_token_id": 0,
20
+ "position_embedding_type": "absolute",
21
+ "torch_dtype": "float32",
22
+ "transformers_version": "4.42.4",
23
+ "type_vocab_size": 2,
24
+ "use_cache": true,
25
+ "vocab_size": 30522
26
+ }
config_sentence_transformers.json ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "__version__": {
3
+ "sentence_transformers": "3.0.1",
4
+ "transformers": "4.42.4",
5
+ "pytorch": "2.3.1+cu121"
6
+ },
7
+ "prompts": {
8
+ "query": "Represent this sentence for searching relevant passages: "
9
+ },
10
+ "default_prompt_name": null,
11
+ "similarity_fn_name": null
12
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:f320f66a727749672730875f907ba4d75c5b79da39e27b4076737eb1d54114e6
3
+ size 90272656
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
+ }
special_tokens_map.json ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "cls_token": {
3
+ "content": "[CLS]",
4
+ "lstrip": false,
5
+ "normalized": false,
6
+ "rstrip": false,
7
+ "single_word": false
8
+ },
9
+ "mask_token": {
10
+ "content": "[MASK]",
11
+ "lstrip": false,
12
+ "normalized": false,
13
+ "rstrip": false,
14
+ "single_word": false
15
+ },
16
+ "pad_token": {
17
+ "content": "[PAD]",
18
+ "lstrip": false,
19
+ "normalized": false,
20
+ "rstrip": false,
21
+ "single_word": false
22
+ },
23
+ "sep_token": {
24
+ "content": "[SEP]",
25
+ "lstrip": false,
26
+ "normalized": false,
27
+ "rstrip": false,
28
+ "single_word": false
29
+ },
30
+ "unk_token": {
31
+ "content": "[UNK]",
32
+ "lstrip": false,
33
+ "normalized": false,
34
+ "rstrip": false,
35
+ "single_word": false
36
+ }
37
+ }
tokenizer.json ADDED
The diff for this file is too large to render. See raw diff
 
tokenizer_config.json ADDED
@@ -0,0 +1,64 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "added_tokens_decoder": {
3
+ "0": {
4
+ "content": "[PAD]",
5
+ "lstrip": false,
6
+ "normalized": false,
7
+ "rstrip": false,
8
+ "single_word": false,
9
+ "special": true
10
+ },
11
+ "100": {
12
+ "content": "[UNK]",
13
+ "lstrip": false,
14
+ "normalized": false,
15
+ "rstrip": false,
16
+ "single_word": false,
17
+ "special": true
18
+ },
19
+ "101": {
20
+ "content": "[CLS]",
21
+ "lstrip": false,
22
+ "normalized": false,
23
+ "rstrip": false,
24
+ "single_word": false,
25
+ "special": true
26
+ },
27
+ "102": {
28
+ "content": "[SEP]",
29
+ "lstrip": false,
30
+ "normalized": false,
31
+ "rstrip": false,
32
+ "single_word": false,
33
+ "special": true
34
+ },
35
+ "103": {
36
+ "content": "[MASK]",
37
+ "lstrip": false,
38
+ "normalized": false,
39
+ "rstrip": false,
40
+ "single_word": false,
41
+ "special": true
42
+ }
43
+ },
44
+ "clean_up_tokenization_spaces": true,
45
+ "cls_token": "[CLS]",
46
+ "do_basic_tokenize": true,
47
+ "do_lower_case": true,
48
+ "mask_token": "[MASK]",
49
+ "max_length": 512,
50
+ "model_max_length": 512,
51
+ "never_split": null,
52
+ "pad_to_multiple_of": null,
53
+ "pad_token": "[PAD]",
54
+ "pad_token_type_id": 0,
55
+ "padding_side": "right",
56
+ "sep_token": "[SEP]",
57
+ "stride": 0,
58
+ "strip_accents": null,
59
+ "tokenize_chinese_chars": true,
60
+ "tokenizer_class": "BertTokenizer",
61
+ "truncation_side": "right",
62
+ "truncation_strategy": "longest_first",
63
+ "unk_token": "[UNK]"
64
+ }
vocab.txt ADDED
The diff for this file is too large to render. See raw diff