albertus-sussex commited on
Commit
302ee95
·
verified ·
1 Parent(s): 47e4697

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,472 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ tags:
3
+ - sentence-transformers
4
+ - sentence-similarity
5
+ - feature-extraction
6
+ - generated_from_trainer
7
+ - dataset_size:2268
8
+ - loss:TripletLoss
9
+ base_model: Alibaba-NLP/gte-base-en-v1.5
10
+ widget:
11
+ - source_sentence: Panasonic DMC-TS2S Silver 14.1 MP 2.7" TFT(230K) LCD 4.6X Optical
12
+ Zoom Waterproof Shockproof 28mm Wide Angle Digital Camera
13
+ sentences:
14
+ - model
15
+ - Pentax Imaging
16
+ - manufacturer
17
+ - CASIO EXILIM EX-G1 Black 12.1 MP 2.5" 230K LCD 3X Optical Zoom Waterproof Shockproof
18
+ Digital Camera
19
+ - source_sentence: FUJIFILM
20
+ sentences:
21
+ - Sanyo
22
+ - manufacturer
23
+ - model
24
+ - Fuji Film Finepix S1800 12 Megapixel Digital Camera - Black
25
+ - source_sentence: 'EXILIM CARD EX-S8 - Digital camera - compact - 12.1 Mpix - optical
26
+ zoom: 4 x - supported memory: SD, SDHC - pink (EX-S8PK)'
27
+ sentences:
28
+ - price
29
+ - model
30
+ - $649.99
31
+ - FUJIFILM FinePix Z33WP Green 10.0 MP 2.7" 230K LCD 3X Optical Zoom 3m Waterproof
32
+ Digital Camera
33
+ - source_sentence: Fuji Film Finepix AV100 12 Megapixel Digital Camera - Silver
34
+ sentences:
35
+ - $84.95
36
+ - 'TL110 - Digital camera - compact - 14.2 Mpix - supported memory: SD, SDHC - black
37
+ (EC-TL110ZBPBUS)'
38
+ - model
39
+ - price
40
+ - source_sentence: $119.99
41
+ sentences:
42
+ - Panasonic
43
+ - manufacturer
44
+ - $1,076.99
45
+ - price
46
+ pipeline_tag: sentence-similarity
47
+ library_name: sentence-transformers
48
+ metrics:
49
+ - cosine_accuracy
50
+ - silhouette_cosine
51
+ - silhouette_euclidean
52
+ model-index:
53
+ - name: SentenceTransformer based on Alibaba-NLP/gte-base-en-v1.5
54
+ results:
55
+ - task:
56
+ type: triplet
57
+ name: Triplet
58
+ dataset:
59
+ name: Unknown
60
+ type: unknown
61
+ metrics:
62
+ - type: cosine_accuracy
63
+ value: 1.0
64
+ name: Cosine Accuracy
65
+ - type: cosine_accuracy
66
+ value: 1.0
67
+ name: Cosine Accuracy
68
+ - task:
69
+ type: silhouette
70
+ name: Silhouette
71
+ dataset:
72
+ name: Unknown
73
+ type: unknown
74
+ metrics:
75
+ - type: silhouette_cosine
76
+ value: 0.9849536418914795
77
+ name: Silhouette Cosine
78
+ - type: silhouette_euclidean
79
+ value: 0.8890269994735718
80
+ name: Silhouette Euclidean
81
+ - type: silhouette_cosine
82
+ value: 0.9848129153251648
83
+ name: Silhouette Cosine
84
+ - type: silhouette_euclidean
85
+ value: 0.8900662064552307
86
+ name: Silhouette Euclidean
87
+ ---
88
+
89
+ # SentenceTransformer based on Alibaba-NLP/gte-base-en-v1.5
90
+
91
+ This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [Alibaba-NLP/gte-base-en-v1.5](https://huggingface.co/Alibaba-NLP/gte-base-en-v1.5). 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.
92
+
93
+ ## Model Details
94
+
95
+ ### Model Description
96
+ - **Model Type:** Sentence Transformer
97
+ - **Base model:** [Alibaba-NLP/gte-base-en-v1.5](https://huggingface.co/Alibaba-NLP/gte-base-en-v1.5) <!-- at revision a829fd0e060bb84554da0dfd354d0de0f7712b7f -->
98
+ - **Maximum Sequence Length:** 512 tokens
99
+ - **Output Dimensionality:** 768 dimensions
100
+ - **Similarity Function:** Cosine Similarity
101
+ <!-- - **Training Dataset:** Unknown -->
102
+ <!-- - **Language:** Unknown -->
103
+ <!-- - **License:** Unknown -->
104
+
105
+ ### Model Sources
106
+
107
+ - **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
108
+ - **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
109
+ - **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
110
+
111
+ ### Full Model Architecture
112
+
113
+ ```
114
+ SentenceTransformer(
115
+ (0): Transformer({'max_seq_length': 512, 'do_lower_case': False}) with Transformer model: NewModel
116
+ (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})
117
+ )
118
+ ```
119
+
120
+ ## Usage
121
+
122
+ ### Direct Usage (Sentence Transformers)
123
+
124
+ First install the Sentence Transformers library:
125
+
126
+ ```bash
127
+ pip install -U sentence-transformers
128
+ ```
129
+
130
+ Then you can load this model and run inference.
131
+ ```python
132
+ from sentence_transformers import SentenceTransformer
133
+
134
+ # Download from the 🤗 Hub
135
+ model = SentenceTransformer("albertus-sussex/veriscrape-sbert-camera-reference_3_to_verify_7-fold-6")
136
+ # Run inference
137
+ sentences = [
138
+ '$119.99',
139
+ '$1,076.99',
140
+ 'Panasonic',
141
+ ]
142
+ embeddings = model.encode(sentences)
143
+ print(embeddings.shape)
144
+ # [3, 768]
145
+
146
+ # Get the similarity scores for the embeddings
147
+ similarities = model.similarity(embeddings, embeddings)
148
+ print(similarities.shape)
149
+ # [3, 3]
150
+ ```
151
+
152
+ <!--
153
+ ### Direct Usage (Transformers)
154
+
155
+ <details><summary>Click to see the direct usage in Transformers</summary>
156
+
157
+ </details>
158
+ -->
159
+
160
+ <!--
161
+ ### Downstream Usage (Sentence Transformers)
162
+
163
+ You can finetune this model on your own dataset.
164
+
165
+ <details><summary>Click to expand</summary>
166
+
167
+ </details>
168
+ -->
169
+
170
+ <!--
171
+ ### Out-of-Scope Use
172
+
173
+ *List how the model may foreseeably be misused and address what users ought not to do with the model.*
174
+ -->
175
+
176
+ ## Evaluation
177
+
178
+ ### Metrics
179
+
180
+ #### Triplet
181
+
182
+ * Evaluated with [<code>TripletEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.TripletEvaluator)
183
+
184
+ | Metric | Value |
185
+ |:--------------------|:--------|
186
+ | **cosine_accuracy** | **1.0** |
187
+
188
+ #### Silhouette
189
+
190
+ * Evaluated with <code>veriscrape.training.SilhouetteEvaluator</code>
191
+
192
+ | Metric | Value |
193
+ |:----------------------|:----------|
194
+ | **silhouette_cosine** | **0.985** |
195
+ | silhouette_euclidean | 0.889 |
196
+
197
+ #### Triplet
198
+
199
+ * Evaluated with [<code>TripletEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.TripletEvaluator)
200
+
201
+ | Metric | Value |
202
+ |:--------------------|:--------|
203
+ | **cosine_accuracy** | **1.0** |
204
+
205
+ #### Silhouette
206
+
207
+ * Evaluated with <code>veriscrape.training.SilhouetteEvaluator</code>
208
+
209
+ | Metric | Value |
210
+ |:----------------------|:-----------|
211
+ | **silhouette_cosine** | **0.9848** |
212
+ | silhouette_euclidean | 0.8901 |
213
+
214
+ <!--
215
+ ## Bias, Risks and Limitations
216
+
217
+ *What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
218
+ -->
219
+
220
+ <!--
221
+ ### Recommendations
222
+
223
+ *What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
224
+ -->
225
+
226
+ ## Training Details
227
+
228
+ ### Training Dataset
229
+
230
+ #### Unnamed Dataset
231
+
232
+ * Size: 2,268 training samples
233
+ * Columns: <code>anchor</code>, <code>positive</code>, <code>negative</code>, <code>pos_attr_name</code>, and <code>neg_attr_name</code>
234
+ * Approximate statistics based on the first 1000 samples:
235
+ | | anchor | positive | negative | pos_attr_name | neg_attr_name |
236
+ |:--------|:----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|:-------------------------------------------------------------------------------|:-------------------------------------------------------------------------------|
237
+ | type | string | string | string | string | string |
238
+ | details | <ul><li>min: 3 tokens</li><li>mean: 12.84 tokens</li><li>max: 60 tokens</li></ul> | <ul><li>min: 3 tokens</li><li>mean: 13.29 tokens</li><li>max: 79 tokens</li></ul> | <ul><li>min: 3 tokens</li><li>mean: 11.12 tokens</li><li>max: 44 tokens</li></ul> | <ul><li>min: 3 tokens</li><li>mean: 3.0 tokens</li><li>max: 3 tokens</li></ul> | <ul><li>min: 3 tokens</li><li>mean: 3.0 tokens</li><li>max: 3 tokens</li></ul> |
239
+ * Samples:
240
+ | anchor | positive | negative | pos_attr_name | neg_attr_name |
241
+ |:-----------------------------------------------|:-----------------------------------------------------------------------------------------------------------------|:------------------------------------------------------------------------------------------------------------------------------------|:--------------------------|:-------------------|
242
+ | <code>PENTAX K-5 BODY KIT BLACK (14622)</code> | <code>SONY Cyber-shot DSC-W350 Black 14.1 MP 2.7" 230K LCD 4X Optical Zoom 26mm Wide Angle Digital Camera</code> | <code>$176.99</code> | <code>model</code> | <code>price</code> |
243
+ | <code>$166.91</code> | <code>$179.36</code> | <code>Nikon COOLPIX S3000 Black 12.0 MP 2.7" 230K Anti-reflection Coating LCD 4X Optical Zoom 27mm Wide Angle Digital Camera</code> | <code>price</code> | <code>model</code> |
244
+ | <code>FUJIFILM</code> | <code>Brand = Samsung</code> | <code>$199.00</code> | <code>manufacturer</code> | <code>price</code> |
245
+ * Loss: [<code>TripletLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#tripletloss) with these parameters:
246
+ ```json
247
+ {
248
+ "distance_metric": "TripletDistanceMetric.EUCLIDEAN",
249
+ "triplet_margin": 5
250
+ }
251
+ ```
252
+
253
+ ### Evaluation Dataset
254
+
255
+ #### Unnamed Dataset
256
+
257
+ * Size: 253 evaluation samples
258
+ * Columns: <code>anchor</code>, <code>positive</code>, <code>negative</code>, <code>pos_attr_name</code>, and <code>neg_attr_name</code>
259
+ * Approximate statistics based on the first 253 samples:
260
+ | | anchor | positive | negative | pos_attr_name | neg_attr_name |
261
+ |:--------|:---------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|:---------------------------------------------------------------------------------|:-------------------------------------------------------------------------------|:-------------------------------------------------------------------------------|
262
+ | type | string | string | string | string | string |
263
+ | details | <ul><li>min: 3 tokens</li><li>mean: 12.5 tokens</li><li>max: 56 tokens</li></ul> | <ul><li>min: 3 tokens</li><li>mean: 12.91 tokens</li><li>max: 69 tokens</li></ul> | <ul><li>min: 3 tokens</li><li>mean: 12.4 tokens</li><li>max: 39 tokens</li></ul> | <ul><li>min: 3 tokens</li><li>mean: 3.0 tokens</li><li>max: 3 tokens</li></ul> | <ul><li>min: 3 tokens</li><li>mean: 3.0 tokens</li><li>max: 3 tokens</li></ul> |
264
+ * Samples:
265
+ | anchor | positive | negative | pos_attr_name | neg_attr_name |
266
+ |:---------------------------------------------------------------------------------------------------------------------------------------|:-------------------------------------------------------------------------|:------------------------------------------------------|:--------------------------|:-------------------|
267
+ | <code>Sony DSC-S2100 12.1 Megapixel Cyber-shot® Digital Camera S2100 - Black</code> | <code>VistaQuest 2.0 MP Digital Camera VQ-2005</code> | <code>$219.99</code> | <code>model</code> | <code>price</code> |
268
+ | <code>EASYSHARE M530 - Digital camera - compact - 12.0 Mpix - optical zoom: 3 x - supported memory: SD, SDHC - carbon (8085730)</code> | <code>Nikon Coolpix S1100pj 14.1-Megapixel Digital Camera - Green</code> | <code>$649.99</code> | <code>model</code> | <code>price</code> |
269
+ | <code>Fujifilm</code> | <code>Sony</code> | <code>FUJIFILM Instax 210 Instant Photo Camera</code> | <code>manufacturer</code> | <code>model</code> |
270
+ * Loss: [<code>TripletLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#tripletloss) with these parameters:
271
+ ```json
272
+ {
273
+ "distance_metric": "TripletDistanceMetric.EUCLIDEAN",
274
+ "triplet_margin": 5
275
+ }
276
+ ```
277
+
278
+ ### Training Hyperparameters
279
+ #### Non-Default Hyperparameters
280
+
281
+ - `eval_strategy`: epoch
282
+ - `per_device_train_batch_size`: 128
283
+ - `per_device_eval_batch_size`: 128
284
+ - `num_train_epochs`: 5
285
+ - `warmup_ratio`: 0.1
286
+
287
+ #### All Hyperparameters
288
+ <details><summary>Click to expand</summary>
289
+
290
+ - `overwrite_output_dir`: False
291
+ - `do_predict`: False
292
+ - `eval_strategy`: epoch
293
+ - `prediction_loss_only`: True
294
+ - `per_device_train_batch_size`: 128
295
+ - `per_device_eval_batch_size`: 128
296
+ - `per_gpu_train_batch_size`: None
297
+ - `per_gpu_eval_batch_size`: None
298
+ - `gradient_accumulation_steps`: 1
299
+ - `eval_accumulation_steps`: None
300
+ - `torch_empty_cache_steps`: None
301
+ - `learning_rate`: 5e-05
302
+ - `weight_decay`: 0.0
303
+ - `adam_beta1`: 0.9
304
+ - `adam_beta2`: 0.999
305
+ - `adam_epsilon`: 1e-08
306
+ - `max_grad_norm`: 1.0
307
+ - `num_train_epochs`: 5
308
+ - `max_steps`: -1
309
+ - `lr_scheduler_type`: linear
310
+ - `lr_scheduler_kwargs`: {}
311
+ - `warmup_ratio`: 0.1
312
+ - `warmup_steps`: 0
313
+ - `log_level`: passive
314
+ - `log_level_replica`: warning
315
+ - `log_on_each_node`: True
316
+ - `logging_nan_inf_filter`: True
317
+ - `save_safetensors`: True
318
+ - `save_on_each_node`: False
319
+ - `save_only_model`: False
320
+ - `restore_callback_states_from_checkpoint`: False
321
+ - `no_cuda`: False
322
+ - `use_cpu`: False
323
+ - `use_mps_device`: False
324
+ - `seed`: 42
325
+ - `data_seed`: None
326
+ - `jit_mode_eval`: False
327
+ - `use_ipex`: False
328
+ - `bf16`: False
329
+ - `fp16`: False
330
+ - `fp16_opt_level`: O1
331
+ - `half_precision_backend`: auto
332
+ - `bf16_full_eval`: False
333
+ - `fp16_full_eval`: False
334
+ - `tf32`: None
335
+ - `local_rank`: 0
336
+ - `ddp_backend`: None
337
+ - `tpu_num_cores`: None
338
+ - `tpu_metrics_debug`: False
339
+ - `debug`: []
340
+ - `dataloader_drop_last`: False
341
+ - `dataloader_num_workers`: 0
342
+ - `dataloader_prefetch_factor`: None
343
+ - `past_index`: -1
344
+ - `disable_tqdm`: False
345
+ - `remove_unused_columns`: True
346
+ - `label_names`: None
347
+ - `load_best_model_at_end`: False
348
+ - `ignore_data_skip`: False
349
+ - `fsdp`: []
350
+ - `fsdp_min_num_params`: 0
351
+ - `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
352
+ - `fsdp_transformer_layer_cls_to_wrap`: None
353
+ - `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
354
+ - `deepspeed`: None
355
+ - `label_smoothing_factor`: 0.0
356
+ - `optim`: adamw_torch
357
+ - `optim_args`: None
358
+ - `adafactor`: False
359
+ - `group_by_length`: False
360
+ - `length_column_name`: length
361
+ - `ddp_find_unused_parameters`: None
362
+ - `ddp_bucket_cap_mb`: None
363
+ - `ddp_broadcast_buffers`: False
364
+ - `dataloader_pin_memory`: True
365
+ - `dataloader_persistent_workers`: False
366
+ - `skip_memory_metrics`: True
367
+ - `use_legacy_prediction_loop`: False
368
+ - `push_to_hub`: False
369
+ - `resume_from_checkpoint`: None
370
+ - `hub_model_id`: None
371
+ - `hub_strategy`: every_save
372
+ - `hub_private_repo`: False
373
+ - `hub_always_push`: False
374
+ - `gradient_checkpointing`: False
375
+ - `gradient_checkpointing_kwargs`: None
376
+ - `include_inputs_for_metrics`: False
377
+ - `eval_do_concat_batches`: True
378
+ - `fp16_backend`: auto
379
+ - `push_to_hub_model_id`: None
380
+ - `push_to_hub_organization`: None
381
+ - `mp_parameters`:
382
+ - `auto_find_batch_size`: False
383
+ - `full_determinism`: False
384
+ - `torchdynamo`: None
385
+ - `ray_scope`: last
386
+ - `ddp_timeout`: 1800
387
+ - `torch_compile`: False
388
+ - `torch_compile_backend`: None
389
+ - `torch_compile_mode`: None
390
+ - `dispatch_batches`: None
391
+ - `split_batches`: None
392
+ - `include_tokens_per_second`: False
393
+ - `include_num_input_tokens_seen`: False
394
+ - `neftune_noise_alpha`: None
395
+ - `optim_target_modules`: None
396
+ - `batch_eval_metrics`: False
397
+ - `eval_on_start`: False
398
+ - `use_liger_kernel`: False
399
+ - `eval_use_gather_object`: False
400
+ - `prompts`: None
401
+ - `batch_sampler`: batch_sampler
402
+ - `multi_dataset_batch_sampler`: proportional
403
+
404
+ </details>
405
+
406
+ ### Training Logs
407
+ | Epoch | Step | Training Loss | Validation Loss | cosine_accuracy | silhouette_cosine |
408
+ |:-----:|:----:|:-------------:|:---------------:|:---------------:|:-----------------:|
409
+ | -1 | -1 | - | - | 0.7945 | 0.3845 |
410
+ | 1.0 | 18 | 0.5008 | 0.0 | 1.0 | 0.9748 |
411
+ | 2.0 | 36 | 0.0 | 0.0 | 1.0 | 0.9840 |
412
+ | 3.0 | 54 | 0.0 | 0.0 | 1.0 | 0.9849 |
413
+ | 4.0 | 72 | 0.0 | 0.0 | 1.0 | 0.9849 |
414
+ | 5.0 | 90 | 0.0 | 0.0 | 1.0 | 0.9850 |
415
+ | -1 | -1 | - | - | 1.0 | 0.9848 |
416
+
417
+
418
+ ### Framework Versions
419
+ - Python: 3.10.16
420
+ - Sentence Transformers: 4.0.1
421
+ - Transformers: 4.45.2
422
+ - PyTorch: 2.5.1+cu124
423
+ - Accelerate: 1.5.2
424
+ - Datasets: 3.1.0
425
+ - Tokenizers: 0.20.3
426
+
427
+ ## Citation
428
+
429
+ ### BibTeX
430
+
431
+ #### Sentence Transformers
432
+ ```bibtex
433
+ @inproceedings{reimers-2019-sentence-bert,
434
+ title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
435
+ author = "Reimers, Nils and Gurevych, Iryna",
436
+ booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
437
+ month = "11",
438
+ year = "2019",
439
+ publisher = "Association for Computational Linguistics",
440
+ url = "https://arxiv.org/abs/1908.10084",
441
+ }
442
+ ```
443
+
444
+ #### TripletLoss
445
+ ```bibtex
446
+ @misc{hermans2017defense,
447
+ title={In Defense of the Triplet Loss for Person Re-Identification},
448
+ author={Alexander Hermans and Lucas Beyer and Bastian Leibe},
449
+ year={2017},
450
+ eprint={1703.07737},
451
+ archivePrefix={arXiv},
452
+ primaryClass={cs.CV}
453
+ }
454
+ ```
455
+
456
+ <!--
457
+ ## Glossary
458
+
459
+ *Clearly define terms in order to be accessible across audiences.*
460
+ -->
461
+
462
+ <!--
463
+ ## Model Card Authors
464
+
465
+ *Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
466
+ -->
467
+
468
+ <!--
469
+ ## Model Card Contact
470
+
471
+ *Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
472
+ -->
config.json ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "Alibaba-NLP/gte-base-en-v1.5",
3
+ "architectures": [
4
+ "NewModel"
5
+ ],
6
+ "attention_probs_dropout_prob": 0.0,
7
+ "auto_map": {
8
+ "AutoConfig": "Alibaba-NLP/new-impl--configuration.NewConfig",
9
+ "AutoModel": "Alibaba-NLP/new-impl--modeling.NewModel",
10
+ "AutoModelForMaskedLM": "Alibaba-NLP/new-impl--modeling.NewForMaskedLM",
11
+ "AutoModelForMultipleChoice": "Alibaba-NLP/new-impl--modeling.NewForMultipleChoice",
12
+ "AutoModelForQuestionAnswering": "Alibaba-NLP/new-impl--modeling.NewForQuestionAnswering",
13
+ "AutoModelForSequenceClassification": "Alibaba-NLP/new-impl--modeling.NewForSequenceClassification",
14
+ "AutoModelForTokenClassification": "Alibaba-NLP/new-impl--modeling.NewForTokenClassification"
15
+ },
16
+ "classifier_dropout": null,
17
+ "hidden_act": "gelu",
18
+ "hidden_dropout_prob": 0.1,
19
+ "hidden_size": 768,
20
+ "initializer_range": 0.02,
21
+ "intermediate_size": 3072,
22
+ "layer_norm_eps": 1e-12,
23
+ "layer_norm_type": "layer_norm",
24
+ "logn_attention_clip1": false,
25
+ "logn_attention_scale": false,
26
+ "max_position_embeddings": 8192,
27
+ "model_type": "new",
28
+ "num_attention_heads": 12,
29
+ "num_hidden_layers": 12,
30
+ "pack_qkv": true,
31
+ "pad_token_id": 0,
32
+ "position_embedding_type": "rope",
33
+ "rope_scaling": {
34
+ "factor": 2.0,
35
+ "type": "ntk"
36
+ },
37
+ "rope_theta": 500000,
38
+ "torch_dtype": "float32",
39
+ "transformers_version": "4.45.2",
40
+ "type_vocab_size": 0,
41
+ "unpad_inputs": false,
42
+ "use_memory_efficient_attention": false,
43
+ "vocab_size": 30528
44
+ }
config_sentence_transformers.json ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "__version__": {
3
+ "sentence_transformers": "4.0.1",
4
+ "transformers": "4.45.2",
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:91b9d4d525004850f3d838c9a3685634ceadf2c9074216cefdefb58377f5c462
3
+ size 547119128
modules.json ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
+ ]
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,62 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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_lower_case": true,
47
+ "mask_token": "[MASK]",
48
+ "max_length": 512,
49
+ "model_max_length": 512,
50
+ "pad_to_multiple_of": null,
51
+ "pad_token": "[PAD]",
52
+ "pad_token_type_id": 0,
53
+ "padding_side": "right",
54
+ "sep_token": "[SEP]",
55
+ "stride": 0,
56
+ "strip_accents": null,
57
+ "tokenize_chinese_chars": true,
58
+ "tokenizer_class": "BertTokenizer",
59
+ "truncation_side": "right",
60
+ "truncation_strategy": "longest_first",
61
+ "unk_token": "[UNK]"
62
+ }
vocab.txt ADDED
The diff for this file is too large to render. See raw diff