alpcansoydas commited on
Commit
c706e31
·
verified ·
1 Parent(s): b5b9f8d

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": 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,484 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ base_model: sentence-transformers/all-mpnet-base-v2
3
+ library_name: sentence-transformers
4
+ metrics:
5
+ - pearson_cosine
6
+ - spearman_cosine
7
+ - pearson_manhattan
8
+ - spearman_manhattan
9
+ - pearson_euclidean
10
+ - spearman_euclidean
11
+ - pearson_dot
12
+ - spearman_dot
13
+ - pearson_max
14
+ - spearman_max
15
+ pipeline_tag: sentence-similarity
16
+ tags:
17
+ - sentence-transformers
18
+ - sentence-similarity
19
+ - feature-extraction
20
+ - generated_from_trainer
21
+ - dataset_size:25110
22
+ - loss:MultipleNegativesRankingLoss
23
+ widget:
24
+ - source_sentence: APPLE iPhone 16 PRO MAX 512GB
25
+ sentences:
26
+ - Communications Devices and Accessories
27
+ - Communications Devices and Accessories
28
+ - Communications Devices and Accessories
29
+ - source_sentence: CISCO.CISCO 878-K9 G.SHDSL SECURİTY ROUTER
30
+ sentences:
31
+ - Communications Devices and Accessories
32
+ - Data Voice or Multimedia Network Equipment or Platforms and Accessories
33
+ - Computer Equipment and Accessories
34
+ - source_sentence: iPhone 14 36 months Tier 3+
35
+ sentences:
36
+ - Heating and ventilation and air circulation
37
+ - Portable Structure Building Components
38
+ - Components for information technology or broadcasting or telecommunications
39
+ - source_sentence: Elektrik Sayacı Optik Okuyucu
40
+ sentences:
41
+ - Components for information technology or broadcasting or telecommunications
42
+ - Power sources
43
+ - Components for information technology or broadcasting or telecommunications
44
+ - source_sentence: Power Cable,600V/1000V,ROV-K,4mm^2,Black Jacket(The Color Of Core
45
+ Is Blue And Brown),36A,Shielded Style Outdoor Cable
46
+ sentences:
47
+ - Electrical equipment and components and supplies
48
+ - Communications Devices and Accessories
49
+ - Power sources
50
+ model-index:
51
+ - name: SentenceTransformer based on sentence-transformers/all-mpnet-base-v2
52
+ results:
53
+ - task:
54
+ type: semantic-similarity
55
+ name: Semantic Similarity
56
+ dataset:
57
+ name: Unknown
58
+ type: unknown
59
+ metrics:
60
+ - type: pearson_cosine
61
+ value: .nan
62
+ name: Pearson Cosine
63
+ - type: spearman_cosine
64
+ value: .nan
65
+ name: Spearman Cosine
66
+ - type: pearson_manhattan
67
+ value: .nan
68
+ name: Pearson Manhattan
69
+ - type: spearman_manhattan
70
+ value: .nan
71
+ name: Spearman Manhattan
72
+ - type: pearson_euclidean
73
+ value: .nan
74
+ name: Pearson Euclidean
75
+ - type: spearman_euclidean
76
+ value: .nan
77
+ name: Spearman Euclidean
78
+ - type: pearson_dot
79
+ value: .nan
80
+ name: Pearson Dot
81
+ - type: spearman_dot
82
+ value: .nan
83
+ name: Spearman Dot
84
+ - type: pearson_max
85
+ value: .nan
86
+ name: Pearson Max
87
+ - type: spearman_max
88
+ value: .nan
89
+ name: Spearman Max
90
+ ---
91
+
92
+ # SentenceTransformer based on sentence-transformers/all-mpnet-base-v2
93
+
94
+ This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [sentence-transformers/all-mpnet-base-v2](https://huggingface.co/sentence-transformers/all-mpnet-base-v2). 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.
95
+
96
+ ## Model Details
97
+
98
+ ### Model Description
99
+ - **Model Type:** Sentence Transformer
100
+ - **Base model:** [sentence-transformers/all-mpnet-base-v2](https://huggingface.co/sentence-transformers/all-mpnet-base-v2) <!-- at revision f1b1b820e405bb8644f5e8d9a3b98f9c9e0a3c58 -->
101
+ - **Maximum Sequence Length:** 384 tokens
102
+ - **Output Dimensionality:** 768 tokens
103
+ - **Similarity Function:** Cosine Similarity
104
+ <!-- - **Training Dataset:** Unknown -->
105
+ <!-- - **Language:** Unknown -->
106
+ <!-- - **License:** Unknown -->
107
+
108
+ ### Model Sources
109
+
110
+ - **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
111
+ - **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
112
+ - **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
113
+
114
+ ### Full Model Architecture
115
+
116
+ ```
117
+ SentenceTransformer(
118
+ (0): Transformer({'max_seq_length': 384, 'do_lower_case': False}) with Transformer model: MPNetModel
119
+ (1): Pooling({'word_embedding_dimension': 768, '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})
120
+ (2): Normalize()
121
+ )
122
+ ```
123
+
124
+ ## Usage
125
+
126
+ ### Direct Usage (Sentence Transformers)
127
+
128
+ First install the Sentence Transformers library:
129
+
130
+ ```bash
131
+ pip install -U sentence-transformers
132
+ ```
133
+
134
+ Then you can load this model and run inference.
135
+ ```python
136
+ from sentence_transformers import SentenceTransformer
137
+
138
+ # Download from the 🤗 Hub
139
+ model = SentenceTransformer("alpcansoydas/product-model-16.10.24-ifhavemorethan10sampleperfamily")
140
+ # Run inference
141
+ sentences = [
142
+ 'Power Cable,600V/1000V,ROV-K,4mm^2,Black Jacket(The Color Of Core Is Blue And Brown),36A,Shielded Style Outdoor Cable',
143
+ 'Electrical equipment and components and supplies',
144
+ 'Power sources',
145
+ ]
146
+ embeddings = model.encode(sentences)
147
+ print(embeddings.shape)
148
+ # [3, 768]
149
+
150
+ # Get the similarity scores for the embeddings
151
+ similarities = model.similarity(embeddings, embeddings)
152
+ print(similarities.shape)
153
+ # [3, 3]
154
+ ```
155
+
156
+ <!--
157
+ ### Direct Usage (Transformers)
158
+
159
+ <details><summary>Click to see the direct usage in Transformers</summary>
160
+
161
+ </details>
162
+ -->
163
+
164
+ <!--
165
+ ### Downstream Usage (Sentence Transformers)
166
+
167
+ You can finetune this model on your own dataset.
168
+
169
+ <details><summary>Click to expand</summary>
170
+
171
+ </details>
172
+ -->
173
+
174
+ <!--
175
+ ### Out-of-Scope Use
176
+
177
+ *List how the model may foreseeably be misused and address what users ought not to do with the model.*
178
+ -->
179
+
180
+ ## Evaluation
181
+
182
+ ### Metrics
183
+
184
+ #### Semantic Similarity
185
+
186
+ * Evaluated with [<code>EmbeddingSimilarityEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.EmbeddingSimilarityEvaluator)
187
+
188
+ | Metric | Value |
189
+ |:-------------------|:--------|
190
+ | pearson_cosine | nan |
191
+ | spearman_cosine | nan |
192
+ | pearson_manhattan | nan |
193
+ | spearman_manhattan | nan |
194
+ | pearson_euclidean | nan |
195
+ | spearman_euclidean | nan |
196
+ | pearson_dot | nan |
197
+ | spearman_dot | nan |
198
+ | pearson_max | nan |
199
+ | **spearman_max** | **nan** |
200
+
201
+ <!--
202
+ ## Bias, Risks and Limitations
203
+
204
+ *What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
205
+ -->
206
+
207
+ <!--
208
+ ### Recommendations
209
+
210
+ *What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
211
+ -->
212
+
213
+ ## Training Details
214
+
215
+ ### Training Dataset
216
+
217
+ #### Unnamed Dataset
218
+
219
+
220
+ * Size: 25,110 training samples
221
+ * Columns: <code>sentence1</code> and <code>sentence2</code>
222
+ * Approximate statistics based on the first 1000 samples:
223
+ | | sentence1 | sentence2 |
224
+ |:--------|:----------------------------------------------------------------------------------|:---------------------------------------------------------------------------------|
225
+ | type | string | string |
226
+ | details | <ul><li>min: 3 tokens</li><li>mean: 17.04 tokens</li><li>max: 83 tokens</li></ul> | <ul><li>min: 3 tokens</li><li>mean: 7.97 tokens</li><li>max: 12 tokens</li></ul> |
227
+ * Samples:
228
+ | sentence1 | sentence2 |
229
+ |:---------------------------------------------------------------------------------------------------------------------------------|:-------------------------------------------------------------------------------------|
230
+ | <code>USRC20(RH2288,2*E5-2680v2,16*16G,12*600GB(2.5 )+2*600GB(2.5 ),4*10GE,4*GE,DC)-OS RAID1,DATA RAID5+Hotspare,No DVDRW</code> | <code>Computer Equipment and Accessories</code> |
231
+ | <code>100m 160x10 Kafes Kule</code> | <code>Heavy construction machinery and equipment</code> |
232
+ | <code>Air4820 Superonline Video Bridge</code> | <code>Data Voice or Multimedia Network Equipment or Platforms and Accessories</code> |
233
+ * Loss: [<code>MultipleNegativesRankingLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#multiplenegativesrankingloss) with these parameters:
234
+ ```json
235
+ {
236
+ "scale": 20.0,
237
+ "similarity_fct": "cos_sim"
238
+ }
239
+ ```
240
+
241
+ ### Evaluation Dataset
242
+
243
+ #### Unnamed Dataset
244
+
245
+
246
+ * Size: 5,381 evaluation samples
247
+ * Columns: <code>sentence1</code> and <code>sentence2</code>
248
+ * Approximate statistics based on the first 1000 samples:
249
+ | | sentence1 | sentence2 |
250
+ |:--------|:----------------------------------------------------------------------------------|:---------------------------------------------------------------------------------|
251
+ | type | string | string |
252
+ | details | <ul><li>min: 3 tokens</li><li>mean: 16.75 tokens</li><li>max: 71 tokens</li></ul> | <ul><li>min: 3 tokens</li><li>mean: 7.89 tokens</li><li>max: 12 tokens</li></ul> |
253
+ * Samples:
254
+ | sentence1 | sentence2 |
255
+ |:------------------------------------------------------------------|:-----------------------------------------------------------------------------------------|
256
+ | <code>SNTC-24X7X4 Cisco ISR 4331 (2GE,2NIM,4G FLASH,4G DRA</code> | <code>Data Voice or Multimedia Network Equipment or Platforms and Accessories</code> |
257
+ | <code>Iridium GO Ecex</code> | <code>Communications Devices and Accessories</code> |
258
+ | <code>LC/LC SM 9/125 DX 1.8mm Lszh L 10m</code> | <code>Components for information technology or broadcasting or telecommunications</code> |
259
+ * Loss: [<code>MultipleNegativesRankingLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#multiplenegativesrankingloss) with these parameters:
260
+ ```json
261
+ {
262
+ "scale": 20.0,
263
+ "similarity_fct": "cos_sim"
264
+ }
265
+ ```
266
+
267
+ ### Training Hyperparameters
268
+ #### Non-Default Hyperparameters
269
+
270
+ - `eval_strategy`: steps
271
+ - `per_device_train_batch_size`: 16
272
+ - `per_device_eval_batch_size`: 16
273
+ - `num_train_epochs`: 2
274
+ - `warmup_ratio`: 0.1
275
+ - `fp16`: True
276
+
277
+ #### All Hyperparameters
278
+ <details><summary>Click to expand</summary>
279
+
280
+ - `overwrite_output_dir`: False
281
+ - `do_predict`: False
282
+ - `eval_strategy`: steps
283
+ - `prediction_loss_only`: True
284
+ - `per_device_train_batch_size`: 16
285
+ - `per_device_eval_batch_size`: 16
286
+ - `per_gpu_train_batch_size`: None
287
+ - `per_gpu_eval_batch_size`: None
288
+ - `gradient_accumulation_steps`: 1
289
+ - `eval_accumulation_steps`: None
290
+ - `torch_empty_cache_steps`: None
291
+ - `learning_rate`: 5e-05
292
+ - `weight_decay`: 0.0
293
+ - `adam_beta1`: 0.9
294
+ - `adam_beta2`: 0.999
295
+ - `adam_epsilon`: 1e-08
296
+ - `max_grad_norm`: 1.0
297
+ - `num_train_epochs`: 2
298
+ - `max_steps`: -1
299
+ - `lr_scheduler_type`: linear
300
+ - `lr_scheduler_kwargs`: {}
301
+ - `warmup_ratio`: 0.1
302
+ - `warmup_steps`: 0
303
+ - `log_level`: passive
304
+ - `log_level_replica`: warning
305
+ - `log_on_each_node`: True
306
+ - `logging_nan_inf_filter`: True
307
+ - `save_safetensors`: True
308
+ - `save_on_each_node`: False
309
+ - `save_only_model`: False
310
+ - `restore_callback_states_from_checkpoint`: False
311
+ - `no_cuda`: False
312
+ - `use_cpu`: False
313
+ - `use_mps_device`: False
314
+ - `seed`: 42
315
+ - `data_seed`: None
316
+ - `jit_mode_eval`: False
317
+ - `use_ipex`: False
318
+ - `bf16`: False
319
+ - `fp16`: True
320
+ - `fp16_opt_level`: O1
321
+ - `half_precision_backend`: auto
322
+ - `bf16_full_eval`: False
323
+ - `fp16_full_eval`: False
324
+ - `tf32`: None
325
+ - `local_rank`: 0
326
+ - `ddp_backend`: None
327
+ - `tpu_num_cores`: None
328
+ - `tpu_metrics_debug`: False
329
+ - `debug`: []
330
+ - `dataloader_drop_last`: False
331
+ - `dataloader_num_workers`: 0
332
+ - `dataloader_prefetch_factor`: None
333
+ - `past_index`: -1
334
+ - `disable_tqdm`: False
335
+ - `remove_unused_columns`: True
336
+ - `label_names`: None
337
+ - `load_best_model_at_end`: False
338
+ - `ignore_data_skip`: False
339
+ - `fsdp`: []
340
+ - `fsdp_min_num_params`: 0
341
+ - `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
342
+ - `fsdp_transformer_layer_cls_to_wrap`: None
343
+ - `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
344
+ - `deepspeed`: None
345
+ - `label_smoothing_factor`: 0.0
346
+ - `optim`: adamw_torch
347
+ - `optim_args`: None
348
+ - `adafactor`: False
349
+ - `group_by_length`: False
350
+ - `length_column_name`: length
351
+ - `ddp_find_unused_parameters`: None
352
+ - `ddp_bucket_cap_mb`: None
353
+ - `ddp_broadcast_buffers`: False
354
+ - `dataloader_pin_memory`: True
355
+ - `dataloader_persistent_workers`: False
356
+ - `skip_memory_metrics`: True
357
+ - `use_legacy_prediction_loop`: False
358
+ - `push_to_hub`: False
359
+ - `resume_from_checkpoint`: None
360
+ - `hub_model_id`: None
361
+ - `hub_strategy`: every_save
362
+ - `hub_private_repo`: False
363
+ - `hub_always_push`: False
364
+ - `gradient_checkpointing`: False
365
+ - `gradient_checkpointing_kwargs`: None
366
+ - `include_inputs_for_metrics`: False
367
+ - `eval_do_concat_batches`: True
368
+ - `fp16_backend`: auto
369
+ - `push_to_hub_model_id`: None
370
+ - `push_to_hub_organization`: None
371
+ - `mp_parameters`:
372
+ - `auto_find_batch_size`: False
373
+ - `full_determinism`: False
374
+ - `torchdynamo`: None
375
+ - `ray_scope`: last
376
+ - `ddp_timeout`: 1800
377
+ - `torch_compile`: False
378
+ - `torch_compile_backend`: None
379
+ - `torch_compile_mode`: None
380
+ - `dispatch_batches`: None
381
+ - `split_batches`: None
382
+ - `include_tokens_per_second`: False
383
+ - `include_num_input_tokens_seen`: False
384
+ - `neftune_noise_alpha`: None
385
+ - `optim_target_modules`: None
386
+ - `batch_eval_metrics`: False
387
+ - `eval_on_start`: False
388
+ - `eval_use_gather_object`: False
389
+ - `batch_sampler`: batch_sampler
390
+ - `multi_dataset_batch_sampler`: proportional
391
+
392
+ </details>
393
+
394
+ ### Training Logs
395
+ | Epoch | Step | Training Loss | Validation Loss | spearman_max |
396
+ |:------:|:----:|:-------------:|:---------------:|:------------:|
397
+ | 0.0637 | 100 | 2.2804 | 1.9512 | nan |
398
+ | 0.1274 | 200 | 1.8803 | 1.9189 | nan |
399
+ | 0.1911 | 300 | 1.8687 | 1.7873 | nan |
400
+ | 0.2548 | 400 | 1.7455 | 1.7351 | nan |
401
+ | 0.3185 | 500 | 1.714 | 1.6717 | nan |
402
+ | 0.3822 | 600 | 1.6956 | 1.6789 | nan |
403
+ | 0.4459 | 700 | 1.7134 | 1.6407 | nan |
404
+ | 0.5096 | 800 | 1.7059 | 1.6175 | nan |
405
+ | 0.5732 | 900 | 1.674 | 1.6256 | nan |
406
+ | 0.6369 | 1000 | 1.6725 | 1.5826 | nan |
407
+ | 0.7006 | 1100 | 1.6238 | 1.5815 | nan |
408
+ | 0.7643 | 1200 | 1.5819 | 1.5684 | nan |
409
+ | 0.8280 | 1300 | 1.526 | 1.5511 | nan |
410
+ | 0.8917 | 1400 | 1.4976 | 1.5496 | nan |
411
+ | 0.9554 | 1500 | 1.5709 | 1.5358 | nan |
412
+ | 1.0191 | 1600 | 1.4731 | 1.5498 | nan |
413
+ | 1.0828 | 1700 | 1.3914 | 1.5280 | nan |
414
+ | 1.1465 | 1800 | 1.4137 | 1.4980 | nan |
415
+ | 1.2102 | 1900 | 1.3964 | 1.5012 | nan |
416
+ | 1.2739 | 2000 | 1.4244 | 1.4972 | nan |
417
+ | 1.3376 | 2100 | 1.4567 | 1.4943 | nan |
418
+ | 1.4013 | 2200 | 1.4224 | 1.4880 | nan |
419
+ | 1.4650 | 2300 | 1.4452 | 1.4685 | nan |
420
+ | 1.5287 | 2400 | 1.3843 | 1.4976 | nan |
421
+ | 1.5924 | 2500 | 1.4538 | 1.4715 | nan |
422
+ | 1.6561 | 2600 | 1.3864 | 1.4738 | nan |
423
+ | 1.7197 | 2700 | 1.3514 | 1.4724 | nan |
424
+ | 1.7834 | 2800 | 1.4295 | 1.4538 | nan |
425
+ | 1.8471 | 2900 | 1.3631 | 1.4629 | nan |
426
+ | 1.9108 | 3000 | 1.3654 | 1.4588 | nan |
427
+ | 1.9745 | 3100 | 1.3335 | 1.4552 | nan |
428
+
429
+
430
+ ### Framework Versions
431
+ - Python: 3.10.12
432
+ - Sentence Transformers: 3.2.0
433
+ - Transformers: 4.44.2
434
+ - PyTorch: 2.4.1+cu121
435
+ - Accelerate: 0.34.2
436
+ - Datasets: 3.0.1
437
+ - Tokenizers: 0.19.1
438
+
439
+ ## Citation
440
+
441
+ ### BibTeX
442
+
443
+ #### Sentence Transformers
444
+ ```bibtex
445
+ @inproceedings{reimers-2019-sentence-bert,
446
+ title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
447
+ author = "Reimers, Nils and Gurevych, Iryna",
448
+ booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
449
+ month = "11",
450
+ year = "2019",
451
+ publisher = "Association for Computational Linguistics",
452
+ url = "https://arxiv.org/abs/1908.10084",
453
+ }
454
+ ```
455
+
456
+ #### MultipleNegativesRankingLoss
457
+ ```bibtex
458
+ @misc{henderson2017efficient,
459
+ title={Efficient Natural Language Response Suggestion for Smart Reply},
460
+ 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},
461
+ year={2017},
462
+ eprint={1705.00652},
463
+ archivePrefix={arXiv},
464
+ primaryClass={cs.CL}
465
+ }
466
+ ```
467
+
468
+ <!--
469
+ ## Glossary
470
+
471
+ *Clearly define terms in order to be accessible across audiences.*
472
+ -->
473
+
474
+ <!--
475
+ ## Model Card Authors
476
+
477
+ *Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
478
+ -->
479
+
480
+ <!--
481
+ ## Model Card Contact
482
+
483
+ *Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
484
+ -->
config.json ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "output/training_embeddings_sentence-transformers-all-mpnet-base-v2-2024-10-16_12-46-22/final",
3
+ "architectures": [
4
+ "MPNetModel"
5
+ ],
6
+ "attention_probs_dropout_prob": 0.1,
7
+ "bos_token_id": 0,
8
+ "eos_token_id": 2,
9
+ "hidden_act": "gelu",
10
+ "hidden_dropout_prob": 0.1,
11
+ "hidden_size": 768,
12
+ "initializer_range": 0.02,
13
+ "intermediate_size": 3072,
14
+ "layer_norm_eps": 1e-05,
15
+ "max_position_embeddings": 514,
16
+ "model_type": "mpnet",
17
+ "num_attention_heads": 12,
18
+ "num_hidden_layers": 12,
19
+ "pad_token_id": 1,
20
+ "relative_attention_num_buckets": 32,
21
+ "torch_dtype": "float32",
22
+ "transformers_version": "4.44.2",
23
+ "vocab_size": 30527
24
+ }
config_sentence_transformers.json ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "__version__": {
3
+ "sentence_transformers": "3.2.0",
4
+ "transformers": "4.44.2",
5
+ "pytorch": "2.4.1+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:0e8062964896a18bb03951d24750bd817c31820cece8db2a7d83a5fbd0f2c866
3
+ size 437967672
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": 384,
3
+ "do_lower_case": false
4
+ }
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": true,
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
The diff for this file is too large to render. See raw diff
 
tokenizer_config.json ADDED
@@ -0,0 +1,72 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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": true,
31
+ "rstrip": false,
32
+ "single_word": false,
33
+ "special": true
34
+ },
35
+ "104": {
36
+ "content": "[UNK]",
37
+ "lstrip": false,
38
+ "normalized": false,
39
+ "rstrip": false,
40
+ "single_word": false,
41
+ "special": true
42
+ },
43
+ "30526": {
44
+ "content": "<mask>",
45
+ "lstrip": true,
46
+ "normalized": false,
47
+ "rstrip": false,
48
+ "single_word": false,
49
+ "special": true
50
+ }
51
+ },
52
+ "bos_token": "<s>",
53
+ "clean_up_tokenization_spaces": true,
54
+ "cls_token": "<s>",
55
+ "do_lower_case": true,
56
+ "eos_token": "</s>",
57
+ "mask_token": "<mask>",
58
+ "max_length": 128,
59
+ "model_max_length": 384,
60
+ "pad_to_multiple_of": null,
61
+ "pad_token": "<pad>",
62
+ "pad_token_type_id": 0,
63
+ "padding_side": "right",
64
+ "sep_token": "</s>",
65
+ "stride": 0,
66
+ "strip_accents": null,
67
+ "tokenize_chinese_chars": true,
68
+ "tokenizer_class": "MPNetTokenizer",
69
+ "truncation_side": "right",
70
+ "truncation_strategy": "longest_first",
71
+ "unk_token": "[UNK]"
72
+ }
vocab.txt ADDED
The diff for this file is too large to render. See raw diff