Text Classification
sentence-transformers
Safetensors
xlm-roberta
cross-encoder
reranker
Generated from Trainer
dataset_size:82796
loss:CrossEntropyLoss
Eval Results (legacy)
text-embeddings-inference
Instructions to use Chimalpopoka/CrossEncoderRanker with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use Chimalpopoka/CrossEncoderRanker with sentence-transformers:
from sentence_transformers import CrossEncoder model = CrossEncoder("Chimalpopoka/CrossEncoderRanker") 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
New version 3
Browse files- README.md +42 -38
- model.safetensors +1 -1
README.md
CHANGED
|
@@ -4,7 +4,7 @@ tags:
|
|
| 4 |
- cross-encoder
|
| 5 |
- reranker
|
| 6 |
- generated_from_trainer
|
| 7 |
-
- dataset_size:
|
| 8 |
- loss:CrossEntropyLoss
|
| 9 |
base_model: deepvk/USER-bge-m3
|
| 10 |
pipeline_tag: text-classification
|
|
@@ -24,13 +24,13 @@ model-index:
|
|
| 24 |
type: softmax_accuracy_eval
|
| 25 |
metrics:
|
| 26 |
- type: f1_macro
|
| 27 |
-
value: 0.
|
| 28 |
name: F1 Macro
|
| 29 |
- type: f1_micro
|
| 30 |
-
value: 0.
|
| 31 |
name: F1 Micro
|
| 32 |
- type: f1_weighted
|
| 33 |
-
value: 0.
|
| 34 |
name: F1 Weighted
|
| 35 |
---
|
| 36 |
|
|
@@ -74,11 +74,11 @@ from sentence_transformers import CrossEncoder
|
|
| 74 |
model = CrossEncoder("Chimalpopoka/CrossEncoderRanker")
|
| 75 |
# Get scores for pairs of texts
|
| 76 |
pairs = [
|
| 77 |
-
['
|
| 78 |
-
['
|
| 79 |
-
['
|
| 80 |
-
['
|
| 81 |
-
['Анти
|
| 82 |
]
|
| 83 |
scores = model.predict(pairs)
|
| 84 |
print(scores.shape)
|
|
@@ -120,9 +120,9 @@ You can finetune this model on your own dataset.
|
|
| 120 |
|
| 121 |
| Metric | Value |
|
| 122 |
|:-------------|:-----------|
|
| 123 |
-
| **f1_macro** | **0.
|
| 124 |
| f1_micro | 0.9742 |
|
| 125 |
-
| f1_weighted | 0.
|
| 126 |
|
| 127 |
<!--
|
| 128 |
## Bias, Risks and Limitations
|
|
@@ -142,19 +142,19 @@ You can finetune this model on your own dataset.
|
|
| 142 |
|
| 143 |
#### Unnamed Dataset
|
| 144 |
|
| 145 |
-
* Size:
|
| 146 |
* Columns: <code>sentence_0</code>, <code>sentence_1</code>, and <code>label</code>
|
| 147 |
* Approximate statistics based on the first 1000 samples:
|
| 148 |
| | sentence_0 | sentence_1 | label |
|
| 149 |
|:--------|:-----------------------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------------------|:------------------------------------------------|
|
| 150 |
| type | string | string | int |
|
| 151 |
-
| details | <ul><li>min:
|
| 152 |
* Samples:
|
| 153 |
-
| sentence_0
|
| 154 |
-
|:----------------------------------------------------------------------------------------------------------------------------
|
| 155 |
-
| <code>
|
| 156 |
-
| <code>
|
| 157 |
-
| <code>
|
| 158 |
* Loss: [<code>CrossEntropyLoss</code>](https://sbert.net/docs/package_reference/cross_encoder/losses.html#crossentropyloss)
|
| 159 |
|
| 160 |
### Training Hyperparameters
|
|
@@ -289,26 +289,30 @@ You can finetune this model on your own dataset.
|
|
| 289 |
### Training Logs
|
| 290 |
| Epoch | Step | Training Loss | softmax_accuracy_eval_f1_macro |
|
| 291 |
|:------:|:-----:|:-------------:|:------------------------------:|
|
| 292 |
-
| 0.
|
| 293 |
-
| 0.
|
| 294 |
-
| 0.
|
| 295 |
-
| 0.
|
| 296 |
-
| 0.
|
| 297 |
-
| 0.
|
| 298 |
-
| 0.
|
| 299 |
-
| 0.
|
| 300 |
-
| 0.
|
| 301 |
-
| 0.
|
| 302 |
-
| 0.
|
| 303 |
-
| 0.
|
| 304 |
-
| 0.
|
| 305 |
-
| 0.
|
| 306 |
-
| 0.
|
| 307 |
-
| 0.
|
| 308 |
-
| 0.
|
| 309 |
-
| 0.
|
| 310 |
-
| 0.
|
| 311 |
-
| 0.
|
|
|
|
|
|
|
|
|
|
|
|
|
| 312 |
|
| 313 |
|
| 314 |
### Framework Versions
|
|
|
|
| 4 |
- cross-encoder
|
| 5 |
- reranker
|
| 6 |
- generated_from_trainer
|
| 7 |
+
- dataset_size:98955
|
| 8 |
- loss:CrossEntropyLoss
|
| 9 |
base_model: deepvk/USER-bge-m3
|
| 10 |
pipeline_tag: text-classification
|
|
|
|
| 24 |
type: softmax_accuracy_eval
|
| 25 |
metrics:
|
| 26 |
- type: f1_macro
|
| 27 |
+
value: 0.9735865814643296
|
| 28 |
name: F1 Macro
|
| 29 |
- type: f1_micro
|
| 30 |
+
value: 0.9742221418234442
|
| 31 |
name: F1 Micro
|
| 32 |
- type: f1_weighted
|
| 33 |
+
value: 0.9741995358864729
|
| 34 |
name: F1 Weighted
|
| 35 |
---
|
| 36 |
|
|
|
|
| 74 |
model = CrossEncoder("Chimalpopoka/CrossEncoderRanker")
|
| 75 |
# Get scores for pairs of texts
|
| 76 |
pairs = [
|
| 77 |
+
['Ультразвуковое исследование фолликулогенеза в режиме 3D/4D, кандидат медицинских наук, профессор, врач-эксперт', 'УЗИ мониторинг фолликулогенеза'],
|
| 78 |
+
['Слива, IgG (F255, ImmunoCAP)', 'Слива, IgG, аллерген - f255. Метод: ImmunoCap'],
|
| 79 |
+
['Проба Реберга (кровь, моча)', 'Микроскопическое исследование синовиальной жидкости'],
|
| 80 |
+
['Йод (анализ на микроэлементы (Метод ИСП-МС))', 'Йод в сыворотке'],
|
| 81 |
+
['Антитела к Варицелла-Зостер(anti-VZV), IgG (Кровь из вены),кол.', 'Грибы рода Candida (C. albicans, C. glabrata, C. krusei, C. parapsilosis, C. tropicalis): Типирование и количественное определение ДНК. Метод: реал-тайм ПЦР в моче'],
|
| 82 |
]
|
| 83 |
scores = model.predict(pairs)
|
| 84 |
print(scores.shape)
|
|
|
|
| 120 |
|
| 121 |
| Metric | Value |
|
| 122 |
|:-------------|:-----------|
|
| 123 |
+
| **f1_macro** | **0.9736** |
|
| 124 |
| f1_micro | 0.9742 |
|
| 125 |
+
| f1_weighted | 0.9742 |
|
| 126 |
|
| 127 |
<!--
|
| 128 |
## Bias, Risks and Limitations
|
|
|
|
| 142 |
|
| 143 |
#### Unnamed Dataset
|
| 144 |
|
| 145 |
+
* Size: 98,955 training samples
|
| 146 |
* Columns: <code>sentence_0</code>, <code>sentence_1</code>, and <code>label</code>
|
| 147 |
* Approximate statistics based on the first 1000 samples:
|
| 148 |
| | sentence_0 | sentence_1 | label |
|
| 149 |
|:--------|:-----------------------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------------------|:------------------------------------------------|
|
| 150 |
| type | string | string | int |
|
| 151 |
+
| details | <ul><li>min: 3 characters</li><li>mean: 67.08 characters</li><li>max: 602 characters</li></ul> | <ul><li>min: 5 characters</li><li>mean: 60.48 characters</li><li>max: 268 characters</li></ul> | <ul><li>0: ~41.70%</li><li>1: ~58.30%</li></ul> |
|
| 152 |
* Samples:
|
| 153 |
+
| sentence_0 | sentence_1 | label |
|
| 154 |
+
|:----------------------------------------------------------------------------------------------------------------------------|:-----------------------------------------------------------------|:---------------|
|
| 155 |
+
| <code>Ультразвуковое исследование фолликулогенеза в режиме 3D/4D, кандидат медицинских наук, профессор, врач-эксперт</code> | <code>УЗИ мониторинг фолликулогенеза</code> | <code>1</code> |
|
| 156 |
+
| <code>Слива, IgG (F255, ImmunoCAP)</code> | <code>Слива, IgG, аллерген - f255. Метод: ImmunoCap</code> | <code>1</code> |
|
| 157 |
+
| <code>Проба Реберга (кровь, моча)</code> | <code>Микроскопическое исследование синовиальной жидкости</code> | <code>0</code> |
|
| 158 |
* Loss: [<code>CrossEntropyLoss</code>](https://sbert.net/docs/package_reference/cross_encoder/losses.html#crossentropyloss)
|
| 159 |
|
| 160 |
### Training Hyperparameters
|
|
|
|
| 289 |
### Training Logs
|
| 290 |
| Epoch | Step | Training Loss | softmax_accuracy_eval_f1_macro |
|
| 291 |
|:------:|:-----:|:-------------:|:------------------------------:|
|
| 292 |
+
| 0.0404 | 500 | 0.5488 | - |
|
| 293 |
+
| 0.0808 | 1000 | 0.2437 | - |
|
| 294 |
+
| 0.1213 | 1500 | 0.2366 | - |
|
| 295 |
+
| 0.1617 | 2000 | 0.1794 | 0.9631 |
|
| 296 |
+
| 0.2021 | 2500 | 0.2134 | - |
|
| 297 |
+
| 0.2425 | 3000 | 0.1922 | - |
|
| 298 |
+
| 0.2829 | 3500 | 0.1766 | - |
|
| 299 |
+
| 0.3234 | 4000 | 0.1651 | 0.9618 |
|
| 300 |
+
| 0.3638 | 4500 | 0.1931 | - |
|
| 301 |
+
| 0.4042 | 5000 | 0.1659 | - |
|
| 302 |
+
| 0.4446 | 5500 | 0.1706 | - |
|
| 303 |
+
| 0.4850 | 6000 | 0.1605 | 0.9663 |
|
| 304 |
+
| 0.5255 | 6500 | 0.1676 | - |
|
| 305 |
+
| 0.5659 | 7000 | 0.1684 | - |
|
| 306 |
+
| 0.6063 | 7500 | 0.1469 | - |
|
| 307 |
+
| 0.6467 | 8000 | 0.1616 | 0.9716 |
|
| 308 |
+
| 0.6871 | 8500 | 0.1507 | - |
|
| 309 |
+
| 0.7276 | 9000 | 0.1396 | - |
|
| 310 |
+
| 0.7680 | 9500 | 0.1285 | - |
|
| 311 |
+
| 0.8084 | 10000 | 0.1504 | 0.9735 |
|
| 312 |
+
| 0.8488 | 10500 | 0.1507 | - |
|
| 313 |
+
| 0.8892 | 11000 | 0.1346 | - |
|
| 314 |
+
| 0.9297 | 11500 | 0.119 | - |
|
| 315 |
+
| 0.9701 | 12000 | 0.1144 | 0.9736 |
|
| 316 |
|
| 317 |
|
| 318 |
### Framework Versions
|
model.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 1436163192
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:84bc05b19f72711914bb01a640d46161d4bda991bb51c7fb7933d5def80c282c
|
| 3 |
size 1436163192
|