Bảo Mai Chí
commited on
Commit
•
1938e4a
1
Parent(s):
5f93279
Add new SentenceTransformer model.
Browse files- 1_Pooling/config.json +10 -0
- README.md +357 -0
- config.json +26 -0
- config_sentence_transformers.json +10 -0
- model.safetensors +3 -0
- modules.json +14 -0
- sentence_bert_config.json +4 -0
- special_tokens_map.json +37 -0
- tokenizer.json +0 -0
- tokenizer_config.json +66 -0
- vocab.txt +0 -0
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,357 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
language: []
|
3 |
+
library_name: sentence-transformers
|
4 |
+
tags:
|
5 |
+
- sentence-transformers
|
6 |
+
- sentence-similarity
|
7 |
+
- feature-extraction
|
8 |
+
- generated_from_trainer
|
9 |
+
- dataset_size:101762
|
10 |
+
- loss:TripletLoss
|
11 |
+
base_model: sentence-transformers/distiluse-base-multilingual-cased-v2
|
12 |
+
datasets: []
|
13 |
+
widget:
|
14 |
+
- source_sentence: How do I clean the screen of my Toshiba TV?
|
15 |
+
sentences:
|
16 |
+
- How can I clear screen overlay from my Samsung Galaxy 6?
|
17 |
+
- Why do police forces exist?
|
18 |
+
- What is the best way to clean a flat screen monitor?
|
19 |
+
- source_sentence: What was the first video you watched on YouTube?
|
20 |
+
sentences:
|
21 |
+
- What was the first Youtube video you ever watched?
|
22 |
+
- What was the first music video ever produced?
|
23 |
+
- What was the long term effect of Hitler's desire to exterminate the Jewish people?
|
24 |
+
- source_sentence: What should I do to recover my data from a hard disk?
|
25 |
+
sentences:
|
26 |
+
- How do I recover my deleted data files from a hard disk?
|
27 |
+
- What's the best Linux operating System distro for beginners?
|
28 |
+
- Formated Data Recovery – Recover Data from Memory Card, Disk Drive, USB, External
|
29 |
+
Drive?
|
30 |
+
- source_sentence: What are your personal top ten music albums of all time?
|
31 |
+
sentences:
|
32 |
+
- What are your top 10 favourite songs of all time?
|
33 |
+
- What are the Top 10 music albums of all time on your list?
|
34 |
+
- What stream should I take in 11th if I have to become an automobile engineer?
|
35 |
+
- source_sentence: What is the best website to learn coding independently?
|
36 |
+
sentences:
|
37 |
+
- What are some of the best website to learn programming from being a total beginner?
|
38 |
+
- What books do I need to read to learn more about Sufism?
|
39 |
+
- What is the best (and fastest) way to learn how to code (web development)?
|
40 |
+
pipeline_tag: sentence-similarity
|
41 |
+
---
|
42 |
+
|
43 |
+
# SentenceTransformer based on sentence-transformers/distiluse-base-multilingual-cased-v2
|
44 |
+
|
45 |
+
This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [sentence-transformers/distiluse-base-multilingual-cased-v2](https://huggingface.co/sentence-transformers/distiluse-base-multilingual-cased-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.
|
46 |
+
|
47 |
+
## Model Details
|
48 |
+
|
49 |
+
### Model Description
|
50 |
+
- **Model Type:** Sentence Transformer
|
51 |
+
- **Base model:** [sentence-transformers/distiluse-base-multilingual-cased-v2](https://huggingface.co/sentence-transformers/distiluse-base-multilingual-cased-v2) <!-- at revision 03a0532331151aeb3e1d2e602ffad62bb212a38d -->
|
52 |
+
- **Maximum Sequence Length:** 256 tokens
|
53 |
+
- **Output Dimensionality:** 768 tokens
|
54 |
+
- **Similarity Function:** Cosine Similarity
|
55 |
+
<!-- - **Training Dataset:** Unknown -->
|
56 |
+
<!-- - **Language:** Unknown -->
|
57 |
+
<!-- - **License:** Unknown -->
|
58 |
+
|
59 |
+
### Model Sources
|
60 |
+
|
61 |
+
- **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
|
62 |
+
- **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
|
63 |
+
- **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
|
64 |
+
|
65 |
+
### Full Model Architecture
|
66 |
+
|
67 |
+
```
|
68 |
+
SentenceTransformer(
|
69 |
+
(0): Transformer({'max_seq_length': 256, 'do_lower_case': False}) with Transformer model: DistilBertModel
|
70 |
+
(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})
|
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("chibao24/distilroberta-base-sentence-transformer-triplets")
|
90 |
+
# Run inference
|
91 |
+
sentences = [
|
92 |
+
'What is the best website to learn coding independently?',
|
93 |
+
'What are some of the best website to learn programming from being a total beginner?',
|
94 |
+
'What is the best (and fastest) way to learn how to code (web development)?',
|
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: 101,762 training samples
|
150 |
+
* Columns: <code>sentence_0</code>, <code>sentence_1</code>, and <code>sentence_2</code>
|
151 |
+
* Approximate statistics based on the first 1000 samples:
|
152 |
+
| | sentence_0 | sentence_1 | sentence_2 |
|
153 |
+
|:--------|:---------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|
|
154 |
+
| type | string | string | string |
|
155 |
+
| details | <ul><li>min: 6 tokens</li><li>mean: 14.7 tokens</li><li>max: 46 tokens</li></ul> | <ul><li>min: 6 tokens</li><li>mean: 14.66 tokens</li><li>max: 41 tokens</li></ul> | <ul><li>min: 6 tokens</li><li>mean: 15.22 tokens</li><li>max: 84 tokens</li></ul> |
|
156 |
+
* Samples:
|
157 |
+
| sentence_0 | sentence_1 | sentence_2 |
|
158 |
+
|:-------------------------------------------------------------------------------|:----------------------------------------------------------------------|:------------------------------------------------------------|
|
159 |
+
| <code>What are the differences between "be made of" and "be made from"?</code> | <code>What's the difference between "made of" and "made from"?</code> | <code>What is the difference between make and craft?</code> |
|
160 |
+
| <code>How can we use the word "inertia" in a sentence?</code> | <code>How can the word "inertia" be used in a sentence?</code> | <code>What is inertia actually?</code> |
|
161 |
+
| <code>Who are the new (i.e. first-time) Top Question Writers for 2017?</code> | <code>Who are the top question writers for 2017?</code> | <code>Who are the 2016 Top Writers?</code> |
|
162 |
+
* Loss: [<code>TripletLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#tripletloss) with these parameters:
|
163 |
+
```json
|
164 |
+
{
|
165 |
+
"distance_metric": "TripletDistanceMetric.EUCLIDEAN",
|
166 |
+
"triplet_margin": 5
|
167 |
+
}
|
168 |
+
```
|
169 |
+
|
170 |
+
### Training Hyperparameters
|
171 |
+
#### Non-Default Hyperparameters
|
172 |
+
|
173 |
+
- `per_device_train_batch_size`: 128
|
174 |
+
- `per_device_eval_batch_size`: 128
|
175 |
+
- `num_train_epochs`: 4
|
176 |
+
- `multi_dataset_batch_sampler`: round_robin
|
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`: 128
|
186 |
+
- `per_device_eval_batch_size`: 128
|
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 |
+
- `learning_rate`: 5e-05
|
192 |
+
- `weight_decay`: 0.0
|
193 |
+
- `adam_beta1`: 0.9
|
194 |
+
- `adam_beta2`: 0.999
|
195 |
+
- `adam_epsilon`: 1e-08
|
196 |
+
- `max_grad_norm`: 1
|
197 |
+
- `num_train_epochs`: 4
|
198 |
+
- `max_steps`: -1
|
199 |
+
- `lr_scheduler_type`: linear
|
200 |
+
- `lr_scheduler_kwargs`: {}
|
201 |
+
- `warmup_ratio`: 0.0
|
202 |
+
- `warmup_steps`: 0
|
203 |
+
- `log_level`: passive
|
204 |
+
- `log_level_replica`: warning
|
205 |
+
- `log_on_each_node`: True
|
206 |
+
- `logging_nan_inf_filter`: True
|
207 |
+
- `save_safetensors`: True
|
208 |
+
- `save_on_each_node`: False
|
209 |
+
- `save_only_model`: False
|
210 |
+
- `restore_callback_states_from_checkpoint`: False
|
211 |
+
- `no_cuda`: False
|
212 |
+
- `use_cpu`: False
|
213 |
+
- `use_mps_device`: False
|
214 |
+
- `seed`: 42
|
215 |
+
- `data_seed`: None
|
216 |
+
- `jit_mode_eval`: False
|
217 |
+
- `use_ipex`: False
|
218 |
+
- `bf16`: False
|
219 |
+
- `fp16`: False
|
220 |
+
- `fp16_opt_level`: O1
|
221 |
+
- `half_precision_backend`: auto
|
222 |
+
- `bf16_full_eval`: False
|
223 |
+
- `fp16_full_eval`: False
|
224 |
+
- `tf32`: None
|
225 |
+
- `local_rank`: 0
|
226 |
+
- `ddp_backend`: None
|
227 |
+
- `tpu_num_cores`: None
|
228 |
+
- `tpu_metrics_debug`: False
|
229 |
+
- `debug`: []
|
230 |
+
- `dataloader_drop_last`: False
|
231 |
+
- `dataloader_num_workers`: 0
|
232 |
+
- `dataloader_prefetch_factor`: None
|
233 |
+
- `past_index`: -1
|
234 |
+
- `disable_tqdm`: False
|
235 |
+
- `remove_unused_columns`: True
|
236 |
+
- `label_names`: None
|
237 |
+
- `load_best_model_at_end`: False
|
238 |
+
- `ignore_data_skip`: False
|
239 |
+
- `fsdp`: []
|
240 |
+
- `fsdp_min_num_params`: 0
|
241 |
+
- `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
|
242 |
+
- `fsdp_transformer_layer_cls_to_wrap`: None
|
243 |
+
- `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
|
244 |
+
- `deepspeed`: None
|
245 |
+
- `label_smoothing_factor`: 0.0
|
246 |
+
- `optim`: adamw_torch
|
247 |
+
- `optim_args`: None
|
248 |
+
- `adafactor`: False
|
249 |
+
- `group_by_length`: False
|
250 |
+
- `length_column_name`: length
|
251 |
+
- `ddp_find_unused_parameters`: None
|
252 |
+
- `ddp_bucket_cap_mb`: None
|
253 |
+
- `ddp_broadcast_buffers`: False
|
254 |
+
- `dataloader_pin_memory`: True
|
255 |
+
- `dataloader_persistent_workers`: False
|
256 |
+
- `skip_memory_metrics`: True
|
257 |
+
- `use_legacy_prediction_loop`: False
|
258 |
+
- `push_to_hub`: False
|
259 |
+
- `resume_from_checkpoint`: None
|
260 |
+
- `hub_model_id`: None
|
261 |
+
- `hub_strategy`: every_save
|
262 |
+
- `hub_private_repo`: False
|
263 |
+
- `hub_always_push`: False
|
264 |
+
- `gradient_checkpointing`: False
|
265 |
+
- `gradient_checkpointing_kwargs`: None
|
266 |
+
- `include_inputs_for_metrics`: False
|
267 |
+
- `eval_do_concat_batches`: True
|
268 |
+
- `fp16_backend`: auto
|
269 |
+
- `push_to_hub_model_id`: None
|
270 |
+
- `push_to_hub_organization`: None
|
271 |
+
- `mp_parameters`:
|
272 |
+
- `auto_find_batch_size`: False
|
273 |
+
- `full_determinism`: False
|
274 |
+
- `torchdynamo`: None
|
275 |
+
- `ray_scope`: last
|
276 |
+
- `ddp_timeout`: 1800
|
277 |
+
- `torch_compile`: False
|
278 |
+
- `torch_compile_backend`: None
|
279 |
+
- `torch_compile_mode`: None
|
280 |
+
- `dispatch_batches`: None
|
281 |
+
- `split_batches`: None
|
282 |
+
- `include_tokens_per_second`: False
|
283 |
+
- `include_num_input_tokens_seen`: False
|
284 |
+
- `neftune_noise_alpha`: None
|
285 |
+
- `optim_target_modules`: None
|
286 |
+
- `batch_eval_metrics`: False
|
287 |
+
- `batch_sampler`: batch_sampler
|
288 |
+
- `multi_dataset_batch_sampler`: round_robin
|
289 |
+
|
290 |
+
</details>
|
291 |
+
|
292 |
+
### Training Logs
|
293 |
+
| Epoch | Step | Training Loss |
|
294 |
+
|:------:|:----:|:-------------:|
|
295 |
+
| 0.6281 | 500 | 4.2255 |
|
296 |
+
| 1.2563 | 1000 | 3.484 |
|
297 |
+
| 1.8844 | 1500 | 2.8611 |
|
298 |
+
| 2.5126 | 2000 | 2.4607 |
|
299 |
+
| 3.1407 | 2500 | 2.148 |
|
300 |
+
| 3.7688 | 3000 | 1.8583 |
|
301 |
+
|
302 |
+
|
303 |
+
### Framework Versions
|
304 |
+
- Python: 3.10.12
|
305 |
+
- Sentence Transformers: 3.0.1
|
306 |
+
- Transformers: 4.41.2
|
307 |
+
- PyTorch: 2.1.2+cu121
|
308 |
+
- Accelerate: 0.32.1
|
309 |
+
- Datasets: 2.19.0
|
310 |
+
- Tokenizers: 0.19.1
|
311 |
+
|
312 |
+
## Citation
|
313 |
+
|
314 |
+
### BibTeX
|
315 |
+
|
316 |
+
#### Sentence Transformers
|
317 |
+
```bibtex
|
318 |
+
@inproceedings{reimers-2019-sentence-bert,
|
319 |
+
title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
|
320 |
+
author = "Reimers, Nils and Gurevych, Iryna",
|
321 |
+
booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
|
322 |
+
month = "11",
|
323 |
+
year = "2019",
|
324 |
+
publisher = "Association for Computational Linguistics",
|
325 |
+
url = "https://arxiv.org/abs/1908.10084",
|
326 |
+
}
|
327 |
+
```
|
328 |
+
|
329 |
+
#### TripletLoss
|
330 |
+
```bibtex
|
331 |
+
@misc{hermans2017defense,
|
332 |
+
title={In Defense of the Triplet Loss for Person Re-Identification},
|
333 |
+
author={Alexander Hermans and Lucas Beyer and Bastian Leibe},
|
334 |
+
year={2017},
|
335 |
+
eprint={1703.07737},
|
336 |
+
archivePrefix={arXiv},
|
337 |
+
primaryClass={cs.CV}
|
338 |
+
}
|
339 |
+
```
|
340 |
+
|
341 |
+
<!--
|
342 |
+
## Glossary
|
343 |
+
|
344 |
+
*Clearly define terms in order to be accessible across audiences.*
|
345 |
+
-->
|
346 |
+
|
347 |
+
<!--
|
348 |
+
## Model Card Authors
|
349 |
+
|
350 |
+
*Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
|
351 |
+
-->
|
352 |
+
|
353 |
+
<!--
|
354 |
+
## Model Card Contact
|
355 |
+
|
356 |
+
*Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
|
357 |
+
-->
|
config.json
ADDED
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"_name_or_path": "model/distilroberta-base-sentence-transformer-triplets",
|
3 |
+
"activation": "gelu",
|
4 |
+
"architectures": [
|
5 |
+
"DistilBertModel"
|
6 |
+
],
|
7 |
+
"attention_dropout": 0.1,
|
8 |
+
"dim": 768,
|
9 |
+
"dropout": 0.1,
|
10 |
+
"hidden_dim": 3072,
|
11 |
+
"initializer_range": 0.02,
|
12 |
+
"max_position_embeddings": 512,
|
13 |
+
"model_type": "distilbert",
|
14 |
+
"n_heads": 12,
|
15 |
+
"n_layers": 6,
|
16 |
+
"output_hidden_states": true,
|
17 |
+
"output_past": true,
|
18 |
+
"pad_token_id": 0,
|
19 |
+
"qa_dropout": 0.1,
|
20 |
+
"seq_classif_dropout": 0.2,
|
21 |
+
"sinusoidal_pos_embds": false,
|
22 |
+
"tie_weights_": true,
|
23 |
+
"torch_dtype": "float32",
|
24 |
+
"transformers_version": "4.41.2",
|
25 |
+
"vocab_size": 119547
|
26 |
+
}
|
config_sentence_transformers.json
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"__version__": {
|
3 |
+
"sentence_transformers": "3.0.1",
|
4 |
+
"transformers": "4.41.2",
|
5 |
+
"pytorch": "2.1.2+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:a4719853593149fe6b6bdfa77672b8250d98c1775dc8d352341c93fc06948e02
|
3 |
+
size 538947416
|
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": 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
The diff for this file is too large to render.
See raw diff
|
|
tokenizer_config.json
ADDED
@@ -0,0 +1,66 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"added_tokens_decoder": {
|
3 |
+
"0": {
|
4 |
+
"content": "[PAD]",
|
5 |
+
"lstrip": false,
|
6 |
+
"normalized": false,
|
7 |
+
"rstrip": false,
|
8 |
+
"single_word": false,
|
9 |
+
"special": true
|
10 |
+
},
|
11 |
+
"100": {
|
12 |
+
"content": "[UNK]",
|
13 |
+
"lstrip": false,
|
14 |
+
"normalized": false,
|
15 |
+
"rstrip": false,
|
16 |
+
"single_word": false,
|
17 |
+
"special": true
|
18 |
+
},
|
19 |
+
"101": {
|
20 |
+
"content": "[CLS]",
|
21 |
+
"lstrip": false,
|
22 |
+
"normalized": false,
|
23 |
+
"rstrip": false,
|
24 |
+
"single_word": false,
|
25 |
+
"special": true
|
26 |
+
},
|
27 |
+
"102": {
|
28 |
+
"content": "[SEP]",
|
29 |
+
"lstrip": false,
|
30 |
+
"normalized": false,
|
31 |
+
"rstrip": false,
|
32 |
+
"single_word": false,
|
33 |
+
"special": true
|
34 |
+
},
|
35 |
+
"103": {
|
36 |
+
"content": "[MASK]",
|
37 |
+
"lstrip": false,
|
38 |
+
"normalized": false,
|
39 |
+
"rstrip": false,
|
40 |
+
"single_word": false,
|
41 |
+
"special": true
|
42 |
+
}
|
43 |
+
},
|
44 |
+
"clean_up_tokenization_spaces": true,
|
45 |
+
"cls_token": "[CLS]",
|
46 |
+
"do_basic_tokenize": true,
|
47 |
+
"do_lower_case": false,
|
48 |
+
"full_tokenizer_file": null,
|
49 |
+
"mask_token": "[MASK]",
|
50 |
+
"max_len": 512,
|
51 |
+
"max_length": 256,
|
52 |
+
"model_max_length": 256,
|
53 |
+
"never_split": null,
|
54 |
+
"pad_to_multiple_of": null,
|
55 |
+
"pad_token": "[PAD]",
|
56 |
+
"pad_token_type_id": 0,
|
57 |
+
"padding_side": "right",
|
58 |
+
"sep_token": "[SEP]",
|
59 |
+
"stride": 0,
|
60 |
+
"strip_accents": null,
|
61 |
+
"tokenize_chinese_chars": true,
|
62 |
+
"tokenizer_class": "DistilBertTokenizer",
|
63 |
+
"truncation_side": "right",
|
64 |
+
"truncation_strategy": "longest_first",
|
65 |
+
"unk_token": "[UNK]"
|
66 |
+
}
|
vocab.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|