Add new SentenceTransformer model.
Browse files- 1_Pooling/config.json +10 -0
- README.md +422 -0
- config.json +26 -0
- config_sentence_transformers.json +10 -0
- model.safetensors +3 -0
- modules.json +20 -0
- sentence_bert_config.json +4 -0
- special_tokens_map.json +37 -0
- tokenizer.json +0 -0
- tokenizer_config.json +64 -0
- vocab.txt +0 -0
1_Pooling/config.json
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"word_embedding_dimension": 384,
|
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,422 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
base_model: sentence-transformers/all-MiniLM-L12-v2
|
3 |
+
datasets: []
|
4 |
+
language: []
|
5 |
+
library_name: sentence-transformers
|
6 |
+
pipeline_tag: sentence-similarity
|
7 |
+
tags:
|
8 |
+
- sentence-transformers
|
9 |
+
- sentence-similarity
|
10 |
+
- feature-extraction
|
11 |
+
- generated_from_trainer
|
12 |
+
- dataset_size:2144
|
13 |
+
- loss:MultipleNegativesRankingLoss
|
14 |
+
widget:
|
15 |
+
- source_sentence: How do I find out when I should write my examinations?
|
16 |
+
sentences:
|
17 |
+
- Information relating to examination timetables is available from the Examination
|
18 |
+
Office and will be published on the official Institute Notice Board and the website.
|
19 |
+
- If you find an error on your academic record, you should contact the Registration
|
20 |
+
and Student Records Management Office immediately.
|
21 |
+
- To request accommodations for a disability, you must submit documentation of the
|
22 |
+
disability to the disability services office and meet with a disability services
|
23 |
+
coordinator.
|
24 |
+
- source_sentence: What is the language of instruction at the Harare Institute of
|
25 |
+
Technology?
|
26 |
+
sentences:
|
27 |
+
- English is the language of instruction.
|
28 |
+
- Tracking international events and conference and strategically link them to HIT,
|
29 |
+
internationalizing HIT programmes and activities, developing bouquet of events
|
30 |
+
and activities for international visitors, helping affiliate, accredit HIT, staff
|
31 |
+
and students to international bodies and associations, liaising with national
|
32 |
+
bodies and promote Zimbabwean culture and symbols, serving as a point of contact
|
33 |
+
for exchange students, staff and visitors, ensuring international programmes align
|
34 |
+
to national programmes and symbols, helping affiliate HIT ethos to national art
|
35 |
+
and culture, monitoring implementation of MoUs and MoAs, facilitation of international
|
36 |
+
travel and visits, providing Institute departments with consular advice, ensuring
|
37 |
+
HIT members get oriented to particular countries’ culture and services before
|
38 |
+
departure, driving recruitment of foreign students and exchange programmes.
|
39 |
+
- BFA 7206 is the course code for Financial Institutions Fraud, which is an elective
|
40 |
+
course in the second semester of the program.
|
41 |
+
- source_sentence: What is the process for collecting a certificate?
|
42 |
+
sentences:
|
43 |
+
- The programme is designed such that on completion, graduates should be able to
|
44 |
+
innovatively execute their professional role within prescribed and legislative
|
45 |
+
parameters, demonstrate a critical understanding and application of quality assurance
|
46 |
+
and radiation protection in Radiography, apply scientific knowledge and technical
|
47 |
+
skills to perform Radiography procedures, plan, develop and apply total quality
|
48 |
+
management appropriate to the Radiography context, apply management, entrepreneurial,
|
49 |
+
education and research skills independently and function in a supervisory clinical
|
50 |
+
governance and quality assurance capacity within the professional sector, demonstrate
|
51 |
+
the ability to reflect in clinical practice, critically evaluate and adjust to
|
52 |
+
current and new trends in Radiography, demonstrate capability to implement new
|
53 |
+
knowledge and solve problems in varying contexts, and engage life-long learning
|
54 |
+
and development in their profession.
|
55 |
+
- The process involves clearing any dues to the Institute and providing valid identification
|
56 |
+
documents.
|
57 |
+
- A student can apply for change of programme within two weeks after commencement
|
58 |
+
of lectures.
|
59 |
+
- source_sentence: How do I change my address or contact information?
|
60 |
+
sentences:
|
61 |
+
- Information Security & Assurance is a field that deals with the protection of
|
62 |
+
information and information systems from unauthorized access, use, disclosure,
|
63 |
+
disruption, modification, or destruction.
|
64 |
+
- The Information and Communications Technology Services (ICTS) Department at HIT
|
65 |
+
is responsible for providing and maintaining the Institute's IT infrastructure
|
66 |
+
and services.
|
67 |
+
- You can update your address or contact information through the online student
|
68 |
+
portal or by contacting the Academic Registry.
|
69 |
+
- source_sentence: What is the difference between Cloud Computing and Information
|
70 |
+
Security & Assurance?
|
71 |
+
sentences:
|
72 |
+
- The fourth semester focuses on courses such as Research Project, Clinical Practice
|
73 |
+
IV, and Seminar.
|
74 |
+
- Cloud Computing is focused on the design, implementation, and management of cloud
|
75 |
+
services, while Information Security & Assurance is focused on the protection
|
76 |
+
of information by mitigating information risks and ensuring availability, privacy,
|
77 |
+
and integrity of data.
|
78 |
+
- The Applied Research Methods course is designed to equip students with the skills
|
79 |
+
and knowledge necessary to conduct research in chemical engineering process and
|
80 |
+
plant design.
|
81 |
+
---
|
82 |
+
|
83 |
+
# SentenceTransformer based on sentence-transformers/all-MiniLM-L12-v2
|
84 |
+
|
85 |
+
This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [sentence-transformers/all-MiniLM-L12-v2](https://huggingface.co/sentence-transformers/all-MiniLM-L12-v2). It maps sentences & paragraphs to a 384-dimensional dense vector space and can be used for semantic textual similarity, semantic search, paraphrase mining, text classification, clustering, and more.
|
86 |
+
|
87 |
+
## Model Details
|
88 |
+
|
89 |
+
### Model Description
|
90 |
+
- **Model Type:** Sentence Transformer
|
91 |
+
- **Base model:** [sentence-transformers/all-MiniLM-L12-v2](https://huggingface.co/sentence-transformers/all-MiniLM-L12-v2) <!-- at revision a05860a77cef7b37e0048a7864658139bc18a854 -->
|
92 |
+
- **Maximum Sequence Length:** 128 tokens
|
93 |
+
- **Output Dimensionality:** 384 tokens
|
94 |
+
- **Similarity Function:** Cosine Similarity
|
95 |
+
<!-- - **Training Dataset:** Unknown -->
|
96 |
+
<!-- - **Language:** Unknown -->
|
97 |
+
<!-- - **License:** Unknown -->
|
98 |
+
|
99 |
+
### Model Sources
|
100 |
+
|
101 |
+
- **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
|
102 |
+
- **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
|
103 |
+
- **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
|
104 |
+
|
105 |
+
### Full Model Architecture
|
106 |
+
|
107 |
+
```
|
108 |
+
SentenceTransformer(
|
109 |
+
(0): Transformer({'max_seq_length': 128, 'do_lower_case': False}) with Transformer model: BertModel
|
110 |
+
(1): Pooling({'word_embedding_dimension': 384, '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})
|
111 |
+
(2): Normalize()
|
112 |
+
)
|
113 |
+
```
|
114 |
+
|
115 |
+
## Usage
|
116 |
+
|
117 |
+
### Direct Usage (Sentence Transformers)
|
118 |
+
|
119 |
+
First install the Sentence Transformers library:
|
120 |
+
|
121 |
+
```bash
|
122 |
+
pip install -U sentence-transformers
|
123 |
+
```
|
124 |
+
|
125 |
+
Then you can load this model and run inference.
|
126 |
+
```python
|
127 |
+
from sentence_transformers import SentenceTransformer
|
128 |
+
|
129 |
+
# Download from the 🤗 Hub
|
130 |
+
model = SentenceTransformer("Dex-X/finehit")
|
131 |
+
# Run inference
|
132 |
+
sentences = [
|
133 |
+
'What is the difference between Cloud Computing and Information Security & Assurance?',
|
134 |
+
'Cloud Computing is focused on the design, implementation, and management of cloud services, while Information Security & Assurance is focused on the protection of information by mitigating information risks and ensuring availability, privacy, and integrity of data.',
|
135 |
+
'The Applied Research Methods course is designed to equip students with the skills and knowledge necessary to conduct research in chemical engineering process and plant design.',
|
136 |
+
]
|
137 |
+
embeddings = model.encode(sentences)
|
138 |
+
print(embeddings.shape)
|
139 |
+
# [3, 384]
|
140 |
+
|
141 |
+
# Get the similarity scores for the embeddings
|
142 |
+
similarities = model.similarity(embeddings, embeddings)
|
143 |
+
print(similarities.shape)
|
144 |
+
# [3, 3]
|
145 |
+
```
|
146 |
+
|
147 |
+
<!--
|
148 |
+
### Direct Usage (Transformers)
|
149 |
+
|
150 |
+
<details><summary>Click to see the direct usage in Transformers</summary>
|
151 |
+
|
152 |
+
</details>
|
153 |
+
-->
|
154 |
+
|
155 |
+
<!--
|
156 |
+
### Downstream Usage (Sentence Transformers)
|
157 |
+
|
158 |
+
You can finetune this model on your own dataset.
|
159 |
+
|
160 |
+
<details><summary>Click to expand</summary>
|
161 |
+
|
162 |
+
</details>
|
163 |
+
-->
|
164 |
+
|
165 |
+
<!--
|
166 |
+
### Out-of-Scope Use
|
167 |
+
|
168 |
+
*List how the model may foreseeably be misused and address what users ought not to do with the model.*
|
169 |
+
-->
|
170 |
+
|
171 |
+
<!--
|
172 |
+
## Bias, Risks and Limitations
|
173 |
+
|
174 |
+
*What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
|
175 |
+
-->
|
176 |
+
|
177 |
+
<!--
|
178 |
+
### Recommendations
|
179 |
+
|
180 |
+
*What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
|
181 |
+
-->
|
182 |
+
|
183 |
+
## Training Details
|
184 |
+
|
185 |
+
### Training Dataset
|
186 |
+
|
187 |
+
#### Unnamed Dataset
|
188 |
+
|
189 |
+
|
190 |
+
* Size: 2,144 training samples
|
191 |
+
* Columns: <code>question</code> and <code>answer</code>
|
192 |
+
* Approximate statistics based on the first 1000 samples:
|
193 |
+
| | question | answer |
|
194 |
+
|:--------|:----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|
|
195 |
+
| type | string | string |
|
196 |
+
| details | <ul><li>min: 6 tokens</li><li>mean: 13.94 tokens</li><li>max: 31 tokens</li></ul> | <ul><li>min: 3 tokens</li><li>mean: 30.7 tokens</li><li>max: 128 tokens</li></ul> |
|
197 |
+
* Samples:
|
198 |
+
| question | answer |
|
199 |
+
|:----------------------------------------------------------------------|:-----------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
200 |
+
| <code>What is the role of the Dean of Students?</code> | <code>The Dean of Students oversees various aspects of student life, including student affairs, campus life and development, accommodation, wellness, and more.</code> |
|
201 |
+
| <code>What does the Student Affairs department do?</code> | <code>The Student Affairs department handles matters related to student life, conduct, and welfare.</code> |
|
202 |
+
| <code>What is the role of Campus Life and Student Development?</code> | <code>Campus Life and Student Development is responsible for fostering a positive campus environment and promoting student growth and development.</code> |
|
203 |
+
* Loss: [<code>MultipleNegativesRankingLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#multiplenegativesrankingloss) with these parameters:
|
204 |
+
```json
|
205 |
+
{
|
206 |
+
"scale": 20.0,
|
207 |
+
"similarity_fct": "cos_sim"
|
208 |
+
}
|
209 |
+
```
|
210 |
+
|
211 |
+
### Evaluation Dataset
|
212 |
+
|
213 |
+
#### Unnamed Dataset
|
214 |
+
|
215 |
+
|
216 |
+
* Size: 214 evaluation samples
|
217 |
+
* Columns: <code>question</code> and <code>answer</code>
|
218 |
+
* Approximate statistics based on the first 1000 samples:
|
219 |
+
| | question | answer |
|
220 |
+
|:--------|:----------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------|
|
221 |
+
| type | string | string |
|
222 |
+
| details | <ul><li>min: 7 tokens</li><li>mean: 15.12 tokens</li><li>max: 31 tokens</li></ul> | <ul><li>min: 3 tokens</li><li>mean: 31.14 tokens</li><li>max: 128 tokens</li></ul> |
|
223 |
+
* Samples:
|
224 |
+
| question | answer |
|
225 |
+
|:--------------------------------------------------------------------------------------------------|:------------------------------------------------------------------------------------------------------------------|
|
226 |
+
| <code>What is Student Accommodation and Catering?</code> | <code>Student Accommodation and Catering is a department that manages student housing and dining services.</code> |
|
227 |
+
| <code>What certification does Mr. Njonga have from the National Social Security Authority?</code> | <code>Safety and Health Advisor Certification</code> |
|
228 |
+
| <code>What is the duration of the B Tech (Hons) Computer Science programme?</code> | <code>The B Tech (Hons) Computer Science programme is a four-year full-time regular programme.</code> |
|
229 |
+
* Loss: [<code>MultipleNegativesRankingLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#multiplenegativesrankingloss) with these parameters:
|
230 |
+
```json
|
231 |
+
{
|
232 |
+
"scale": 20.0,
|
233 |
+
"similarity_fct": "cos_sim"
|
234 |
+
}
|
235 |
+
```
|
236 |
+
|
237 |
+
### Training Hyperparameters
|
238 |
+
#### Non-Default Hyperparameters
|
239 |
+
|
240 |
+
- `eval_strategy`: steps
|
241 |
+
- `per_device_train_batch_size`: 16
|
242 |
+
- `per_device_eval_batch_size`: 16
|
243 |
+
- `num_train_epochs`: 1
|
244 |
+
- `warmup_ratio`: 0.1
|
245 |
+
- `fp16`: True
|
246 |
+
- `batch_sampler`: no_duplicates
|
247 |
+
|
248 |
+
#### All Hyperparameters
|
249 |
+
<details><summary>Click to expand</summary>
|
250 |
+
|
251 |
+
- `overwrite_output_dir`: False
|
252 |
+
- `do_predict`: False
|
253 |
+
- `eval_strategy`: steps
|
254 |
+
- `prediction_loss_only`: True
|
255 |
+
- `per_device_train_batch_size`: 16
|
256 |
+
- `per_device_eval_batch_size`: 16
|
257 |
+
- `per_gpu_train_batch_size`: None
|
258 |
+
- `per_gpu_eval_batch_size`: None
|
259 |
+
- `gradient_accumulation_steps`: 1
|
260 |
+
- `eval_accumulation_steps`: None
|
261 |
+
- `learning_rate`: 5e-05
|
262 |
+
- `weight_decay`: 0.0
|
263 |
+
- `adam_beta1`: 0.9
|
264 |
+
- `adam_beta2`: 0.999
|
265 |
+
- `adam_epsilon`: 1e-08
|
266 |
+
- `max_grad_norm`: 1.0
|
267 |
+
- `num_train_epochs`: 1
|
268 |
+
- `max_steps`: -1
|
269 |
+
- `lr_scheduler_type`: linear
|
270 |
+
- `lr_scheduler_kwargs`: {}
|
271 |
+
- `warmup_ratio`: 0.1
|
272 |
+
- `warmup_steps`: 0
|
273 |
+
- `log_level`: passive
|
274 |
+
- `log_level_replica`: warning
|
275 |
+
- `log_on_each_node`: True
|
276 |
+
- `logging_nan_inf_filter`: True
|
277 |
+
- `save_safetensors`: True
|
278 |
+
- `save_on_each_node`: False
|
279 |
+
- `save_only_model`: False
|
280 |
+
- `restore_callback_states_from_checkpoint`: False
|
281 |
+
- `no_cuda`: False
|
282 |
+
- `use_cpu`: False
|
283 |
+
- `use_mps_device`: False
|
284 |
+
- `seed`: 42
|
285 |
+
- `data_seed`: None
|
286 |
+
- `jit_mode_eval`: False
|
287 |
+
- `use_ipex`: False
|
288 |
+
- `bf16`: False
|
289 |
+
- `fp16`: True
|
290 |
+
- `fp16_opt_level`: O1
|
291 |
+
- `half_precision_backend`: auto
|
292 |
+
- `bf16_full_eval`: False
|
293 |
+
- `fp16_full_eval`: False
|
294 |
+
- `tf32`: None
|
295 |
+
- `local_rank`: 0
|
296 |
+
- `ddp_backend`: None
|
297 |
+
- `tpu_num_cores`: None
|
298 |
+
- `tpu_metrics_debug`: False
|
299 |
+
- `debug`: []
|
300 |
+
- `dataloader_drop_last`: False
|
301 |
+
- `dataloader_num_workers`: 0
|
302 |
+
- `dataloader_prefetch_factor`: None
|
303 |
+
- `past_index`: -1
|
304 |
+
- `disable_tqdm`: False
|
305 |
+
- `remove_unused_columns`: True
|
306 |
+
- `label_names`: None
|
307 |
+
- `load_best_model_at_end`: False
|
308 |
+
- `ignore_data_skip`: False
|
309 |
+
- `fsdp`: []
|
310 |
+
- `fsdp_min_num_params`: 0
|
311 |
+
- `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
|
312 |
+
- `fsdp_transformer_layer_cls_to_wrap`: None
|
313 |
+
- `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
|
314 |
+
- `deepspeed`: None
|
315 |
+
- `label_smoothing_factor`: 0.0
|
316 |
+
- `optim`: adamw_torch
|
317 |
+
- `optim_args`: None
|
318 |
+
- `adafactor`: False
|
319 |
+
- `group_by_length`: False
|
320 |
+
- `length_column_name`: length
|
321 |
+
- `ddp_find_unused_parameters`: None
|
322 |
+
- `ddp_bucket_cap_mb`: None
|
323 |
+
- `ddp_broadcast_buffers`: False
|
324 |
+
- `dataloader_pin_memory`: True
|
325 |
+
- `dataloader_persistent_workers`: False
|
326 |
+
- `skip_memory_metrics`: True
|
327 |
+
- `use_legacy_prediction_loop`: False
|
328 |
+
- `push_to_hub`: False
|
329 |
+
- `resume_from_checkpoint`: None
|
330 |
+
- `hub_model_id`: None
|
331 |
+
- `hub_strategy`: every_save
|
332 |
+
- `hub_private_repo`: False
|
333 |
+
- `hub_always_push`: False
|
334 |
+
- `gradient_checkpointing`: False
|
335 |
+
- `gradient_checkpointing_kwargs`: None
|
336 |
+
- `include_inputs_for_metrics`: False
|
337 |
+
- `eval_do_concat_batches`: True
|
338 |
+
- `fp16_backend`: auto
|
339 |
+
- `push_to_hub_model_id`: None
|
340 |
+
- `push_to_hub_organization`: None
|
341 |
+
- `mp_parameters`:
|
342 |
+
- `auto_find_batch_size`: False
|
343 |
+
- `full_determinism`: False
|
344 |
+
- `torchdynamo`: None
|
345 |
+
- `ray_scope`: last
|
346 |
+
- `ddp_timeout`: 1800
|
347 |
+
- `torch_compile`: False
|
348 |
+
- `torch_compile_backend`: None
|
349 |
+
- `torch_compile_mode`: None
|
350 |
+
- `dispatch_batches`: None
|
351 |
+
- `split_batches`: None
|
352 |
+
- `include_tokens_per_second`: False
|
353 |
+
- `include_num_input_tokens_seen`: False
|
354 |
+
- `neftune_noise_alpha`: None
|
355 |
+
- `optim_target_modules`: None
|
356 |
+
- `batch_eval_metrics`: False
|
357 |
+
- `batch_sampler`: no_duplicates
|
358 |
+
- `multi_dataset_batch_sampler`: proportional
|
359 |
+
|
360 |
+
</details>
|
361 |
+
|
362 |
+
### Training Logs
|
363 |
+
| Epoch | Step | Training Loss | loss |
|
364 |
+
|:------:|:----:|:-------------:|:------:|
|
365 |
+
| 0.7463 | 100 | 0.5551 | 0.0665 |
|
366 |
+
|
367 |
+
|
368 |
+
### Framework Versions
|
369 |
+
- Python: 3.10.12
|
370 |
+
- Sentence Transformers: 3.0.1
|
371 |
+
- Transformers: 4.41.2
|
372 |
+
- PyTorch: 2.3.0+cu121
|
373 |
+
- Accelerate: 0.32.1
|
374 |
+
- Datasets: 2.20.0
|
375 |
+
- Tokenizers: 0.19.1
|
376 |
+
|
377 |
+
## Citation
|
378 |
+
|
379 |
+
### BibTeX
|
380 |
+
|
381 |
+
#### Sentence Transformers
|
382 |
+
```bibtex
|
383 |
+
@inproceedings{reimers-2019-sentence-bert,
|
384 |
+
title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
|
385 |
+
author = "Reimers, Nils and Gurevych, Iryna",
|
386 |
+
booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
|
387 |
+
month = "11",
|
388 |
+
year = "2019",
|
389 |
+
publisher = "Association for Computational Linguistics",
|
390 |
+
url = "https://arxiv.org/abs/1908.10084",
|
391 |
+
}
|
392 |
+
```
|
393 |
+
|
394 |
+
#### MultipleNegativesRankingLoss
|
395 |
+
```bibtex
|
396 |
+
@misc{henderson2017efficient,
|
397 |
+
title={Efficient Natural Language Response Suggestion for Smart Reply},
|
398 |
+
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},
|
399 |
+
year={2017},
|
400 |
+
eprint={1705.00652},
|
401 |
+
archivePrefix={arXiv},
|
402 |
+
primaryClass={cs.CL}
|
403 |
+
}
|
404 |
+
```
|
405 |
+
|
406 |
+
<!--
|
407 |
+
## Glossary
|
408 |
+
|
409 |
+
*Clearly define terms in order to be accessible across audiences.*
|
410 |
+
-->
|
411 |
+
|
412 |
+
<!--
|
413 |
+
## Model Card Authors
|
414 |
+
|
415 |
+
*Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
|
416 |
+
-->
|
417 |
+
|
418 |
+
<!--
|
419 |
+
## Model Card Contact
|
420 |
+
|
421 |
+
*Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
|
422 |
+
-->
|
config.json
ADDED
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"_name_or_path": "sentence-transformers/all-MiniLM-L12-v2",
|
3 |
+
"architectures": [
|
4 |
+
"BertModel"
|
5 |
+
],
|
6 |
+
"attention_probs_dropout_prob": 0.1,
|
7 |
+
"classifier_dropout": null,
|
8 |
+
"gradient_checkpointing": false,
|
9 |
+
"hidden_act": "gelu",
|
10 |
+
"hidden_dropout_prob": 0.1,
|
11 |
+
"hidden_size": 384,
|
12 |
+
"initializer_range": 0.02,
|
13 |
+
"intermediate_size": 1536,
|
14 |
+
"layer_norm_eps": 1e-12,
|
15 |
+
"max_position_embeddings": 512,
|
16 |
+
"model_type": "bert",
|
17 |
+
"num_attention_heads": 12,
|
18 |
+
"num_hidden_layers": 12,
|
19 |
+
"pad_token_id": 0,
|
20 |
+
"position_embedding_type": "absolute",
|
21 |
+
"torch_dtype": "float32",
|
22 |
+
"transformers_version": "4.41.2",
|
23 |
+
"type_vocab_size": 2,
|
24 |
+
"use_cache": true,
|
25 |
+
"vocab_size": 30522
|
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.3.0+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:f04d2893981a0fd27b5243b39191077f85a468446e90d27f78fe50b297ba0d2b
|
3 |
+
size 133462128
|
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": 128,
|
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,64 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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": true,
|
48 |
+
"mask_token": "[MASK]",
|
49 |
+
"max_length": 128,
|
50 |
+
"model_max_length": 128,
|
51 |
+
"never_split": null,
|
52 |
+
"pad_to_multiple_of": null,
|
53 |
+
"pad_token": "[PAD]",
|
54 |
+
"pad_token_type_id": 0,
|
55 |
+
"padding_side": "right",
|
56 |
+
"sep_token": "[SEP]",
|
57 |
+
"stride": 0,
|
58 |
+
"strip_accents": null,
|
59 |
+
"tokenize_chinese_chars": true,
|
60 |
+
"tokenizer_class": "BertTokenizer",
|
61 |
+
"truncation_side": "right",
|
62 |
+
"truncation_strategy": "longest_first",
|
63 |
+
"unk_token": "[UNK]"
|
64 |
+
}
|
vocab.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|