jonny9f commited on
Commit
02239ea
·
verified ·
1 Parent(s): 8a30bc3

Upload food embeddings 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,604 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ tags:
3
+ - sentence-transformers
4
+ - sentence-similarity
5
+ - feature-extraction
6
+ - generated_from_trainer
7
+ - dataset_size:1200000
8
+ - loss:CosineSimilarityLoss
9
+ base_model: sentence-transformers/all-mpnet-base-v2
10
+ widget:
11
+ - source_sentence: Mutton, roasted
12
+ sentences:
13
+ - Imagine Creamy Butternut Squash Soup
14
+ - Perrier Water, bottled
15
+ - Crackers, whole-wheat
16
+ - source_sentence: Beef Chuck Mock Tender Steak, lean and fat raw
17
+ sentences:
18
+ - Lamb, Australian leg roasted, bone-in
19
+ - Chicken wing, meat and skin, cooked fried flour
20
+ - Peaches, canned in heavy syrup
21
+ - source_sentence: Squash, zucchini baby raw
22
+ sentences:
23
+ - Dandelion greens, cooked with salt
24
+ - Beets, pickled canned
25
+ - Cod, Atlantic canned
26
+ - source_sentence: Veggie Meatballs
27
+ sentences:
28
+ - Salt, iodized
29
+ - Sweet and Sour Sauce, ready-to-serve
30
+ - Salt pork, raw
31
+ - source_sentence: Beef Top Round, lean raw
32
+ sentences:
33
+ - Ravioli, meat-filled with tomato or meat sauce canned
34
+ - Pasta Sauce, spaghetti/marinara ready-to-serve
35
+ - Luncheon Slices, meatless
36
+ pipeline_tag: sentence-similarity
37
+ library_name: sentence-transformers
38
+ metrics:
39
+ - pearson_cosine
40
+ - spearman_cosine
41
+ model-index:
42
+ - name: SentenceTransformer based on sentence-transformers/all-mpnet-base-v2
43
+ results:
44
+ - task:
45
+ type: semantic-similarity
46
+ name: Semantic Similarity
47
+ dataset:
48
+ name: validation
49
+ type: validation
50
+ metrics:
51
+ - type: pearson_cosine
52
+ value: 0.9913128359649296
53
+ name: Pearson Cosine
54
+ - type: spearman_cosine
55
+ value: 0.9868170667730207
56
+ name: Spearman Cosine
57
+ ---
58
+
59
+ # SentenceTransformer based on sentence-transformers/all-mpnet-base-v2
60
+
61
+ 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.
62
+
63
+ ## Model Details
64
+
65
+ ### Model Description
66
+ - **Model Type:** Sentence Transformer
67
+ - **Base model:** [sentence-transformers/all-mpnet-base-v2](https://huggingface.co/sentence-transformers/all-mpnet-base-v2) <!-- at revision 9a3225965996d404b775526de6dbfe85d3368642 -->
68
+ - **Maximum Sequence Length:** 384 tokens
69
+ - **Output Dimensionality:** 768 dimensions
70
+ - **Similarity Function:** Cosine Similarity
71
+ <!-- - **Training Dataset:** Unknown -->
72
+ <!-- - **Language:** Unknown -->
73
+ <!-- - **License:** Unknown -->
74
+
75
+ ### Model Sources
76
+
77
+ - **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
78
+ - **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
79
+ - **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
80
+
81
+ ### Full Model Architecture
82
+
83
+ ```
84
+ SentenceTransformer(
85
+ (0): Transformer({'max_seq_length': 384, 'do_lower_case': False}) with Transformer model: MPNetModel
86
+ (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})
87
+ (2): Normalize()
88
+ )
89
+ ```
90
+
91
+ ## Usage
92
+
93
+ ### Direct Usage (Sentence Transformers)
94
+
95
+ First install the Sentence Transformers library:
96
+
97
+ ```bash
98
+ pip install -U sentence-transformers
99
+ ```
100
+
101
+ Then you can load this model and run inference.
102
+ ```python
103
+ from sentence_transformers import SentenceTransformer
104
+
105
+ # Download from the 🤗 Hub
106
+ model = SentenceTransformer("jonny9f/food_embeddings")
107
+ # Run inference
108
+ sentences = [
109
+ 'Beef Top Round, lean raw',
110
+ 'Luncheon Slices, meatless',
111
+ 'Pasta Sauce, spaghetti/marinara ready-to-serve',
112
+ ]
113
+ embeddings = model.encode(sentences)
114
+ print(embeddings.shape)
115
+ # [3, 768]
116
+
117
+ # Get the similarity scores for the embeddings
118
+ similarities = model.similarity(embeddings, embeddings)
119
+ print(similarities.shape)
120
+ # [3, 3]
121
+ ```
122
+
123
+ <!--
124
+ ### Direct Usage (Transformers)
125
+
126
+ <details><summary>Click to see the direct usage in Transformers</summary>
127
+
128
+ </details>
129
+ -->
130
+
131
+ <!--
132
+ ### Downstream Usage (Sentence Transformers)
133
+
134
+ You can finetune this model on your own dataset.
135
+
136
+ <details><summary>Click to expand</summary>
137
+
138
+ </details>
139
+ -->
140
+
141
+ <!--
142
+ ### Out-of-Scope Use
143
+
144
+ *List how the model may foreseeably be misused and address what users ought not to do with the model.*
145
+ -->
146
+
147
+ ## Evaluation
148
+
149
+ ### Metrics
150
+
151
+ #### Semantic Similarity
152
+
153
+ * Dataset: `validation`
154
+ * Evaluated with [<code>EmbeddingSimilarityEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.EmbeddingSimilarityEvaluator)
155
+
156
+ | Metric | Value |
157
+ |:--------------------|:-----------|
158
+ | pearson_cosine | 0.9913 |
159
+ | **spearman_cosine** | **0.9868** |
160
+
161
+ <!--
162
+ ## Bias, Risks and Limitations
163
+
164
+ *What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
165
+ -->
166
+
167
+ <!--
168
+ ### Recommendations
169
+
170
+ *What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
171
+ -->
172
+
173
+ ## Training Details
174
+
175
+ ### Training Dataset
176
+
177
+ #### Unnamed Dataset
178
+
179
+
180
+ * Size: 1,200,000 training samples
181
+ * Columns: <code>sentence_0</code>, <code>sentence_1</code>, and <code>label</code>
182
+ * Approximate statistics based on the first 1000 samples:
183
+ | | sentence_0 | sentence_1 | label |
184
+ |:--------|:---------------------------------------------------------------------------------|:---------------------------------------------------------------------------------|:----------------------------------------------------------------|
185
+ | type | string | string | float |
186
+ | details | <ul><li>min: 4 tokens</li><li>mean: 10.2 tokens</li><li>max: 28 tokens</li></ul> | <ul><li>min: 4 tokens</li><li>mean: 9.65 tokens</li><li>max: 23 tokens</li></ul> | <ul><li>min: 0.0</li><li>mean: 0.26</li><li>max: 0.92</li></ul> |
187
+ * Samples:
188
+ | sentence_0 | sentence_1 | label |
189
+ |:---------------------------------------------------------------|:-------------------------------------------------------------|:---------------------------------|
190
+ | <code>Beef top round roast, boneless lean select cooked</code> | <code>Blueberries, canned wild in heavy syrup drained</code> | <code>0.21440656185150148</code> |
191
+ | <code>Nance, frozen unsweetened</code> | <code>Soymilk, unsweetened</code> | <code>0.3654276132583618</code> |
192
+ | <code>Drops - Lemonade</code> | <code>Pickle relish, sweet</code> | <code>0.30108280181884767</code> |
193
+ * Loss: [<code>CosineSimilarityLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#cosinesimilarityloss) with these parameters:
194
+ ```json
195
+ {
196
+ "loss_fct": "torch.nn.modules.loss.MSELoss"
197
+ }
198
+ ```
199
+
200
+ ### Training Hyperparameters
201
+ #### Non-Default Hyperparameters
202
+
203
+ - `per_device_train_batch_size`: 32
204
+ - `per_device_eval_batch_size`: 32
205
+ - `num_train_epochs`: 1
206
+ - `multi_dataset_batch_sampler`: round_robin
207
+
208
+ #### All Hyperparameters
209
+ <details><summary>Click to expand</summary>
210
+
211
+ - `overwrite_output_dir`: False
212
+ - `do_predict`: False
213
+ - `eval_strategy`: no
214
+ - `prediction_loss_only`: True
215
+ - `per_device_train_batch_size`: 32
216
+ - `per_device_eval_batch_size`: 32
217
+ - `per_gpu_train_batch_size`: None
218
+ - `per_gpu_eval_batch_size`: None
219
+ - `gradient_accumulation_steps`: 1
220
+ - `eval_accumulation_steps`: None
221
+ - `torch_empty_cache_steps`: None
222
+ - `learning_rate`: 5e-05
223
+ - `weight_decay`: 0.0
224
+ - `adam_beta1`: 0.9
225
+ - `adam_beta2`: 0.999
226
+ - `adam_epsilon`: 1e-08
227
+ - `max_grad_norm`: 1
228
+ - `num_train_epochs`: 1
229
+ - `max_steps`: -1
230
+ - `lr_scheduler_type`: linear
231
+ - `lr_scheduler_kwargs`: {}
232
+ - `warmup_ratio`: 0.0
233
+ - `warmup_steps`: 0
234
+ - `log_level`: passive
235
+ - `log_level_replica`: warning
236
+ - `log_on_each_node`: True
237
+ - `logging_nan_inf_filter`: True
238
+ - `save_safetensors`: True
239
+ - `save_on_each_node`: False
240
+ - `save_only_model`: False
241
+ - `restore_callback_states_from_checkpoint`: False
242
+ - `no_cuda`: False
243
+ - `use_cpu`: False
244
+ - `use_mps_device`: False
245
+ - `seed`: 42
246
+ - `data_seed`: None
247
+ - `jit_mode_eval`: False
248
+ - `use_ipex`: False
249
+ - `bf16`: False
250
+ - `fp16`: False
251
+ - `fp16_opt_level`: O1
252
+ - `half_precision_backend`: auto
253
+ - `bf16_full_eval`: False
254
+ - `fp16_full_eval`: False
255
+ - `tf32`: None
256
+ - `local_rank`: 0
257
+ - `ddp_backend`: None
258
+ - `tpu_num_cores`: None
259
+ - `tpu_metrics_debug`: False
260
+ - `debug`: []
261
+ - `dataloader_drop_last`: False
262
+ - `dataloader_num_workers`: 0
263
+ - `dataloader_prefetch_factor`: None
264
+ - `past_index`: -1
265
+ - `disable_tqdm`: False
266
+ - `remove_unused_columns`: True
267
+ - `label_names`: None
268
+ - `load_best_model_at_end`: False
269
+ - `ignore_data_skip`: False
270
+ - `fsdp`: []
271
+ - `fsdp_min_num_params`: 0
272
+ - `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
273
+ - `fsdp_transformer_layer_cls_to_wrap`: None
274
+ - `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
275
+ - `deepspeed`: None
276
+ - `label_smoothing_factor`: 0.0
277
+ - `optim`: adamw_torch
278
+ - `optim_args`: None
279
+ - `adafactor`: False
280
+ - `group_by_length`: False
281
+ - `length_column_name`: length
282
+ - `ddp_find_unused_parameters`: None
283
+ - `ddp_bucket_cap_mb`: None
284
+ - `ddp_broadcast_buffers`: False
285
+ - `dataloader_pin_memory`: True
286
+ - `dataloader_persistent_workers`: False
287
+ - `skip_memory_metrics`: True
288
+ - `use_legacy_prediction_loop`: False
289
+ - `push_to_hub`: False
290
+ - `resume_from_checkpoint`: None
291
+ - `hub_model_id`: None
292
+ - `hub_strategy`: every_save
293
+ - `hub_private_repo`: None
294
+ - `hub_always_push`: False
295
+ - `gradient_checkpointing`: False
296
+ - `gradient_checkpointing_kwargs`: None
297
+ - `include_inputs_for_metrics`: False
298
+ - `include_for_metrics`: []
299
+ - `eval_do_concat_batches`: True
300
+ - `fp16_backend`: auto
301
+ - `push_to_hub_model_id`: None
302
+ - `push_to_hub_organization`: None
303
+ - `mp_parameters`:
304
+ - `auto_find_batch_size`: False
305
+ - `full_determinism`: False
306
+ - `torchdynamo`: None
307
+ - `ray_scope`: last
308
+ - `ddp_timeout`: 1800
309
+ - `torch_compile`: False
310
+ - `torch_compile_backend`: None
311
+ - `torch_compile_mode`: None
312
+ - `dispatch_batches`: None
313
+ - `split_batches`: None
314
+ - `include_tokens_per_second`: False
315
+ - `include_num_input_tokens_seen`: False
316
+ - `neftune_noise_alpha`: None
317
+ - `optim_target_modules`: None
318
+ - `batch_eval_metrics`: False
319
+ - `eval_on_start`: False
320
+ - `use_liger_kernel`: False
321
+ - `eval_use_gather_object`: False
322
+ - `average_tokens_across_devices`: False
323
+ - `prompts`: None
324
+ - `batch_sampler`: batch_sampler
325
+ - `multi_dataset_batch_sampler`: round_robin
326
+
327
+ </details>
328
+
329
+ ### Training Logs
330
+ <details><summary>Click to expand</summary>
331
+
332
+ | Epoch | Step | Training Loss | validation_spearman_cosine |
333
+ |:------:|:-----:|:-------------:|:--------------------------:|
334
+ | 0.0133 | 500 | 0.0031 | - |
335
+ | 0.0267 | 1000 | 0.0028 | - |
336
+ | 0.04 | 1500 | 0.0025 | - |
337
+ | 0.0533 | 2000 | 0.0024 | - |
338
+ | 0.0667 | 2500 | 0.0023 | - |
339
+ | 0.08 | 3000 | 0.0022 | - |
340
+ | 0.0933 | 3500 | 0.0021 | - |
341
+ | 0.1067 | 4000 | 0.002 | - |
342
+ | 0.12 | 4500 | 0.002 | - |
343
+ | 0.1333 | 5000 | 0.0019 | - |
344
+ | 0.1467 | 5500 | 0.0018 | - |
345
+ | 0.16 | 6000 | 0.0018 | - |
346
+ | 0.1733 | 6500 | 0.0017 | - |
347
+ | 0.1867 | 7000 | 0.0017 | - |
348
+ | 0.2 | 7500 | 0.0016 | - |
349
+ | 0.2133 | 8000 | 0.0016 | - |
350
+ | 0.2267 | 8500 | 0.0016 | - |
351
+ | 0.24 | 9000 | 0.0015 | - |
352
+ | 0.2533 | 9500 | 0.0015 | - |
353
+ | 0.2667 | 10000 | 0.0015 | - |
354
+ | 0.28 | 10500 | 0.0015 | - |
355
+ | 0.2933 | 11000 | 0.0015 | - |
356
+ | 0.3067 | 11500 | 0.0014 | - |
357
+ | 0.32 | 12000 | 0.0014 | - |
358
+ | 0.3333 | 12500 | 0.0013 | - |
359
+ | 0.3467 | 13000 | 0.0013 | - |
360
+ | 0.36 | 13500 | 0.0013 | - |
361
+ | 0.3733 | 14000 | 0.0013 | - |
362
+ | 0.3867 | 14500 | 0.0012 | - |
363
+ | 0.4 | 15000 | 0.0012 | - |
364
+ | 0.4133 | 15500 | 0.0012 | - |
365
+ | 0.4267 | 16000 | 0.0012 | - |
366
+ | 0.44 | 16500 | 0.0012 | - |
367
+ | 0.4533 | 17000 | 0.0012 | - |
368
+ | 0.4667 | 17500 | 0.0011 | - |
369
+ | 0.48 | 18000 | 0.0011 | - |
370
+ | 0.4933 | 18500 | 0.0011 | - |
371
+ | 0.5067 | 19000 | 0.0011 | - |
372
+ | 0.52 | 19500 | 0.0011 | - |
373
+ | 0.5333 | 20000 | 0.0011 | - |
374
+ | 0.5467 | 20500 | 0.0011 | - |
375
+ | 0.56 | 21000 | 0.001 | - |
376
+ | 0.5733 | 21500 | 0.001 | - |
377
+ | 0.5867 | 22000 | 0.001 | - |
378
+ | 0.6 | 22500 | 0.001 | - |
379
+ | 0.6133 | 23000 | 0.001 | - |
380
+ | 0.6267 | 23500 | 0.001 | - |
381
+ | 0.64 | 24000 | 0.0009 | - |
382
+ | 0.6533 | 24500 | 0.0009 | - |
383
+ | 0.6667 | 25000 | 0.0009 | - |
384
+ | 0.68 | 25500 | 0.0009 | - |
385
+ | 0.6933 | 26000 | 0.0009 | - |
386
+ | 0.7067 | 26500 | 0.0009 | - |
387
+ | 0.72 | 27000 | 0.0009 | - |
388
+ | 0.7333 | 27500 | 0.0009 | - |
389
+ | 0.7467 | 28000 | 0.0009 | - |
390
+ | 0.76 | 28500 | 0.0008 | - |
391
+ | 0.7733 | 29000 | 0.0008 | - |
392
+ | 0.7867 | 29500 | 0.0008 | - |
393
+ | 0.8 | 30000 | 0.0008 | - |
394
+ | 0.8133 | 30500 | 0.0008 | - |
395
+ | 0.8267 | 31000 | 0.0008 | - |
396
+ | 0.84 | 31500 | 0.0008 | - |
397
+ | 0.8533 | 32000 | 0.0008 | - |
398
+ | 0.8667 | 32500 | 0.0008 | - |
399
+ | 0.88 | 33000 | 0.0007 | - |
400
+ | 0.8933 | 33500 | 0.0007 | - |
401
+ | 0.9067 | 34000 | 0.0008 | - |
402
+ | 0.92 | 34500 | 0.0007 | - |
403
+ | 0.9333 | 35000 | 0.0007 | - |
404
+ | 0.9467 | 35500 | 0.0007 | - |
405
+ | 0.96 | 36000 | 0.0007 | - |
406
+ | 0.9733 | 36500 | 0.0007 | - |
407
+ | 0.9867 | 37000 | 0.0007 | - |
408
+ | 1.0 | 37500 | 0.0007 | 0.9799 |
409
+ | 0.0133 | 500 | 0.0009 | - |
410
+ | 0.0267 | 1000 | 0.0011 | - |
411
+ | 0.04 | 1500 | 0.0011 | - |
412
+ | 0.0533 | 2000 | 0.001 | - |
413
+ | 0.0667 | 2500 | 0.001 | - |
414
+ | 0.08 | 3000 | 0.001 | - |
415
+ | 0.0933 | 3500 | 0.001 | - |
416
+ | 0.1067 | 4000 | 0.001 | - |
417
+ | 0.12 | 4500 | 0.001 | - |
418
+ | 0.1333 | 5000 | 0.001 | - |
419
+ | 0.1467 | 5500 | 0.001 | - |
420
+ | 0.16 | 6000 | 0.0009 | - |
421
+ | 0.1733 | 6500 | 0.0009 | - |
422
+ | 0.1867 | 7000 | 0.0009 | - |
423
+ | 0.2 | 7500 | 0.0009 | - |
424
+ | 0.2133 | 8000 | 0.001 | - |
425
+ | 0.2267 | 8500 | 0.0009 | - |
426
+ | 0.24 | 9000 | 0.0009 | - |
427
+ | 0.2533 | 9500 | 0.0009 | - |
428
+ | 0.2667 | 10000 | 0.0008 | - |
429
+ | 0.28 | 10500 | 0.0009 | - |
430
+ | 0.2933 | 11000 | 0.0008 | - |
431
+ | 0.3067 | 11500 | 0.0008 | - |
432
+ | 0.32 | 12000 | 0.0008 | - |
433
+ | 0.3333 | 12500 | 0.0008 | - |
434
+ | 0.3467 | 13000 | 0.0008 | - |
435
+ | 0.36 | 13500 | 0.0008 | - |
436
+ | 0.3733 | 14000 | 0.0008 | - |
437
+ | 0.3867 | 14500 | 0.0008 | - |
438
+ | 0.4 | 15000 | 0.0008 | - |
439
+ | 0.4133 | 15500 | 0.0007 | - |
440
+ | 0.4267 | 16000 | 0.0007 | - |
441
+ | 0.44 | 16500 | 0.0008 | - |
442
+ | 0.4533 | 17000 | 0.0007 | - |
443
+ | 0.4667 | 17500 | 0.0007 | - |
444
+ | 0.48 | 18000 | 0.0007 | - |
445
+ | 0.4933 | 18500 | 0.0007 | - |
446
+ | 0.5067 | 19000 | 0.0007 | - |
447
+ | 0.52 | 19500 | 0.0007 | - |
448
+ | 0.5333 | 20000 | 0.0007 | - |
449
+ | 0.5467 | 20500 | 0.0007 | - |
450
+ | 0.56 | 21000 | 0.0007 | - |
451
+ | 0.5733 | 21500 | 0.0006 | - |
452
+ | 0.5867 | 22000 | 0.0007 | - |
453
+ | 0.6 | 22500 | 0.0006 | - |
454
+ | 0.6133 | 23000 | 0.0006 | - |
455
+ | 0.6267 | 23500 | 0.0006 | - |
456
+ | 0.64 | 24000 | 0.0006 | - |
457
+ | 0.6533 | 24500 | 0.0006 | - |
458
+ | 0.6667 | 25000 | 0.0006 | - |
459
+ | 0.68 | 25500 | 0.0006 | - |
460
+ | 0.6933 | 26000 | 0.0006 | - |
461
+ | 0.7067 | 26500 | 0.0006 | - |
462
+ | 0.72 | 27000 | 0.0006 | - |
463
+ | 0.7333 | 27500 | 0.0006 | - |
464
+ | 0.7467 | 28000 | 0.0006 | - |
465
+ | 0.76 | 28500 | 0.0005 | - |
466
+ | 0.7733 | 29000 | 0.0005 | - |
467
+ | 0.7867 | 29500 | 0.0006 | - |
468
+ | 0.8 | 30000 | 0.0005 | - |
469
+ | 0.8133 | 30500 | 0.0005 | - |
470
+ | 0.8267 | 31000 | 0.0005 | - |
471
+ | 0.84 | 31500 | 0.0005 | - |
472
+ | 0.8533 | 32000 | 0.0005 | - |
473
+ | 0.8667 | 32500 | 0.0005 | - |
474
+ | 0.88 | 33000 | 0.0005 | - |
475
+ | 0.8933 | 33500 | 0.0005 | - |
476
+ | 0.9067 | 34000 | 0.0005 | - |
477
+ | 0.92 | 34500 | 0.0005 | - |
478
+ | 0.9333 | 35000 | 0.0005 | - |
479
+ | 0.9467 | 35500 | 0.0005 | - |
480
+ | 0.96 | 36000 | 0.0005 | - |
481
+ | 0.9733 | 36500 | 0.0005 | - |
482
+ | 0.9867 | 37000 | 0.0005 | - |
483
+ | 1.0 | 37500 | 0.0005 | 0.9850 |
484
+ | 0.0133 | 500 | 0.0004 | - |
485
+ | 0.0267 | 1000 | 0.0005 | - |
486
+ | 0.04 | 1500 | 0.0005 | - |
487
+ | 0.0533 | 2000 | 0.0005 | - |
488
+ | 0.0667 | 2500 | 0.0005 | - |
489
+ | 0.08 | 3000 | 0.0005 | - |
490
+ | 0.0933 | 3500 | 0.0005 | - |
491
+ | 0.1067 | 4000 | 0.0004 | - |
492
+ | 0.12 | 4500 | 0.0004 | - |
493
+ | 0.1333 | 5000 | 0.0004 | - |
494
+ | 0.1467 | 5500 | 0.0004 | - |
495
+ | 0.16 | 6000 | 0.0004 | - |
496
+ | 0.1733 | 6500 | 0.0004 | - |
497
+ | 0.1867 | 7000 | 0.0004 | - |
498
+ | 0.2 | 7500 | 0.0004 | - |
499
+ | 0.2133 | 8000 | 0.0004 | - |
500
+ | 0.2267 | 8500 | 0.0004 | - |
501
+ | 0.24 | 9000 | 0.0004 | - |
502
+ | 0.2533 | 9500 | 0.0004 | - |
503
+ | 0.2667 | 10000 | 0.0004 | - |
504
+ | 0.28 | 10500 | 0.0004 | - |
505
+ | 0.2933 | 11000 | 0.0004 | - |
506
+ | 0.3067 | 11500 | 0.0004 | - |
507
+ | 0.32 | 12000 | 0.0004 | - |
508
+ | 0.3333 | 12500 | 0.0004 | - |
509
+ | 0.3467 | 13000 | 0.0004 | - |
510
+ | 0.36 | 13500 | 0.0004 | - |
511
+ | 0.3733 | 14000 | 0.0004 | - |
512
+ | 0.3867 | 14500 | 0.0004 | - |
513
+ | 0.4 | 15000 | 0.0004 | - |
514
+ | 0.4133 | 15500 | 0.0004 | - |
515
+ | 0.4267 | 16000 | 0.0004 | - |
516
+ | 0.44 | 16500 | 0.0004 | - |
517
+ | 0.4533 | 17000 | 0.0004 | - |
518
+ | 0.4667 | 17500 | 0.0004 | - |
519
+ | 0.48 | 18000 | 0.0004 | - |
520
+ | 0.4933 | 18500 | 0.0004 | - |
521
+ | 0.5067 | 19000 | 0.0004 | - |
522
+ | 0.52 | 19500 | 0.0004 | - |
523
+ | 0.5333 | 20000 | 0.0004 | - |
524
+ | 0.5467 | 20500 | 0.0004 | - |
525
+ | 0.56 | 21000 | 0.0004 | - |
526
+ | 0.5733 | 21500 | 0.0004 | - |
527
+ | 0.5867 | 22000 | 0.0004 | - |
528
+ | 0.6 | 22500 | 0.0004 | - |
529
+ | 0.6133 | 23000 | 0.0004 | - |
530
+ | 0.6267 | 23500 | 0.0004 | - |
531
+ | 0.64 | 24000 | 0.0004 | - |
532
+ | 0.6533 | 24500 | 0.0004 | - |
533
+ | 0.6667 | 25000 | 0.0004 | - |
534
+ | 0.68 | 25500 | 0.0004 | - |
535
+ | 0.6933 | 26000 | 0.0004 | - |
536
+ | 0.7067 | 26500 | 0.0004 | - |
537
+ | 0.72 | 27000 | 0.0004 | - |
538
+ | 0.7333 | 27500 | 0.0004 | - |
539
+ | 0.7467 | 28000 | 0.0004 | - |
540
+ | 0.76 | 28500 | 0.0004 | - |
541
+ | 0.7733 | 29000 | 0.0004 | - |
542
+ | 0.7867 | 29500 | 0.0004 | - |
543
+ | 0.8 | 30000 | 0.0004 | - |
544
+ | 0.8133 | 30500 | 0.0004 | - |
545
+ | 0.8267 | 31000 | 0.0004 | - |
546
+ | 0.84 | 31500 | 0.0004 | - |
547
+ | 0.8533 | 32000 | 0.0004 | - |
548
+ | 0.8667 | 32500 | 0.0004 | - |
549
+ | 0.88 | 33000 | 0.0004 | - |
550
+ | 0.8933 | 33500 | 0.0004 | - |
551
+ | 0.9067 | 34000 | 0.0004 | - |
552
+ | 0.92 | 34500 | 0.0004 | - |
553
+ | 0.9333 | 35000 | 0.0004 | - |
554
+ | 0.9467 | 35500 | 0.0004 | - |
555
+ | 0.96 | 36000 | 0.0004 | - |
556
+ | 0.9733 | 36500 | 0.0004 | - |
557
+ | 0.9867 | 37000 | 0.0004 | - |
558
+ | 1.0 | 37500 | 0.0004 | 0.9868 |
559
+
560
+ </details>
561
+
562
+ ### Framework Versions
563
+ - Python: 3.11.3
564
+ - Sentence Transformers: 3.3.1
565
+ - Transformers: 4.48.0
566
+ - PyTorch: 2.5.1+cu124
567
+ - Accelerate: 1.2.1
568
+ - Datasets: 3.2.0
569
+ - Tokenizers: 0.21.0
570
+
571
+ ## Citation
572
+
573
+ ### BibTeX
574
+
575
+ #### Sentence Transformers
576
+ ```bibtex
577
+ @inproceedings{reimers-2019-sentence-bert,
578
+ title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
579
+ author = "Reimers, Nils and Gurevych, Iryna",
580
+ booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
581
+ month = "11",
582
+ year = "2019",
583
+ publisher = "Association for Computational Linguistics",
584
+ url = "https://arxiv.org/abs/1908.10084",
585
+ }
586
+ ```
587
+
588
+ <!--
589
+ ## Glossary
590
+
591
+ *Clearly define terms in order to be accessible across audiences.*
592
+ -->
593
+
594
+ <!--
595
+ ## Model Card Authors
596
+
597
+ *Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
598
+ -->
599
+
600
+ <!--
601
+ ## Model Card Contact
602
+
603
+ *Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
604
+ -->
config.json ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "fine_tuned_mpnet_food_embeddings",
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.48.0",
23
+ "vocab_size": 30527
24
+ }
config_sentence_transformers.json ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "__version__": {
3
+ "sentence_transformers": "3.3.1",
4
+ "transformers": "4.48.0",
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:eebe0c3415141b3025aaf909f6040bb92835dcef8671d07f87507dd151f16e30
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,73 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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": false,
54
+ "cls_token": "<s>",
55
+ "do_lower_case": true,
56
+ "eos_token": "</s>",
57
+ "extra_special_tokens": {},
58
+ "mask_token": "<mask>",
59
+ "max_length": 128,
60
+ "model_max_length": 384,
61
+ "pad_to_multiple_of": null,
62
+ "pad_token": "<pad>",
63
+ "pad_token_type_id": 0,
64
+ "padding_side": "right",
65
+ "sep_token": "</s>",
66
+ "stride": 0,
67
+ "strip_accents": null,
68
+ "tokenize_chinese_chars": true,
69
+ "tokenizer_class": "MPNetTokenizer",
70
+ "truncation_side": "right",
71
+ "truncation_strategy": "longest_first",
72
+ "unk_token": "[UNK]"
73
+ }
vocab.txt ADDED
The diff for this file is too large to render. See raw diff