Add new SentenceTransformer model
Browse files- .gitattributes +1 -0
- 1_Pooling/config.json +10 -0
- 2_Dense/config.json +1 -0
- 2_Dense/model.safetensors +3 -0
- README.md +435 -0
- config.json +32 -0
- config_sentence_transformers.json +10 -0
- model.safetensors +3 -0
- modules.json +26 -0
- sentence_bert_config.json +4 -0
- special_tokens_map.json +37 -0
- tokenizer.json +3 -0
- tokenizer_config.json +59 -0
- vocab.txt +0 -0
.gitattributes
CHANGED
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
36 |
+
tokenizer.json filter=lfs diff=lfs merge=lfs -text
|
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 |
+
}
|
2_Dense/config.json
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
{"in_features": 768, "out_features": 768, "bias": true, "activation_function": "torch.nn.modules.activation.Tanh"}
|
2_Dense/model.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:cceb4b25427f2745b12bf7a6012c76e73745a6538cd1ce597e48757f2b383f95
|
3 |
+
size 2362528
|
README.md
ADDED
@@ -0,0 +1,435 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
tags:
|
3 |
+
- sentence-transformers
|
4 |
+
- sentence-similarity
|
5 |
+
- feature-extraction
|
6 |
+
- generated_from_trainer
|
7 |
+
- dataset_size:165665
|
8 |
+
- loss:MultipleNegativesRankingLoss
|
9 |
+
base_model: sentence-transformers/LaBSE
|
10 |
+
widget:
|
11 |
+
- source_sentence: کدام یک از تجربیات بدی که در زندگی داشتید؟
|
12 |
+
sentences:
|
13 |
+
- آیا Urjit Patel برای فرماندار RBI مناسب است؟
|
14 |
+
- چگونه برای اولین بار با پورنو آشنا شدید؟
|
15 |
+
- برخی از تجربیات خوب و بد زندگی شما چه بود؟
|
16 |
+
- source_sentence: بهترین مشاغل در فیلیپین چیست؟
|
17 |
+
sentences:
|
18 |
+
- چرا مردم در مورد Quora سؤالاتی می پرسند که به راحتی توسط Google قابل پاسخگویی
|
19 |
+
است؟
|
20 |
+
- آیا جهان بی نهایت است یا به جهان پایان می یابد؟
|
21 |
+
- بهترین کار در فیلیپین چیست؟
|
22 |
+
- source_sentence: آیا بروس لی می تواند جنگجویان MMA را تحمل کند؟
|
23 |
+
sentences:
|
24 |
+
- آیا بروس لی در اوج خود می تواند با مبارزان برتر MMA امروز رقابت کند؟
|
25 |
+
- آیا باید تصاویر را در رسانه های اجتماعی ارسال کنید؟
|
26 |
+
- آیا ظرفیت گرما همان گرمای خاص است؟
|
27 |
+
- source_sentence: چگونه می توانم موهای زائد را متوقف کنم؟
|
28 |
+
sentences:
|
29 |
+
- چه اتفاقی می افتد اگر نامزد ریاست جمهوری قبل از انتخابات نوامبر درگذشت؟
|
30 |
+
- بهترین وسایل آیفون که واقعاً ارزش خرید دارند چیست؟
|
31 |
+
- چگونه می توانم موهای زائد را متوقف کنم؟
|
32 |
+
- source_sentence: معنی و هدف زندگی چیست؟
|
33 |
+
sentences:
|
34 |
+
- چه فیلم هایی را به همه توصیه می کنید که تماشا کنند؟
|
35 |
+
- مراکز خرید در آینده چگونه خواهد بود؟
|
36 |
+
- معنی دقیق زندگی چیست؟
|
37 |
+
pipeline_tag: sentence-similarity
|
38 |
+
library_name: sentence-transformers
|
39 |
+
---
|
40 |
+
|
41 |
+
# SentenceTransformer based on sentence-transformers/LaBSE
|
42 |
+
|
43 |
+
This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [sentence-transformers/LaBSE](https://huggingface.co/sentence-transformers/LaBSE). 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.
|
44 |
+
|
45 |
+
## Model Details
|
46 |
+
|
47 |
+
### Model Description
|
48 |
+
- **Model Type:** Sentence Transformer
|
49 |
+
- **Base model:** [sentence-transformers/LaBSE](https://huggingface.co/sentence-transformers/LaBSE) <!-- at revision b7f947194ceae0ddf90bafe213722569e274ad28 -->
|
50 |
+
- **Maximum Sequence Length:** 256 tokens
|
51 |
+
- **Output Dimensionality:** 768 dimensions
|
52 |
+
- **Similarity Function:** Cosine Similarity
|
53 |
+
<!-- - **Training Dataset:** Unknown -->
|
54 |
+
<!-- - **Language:** Unknown -->
|
55 |
+
<!-- - **License:** Unknown -->
|
56 |
+
|
57 |
+
### Model Sources
|
58 |
+
|
59 |
+
- **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
|
60 |
+
- **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
|
61 |
+
- **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
|
62 |
+
|
63 |
+
### Full Model Architecture
|
64 |
+
|
65 |
+
```
|
66 |
+
SentenceTransformer(
|
67 |
+
(0): Transformer({'max_seq_length': 256, 'do_lower_case': False}) with Transformer model: BertModel
|
68 |
+
(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})
|
69 |
+
(2): Dense({'in_features': 768, 'out_features': 768, 'bias': True, 'activation_function': 'torch.nn.modules.activation.Tanh'})
|
70 |
+
(3): Normalize()
|
71 |
+
)
|
72 |
+
```
|
73 |
+
|
74 |
+
## Usage
|
75 |
+
|
76 |
+
### Direct Usage (Sentence Transformers)
|
77 |
+
|
78 |
+
First install the Sentence Transformers library:
|
79 |
+
|
80 |
+
```bash
|
81 |
+
pip install -U sentence-transformers
|
82 |
+
```
|
83 |
+
|
84 |
+
Then you can load this model and run inference.
|
85 |
+
```python
|
86 |
+
from sentence_transformers import SentenceTransformer
|
87 |
+
|
88 |
+
# Download from the 🤗 Hub
|
89 |
+
model = SentenceTransformer("codersan/FaLaBSE-v4")
|
90 |
+
# Run inference
|
91 |
+
sentences = [
|
92 |
+
'معنی و هدف زندگی چیست؟',
|
93 |
+
'معنی دقیق زندگی چیست؟',
|
94 |
+
'چه فیلم هایی را به همه توصیه می کنید که تماشا کنند؟',
|
95 |
+
]
|
96 |
+
embeddings = model.encode(sentences)
|
97 |
+
print(embeddings.shape)
|
98 |
+
# [3, 768]
|
99 |
+
|
100 |
+
# Get the similarity scores for the embeddings
|
101 |
+
similarities = model.similarity(embeddings, embeddings)
|
102 |
+
print(similarities.shape)
|
103 |
+
# [3, 3]
|
104 |
+
```
|
105 |
+
|
106 |
+
<!--
|
107 |
+
### Direct Usage (Transformers)
|
108 |
+
|
109 |
+
<details><summary>Click to see the direct usage in Transformers</summary>
|
110 |
+
|
111 |
+
</details>
|
112 |
+
-->
|
113 |
+
|
114 |
+
<!--
|
115 |
+
### Downstream Usage (Sentence Transformers)
|
116 |
+
|
117 |
+
You can finetune this model on your own dataset.
|
118 |
+
|
119 |
+
<details><summary>Click to expand</summary>
|
120 |
+
|
121 |
+
</details>
|
122 |
+
-->
|
123 |
+
|
124 |
+
<!--
|
125 |
+
### Out-of-Scope Use
|
126 |
+
|
127 |
+
*List how the model may foreseeably be misused and address what users ought not to do with the model.*
|
128 |
+
-->
|
129 |
+
|
130 |
+
<!--
|
131 |
+
## Bias, Risks and Limitations
|
132 |
+
|
133 |
+
*What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
|
134 |
+
-->
|
135 |
+
|
136 |
+
<!--
|
137 |
+
### Recommendations
|
138 |
+
|
139 |
+
*What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
|
140 |
+
-->
|
141 |
+
|
142 |
+
## Training Details
|
143 |
+
|
144 |
+
### Training Dataset
|
145 |
+
|
146 |
+
#### Unnamed Dataset
|
147 |
+
|
148 |
+
|
149 |
+
* Size: 165,665 training samples
|
150 |
+
* Columns: <code>anchor</code> and <code>positive</code>
|
151 |
+
* Approximate statistics based on the first 1000 samples:
|
152 |
+
| | anchor | positive |
|
153 |
+
|:--------|:----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|
|
154 |
+
| type | string | string |
|
155 |
+
| details | <ul><li>min: 5 tokens</li><li>mean: 14.65 tokens</li><li>max: 48 tokens</li></ul> | <ul><li>min: 5 tokens</li><li>mean: 14.87 tokens</li><li>max: 53 tokens</li></ul> |
|
156 |
+
* Samples:
|
157 |
+
| anchor | positive |
|
158 |
+
|:-----------------------------------------------------------------------------------------|:---------------------------------------------------------------------------------------------------|
|
159 |
+
| <code>طالع بینی: من یک ماه و کلاه درپوش خورشید است ... این در مورد من چه می گوید؟</code> | <code>من یک برج سه گانه (خورشید ، ماه و صعود در برجستگی) هستم که این در مورد من چه می گوید؟</code> |
|
160 |
+
| <code>چگونه می توانم یک زمین شناس خوب باشم؟</code> | <code>چه کاری باید انجام دهم تا یک زمین شناس عالی باشم؟</code> |
|
161 |
+
| <code>چگونه می توانم نظرات YouTube خود را بخوانم و پیدا کنم؟</code> | <code>چگونه می توانم تمام نظرات YouTube خود را ببینم؟</code> |
|
162 |
+
* Loss: [<code>MultipleNegativesRankingLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#multiplenegativesrankingloss) with these parameters:
|
163 |
+
```json
|
164 |
+
{
|
165 |
+
"scale": 20.0,
|
166 |
+
"similarity_fct": "cos_sim"
|
167 |
+
}
|
168 |
+
```
|
169 |
+
|
170 |
+
### Training Hyperparameters
|
171 |
+
#### Non-Default Hyperparameters
|
172 |
+
|
173 |
+
- `per_device_train_batch_size`: 32
|
174 |
+
- `learning_rate`: 2e-05
|
175 |
+
- `weight_decay`: 0.01
|
176 |
+
- `batch_sampler`: no_duplicates
|
177 |
+
|
178 |
+
#### All Hyperparameters
|
179 |
+
<details><summary>Click to expand</summary>
|
180 |
+
|
181 |
+
- `overwrite_output_dir`: False
|
182 |
+
- `do_predict`: False
|
183 |
+
- `eval_strategy`: no
|
184 |
+
- `prediction_loss_only`: True
|
185 |
+
- `per_device_train_batch_size`: 32
|
186 |
+
- `per_device_eval_batch_size`: 8
|
187 |
+
- `per_gpu_train_batch_size`: None
|
188 |
+
- `per_gpu_eval_batch_size`: None
|
189 |
+
- `gradient_accumulation_steps`: 1
|
190 |
+
- `eval_accumulation_steps`: None
|
191 |
+
- `torch_empty_cache_steps`: None
|
192 |
+
- `learning_rate`: 2e-05
|
193 |
+
- `weight_decay`: 0.01
|
194 |
+
- `adam_beta1`: 0.9
|
195 |
+
- `adam_beta2`: 0.999
|
196 |
+
- `adam_epsilon`: 1e-08
|
197 |
+
- `max_grad_norm`: 1.0
|
198 |
+
- `num_train_epochs`: 3
|
199 |
+
- `max_steps`: -1
|
200 |
+
- `lr_scheduler_type`: linear
|
201 |
+
- `lr_scheduler_kwargs`: {}
|
202 |
+
- `warmup_ratio`: 0.0
|
203 |
+
- `warmup_steps`: 0
|
204 |
+
- `log_level`: passive
|
205 |
+
- `log_level_replica`: warning
|
206 |
+
- `log_on_each_node`: True
|
207 |
+
- `logging_nan_inf_filter`: True
|
208 |
+
- `save_safetensors`: True
|
209 |
+
- `save_on_each_node`: False
|
210 |
+
- `save_only_model`: False
|
211 |
+
- `restore_callback_states_from_checkpoint`: False
|
212 |
+
- `no_cuda`: False
|
213 |
+
- `use_cpu`: False
|
214 |
+
- `use_mps_device`: False
|
215 |
+
- `seed`: 42
|
216 |
+
- `data_seed`: None
|
217 |
+
- `jit_mode_eval`: False
|
218 |
+
- `use_ipex`: False
|
219 |
+
- `bf16`: False
|
220 |
+
- `fp16`: False
|
221 |
+
- `fp16_opt_level`: O1
|
222 |
+
- `half_precision_backend`: auto
|
223 |
+
- `bf16_full_eval`: False
|
224 |
+
- `fp16_full_eval`: False
|
225 |
+
- `tf32`: None
|
226 |
+
- `local_rank`: 0
|
227 |
+
- `ddp_backend`: None
|
228 |
+
- `tpu_num_cores`: None
|
229 |
+
- `tpu_metrics_debug`: False
|
230 |
+
- `debug`: []
|
231 |
+
- `dataloader_drop_last`: False
|
232 |
+
- `dataloader_num_workers`: 0
|
233 |
+
- `dataloader_prefetch_factor`: None
|
234 |
+
- `past_index`: -1
|
235 |
+
- `disable_tqdm`: False
|
236 |
+
- `remove_unused_columns`: True
|
237 |
+
- `label_names`: None
|
238 |
+
- `load_best_model_at_end`: False
|
239 |
+
- `ignore_data_skip`: False
|
240 |
+
- `fsdp`: []
|
241 |
+
- `fsdp_min_num_params`: 0
|
242 |
+
- `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
|
243 |
+
- `fsdp_transformer_layer_cls_to_wrap`: None
|
244 |
+
- `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
|
245 |
+
- `deepspeed`: None
|
246 |
+
- `label_smoothing_factor`: 0.0
|
247 |
+
- `optim`: adamw_torch
|
248 |
+
- `optim_args`: None
|
249 |
+
- `adafactor`: False
|
250 |
+
- `group_by_length`: False
|
251 |
+
- `length_column_name`: length
|
252 |
+
- `ddp_find_unused_parameters`: None
|
253 |
+
- `ddp_bucket_cap_mb`: None
|
254 |
+
- `ddp_broadcast_buffers`: False
|
255 |
+
- `dataloader_pin_memory`: True
|
256 |
+
- `dataloader_persistent_workers`: False
|
257 |
+
- `skip_memory_metrics`: True
|
258 |
+
- `use_legacy_prediction_loop`: False
|
259 |
+
- `push_to_hub`: False
|
260 |
+
- `resume_from_checkpoint`: None
|
261 |
+
- `hub_model_id`: None
|
262 |
+
- `hub_strategy`: every_save
|
263 |
+
- `hub_private_repo`: None
|
264 |
+
- `hub_always_push`: False
|
265 |
+
- `gradient_checkpointing`: False
|
266 |
+
- `gradient_checkpointing_kwargs`: None
|
267 |
+
- `include_inputs_for_metrics`: False
|
268 |
+
- `include_for_metrics`: []
|
269 |
+
- `eval_do_concat_batches`: True
|
270 |
+
- `fp16_backend`: auto
|
271 |
+
- `push_to_hub_model_id`: None
|
272 |
+
- `push_to_hub_organization`: None
|
273 |
+
- `mp_parameters`:
|
274 |
+
- `auto_find_batch_size`: False
|
275 |
+
- `full_determinism`: False
|
276 |
+
- `torchdynamo`: None
|
277 |
+
- `ray_scope`: last
|
278 |
+
- `ddp_timeout`: 1800
|
279 |
+
- `torch_compile`: False
|
280 |
+
- `torch_compile_backend`: None
|
281 |
+
- `torch_compile_mode`: None
|
282 |
+
- `dispatch_batches`: None
|
283 |
+
- `split_batches`: None
|
284 |
+
- `include_tokens_per_second`: False
|
285 |
+
- `include_num_input_tokens_seen`: False
|
286 |
+
- `neftune_noise_alpha`: None
|
287 |
+
- `optim_target_modules`: None
|
288 |
+
- `batch_eval_metrics`: False
|
289 |
+
- `eval_on_start`: False
|
290 |
+
- `use_liger_kernel`: False
|
291 |
+
- `eval_use_gather_object`: False
|
292 |
+
- `average_tokens_across_devices`: False
|
293 |
+
- `prompts`: None
|
294 |
+
- `batch_sampler`: no_duplicates
|
295 |
+
- `multi_dataset_batch_sampler`: proportional
|
296 |
+
|
297 |
+
</details>
|
298 |
+
|
299 |
+
### Training Logs
|
300 |
+
| Epoch | Step | Training Loss |
|
301 |
+
|:------:|:----:|:-------------:|
|
302 |
+
| 0.0386 | 100 | 0.0863 |
|
303 |
+
| 0.0772 | 200 | 0.0652 |
|
304 |
+
| 0.1159 | 300 | 0.0595 |
|
305 |
+
| 0.1545 | 400 | 0.0614 |
|
306 |
+
| 0.1931 | 500 | 0.05 |
|
307 |
+
| 0.2317 | 600 | 0.0453 |
|
308 |
+
| 0.2704 | 700 | 0.0579 |
|
309 |
+
| 0.3090 | 800 | 0.0542 |
|
310 |
+
| 0.3476 | 900 | 0.0534 |
|
311 |
+
| 0.3862 | 1000 | 0.0532 |
|
312 |
+
| 0.4249 | 1100 | 0.0548 |
|
313 |
+
| 0.4635 | 1200 | 0.0519 |
|
314 |
+
| 0.5021 | 1300 | 0.0547 |
|
315 |
+
| 0.5407 | 1400 | 0.0563 |
|
316 |
+
| 0.5794 | 1500 | 0.0474 |
|
317 |
+
| 0.6180 | 1600 | 0.0433 |
|
318 |
+
| 0.6566 | 1700 | 0.0545 |
|
319 |
+
| 0.6952 | 1800 | 0.0509 |
|
320 |
+
| 0.7339 | 1900 | 0.0453 |
|
321 |
+
| 0.7725 | 2000 | 0.0446 |
|
322 |
+
| 0.8111 | 2100 | 0.0506 |
|
323 |
+
| 0.8497 | 2200 | 0.046 |
|
324 |
+
| 0.8884 | 2300 | 0.0413 |
|
325 |
+
| 0.9270 | 2400 | 0.149 |
|
326 |
+
| 0.9656 | 2500 | 0.6993 |
|
327 |
+
| 1.0039 | 2600 | 1.081 |
|
328 |
+
| 1.0425 | 2700 | 0.0397 |
|
329 |
+
| 1.0811 | 2800 | 0.0337 |
|
330 |
+
| 1.1197 | 2900 | 0.0307 |
|
331 |
+
| 1.1584 | 3000 | 0.0323 |
|
332 |
+
| 1.1970 | 3100 | 0.0273 |
|
333 |
+
| 1.2356 | 3200 | 0.0292 |
|
334 |
+
| 1.2742 | 3300 | 0.0323 |
|
335 |
+
| 1.3129 | 3400 | 0.0352 |
|
336 |
+
| 1.3515 | 3500 | 0.0281 |
|
337 |
+
| 1.3901 | 3600 | 0.0318 |
|
338 |
+
| 1.4287 | 3700 | 0.0281 |
|
339 |
+
| 1.4674 | 3800 | 0.0304 |
|
340 |
+
| 1.5060 | 3900 | 0.0321 |
|
341 |
+
| 1.5446 | 4000 | 0.035 |
|
342 |
+
| 1.5832 | 4100 | 0.0279 |
|
343 |
+
| 1.6219 | 4200 | 0.0286 |
|
344 |
+
| 1.6605 | 4300 | 0.0333 |
|
345 |
+
| 1.6991 | 4400 | 0.0323 |
|
346 |
+
| 1.7377 | 4500 | 0.0312 |
|
347 |
+
| 1.7764 | 4600 | 0.0261 |
|
348 |
+
| 1.8150 | 4700 | 0.0361 |
|
349 |
+
| 1.8536 | 4800 | 0.0306 |
|
350 |
+
| 1.8922 | 4900 | 0.028 |
|
351 |
+
| 1.9309 | 5000 | 0.1226 |
|
352 |
+
| 1.9695 | 5100 | 0.5625 |
|
353 |
+
| 2.0077 | 5200 | 0.8337 |
|
354 |
+
| 2.0463 | 5300 | 0.0273 |
|
355 |
+
| 2.0850 | 5400 | 0.0242 |
|
356 |
+
| 2.1236 | 5500 | 0.0236 |
|
357 |
+
| 2.1622 | 5600 | 0.0237 |
|
358 |
+
| 2.2008 | 5700 | 0.0197 |
|
359 |
+
| 2.2395 | 5800 | 0.0217 |
|
360 |
+
| 2.2781 | 5900 | 0.0244 |
|
361 |
+
| 2.3167 | 6000 | 0.027 |
|
362 |
+
| 2.3553 | 6100 | 0.0235 |
|
363 |
+
| 2.3940 | 6200 | 0.0233 |
|
364 |
+
| 2.4326 | 6300 | 0.0225 |
|
365 |
+
| 2.4712 | 6400 | 0.023 |
|
366 |
+
| 2.5098 | 6500 | 0.023 |
|
367 |
+
| 2.5485 | 6600 | 0.0243 |
|
368 |
+
| 2.5871 | 6700 | 0.0215 |
|
369 |
+
| 2.6257 | 6800 | 0.0236 |
|
370 |
+
| 2.6643 | 6900 | 0.0234 |
|
371 |
+
| 2.7030 | 7000 | 0.0239 |
|
372 |
+
| 2.7416 | 7100 | 0.0248 |
|
373 |
+
| 2.7802 | 7200 | 0.02 |
|
374 |
+
| 2.8188 | 7300 | 0.0271 |
|
375 |
+
| 2.8575 | 7400 | 0.0235 |
|
376 |
+
| 2.8961 | 7500 | 0.0214 |
|
377 |
+
| 2.9347 | 7600 | 0.1147 |
|
378 |
+
| 2.9733 | 7700 | 0.5838 |
|
379 |
+
|
380 |
+
|
381 |
+
### Framework Versions
|
382 |
+
- Python: 3.10.12
|
383 |
+
- Sentence Transformers: 3.3.1
|
384 |
+
- Transformers: 4.47.0
|
385 |
+
- PyTorch: 2.5.1+cu121
|
386 |
+
- Accelerate: 1.2.1
|
387 |
+
- Datasets: 3.2.0
|
388 |
+
- Tokenizers: 0.21.0
|
389 |
+
|
390 |
+
## Citation
|
391 |
+
|
392 |
+
### BibTeX
|
393 |
+
|
394 |
+
#### Sentence Transformers
|
395 |
+
```bibtex
|
396 |
+
@inproceedings{reimers-2019-sentence-bert,
|
397 |
+
title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
|
398 |
+
author = "Reimers, Nils and Gurevych, Iryna",
|
399 |
+
booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
|
400 |
+
month = "11",
|
401 |
+
year = "2019",
|
402 |
+
publisher = "Association for Computational Linguistics",
|
403 |
+
url = "https://arxiv.org/abs/1908.10084",
|
404 |
+
}
|
405 |
+
```
|
406 |
+
|
407 |
+
#### MultipleNegativesRankingLoss
|
408 |
+
```bibtex
|
409 |
+
@misc{henderson2017efficient,
|
410 |
+
title={Efficient Natural Language Response Suggestion for Smart Reply},
|
411 |
+
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},
|
412 |
+
year={2017},
|
413 |
+
eprint={1705.00652},
|
414 |
+
archivePrefix={arXiv},
|
415 |
+
primaryClass={cs.CL}
|
416 |
+
}
|
417 |
+
```
|
418 |
+
|
419 |
+
<!--
|
420 |
+
## Glossary
|
421 |
+
|
422 |
+
*Clearly define terms in order to be accessible across audiences.*
|
423 |
+
-->
|
424 |
+
|
425 |
+
<!--
|
426 |
+
## Model Card Authors
|
427 |
+
|
428 |
+
*Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
|
429 |
+
-->
|
430 |
+
|
431 |
+
<!--
|
432 |
+
## Model Card Contact
|
433 |
+
|
434 |
+
*Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
|
435 |
+
-->
|
config.json
ADDED
@@ -0,0 +1,32 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"_name_or_path": "sentence-transformers/LaBSE",
|
3 |
+
"architectures": [
|
4 |
+
"BertModel"
|
5 |
+
],
|
6 |
+
"attention_probs_dropout_prob": 0.1,
|
7 |
+
"classifier_dropout": null,
|
8 |
+
"directionality": "bidi",
|
9 |
+
"gradient_checkpointing": false,
|
10 |
+
"hidden_act": "gelu",
|
11 |
+
"hidden_dropout_prob": 0.1,
|
12 |
+
"hidden_size": 768,
|
13 |
+
"initializer_range": 0.02,
|
14 |
+
"intermediate_size": 3072,
|
15 |
+
"layer_norm_eps": 1e-12,
|
16 |
+
"max_position_embeddings": 512,
|
17 |
+
"model_type": "bert",
|
18 |
+
"num_attention_heads": 12,
|
19 |
+
"num_hidden_layers": 12,
|
20 |
+
"pad_token_id": 0,
|
21 |
+
"pooler_fc_size": 768,
|
22 |
+
"pooler_num_attention_heads": 12,
|
23 |
+
"pooler_num_fc_layers": 3,
|
24 |
+
"pooler_size_per_head": 128,
|
25 |
+
"pooler_type": "first_token_transform",
|
26 |
+
"position_embedding_type": "absolute",
|
27 |
+
"torch_dtype": "float32",
|
28 |
+
"transformers_version": "4.47.0",
|
29 |
+
"type_vocab_size": 2,
|
30 |
+
"use_cache": true,
|
31 |
+
"vocab_size": 501153
|
32 |
+
}
|
config_sentence_transformers.json
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"__version__": {
|
3 |
+
"sentence_transformers": "3.3.1",
|
4 |
+
"transformers": "4.47.0",
|
5 |
+
"pytorch": "2.5.1+cu121"
|
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:e83d6ae07bb7d33f76aa7a5c4b21c642a0228f37db18916eff08da1080e704b6
|
3 |
+
size 1883730160
|
modules.json
ADDED
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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_Dense",
|
18 |
+
"type": "sentence_transformers.models.Dense"
|
19 |
+
},
|
20 |
+
{
|
21 |
+
"idx": 3,
|
22 |
+
"name": "3",
|
23 |
+
"path": "3_Normalize",
|
24 |
+
"type": "sentence_transformers.models.Normalize"
|
25 |
+
}
|
26 |
+
]
|
sentence_bert_config.json
ADDED
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"max_seq_length": 256,
|
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
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:92262b29204f8fdc169a63f9005a0e311a16262cef4d96ecfe2a7ed638662ed3
|
3 |
+
size 13632172
|
tokenizer_config.json
ADDED
@@ -0,0 +1,59 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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": false,
|
45 |
+
"cls_token": "[CLS]",
|
46 |
+
"do_basic_tokenize": true,
|
47 |
+
"do_lower_case": false,
|
48 |
+
"extra_special_tokens": {},
|
49 |
+
"full_tokenizer_file": null,
|
50 |
+
"mask_token": "[MASK]",
|
51 |
+
"model_max_length": 256,
|
52 |
+
"never_split": null,
|
53 |
+
"pad_token": "[PAD]",
|
54 |
+
"sep_token": "[SEP]",
|
55 |
+
"strip_accents": null,
|
56 |
+
"tokenize_chinese_chars": true,
|
57 |
+
"tokenizer_class": "BertTokenizer",
|
58 |
+
"unk_token": "[UNK]"
|
59 |
+
}
|
vocab.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|