Add new SentenceTransformer model
Browse files- 1_Pooling/config.json +10 -0
- README.md +615 -0
- config.json +24 -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 +51 -0
- tokenizer.json +0 -0
- tokenizer_config.json +73 -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,615 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
tags:
|
| 3 |
+
- sentence-transformers
|
| 4 |
+
- sentence-similarity
|
| 5 |
+
- feature-extraction
|
| 6 |
+
- generated_from_trainer
|
| 7 |
+
- dataset_size:360886
|
| 8 |
+
- loss:CoSENTLoss
|
| 9 |
+
base_model: sentence-transformers/all-mpnet-base-v2
|
| 10 |
+
widget:
|
| 11 |
+
- source_sentence: '|Immunosuppressant drug therapy (procedure)| : { |Method (attribute)|
|
| 12 |
+
= |Administration - action (qualifier value)|, |Direct substance (attribute)|
|
| 13 |
+
= |Auranofin (substance)| }, { |Has intent (attribute)| = |Therapeutic intent
|
| 14 |
+
(qualifier value)| }'
|
| 15 |
+
sentences:
|
| 16 |
+
- Tofacitinib therapy (procedure)
|
| 17 |
+
- Mural thrombus of right ventricle following acute myocardial infarction (disorder)
|
| 18 |
+
- Neonatal botulism (disorder)
|
| 19 |
+
- source_sentence: '|Injury of finger of left hand (disorder)| + |Traumatic blister
|
| 20 |
+
of index finger (disorder)| + |Traumatic blister of left hand (disorder)| : {
|
| 21 |
+
|Finding site (attribute)| = |Skin structure of left index finger (body structure)|,
|
| 22 |
+
|Associated morphology (attribute)| = |Blister (morphologic abnormality)| }, {
|
| 23 |
+
|Due to (attribute)| = |Traumatic event (event)| }'
|
| 24 |
+
sentences:
|
| 25 |
+
- Cardiovascular system closure (procedure)
|
| 26 |
+
- Entire skin of lower eyelid and periocular area (body structure)
|
| 27 |
+
- Avulsion of nail unit of left little finger (disorder)
|
| 28 |
+
- source_sentence: '|Evaluation finding (finding)| : { |Interprets (attribute)| =
|
| 29 |
+
|Interferon gamma assay (procedure)|, |Has interpretation (attribute)| = |Positive
|
| 30 |
+
(qualifier value)| }'
|
| 31 |
+
sentences:
|
| 32 |
+
- Gleason pattern (observable entity)
|
| 33 |
+
- Interferon gamma assay positive (finding)
|
| 34 |
+
- Intentional melphalan overdose (disorder)
|
| 35 |
+
- source_sentence: '|Finding of specific antibody level (finding)| : { |Interprets
|
| 36 |
+
(attribute)| = |Measurement of viral antibody (procedure)| }'
|
| 37 |
+
sentences:
|
| 38 |
+
- Lyme detected by immunoblot (finding)
|
| 39 |
+
- Primary malignant neoplasm of accessory sinus (disorder)
|
| 40 |
+
- Perfusion of lymphatics with hyperthermia (procedure)
|
| 41 |
+
- source_sentence: '|Neoplasm of anterior wall of nasopharynx (disorder)| + |Neoplasm
|
| 42 |
+
of uncertain behavior of nasopharynx (disorder)| : { |Finding site (attribute)|
|
| 43 |
+
= |Structure of anterior wall of nasopharynx (body structure)|, |Associated morphology
|
| 44 |
+
(attribute)| = |Neoplasm of uncertain behavior (morphologic abnormality)| }'
|
| 45 |
+
sentences:
|
| 46 |
+
- Secondary angle-closure glaucoma - synechial (disorder)
|
| 47 |
+
- Neoplasm of uncertain behavior of lateral wall of nasopharynx (disorder)
|
| 48 |
+
- Product containing precisely cefamandole (as cefamandole nafate) 1 gram/1 vial
|
| 49 |
+
powder for conventional release solution for injection (clinical drug)
|
| 50 |
+
pipeline_tag: sentence-similarity
|
| 51 |
+
library_name: sentence-transformers
|
| 52 |
+
metrics:
|
| 53 |
+
- pearson_cosine
|
| 54 |
+
- spearman_cosine
|
| 55 |
+
model-index:
|
| 56 |
+
- name: SentenceTransformer based on sentence-transformers/all-mpnet-base-v2
|
| 57 |
+
results:
|
| 58 |
+
- task:
|
| 59 |
+
type: semantic-similarity
|
| 60 |
+
name: Semantic Similarity
|
| 61 |
+
dataset:
|
| 62 |
+
name: sts dev
|
| 63 |
+
type: sts-dev
|
| 64 |
+
metrics:
|
| 65 |
+
- type: pearson_cosine
|
| 66 |
+
value: 0.9048593944190657
|
| 67 |
+
name: Pearson Cosine
|
| 68 |
+
- type: spearman_cosine
|
| 69 |
+
value: 0.8556279874385214
|
| 70 |
+
name: Spearman Cosine
|
| 71 |
+
---
|
| 72 |
+
|
| 73 |
+
# SentenceTransformer based on sentence-transformers/all-mpnet-base-v2
|
| 74 |
+
|
| 75 |
+
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) on the csv dataset. 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.
|
| 76 |
+
|
| 77 |
+
## Model Details
|
| 78 |
+
|
| 79 |
+
### Model Description
|
| 80 |
+
- **Model Type:** Sentence Transformer
|
| 81 |
+
- **Base model:** [sentence-transformers/all-mpnet-base-v2](https://huggingface.co/sentence-transformers/all-mpnet-base-v2) <!-- at revision 9a3225965996d404b775526de6dbfe85d3368642 -->
|
| 82 |
+
- **Maximum Sequence Length:** 384 tokens
|
| 83 |
+
- **Output Dimensionality:** 768 dimensions
|
| 84 |
+
- **Similarity Function:** Cosine Similarity
|
| 85 |
+
- **Training Dataset:**
|
| 86 |
+
- csv
|
| 87 |
+
<!-- - **Language:** Unknown -->
|
| 88 |
+
<!-- - **License:** Unknown -->
|
| 89 |
+
|
| 90 |
+
### Model Sources
|
| 91 |
+
|
| 92 |
+
- **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
|
| 93 |
+
- **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
|
| 94 |
+
- **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
|
| 95 |
+
|
| 96 |
+
### Full Model Architecture
|
| 97 |
+
|
| 98 |
+
```
|
| 99 |
+
SentenceTransformer(
|
| 100 |
+
(0): Transformer({'max_seq_length': 384, 'do_lower_case': False}) with Transformer model: MPNetModel
|
| 101 |
+
(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})
|
| 102 |
+
(2): Normalize()
|
| 103 |
+
)
|
| 104 |
+
```
|
| 105 |
+
|
| 106 |
+
## Usage
|
| 107 |
+
|
| 108 |
+
### Direct Usage (Sentence Transformers)
|
| 109 |
+
|
| 110 |
+
First install the Sentence Transformers library:
|
| 111 |
+
|
| 112 |
+
```bash
|
| 113 |
+
pip install -U sentence-transformers
|
| 114 |
+
```
|
| 115 |
+
|
| 116 |
+
Then you can load this model and run inference.
|
| 117 |
+
```python
|
| 118 |
+
from sentence_transformers import SentenceTransformer
|
| 119 |
+
|
| 120 |
+
# Download from the 🤗 Hub
|
| 121 |
+
model = SentenceTransformer("yyzheng00/all-mpnet-base-v2_snomed_expression")
|
| 122 |
+
# Run inference
|
| 123 |
+
sentences = [
|
| 124 |
+
'|Neoplasm of anterior wall of nasopharynx (disorder)| + |Neoplasm of uncertain behavior of nasopharynx (disorder)| : { |Finding site (attribute)| = |Structure of anterior wall of nasopharynx (body structure)|, |Associated morphology (attribute)| = |Neoplasm of uncertain behavior (morphologic abnormality)| }',
|
| 125 |
+
'Neoplasm of uncertain behavior of lateral wall of nasopharynx (disorder)',
|
| 126 |
+
'Secondary angle-closure glaucoma - synechial (disorder)',
|
| 127 |
+
]
|
| 128 |
+
embeddings = model.encode(sentences)
|
| 129 |
+
print(embeddings.shape)
|
| 130 |
+
# [3, 768]
|
| 131 |
+
|
| 132 |
+
# Get the similarity scores for the embeddings
|
| 133 |
+
similarities = model.similarity(embeddings, embeddings)
|
| 134 |
+
print(similarities.shape)
|
| 135 |
+
# [3, 3]
|
| 136 |
+
```
|
| 137 |
+
|
| 138 |
+
<!--
|
| 139 |
+
### Direct Usage (Transformers)
|
| 140 |
+
|
| 141 |
+
<details><summary>Click to see the direct usage in Transformers</summary>
|
| 142 |
+
|
| 143 |
+
</details>
|
| 144 |
+
-->
|
| 145 |
+
|
| 146 |
+
<!--
|
| 147 |
+
### Downstream Usage (Sentence Transformers)
|
| 148 |
+
|
| 149 |
+
You can finetune this model on your own dataset.
|
| 150 |
+
|
| 151 |
+
<details><summary>Click to expand</summary>
|
| 152 |
+
|
| 153 |
+
</details>
|
| 154 |
+
-->
|
| 155 |
+
|
| 156 |
+
<!--
|
| 157 |
+
### Out-of-Scope Use
|
| 158 |
+
|
| 159 |
+
*List how the model may foreseeably be misused and address what users ought not to do with the model.*
|
| 160 |
+
-->
|
| 161 |
+
|
| 162 |
+
## Evaluation
|
| 163 |
+
|
| 164 |
+
### Metrics
|
| 165 |
+
|
| 166 |
+
#### Semantic Similarity
|
| 167 |
+
|
| 168 |
+
* Dataset: `sts-dev`
|
| 169 |
+
* Evaluated with [<code>EmbeddingSimilarityEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.EmbeddingSimilarityEvaluator)
|
| 170 |
+
|
| 171 |
+
| Metric | Value |
|
| 172 |
+
|:--------------------|:-----------|
|
| 173 |
+
| pearson_cosine | 0.9049 |
|
| 174 |
+
| **spearman_cosine** | **0.8556** |
|
| 175 |
+
|
| 176 |
+
<!--
|
| 177 |
+
## Bias, Risks and Limitations
|
| 178 |
+
|
| 179 |
+
*What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
|
| 180 |
+
-->
|
| 181 |
+
|
| 182 |
+
<!--
|
| 183 |
+
### Recommendations
|
| 184 |
+
|
| 185 |
+
*What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
|
| 186 |
+
-->
|
| 187 |
+
|
| 188 |
+
## Training Details
|
| 189 |
+
|
| 190 |
+
### Training Dataset
|
| 191 |
+
|
| 192 |
+
#### csv
|
| 193 |
+
|
| 194 |
+
* Dataset: csv
|
| 195 |
+
* Size: 360,886 training samples
|
| 196 |
+
* Columns: <code>text_a</code>, <code>text_b</code>, and <code>label</code>
|
| 197 |
+
* Approximate statistics based on the first 1000 samples:
|
| 198 |
+
| | text_a | text_b | label |
|
| 199 |
+
|:--------|:-------------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|:------------------------------------------------|
|
| 200 |
+
| type | string | string | int |
|
| 201 |
+
| details | <ul><li>min: 28 tokens</li><li>mean: 101.13 tokens</li><li>max: 357 tokens</li></ul> | <ul><li>min: 7 tokens</li><li>mean: 15.29 tokens</li><li>max: 60 tokens</li></ul> | <ul><li>0: ~51.40%</li><li>1: ~48.60%</li></ul> |
|
| 202 |
+
* Samples:
|
| 203 |
+
| text_a | text_b | label |
|
| 204 |
+
|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:----------------------------------------------------------------------------|:---------------|
|
| 205 |
+
| <code>|Risk assessment (procedure)| : { |Method (attribute)| = |Evaluation - action (qualifier value)| }, { |Has focus (attribute)| = |At increased risk of ineffective tissue perfusion (finding)| }</code> | <code>Assessment of risk of ineffective tissue perfusion (procedure)</code> | <code>1</code> |
|
| 206 |
+
| <code>|Chronic inflammatory disorder (disorder)| + |Chronic nervous system disorder (disorder)| + |Meningitis (disorder)| : { |Finding site (attribute)| = |Meninges structure (body structure)|, |Associated morphology (attribute)| = |Chronic inflammatory morphology (morphologic abnormality)| }, { |Clinical course (attribute)| = |Chronic (qualifier value)| }</code> | <code>Chronic meningitis (disorder)</code> | <code>1</code> |
|
| 207 |
+
| <code>|Imaging of head (procedure)| + |Ultrasound procedure on topographic region (procedure)| : { |Method (attribute)| = |Ultrasound imaging - action (qualifier value)|, |Procedure site - Direct (attribute)| = |Head structure (body structure)| }</code> | <code>Imaging of brain (procedure)</code> | <code>0</code> |
|
| 208 |
+
* Loss: [<code>CoSENTLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#cosentloss) with these parameters:
|
| 209 |
+
```json
|
| 210 |
+
{
|
| 211 |
+
"scale": 20.0,
|
| 212 |
+
"similarity_fct": "pairwise_cos_sim"
|
| 213 |
+
}
|
| 214 |
+
```
|
| 215 |
+
|
| 216 |
+
### Evaluation Dataset
|
| 217 |
+
|
| 218 |
+
#### csv
|
| 219 |
+
|
| 220 |
+
* Dataset: csv
|
| 221 |
+
* Size: 360,886 evaluation samples
|
| 222 |
+
* Columns: <code>text_a</code>, <code>text_b</code>, and <code>label</code>
|
| 223 |
+
* Approximate statistics based on the first 1000 samples:
|
| 224 |
+
| | text_a | text_b | label |
|
| 225 |
+
|:--------|:-------------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|:------------------------------------------------|
|
| 226 |
+
| type | string | string | int |
|
| 227 |
+
| details | <ul><li>min: 25 tokens</li><li>mean: 101.18 tokens</li><li>max: 366 tokens</li></ul> | <ul><li>min: 7 tokens</li><li>mean: 15.21 tokens</li><li>max: 52 tokens</li></ul> | <ul><li>0: ~51.30%</li><li>1: ~48.70%</li></ul> |
|
| 228 |
+
* Samples:
|
| 229 |
+
| text_a | text_b | label |
|
| 230 |
+
|:--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:-------------------------------------------------------------------------------------------------|:---------------|
|
| 231 |
+
| <code>|Disorder of fetal abdominal region (disorder)| + |Fetal genitourinary abnormality (disorder)| + |Kidney disease (disorder)| : { |Occurrence (attribute)| = |Fetal period (qualifier value)|, |Finding site (attribute)| = |Kidney structure (body structure)|, |Associated morphology (attribute)| = |Morphologically abnormal structure (morphologic abnormality)|, |Pathological process (attribute)| = |Pathological developmental process (qualifier value)| }</code> | <code>Early urethral obstruction sequence (disorder)</code> | <code>0</code> |
|
| 232 |
+
| <code>|Computed tomography of pelvis for brachytherapy planning (procedure)| + |Computed tomography of prostate for radiotherapy planning (procedure)| : { |Has focus (attribute)| = |Treatment planning for brachytherapy (procedure)| }, { |Method (attribute)| = |Computed tomography imaging - action (qualifier value)|, |Procedure site - Direct (attribute)| = |Prostatic structure (body structure)| }</code> | <code>Computed tomography of prostate with contrast for radiotherapy planning (procedure)</code> | <code>0</code> |
|
| 233 |
+
| <code>|Product containing only hydroxyzine in oral dose form (medicinal product form)| : |Has manufactured dose form (attribute)| = |Conventional release oral capsule (dose form)|, |Has unit of presentation (attribute)| = |Capsule (unit of presentation)|, |Count of base of active ingredient (attribute)| = #1, { |Has precise active ingredient (attribute)| = |Hydroxyzine pamoate (substance)|, |Has basis of strength substance (attribute)| = |Hydroxyzine pamoate (substance)|, |Has presentation strength numerator value (attribute)| = #100, |Has presentation strength numerator unit (attribute)| = |milligram (qualifier value)|, |Has presentation strength denominator value (attribute)| = #1, |Has presentation strength denominator unit (attribute)| = |Capsule (unit of presentation)| }</code> | <code>Hydroxyzine pamoate 100mg capsule (product)</code> | <code>1</code> |
|
| 234 |
+
* Loss: [<code>CoSENTLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#cosentloss) with these parameters:
|
| 235 |
+
```json
|
| 236 |
+
{
|
| 237 |
+
"scale": 20.0,
|
| 238 |
+
"similarity_fct": "pairwise_cos_sim"
|
| 239 |
+
}
|
| 240 |
+
```
|
| 241 |
+
|
| 242 |
+
### Training Hyperparameters
|
| 243 |
+
#### Non-Default Hyperparameters
|
| 244 |
+
|
| 245 |
+
- `eval_strategy`: steps
|
| 246 |
+
- `per_device_train_batch_size`: 16
|
| 247 |
+
- `per_device_eval_batch_size`: 16
|
| 248 |
+
- `num_train_epochs`: 1
|
| 249 |
+
- `warmup_ratio`: 0.1
|
| 250 |
+
- `fp16`: True
|
| 251 |
+
- `batch_sampler`: no_duplicates
|
| 252 |
+
|
| 253 |
+
#### All Hyperparameters
|
| 254 |
+
<details><summary>Click to expand</summary>
|
| 255 |
+
|
| 256 |
+
- `overwrite_output_dir`: False
|
| 257 |
+
- `do_predict`: False
|
| 258 |
+
- `eval_strategy`: steps
|
| 259 |
+
- `prediction_loss_only`: True
|
| 260 |
+
- `per_device_train_batch_size`: 16
|
| 261 |
+
- `per_device_eval_batch_size`: 16
|
| 262 |
+
- `per_gpu_train_batch_size`: None
|
| 263 |
+
- `per_gpu_eval_batch_size`: None
|
| 264 |
+
- `gradient_accumulation_steps`: 1
|
| 265 |
+
- `eval_accumulation_steps`: None
|
| 266 |
+
- `torch_empty_cache_steps`: None
|
| 267 |
+
- `learning_rate`: 5e-05
|
| 268 |
+
- `weight_decay`: 0.0
|
| 269 |
+
- `adam_beta1`: 0.9
|
| 270 |
+
- `adam_beta2`: 0.999
|
| 271 |
+
- `adam_epsilon`: 1e-08
|
| 272 |
+
- `max_grad_norm`: 1.0
|
| 273 |
+
- `num_train_epochs`: 1
|
| 274 |
+
- `max_steps`: -1
|
| 275 |
+
- `lr_scheduler_type`: linear
|
| 276 |
+
- `lr_scheduler_kwargs`: {}
|
| 277 |
+
- `warmup_ratio`: 0.1
|
| 278 |
+
- `warmup_steps`: 0
|
| 279 |
+
- `log_level`: passive
|
| 280 |
+
- `log_level_replica`: warning
|
| 281 |
+
- `log_on_each_node`: True
|
| 282 |
+
- `logging_nan_inf_filter`: True
|
| 283 |
+
- `save_safetensors`: True
|
| 284 |
+
- `save_on_each_node`: False
|
| 285 |
+
- `save_only_model`: False
|
| 286 |
+
- `restore_callback_states_from_checkpoint`: False
|
| 287 |
+
- `no_cuda`: False
|
| 288 |
+
- `use_cpu`: False
|
| 289 |
+
- `use_mps_device`: False
|
| 290 |
+
- `seed`: 42
|
| 291 |
+
- `data_seed`: None
|
| 292 |
+
- `jit_mode_eval`: False
|
| 293 |
+
- `use_ipex`: False
|
| 294 |
+
- `bf16`: False
|
| 295 |
+
- `fp16`: True
|
| 296 |
+
- `fp16_opt_level`: O1
|
| 297 |
+
- `half_precision_backend`: auto
|
| 298 |
+
- `bf16_full_eval`: False
|
| 299 |
+
- `fp16_full_eval`: False
|
| 300 |
+
- `tf32`: None
|
| 301 |
+
- `local_rank`: 0
|
| 302 |
+
- `ddp_backend`: None
|
| 303 |
+
- `tpu_num_cores`: None
|
| 304 |
+
- `tpu_metrics_debug`: False
|
| 305 |
+
- `debug`: []
|
| 306 |
+
- `dataloader_drop_last`: False
|
| 307 |
+
- `dataloader_num_workers`: 0
|
| 308 |
+
- `dataloader_prefetch_factor`: None
|
| 309 |
+
- `past_index`: -1
|
| 310 |
+
- `disable_tqdm`: False
|
| 311 |
+
- `remove_unused_columns`: True
|
| 312 |
+
- `label_names`: None
|
| 313 |
+
- `load_best_model_at_end`: False
|
| 314 |
+
- `ignore_data_skip`: False
|
| 315 |
+
- `fsdp`: []
|
| 316 |
+
- `fsdp_min_num_params`: 0
|
| 317 |
+
- `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
|
| 318 |
+
- `fsdp_transformer_layer_cls_to_wrap`: None
|
| 319 |
+
- `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
|
| 320 |
+
- `deepspeed`: None
|
| 321 |
+
- `label_smoothing_factor`: 0.0
|
| 322 |
+
- `optim`: adamw_torch
|
| 323 |
+
- `optim_args`: None
|
| 324 |
+
- `adafactor`: False
|
| 325 |
+
- `group_by_length`: False
|
| 326 |
+
- `length_column_name`: length
|
| 327 |
+
- `ddp_find_unused_parameters`: None
|
| 328 |
+
- `ddp_bucket_cap_mb`: None
|
| 329 |
+
- `ddp_broadcast_buffers`: False
|
| 330 |
+
- `dataloader_pin_memory`: True
|
| 331 |
+
- `dataloader_persistent_workers`: False
|
| 332 |
+
- `skip_memory_metrics`: True
|
| 333 |
+
- `use_legacy_prediction_loop`: False
|
| 334 |
+
- `push_to_hub`: False
|
| 335 |
+
- `resume_from_checkpoint`: None
|
| 336 |
+
- `hub_model_id`: None
|
| 337 |
+
- `hub_strategy`: every_save
|
| 338 |
+
- `hub_private_repo`: None
|
| 339 |
+
- `hub_always_push`: False
|
| 340 |
+
- `gradient_checkpointing`: False
|
| 341 |
+
- `gradient_checkpointing_kwargs`: None
|
| 342 |
+
- `include_inputs_for_metrics`: False
|
| 343 |
+
- `include_for_metrics`: []
|
| 344 |
+
- `eval_do_concat_batches`: True
|
| 345 |
+
- `fp16_backend`: auto
|
| 346 |
+
- `push_to_hub_model_id`: None
|
| 347 |
+
- `push_to_hub_organization`: None
|
| 348 |
+
- `mp_parameters`:
|
| 349 |
+
- `auto_find_batch_size`: False
|
| 350 |
+
- `full_determinism`: False
|
| 351 |
+
- `torchdynamo`: None
|
| 352 |
+
- `ray_scope`: last
|
| 353 |
+
- `ddp_timeout`: 1800
|
| 354 |
+
- `torch_compile`: False
|
| 355 |
+
- `torch_compile_backend`: None
|
| 356 |
+
- `torch_compile_mode`: None
|
| 357 |
+
- `dispatch_batches`: None
|
| 358 |
+
- `split_batches`: None
|
| 359 |
+
- `include_tokens_per_second`: False
|
| 360 |
+
- `include_num_input_tokens_seen`: False
|
| 361 |
+
- `neftune_noise_alpha`: None
|
| 362 |
+
- `optim_target_modules`: None
|
| 363 |
+
- `batch_eval_metrics`: False
|
| 364 |
+
- `eval_on_start`: False
|
| 365 |
+
- `use_liger_kernel`: False
|
| 366 |
+
- `eval_use_gather_object`: False
|
| 367 |
+
- `average_tokens_across_devices`: False
|
| 368 |
+
- `prompts`: None
|
| 369 |
+
- `batch_sampler`: no_duplicates
|
| 370 |
+
- `multi_dataset_batch_sampler`: proportional
|
| 371 |
+
|
| 372 |
+
</details>
|
| 373 |
+
|
| 374 |
+
### Training Logs
|
| 375 |
+
<details><summary>Click to expand</summary>
|
| 376 |
+
|
| 377 |
+
| Epoch | Step | Training Loss | Validation Loss | sts-dev_spearman_cosine |
|
| 378 |
+
|:------:|:-----:|:-------------:|:---------------:|:-----------------------:|
|
| 379 |
+
| 0.0055 | 100 | 5.2922 | 3.9427 | 0.6159 |
|
| 380 |
+
| 0.0111 | 200 | 3.2766 | 2.8638 | 0.7437 |
|
| 381 |
+
| 0.0166 | 300 | 2.8445 | 2.4816 | 0.7833 |
|
| 382 |
+
| 0.0222 | 400 | 2.5209 | 2.2995 | 0.7974 |
|
| 383 |
+
| 0.0277 | 500 | 2.5298 | 2.1033 | 0.8072 |
|
| 384 |
+
| 0.0333 | 600 | 2.0427 | 2.1055 | 0.8114 |
|
| 385 |
+
| 0.0388 | 700 | 2.1367 | 2.0634 | 0.8121 |
|
| 386 |
+
| 0.0443 | 800 | 2.2486 | 1.7848 | 0.8210 |
|
| 387 |
+
| 0.0499 | 900 | 1.921 | 1.9666 | 0.8190 |
|
| 388 |
+
| 0.0554 | 1000 | 1.9962 | 1.9688 | 0.8180 |
|
| 389 |
+
| 0.0610 | 1100 | 1.5203 | 2.0695 | 0.8187 |
|
| 390 |
+
| 0.0665 | 1200 | 2.0616 | 1.7060 | 0.8223 |
|
| 391 |
+
| 0.0720 | 1300 | 2.0793 | 1.8158 | 0.8254 |
|
| 392 |
+
| 0.0776 | 1400 | 2.0766 | 1.8549 | 0.8213 |
|
| 393 |
+
| 0.0831 | 1500 | 1.5608 | 1.8045 | 0.8241 |
|
| 394 |
+
| 0.0887 | 1600 | 1.7671 | 1.9724 | 0.8196 |
|
| 395 |
+
| 0.0942 | 1700 | 2.1665 | 2.2623 | 0.8033 |
|
| 396 |
+
| 0.0998 | 1800 | 1.9596 | 1.8070 | 0.8224 |
|
| 397 |
+
| 0.1053 | 1900 | 1.5704 | 1.8142 | 0.8265 |
|
| 398 |
+
| 0.1108 | 2000 | 2.0749 | 2.0596 | 0.8205 |
|
| 399 |
+
| 0.1164 | 2100 | 1.9445 | 1.7458 | 0.8279 |
|
| 400 |
+
| 0.1219 | 2200 | 1.6043 | 2.0309 | 0.8242 |
|
| 401 |
+
| 0.1275 | 2300 | 1.5723 | 1.7440 | 0.8286 |
|
| 402 |
+
| 0.1330 | 2400 | 1.7905 | 1.5584 | 0.8319 |
|
| 403 |
+
| 0.1385 | 2500 | 2.0777 | 1.7437 | 0.8254 |
|
| 404 |
+
| 0.1441 | 2600 | 1.7563 | 1.6852 | 0.8322 |
|
| 405 |
+
| 0.1496 | 2700 | 1.6565 | 1.8196 | 0.8268 |
|
| 406 |
+
| 0.1552 | 2800 | 1.5064 | 1.6763 | 0.8302 |
|
| 407 |
+
| 0.1607 | 2900 | 1.9221 | 1.7317 | 0.8279 |
|
| 408 |
+
| 0.1663 | 3000 | 1.7803 | 1.8330 | 0.8225 |
|
| 409 |
+
| 0.1718 | 3100 | 1.3559 | 1.9419 | 0.8278 |
|
| 410 |
+
| 0.1773 | 3200 | 1.5309 | 1.5263 | 0.8345 |
|
| 411 |
+
| 0.1829 | 3300 | 1.6429 | 1.7952 | 0.8290 |
|
| 412 |
+
| 0.1884 | 3400 | 1.4676 | 1.8284 | 0.8270 |
|
| 413 |
+
| 0.1940 | 3500 | 1.5167 | 1.6084 | 0.8295 |
|
| 414 |
+
| 0.1995 | 3600 | 1.7605 | 1.6362 | 0.8334 |
|
| 415 |
+
| 0.2050 | 3700 | 1.6812 | 1.4205 | 0.8348 |
|
| 416 |
+
| 0.2106 | 3800 | 1.4537 | 1.6432 | 0.8341 |
|
| 417 |
+
| 0.2161 | 3900 | 1.6718 | 1.2594 | 0.8382 |
|
| 418 |
+
| 0.2217 | 4000 | 1.3892 | 1.4798 | 0.8351 |
|
| 419 |
+
| 0.2272 | 4100 | 1.7261 | 1.3948 | 0.8354 |
|
| 420 |
+
| 0.2328 | 4200 | 1.6611 | 1.4519 | 0.8368 |
|
| 421 |
+
| 0.2383 | 4300 | 1.3181 | 1.2844 | 0.8389 |
|
| 422 |
+
| 0.2438 | 4400 | 1.4356 | 1.3015 | 0.8392 |
|
| 423 |
+
| 0.2494 | 4500 | 1.4077 | 1.3217 | 0.8381 |
|
| 424 |
+
| 0.2549 | 4600 | 1.2534 | 1.5767 | 0.8340 |
|
| 425 |
+
| 0.2605 | 4700 | 1.6881 | 1.2737 | 0.8398 |
|
| 426 |
+
| 0.2660 | 4800 | 1.4572 | 1.2570 | 0.8408 |
|
| 427 |
+
| 0.2715 | 4900 | 1.2339 | 1.1919 | 0.8423 |
|
| 428 |
+
| 0.2771 | 5000 | 1.2871 | 1.3166 | 0.8398 |
|
| 429 |
+
| 0.2826 | 5100 | 1.3532 | 1.4045 | 0.8360 |
|
| 430 |
+
| 0.2882 | 5200 | 1.2731 | 1.4843 | 0.8384 |
|
| 431 |
+
| 0.2937 | 5300 | 1.3776 | 1.1347 | 0.8423 |
|
| 432 |
+
| 0.2993 | 5400 | 1.2179 | 1.5040 | 0.8373 |
|
| 433 |
+
| 0.3048 | 5500 | 1.41 | 1.2401 | 0.8418 |
|
| 434 |
+
| 0.3103 | 5600 | 1.3901 | 1.1494 | 0.8416 |
|
| 435 |
+
| 0.3159 | 5700 | 1.4007 | 1.2487 | 0.8414 |
|
| 436 |
+
| 0.3214 | 5800 | 1.3444 | 1.4062 | 0.8397 |
|
| 437 |
+
| 0.3270 | 5900 | 1.3671 | 1.3194 | 0.8410 |
|
| 438 |
+
| 0.3325 | 6000 | 1.2401 | 1.2642 | 0.8411 |
|
| 439 |
+
| 0.3380 | 6100 | 1.4102 | 1.3317 | 0.8392 |
|
| 440 |
+
| 0.3436 | 6200 | 1.1672 | 1.0846 | 0.8438 |
|
| 441 |
+
| 0.3491 | 6300 | 1.3595 | 1.2747 | 0.8387 |
|
| 442 |
+
| 0.3547 | 6400 | 1.0956 | 1.4071 | 0.8392 |
|
| 443 |
+
| 0.3602 | 6500 | 1.539 | 1.2683 | 0.8413 |
|
| 444 |
+
| 0.3658 | 6600 | 1.3078 | 1.2173 | 0.8430 |
|
| 445 |
+
| 0.3713 | 6700 | 1.3562 | 1.0733 | 0.8447 |
|
| 446 |
+
| 0.3768 | 6800 | 1.3009 | 1.3561 | 0.8408 |
|
| 447 |
+
| 0.3824 | 6900 | 1.4319 | 1.1958 | 0.8432 |
|
| 448 |
+
| 0.3879 | 7000 | 1.0702 | 1.1325 | 0.8437 |
|
| 449 |
+
| 0.3935 | 7100 | 1.2339 | 0.9852 | 0.8465 |
|
| 450 |
+
| 0.3990 | 7200 | 0.8772 | 1.2658 | 0.8419 |
|
| 451 |
+
| 0.4045 | 7300 | 1.3411 | 1.1585 | 0.8438 |
|
| 452 |
+
| 0.4101 | 7400 | 1.1518 | 1.1572 | 0.8439 |
|
| 453 |
+
| 0.4156 | 7500 | 1.0287 | 0.9960 | 0.8456 |
|
| 454 |
+
| 0.4212 | 7600 | 1.2913 | 1.1595 | 0.8437 |
|
| 455 |
+
| 0.4267 | 7700 | 1.1006 | 1.1575 | 0.8437 |
|
| 456 |
+
| 0.4323 | 7800 | 1.3463 | 1.0478 | 0.8459 |
|
| 457 |
+
| 0.4378 | 7900 | 1.0428 | 1.0495 | 0.8461 |
|
| 458 |
+
| 0.4433 | 8000 | 1.0657 | 1.0442 | 0.8465 |
|
| 459 |
+
| 0.4489 | 8100 | 1.1002 | 1.0223 | 0.8475 |
|
| 460 |
+
| 0.4544 | 8200 | 1.1596 | 1.0066 | 0.8474 |
|
| 461 |
+
| 0.4600 | 8300 | 1.3218 | 1.0403 | 0.8460 |
|
| 462 |
+
| 0.4655 | 8400 | 1.1482 | 1.1177 | 0.8457 |
|
| 463 |
+
| 0.4710 | 8500 | 1.0033 | 1.1743 | 0.8448 |
|
| 464 |
+
| 0.4766 | 8600 | 1.0772 | 1.1071 | 0.8464 |
|
| 465 |
+
| 0.4821 | 8700 | 0.775 | 1.2731 | 0.8438 |
|
| 466 |
+
| 0.4877 | 8800 | 0.8859 | 0.9293 | 0.8491 |
|
| 467 |
+
| 0.4932 | 8900 | 0.7837 | 1.0760 | 0.8462 |
|
| 468 |
+
| 0.4988 | 9000 | 0.7768 | 1.0135 | 0.8470 |
|
| 469 |
+
| 0.5043 | 9100 | 1.0103 | 0.9691 | 0.8477 |
|
| 470 |
+
| 0.5098 | 9200 | 1.0219 | 1.2059 | 0.8441 |
|
| 471 |
+
| 0.5154 | 9300 | 0.9093 | 1.0895 | 0.8461 |
|
| 472 |
+
| 0.5209 | 9400 | 1.0176 | 0.9229 | 0.8489 |
|
| 473 |
+
| 0.5265 | 9500 | 1.3811 | 0.9470 | 0.8483 |
|
| 474 |
+
| 0.5320 | 9600 | 0.8338 | 1.0048 | 0.8477 |
|
| 475 |
+
| 0.5375 | 9700 | 0.7105 | 1.0591 | 0.8464 |
|
| 476 |
+
| 0.5431 | 9800 | 1.0313 | 0.9789 | 0.8482 |
|
| 477 |
+
| 0.5486 | 9900 | 1.0308 | 0.8741 | 0.8499 |
|
| 478 |
+
| 0.5542 | 10000 | 0.7353 | 0.9419 | 0.8482 |
|
| 479 |
+
| 0.5597 | 10100 | 0.7683 | 1.0695 | 0.8473 |
|
| 480 |
+
| 0.5653 | 10200 | 1.1728 | 0.9705 | 0.8494 |
|
| 481 |
+
| 0.5708 | 10300 | 0.8578 | 0.9633 | 0.8493 |
|
| 482 |
+
| 0.5763 | 10400 | 1.0095 | 0.7799 | 0.8514 |
|
| 483 |
+
| 0.5819 | 10500 | 1.0157 | 1.0333 | 0.8485 |
|
| 484 |
+
| 0.5874 | 10600 | 0.8164 | 0.8596 | 0.8509 |
|
| 485 |
+
| 0.5930 | 10700 | 0.9278 | 0.8256 | 0.8516 |
|
| 486 |
+
| 0.5985 | 10800 | 0.5919 | 1.0104 | 0.8493 |
|
| 487 |
+
| 0.6040 | 10900 | 0.6931 | 0.9957 | 0.8492 |
|
| 488 |
+
| 0.6096 | 11000 | 1.1545 | 0.9758 | 0.8494 |
|
| 489 |
+
| 0.6151 | 11100 | 1.1061 | 1.0360 | 0.8493 |
|
| 490 |
+
| 0.6207 | 11200 | 0.7954 | 0.9362 | 0.8509 |
|
| 491 |
+
| 0.6262 | 11300 | 0.6365 | 0.9504 | 0.8511 |
|
| 492 |
+
| 0.6318 | 11400 | 0.992 | 0.8553 | 0.8521 |
|
| 493 |
+
| 0.6373 | 11500 | 0.6971 | 0.8763 | 0.8520 |
|
| 494 |
+
| 0.6428 | 11600 | 0.8162 | 0.9527 | 0.8504 |
|
| 495 |
+
| 0.6484 | 11700 | 0.8973 | 0.8722 | 0.8519 |
|
| 496 |
+
| 0.6539 | 11800 | 0.7652 | 0.9417 | 0.8510 |
|
| 497 |
+
| 0.6595 | 11900 | 0.7305 | 0.8955 | 0.8519 |
|
| 498 |
+
| 0.6650 | 12000 | 0.8555 | 0.9007 | 0.8510 |
|
| 499 |
+
| 0.6705 | 12100 | 0.7165 | 0.7924 | 0.8530 |
|
| 500 |
+
| 0.6761 | 12200 | 0.7939 | 0.8607 | 0.8516 |
|
| 501 |
+
| 0.6816 | 12300 | 0.9873 | 0.7780 | 0.8533 |
|
| 502 |
+
| 0.6872 | 12400 | 0.7197 | 0.9380 | 0.8508 |
|
| 503 |
+
| 0.6927 | 12500 | 1.076 | 0.8041 | 0.8531 |
|
| 504 |
+
| 0.6983 | 12600 | 0.6853 | 0.8800 | 0.8517 |
|
| 505 |
+
| 0.7038 | 12700 | 0.9403 | 0.8181 | 0.8527 |
|
| 506 |
+
| 0.7093 | 12800 | 0.8598 | 0.7641 | 0.8536 |
|
| 507 |
+
| 0.7149 | 12900 | 0.628 | 0.7479 | 0.8540 |
|
| 508 |
+
| 0.7204 | 13000 | 1.0517 | 0.7611 | 0.8536 |
|
| 509 |
+
| 0.7260 | 13100 | 0.5099 | 0.8426 | 0.8521 |
|
| 510 |
+
| 0.7315 | 13200 | 0.751 | 0.8133 | 0.8526 |
|
| 511 |
+
| 0.7370 | 13300 | 0.572 | 0.8344 | 0.8524 |
|
| 512 |
+
| 0.7426 | 13400 | 0.8213 | 0.7869 | 0.8528 |
|
| 513 |
+
| 0.7481 | 13500 | 0.6046 | 0.7810 | 0.8528 |
|
| 514 |
+
| 0.7537 | 13600 | 0.7211 | 0.7502 | 0.8537 |
|
| 515 |
+
| 0.7592 | 13700 | 0.7443 | 0.7398 | 0.8538 |
|
| 516 |
+
| 0.7648 | 13800 | 0.6644 | 0.8257 | 0.8529 |
|
| 517 |
+
| 0.7703 | 13900 | 0.8948 | 0.7271 | 0.8536 |
|
| 518 |
+
| 0.7758 | 14000 | 0.6886 | 0.7607 | 0.8531 |
|
| 519 |
+
| 0.7814 | 14100 | 0.8322 | 0.7143 | 0.8540 |
|
| 520 |
+
| 0.7869 | 14200 | 0.6965 | 0.7270 | 0.8540 |
|
| 521 |
+
| 0.7925 | 14300 | 0.6478 | 0.7368 | 0.8541 |
|
| 522 |
+
| 0.7980 | 14400 | 0.6877 | 0.7690 | 0.8532 |
|
| 523 |
+
| 0.8035 | 14500 | 0.6289 | 0.7316 | 0.8538 |
|
| 524 |
+
| 0.8091 | 14600 | 0.9058 | 0.6514 | 0.8548 |
|
| 525 |
+
| 0.8146 | 14700 | 0.5971 | 0.6980 | 0.8542 |
|
| 526 |
+
| 0.8202 | 14800 | 0.5774 | 0.7124 | 0.8539 |
|
| 527 |
+
| 0.8257 | 14900 | 0.6134 | 0.7480 | 0.8534 |
|
| 528 |
+
| 0.8313 | 15000 | 0.6962 | 0.6284 | 0.8551 |
|
| 529 |
+
| 0.8368 | 15100 | 0.5934 | 0.7099 | 0.8540 |
|
| 530 |
+
| 0.8423 | 15200 | 0.7791 | 0.6925 | 0.8542 |
|
| 531 |
+
| 0.8479 | 15300 | 0.5418 | 0.6774 | 0.8544 |
|
| 532 |
+
| 0.8534 | 15400 | 0.7526 | 0.6380 | 0.8552 |
|
| 533 |
+
| 0.8590 | 15500 | 0.694 | 0.6967 | 0.8543 |
|
| 534 |
+
| 0.8645 | 15600 | 0.5813 | 0.6864 | 0.8543 |
|
| 535 |
+
| 0.8700 | 15700 | 0.726 | 0.6325 | 0.8552 |
|
| 536 |
+
| 0.8756 | 15800 | 0.5094 | 0.6491 | 0.8549 |
|
| 537 |
+
| 0.8811 | 15900 | 0.5728 | 0.6549 | 0.8549 |
|
| 538 |
+
| 0.8867 | 16000 | 0.5272 | 0.6723 | 0.8548 |
|
| 539 |
+
| 0.8922 | 16100 | 0.6896 | 0.6786 | 0.8546 |
|
| 540 |
+
| 0.8978 | 16200 | 0.5666 | 0.6629 | 0.8550 |
|
| 541 |
+
| 0.9033 | 16300 | 0.7312 | 0.6801 | 0.8549 |
|
| 542 |
+
| 0.9088 | 16400 | 0.6451 | 0.6779 | 0.8549 |
|
| 543 |
+
| 0.9144 | 16500 | 0.6572 | 0.6374 | 0.8556 |
|
| 544 |
+
| 0.9199 | 16600 | 0.5052 | 0.6672 | 0.8551 |
|
| 545 |
+
| 0.9255 | 16700 | 0.5395 | 0.6686 | 0.8550 |
|
| 546 |
+
| 0.9310 | 16800 | 0.4715 | 0.6840 | 0.8547 |
|
| 547 |
+
| 0.9365 | 16900 | 0.7149 | 0.6576 | 0.8552 |
|
| 548 |
+
| 0.9421 | 17000 | 0.5066 | 0.6533 | 0.8553 |
|
| 549 |
+
| 0.9476 | 17100 | 0.6382 | 0.6509 | 0.8552 |
|
| 550 |
+
| 0.9532 | 17200 | 0.5585 | 0.6729 | 0.8550 |
|
| 551 |
+
| 0.9587 | 17300 | 0.5953 | 0.6505 | 0.8554 |
|
| 552 |
+
| 0.9643 | 17400 | 0.3545 | 0.6487 | 0.8555 |
|
| 553 |
+
| 0.9698 | 17500 | 0.8031 | 0.6451 | 0.8555 |
|
| 554 |
+
| 0.9753 | 17600 | 0.8531 | 0.6366 | 0.8557 |
|
| 555 |
+
| 0.9809 | 17700 | 0.7154 | 0.6365 | 0.8557 |
|
| 556 |
+
| 0.9864 | 17800 | 0.3339 | 0.6339 | 0.8557 |
|
| 557 |
+
| 0.9920 | 17900 | 0.5858 | 0.6410 | 0.8556 |
|
| 558 |
+
| 0.9975 | 18000 | 0.7509 | 0.6400 | 0.8556 |
|
| 559 |
+
|
| 560 |
+
</details>
|
| 561 |
+
|
| 562 |
+
### Framework Versions
|
| 563 |
+
- Python: 3.11.1
|
| 564 |
+
- Sentence Transformers: 3.3.1
|
| 565 |
+
- Transformers: 4.47.0
|
| 566 |
+
- PyTorch: 2.1.1+cu121
|
| 567 |
+
- Accelerate: 1.2.0
|
| 568 |
+
- Datasets: 2.18.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 |
+
#### CoSENTLoss
|
| 589 |
+
```bibtex
|
| 590 |
+
@online{kexuefm-8847,
|
| 591 |
+
title={CoSENT: A more efficient sentence vector scheme than Sentence-BERT},
|
| 592 |
+
author={Su Jianlin},
|
| 593 |
+
year={2022},
|
| 594 |
+
month={Jan},
|
| 595 |
+
url={https://kexue.fm/archives/8847},
|
| 596 |
+
}
|
| 597 |
+
```
|
| 598 |
+
|
| 599 |
+
<!--
|
| 600 |
+
## Glossary
|
| 601 |
+
|
| 602 |
+
*Clearly define terms in order to be accessible across audiences.*
|
| 603 |
+
-->
|
| 604 |
+
|
| 605 |
+
<!--
|
| 606 |
+
## Model Card Authors
|
| 607 |
+
|
| 608 |
+
*Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
|
| 609 |
+
-->
|
| 610 |
+
|
| 611 |
+
<!--
|
| 612 |
+
## Model Card Contact
|
| 613 |
+
|
| 614 |
+
*Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
|
| 615 |
+
-->
|
config.json
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"_name_or_path": "sentence-transformers/all-mpnet-base-v2",
|
| 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.47.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.47.0",
|
| 5 |
+
"pytorch": "2.1.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:f7e306368f641be132de2af2261e2931594e13f7131198d9e7fbffcb28d3fb0f
|
| 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
|
|
|