Text Ranking
sentence-transformers
Safetensors
xlm-roberta
cross-encoder
Generated from Trainer
dataset_size:82744
loss:MultipleNegativesRankingLoss
text-embeddings-inference
Instructions to use foochun/bge-reranker-ft with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use foochun/bge-reranker-ft with sentence-transformers:
from sentence_transformers import CrossEncoder model = CrossEncoder("foochun/bge-reranker-ft") query = "Which planet is known as the Red Planet?" passages = [ "Venus is often called Earth's twin because of its similar size and proximity.", "Mars, known for its reddish appearance, is often referred to as the Red Planet.", "Jupiter, the largest planet in our solar system, has a prominent red spot.", "Saturn, famous for its rings, is sometimes mistaken for the Red Planet." ] scores = model.predict([(query, passage) for passage in passages]) print(scores) - Notebooks
- Google Colab
- Kaggle
Finetuned Reranker
Browse files- .gitattributes +1 -0
- README.md +367 -0
- config.json +37 -0
- model.safetensors +3 -0
- special_tokens_map.json +51 -0
- tokenizer.json +3 -0
- tokenizer_config.json +63 -0
.gitattributes
CHANGED
|
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
tokenizer.json filter=lfs diff=lfs merge=lfs -text
|
README.md
ADDED
|
@@ -0,0 +1,367 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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+
tags:
|
| 3 |
+
- sentence-transformers
|
| 4 |
+
- cross-encoder
|
| 5 |
+
- generated_from_trainer
|
| 6 |
+
- dataset_size:32380
|
| 7 |
+
- loss:BinaryCrossEntropyLoss
|
| 8 |
+
base_model: BAAI/bge-reranker-base
|
| 9 |
+
pipeline_tag: text-ranking
|
| 10 |
+
library_name: sentence-transformers
|
| 11 |
+
metrics:
|
| 12 |
+
- pearson
|
| 13 |
+
- spearman
|
| 14 |
+
model-index:
|
| 15 |
+
- name: CrossEncoder based on BAAI/bge-reranker-base
|
| 16 |
+
results:
|
| 17 |
+
- task:
|
| 18 |
+
type: cross-encoder-correlation
|
| 19 |
+
name: Cross Encoder Correlation
|
| 20 |
+
dataset:
|
| 21 |
+
name: name similarity
|
| 22 |
+
type: name_similarity
|
| 23 |
+
metrics:
|
| 24 |
+
- type: pearson
|
| 25 |
+
value: 0.9803135847456451
|
| 26 |
+
name: Pearson
|
| 27 |
+
- type: spearman
|
| 28 |
+
value: 0.975407488053043
|
| 29 |
+
name: Spearman
|
| 30 |
+
---
|
| 31 |
+
|
| 32 |
+
# CrossEncoder based on BAAI/bge-reranker-base
|
| 33 |
+
|
| 34 |
+
This is a [Cross Encoder](https://www.sbert.net/docs/cross_encoder/usage/usage.html) model finetuned from [BAAI/bge-reranker-base](https://huggingface.co/BAAI/bge-reranker-base) using the [sentence-transformers](https://www.SBERT.net) library. It computes scores for pairs of texts, which can be used for text reranking and semantic search.
|
| 35 |
+
|
| 36 |
+
## Model Details
|
| 37 |
+
|
| 38 |
+
### Model Description
|
| 39 |
+
- **Model Type:** Cross Encoder
|
| 40 |
+
- **Base model:** [BAAI/bge-reranker-base](https://huggingface.co/BAAI/bge-reranker-base) <!-- at revision 2cfc18c9415c912f9d8155881c133215df768a70 -->
|
| 41 |
+
- **Maximum Sequence Length:** 512 tokens
|
| 42 |
+
- **Number of Output Labels:** 1 label
|
| 43 |
+
<!-- - **Training Dataset:** Unknown -->
|
| 44 |
+
<!-- - **Language:** Unknown -->
|
| 45 |
+
<!-- - **License:** Unknown -->
|
| 46 |
+
|
| 47 |
+
### Model Sources
|
| 48 |
+
|
| 49 |
+
- **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
|
| 50 |
+
- **Documentation:** [Cross Encoder Documentation](https://www.sbert.net/docs/cross_encoder/usage/usage.html)
|
| 51 |
+
- **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
|
| 52 |
+
- **Hugging Face:** [Cross Encoders on Hugging Face](https://huggingface.co/models?library=sentence-transformers&other=cross-encoder)
|
| 53 |
+
|
| 54 |
+
## Usage
|
| 55 |
+
|
| 56 |
+
### Direct Usage (Sentence Transformers)
|
| 57 |
+
|
| 58 |
+
First install the Sentence Transformers library:
|
| 59 |
+
|
| 60 |
+
```bash
|
| 61 |
+
pip install -U sentence-transformers
|
| 62 |
+
```
|
| 63 |
+
|
| 64 |
+
Then you can load this model and run inference.
|
| 65 |
+
```python
|
| 66 |
+
from sentence_transformers import CrossEncoder
|
| 67 |
+
|
| 68 |
+
# Download from the 🤗 Hub
|
| 69 |
+
model = CrossEncoder("foochun/bge-reranker-ft")
|
| 70 |
+
# Get scores for pairs of texts
|
| 71 |
+
pairs = [
|
| 72 |
+
['zach toh zhen bing', 'zach toh zhen bing'],
|
| 73 |
+
['zach yap bing sheng', 'yap bing sheng zach'],
|
| 74 |
+
['carmen chia zhen meng', 'carmen zhen chia meng'],
|
| 75 |
+
['carmen lau zhen bing', 'carmen zhen bing lau'],
|
| 76 |
+
['ajith s/o sockalingam', 'sockalingam ajith'],
|
| 77 |
+
]
|
| 78 |
+
scores = model.predict(pairs)
|
| 79 |
+
print(scores.shape)
|
| 80 |
+
# (5,)
|
| 81 |
+
|
| 82 |
+
# Or rank different texts based on similarity to a single text
|
| 83 |
+
ranks = model.rank(
|
| 84 |
+
'zach toh zhen bing',
|
| 85 |
+
[
|
| 86 |
+
'zach toh zhen bing',
|
| 87 |
+
'yap bing sheng zach',
|
| 88 |
+
'carmen zhen chia meng',
|
| 89 |
+
'carmen zhen bing lau',
|
| 90 |
+
'sockalingam ajith',
|
| 91 |
+
]
|
| 92 |
+
)
|
| 93 |
+
# [{'corpus_id': ..., 'score': ...}, {'corpus_id': ..., 'score': ...}, ...]
|
| 94 |
+
```
|
| 95 |
+
|
| 96 |
+
<!--
|
| 97 |
+
### Direct Usage (Transformers)
|
| 98 |
+
|
| 99 |
+
<details><summary>Click to see the direct usage in Transformers</summary>
|
| 100 |
+
|
| 101 |
+
</details>
|
| 102 |
+
-->
|
| 103 |
+
|
| 104 |
+
<!--
|
| 105 |
+
### Downstream Usage (Sentence Transformers)
|
| 106 |
+
|
| 107 |
+
You can finetune this model on your own dataset.
|
| 108 |
+
|
| 109 |
+
<details><summary>Click to expand</summary>
|
| 110 |
+
|
| 111 |
+
</details>
|
| 112 |
+
-->
|
| 113 |
+
|
| 114 |
+
<!--
|
| 115 |
+
### Out-of-Scope Use
|
| 116 |
+
|
| 117 |
+
*List how the model may foreseeably be misused and address what users ought not to do with the model.*
|
| 118 |
+
-->
|
| 119 |
+
|
| 120 |
+
## Evaluation
|
| 121 |
+
|
| 122 |
+
### Metrics
|
| 123 |
+
|
| 124 |
+
#### Cross Encoder Correlation
|
| 125 |
+
|
| 126 |
+
* Dataset: `name_similarity`
|
| 127 |
+
* Evaluated with [<code>CECorrelationEvaluator</code>](https://sbert.net/docs/package_reference/cross_encoder/evaluation.html#sentence_transformers.cross_encoder.evaluation.CECorrelationEvaluator)
|
| 128 |
+
|
| 129 |
+
| Metric | Value |
|
| 130 |
+
|:-------------|:-----------|
|
| 131 |
+
| pearson | 0.9803 |
|
| 132 |
+
| **spearman** | **0.9754** |
|
| 133 |
+
|
| 134 |
+
<!--
|
| 135 |
+
## Bias, Risks and Limitations
|
| 136 |
+
|
| 137 |
+
*What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
|
| 138 |
+
-->
|
| 139 |
+
|
| 140 |
+
<!--
|
| 141 |
+
### Recommendations
|
| 142 |
+
|
| 143 |
+
*What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
|
| 144 |
+
-->
|
| 145 |
+
|
| 146 |
+
## Training Details
|
| 147 |
+
|
| 148 |
+
### Training Dataset
|
| 149 |
+
|
| 150 |
+
#### Unnamed Dataset
|
| 151 |
+
|
| 152 |
+
* Size: 32,380 training samples
|
| 153 |
+
* Columns: <code>sentence_0</code>, <code>sentence_1</code>, and <code>label</code>
|
| 154 |
+
* Approximate statistics based on the first 1000 samples:
|
| 155 |
+
| | sentence_0 | sentence_1 | label |
|
| 156 |
+
|:--------|:----------------------------------------------------------------------------------------------|:----------------------------------------------------------------------------------------------|:----------------------------------------------------------------|
|
| 157 |
+
| type | string | string | float |
|
| 158 |
+
| details | <ul><li>min: 10 characters</li><li>mean: 19.2 characters</li><li>max: 43 characters</li></ul> | <ul><li>min: 9 characters</li><li>mean: 17.93 characters</li><li>max: 40 characters</li></ul> | <ul><li>min: -0.3</li><li>mean: 0.53</li><li>max: 1.0</li></ul> |
|
| 159 |
+
* Samples:
|
| 160 |
+
| sentence_0 | sentence_1 | label |
|
| 161 |
+
|:-----------------------------------|:-----------------------------------|:--------------------------------|
|
| 162 |
+
| <code>zach toh zhen bing</code> | <code>zach toh zhen bing</code> | <code>0.9999998211860657</code> |
|
| 163 |
+
| <code>zach yap bing sheng</code> | <code>yap bing sheng zach</code> | <code>0.9400546550750732</code> |
|
| 164 |
+
| <code>carmen chia zhen meng</code> | <code>carmen zhen chia meng</code> | <code>0.17237488925457</code> |
|
| 165 |
+
* Loss: [<code>BinaryCrossEntropyLoss</code>](https://sbert.net/docs/package_reference/cross_encoder/losses.html#binarycrossentropyloss) with these parameters:
|
| 166 |
+
```json
|
| 167 |
+
{
|
| 168 |
+
"activation_fn": "torch.nn.modules.linear.Identity",
|
| 169 |
+
"pos_weight": null
|
| 170 |
+
}
|
| 171 |
+
```
|
| 172 |
+
|
| 173 |
+
### Training Hyperparameters
|
| 174 |
+
#### Non-Default Hyperparameters
|
| 175 |
+
|
| 176 |
+
- `eval_strategy`: steps
|
| 177 |
+
- `per_device_train_batch_size`: 16
|
| 178 |
+
- `per_device_eval_batch_size`: 16
|
| 179 |
+
- `num_train_epochs`: 4
|
| 180 |
+
|
| 181 |
+
#### All Hyperparameters
|
| 182 |
+
<details><summary>Click to expand</summary>
|
| 183 |
+
|
| 184 |
+
- `overwrite_output_dir`: False
|
| 185 |
+
- `do_predict`: False
|
| 186 |
+
- `eval_strategy`: steps
|
| 187 |
+
- `prediction_loss_only`: True
|
| 188 |
+
- `per_device_train_batch_size`: 16
|
| 189 |
+
- `per_device_eval_batch_size`: 16
|
| 190 |
+
- `per_gpu_train_batch_size`: None
|
| 191 |
+
- `per_gpu_eval_batch_size`: None
|
| 192 |
+
- `gradient_accumulation_steps`: 1
|
| 193 |
+
- `eval_accumulation_steps`: None
|
| 194 |
+
- `torch_empty_cache_steps`: None
|
| 195 |
+
- `learning_rate`: 5e-05
|
| 196 |
+
- `weight_decay`: 0.0
|
| 197 |
+
- `adam_beta1`: 0.9
|
| 198 |
+
- `adam_beta2`: 0.999
|
| 199 |
+
- `adam_epsilon`: 1e-08
|
| 200 |
+
- `max_grad_norm`: 1
|
| 201 |
+
- `num_train_epochs`: 4
|
| 202 |
+
- `max_steps`: -1
|
| 203 |
+
- `lr_scheduler_type`: linear
|
| 204 |
+
- `lr_scheduler_kwargs`: {}
|
| 205 |
+
- `warmup_ratio`: 0.0
|
| 206 |
+
- `warmup_steps`: 0
|
| 207 |
+
- `log_level`: passive
|
| 208 |
+
- `log_level_replica`: warning
|
| 209 |
+
- `log_on_each_node`: True
|
| 210 |
+
- `logging_nan_inf_filter`: True
|
| 211 |
+
- `save_safetensors`: True
|
| 212 |
+
- `save_on_each_node`: False
|
| 213 |
+
- `save_only_model`: False
|
| 214 |
+
- `restore_callback_states_from_checkpoint`: False
|
| 215 |
+
- `no_cuda`: False
|
| 216 |
+
- `use_cpu`: False
|
| 217 |
+
- `use_mps_device`: False
|
| 218 |
+
- `seed`: 42
|
| 219 |
+
- `data_seed`: None
|
| 220 |
+
- `jit_mode_eval`: False
|
| 221 |
+
- `use_ipex`: False
|
| 222 |
+
- `bf16`: False
|
| 223 |
+
- `fp16`: False
|
| 224 |
+
- `fp16_opt_level`: O1
|
| 225 |
+
- `half_precision_backend`: auto
|
| 226 |
+
- `bf16_full_eval`: False
|
| 227 |
+
- `fp16_full_eval`: False
|
| 228 |
+
- `tf32`: None
|
| 229 |
+
- `local_rank`: 0
|
| 230 |
+
- `ddp_backend`: None
|
| 231 |
+
- `tpu_num_cores`: None
|
| 232 |
+
- `tpu_metrics_debug`: False
|
| 233 |
+
- `debug`: []
|
| 234 |
+
- `dataloader_drop_last`: False
|
| 235 |
+
- `dataloader_num_workers`: 0
|
| 236 |
+
- `dataloader_prefetch_factor`: None
|
| 237 |
+
- `past_index`: -1
|
| 238 |
+
- `disable_tqdm`: False
|
| 239 |
+
- `remove_unused_columns`: True
|
| 240 |
+
- `label_names`: None
|
| 241 |
+
- `load_best_model_at_end`: False
|
| 242 |
+
- `ignore_data_skip`: False
|
| 243 |
+
- `fsdp`: []
|
| 244 |
+
- `fsdp_min_num_params`: 0
|
| 245 |
+
- `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
|
| 246 |
+
- `tp_size`: 0
|
| 247 |
+
- `fsdp_transformer_layer_cls_to_wrap`: None
|
| 248 |
+
- `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
|
| 249 |
+
- `deepspeed`: None
|
| 250 |
+
- `label_smoothing_factor`: 0.0
|
| 251 |
+
- `optim`: adamw_torch
|
| 252 |
+
- `optim_args`: None
|
| 253 |
+
- `adafactor`: False
|
| 254 |
+
- `group_by_length`: False
|
| 255 |
+
- `length_column_name`: length
|
| 256 |
+
- `ddp_find_unused_parameters`: None
|
| 257 |
+
- `ddp_bucket_cap_mb`: None
|
| 258 |
+
- `ddp_broadcast_buffers`: False
|
| 259 |
+
- `dataloader_pin_memory`: True
|
| 260 |
+
- `dataloader_persistent_workers`: False
|
| 261 |
+
- `skip_memory_metrics`: True
|
| 262 |
+
- `use_legacy_prediction_loop`: False
|
| 263 |
+
- `push_to_hub`: False
|
| 264 |
+
- `resume_from_checkpoint`: None
|
| 265 |
+
- `hub_model_id`: None
|
| 266 |
+
- `hub_strategy`: every_save
|
| 267 |
+
- `hub_private_repo`: None
|
| 268 |
+
- `hub_always_push`: False
|
| 269 |
+
- `gradient_checkpointing`: False
|
| 270 |
+
- `gradient_checkpointing_kwargs`: None
|
| 271 |
+
- `include_inputs_for_metrics`: False
|
| 272 |
+
- `include_for_metrics`: []
|
| 273 |
+
- `eval_do_concat_batches`: True
|
| 274 |
+
- `fp16_backend`: auto
|
| 275 |
+
- `push_to_hub_model_id`: None
|
| 276 |
+
- `push_to_hub_organization`: None
|
| 277 |
+
- `mp_parameters`:
|
| 278 |
+
- `auto_find_batch_size`: False
|
| 279 |
+
- `full_determinism`: False
|
| 280 |
+
- `torchdynamo`: None
|
| 281 |
+
- `ray_scope`: last
|
| 282 |
+
- `ddp_timeout`: 1800
|
| 283 |
+
- `torch_compile`: False
|
| 284 |
+
- `torch_compile_backend`: None
|
| 285 |
+
- `torch_compile_mode`: None
|
| 286 |
+
- `include_tokens_per_second`: False
|
| 287 |
+
- `include_num_input_tokens_seen`: False
|
| 288 |
+
- `neftune_noise_alpha`: None
|
| 289 |
+
- `optim_target_modules`: None
|
| 290 |
+
- `batch_eval_metrics`: False
|
| 291 |
+
- `eval_on_start`: False
|
| 292 |
+
- `use_liger_kernel`: False
|
| 293 |
+
- `eval_use_gather_object`: False
|
| 294 |
+
- `average_tokens_across_devices`: False
|
| 295 |
+
- `prompts`: None
|
| 296 |
+
- `batch_sampler`: batch_sampler
|
| 297 |
+
- `multi_dataset_batch_sampler`: proportional
|
| 298 |
+
|
| 299 |
+
</details>
|
| 300 |
+
|
| 301 |
+
### Training Logs
|
| 302 |
+
| Epoch | Step | Training Loss | name_similarity_spearman |
|
| 303 |
+
|:------:|:----:|:-------------:|:------------------------:|
|
| 304 |
+
| 0.2470 | 500 | 0.4855 | 0.9288 |
|
| 305 |
+
| 0.4941 | 1000 | 0.361 | 0.9507 |
|
| 306 |
+
| 0.7411 | 1500 | 0.3367 | 0.9563 |
|
| 307 |
+
| 0.9881 | 2000 | 0.3398 | 0.9633 |
|
| 308 |
+
| 1.0 | 2024 | - | 0.9636 |
|
| 309 |
+
| 1.2352 | 2500 | 0.3286 | 0.9650 |
|
| 310 |
+
| 1.4822 | 3000 | 0.3267 | 0.9685 |
|
| 311 |
+
| 1.7292 | 3500 | 0.315 | 0.9702 |
|
| 312 |
+
| 1.9763 | 4000 | 0.3236 | 0.9719 |
|
| 313 |
+
| 2.0 | 4048 | - | 0.9719 |
|
| 314 |
+
| 2.2233 | 4500 | 0.3081 | 0.9727 |
|
| 315 |
+
| 2.4704 | 5000 | 0.3172 | 0.9732 |
|
| 316 |
+
| 2.7174 | 5500 | 0.3121 | 0.9738 |
|
| 317 |
+
| 2.9644 | 6000 | 0.3037 | 0.9745 |
|
| 318 |
+
| 3.0 | 6072 | - | 0.9745 |
|
| 319 |
+
| 3.2115 | 6500 | 0.3105 | 0.9745 |
|
| 320 |
+
| 3.4585 | 7000 | 0.2965 | 0.9750 |
|
| 321 |
+
| 3.7055 | 7500 | 0.3031 | 0.9751 |
|
| 322 |
+
| 3.9526 | 8000 | 0.2998 | 0.9754 |
|
| 323 |
+
|
| 324 |
+
|
| 325 |
+
### Framework Versions
|
| 326 |
+
- Python: 3.11.9
|
| 327 |
+
- Sentence Transformers: 4.1.0
|
| 328 |
+
- Transformers: 4.51.3
|
| 329 |
+
- PyTorch: 2.6.0+cu124
|
| 330 |
+
- Accelerate: 1.6.0
|
| 331 |
+
- Datasets: 3.5.1
|
| 332 |
+
- Tokenizers: 0.21.1
|
| 333 |
+
|
| 334 |
+
## Citation
|
| 335 |
+
|
| 336 |
+
### BibTeX
|
| 337 |
+
|
| 338 |
+
#### Sentence Transformers
|
| 339 |
+
```bibtex
|
| 340 |
+
@inproceedings{reimers-2019-sentence-bert,
|
| 341 |
+
title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
|
| 342 |
+
author = "Reimers, Nils and Gurevych, Iryna",
|
| 343 |
+
booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
|
| 344 |
+
month = "11",
|
| 345 |
+
year = "2019",
|
| 346 |
+
publisher = "Association for Computational Linguistics",
|
| 347 |
+
url = "https://arxiv.org/abs/1908.10084",
|
| 348 |
+
}
|
| 349 |
+
```
|
| 350 |
+
|
| 351 |
+
<!--
|
| 352 |
+
## Glossary
|
| 353 |
+
|
| 354 |
+
*Clearly define terms in order to be accessible across audiences.*
|
| 355 |
+
-->
|
| 356 |
+
|
| 357 |
+
<!--
|
| 358 |
+
## Model Card Authors
|
| 359 |
+
|
| 360 |
+
*Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
|
| 361 |
+
-->
|
| 362 |
+
|
| 363 |
+
<!--
|
| 364 |
+
## Model Card Contact
|
| 365 |
+
|
| 366 |
+
*Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
|
| 367 |
+
-->
|
config.json
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"architectures": [
|
| 3 |
+
"XLMRobertaForSequenceClassification"
|
| 4 |
+
],
|
| 5 |
+
"attention_probs_dropout_prob": 0.1,
|
| 6 |
+
"bos_token_id": 0,
|
| 7 |
+
"classifier_dropout": null,
|
| 8 |
+
"eos_token_id": 2,
|
| 9 |
+
"hidden_act": "gelu",
|
| 10 |
+
"hidden_dropout_prob": 0.1,
|
| 11 |
+
"hidden_size": 768,
|
| 12 |
+
"id2label": {
|
| 13 |
+
"0": "LABEL_0"
|
| 14 |
+
},
|
| 15 |
+
"initializer_range": 0.02,
|
| 16 |
+
"intermediate_size": 3072,
|
| 17 |
+
"label2id": {
|
| 18 |
+
"LABEL_0": 0
|
| 19 |
+
},
|
| 20 |
+
"layer_norm_eps": 1e-05,
|
| 21 |
+
"max_position_embeddings": 514,
|
| 22 |
+
"model_type": "xlm-roberta",
|
| 23 |
+
"num_attention_heads": 12,
|
| 24 |
+
"num_hidden_layers": 12,
|
| 25 |
+
"output_past": true,
|
| 26 |
+
"pad_token_id": 1,
|
| 27 |
+
"position_embedding_type": "absolute",
|
| 28 |
+
"sentence_transformers": {
|
| 29 |
+
"activation_fn": "torch.nn.modules.activation.Sigmoid",
|
| 30 |
+
"version": "4.1.0"
|
| 31 |
+
},
|
| 32 |
+
"torch_dtype": "float32",
|
| 33 |
+
"transformers_version": "4.51.3",
|
| 34 |
+
"type_vocab_size": 1,
|
| 35 |
+
"use_cache": true,
|
| 36 |
+
"vocab_size": 250002
|
| 37 |
+
}
|
model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:df3df7ab41b95c380ef7801f7bd9085b327e2cc9279234c80b8445cff0540214
|
| 3 |
+
size 1112201932
|
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": true,
|
| 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
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:4a8d0b7573869188be52cca17a27a84f3cfbc0a5536c28ee1eca82903e8c68c6
|
| 3 |
+
size 17083051
|
tokenizer_config.json
ADDED
|
@@ -0,0 +1,63 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 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": false,
|
| 31 |
+
"rstrip": false,
|
| 32 |
+
"single_word": false,
|
| 33 |
+
"special": true
|
| 34 |
+
},
|
| 35 |
+
"250001": {
|
| 36 |
+
"content": "<mask>",
|
| 37 |
+
"lstrip": true,
|
| 38 |
+
"normalized": true,
|
| 39 |
+
"rstrip": false,
|
| 40 |
+
"single_word": false,
|
| 41 |
+
"special": true
|
| 42 |
+
}
|
| 43 |
+
},
|
| 44 |
+
"bos_token": "<s>",
|
| 45 |
+
"clean_up_tokenization_spaces": true,
|
| 46 |
+
"cls_token": "<s>",
|
| 47 |
+
"eos_token": "</s>",
|
| 48 |
+
"extra_special_tokens": {},
|
| 49 |
+
"mask_token": "<mask>",
|
| 50 |
+
"max_length": 512,
|
| 51 |
+
"model_max_length": 512,
|
| 52 |
+
"pad_to_multiple_of": null,
|
| 53 |
+
"pad_token": "<pad>",
|
| 54 |
+
"pad_token_type_id": 0,
|
| 55 |
+
"padding_side": "right",
|
| 56 |
+
"sep_token": "</s>",
|
| 57 |
+
"sp_model_kwargs": {},
|
| 58 |
+
"stride": 0,
|
| 59 |
+
"tokenizer_class": "XLMRobertaTokenizerFast",
|
| 60 |
+
"truncation_side": "right",
|
| 61 |
+
"truncation_strategy": "longest_first",
|
| 62 |
+
"unk_token": "<unk>"
|
| 63 |
+
}
|