Update README.md
Browse files
README.md
CHANGED
|
@@ -60,18 +60,6 @@ widget:
|
|
| 60 |
|
| 61 |
[Recoded Cell Factories](http://m.phys.org/news/2015-09-recoded-cells-factories-proteins.html)
|
| 62 |
| [Reddit](https://www.reddit.com/r/EverythingScience/comments/3krux3/researchers_transform_recoded_cells_into/)'
|
| 63 |
-
- I do not expect things to work out for me.
|
| 64 |
-
- source_sentence: Do you feel sad or unhappy?
|
| 65 |
-
sentences:
|
| 66 |
-
- Me everyday im depressing
|
| 67 |
-
- And now I feel very alone and useless.
|
| 68 |
-
- Sucks that I'm not the only one because others are suffering, but it's nice to
|
| 69 |
-
know I'm not alone.
|
| 70 |
-
- source_sentence: Do you feel sad or unhappy?
|
| 71 |
-
sentences:
|
| 72 |
-
- I cried because I lost not only my money, but because I lost myself.
|
| 73 |
-
- Im not exactly depressed, at least not all of the time.
|
| 74 |
-
- does anyone feel like they cant be sad
|
| 75 |
pipeline_tag: sentence-similarity
|
| 76 |
library_name: sentence-transformers
|
| 77 |
---
|
|
@@ -126,9 +114,9 @@ from sentence_transformers import SentenceTransformer
|
|
| 126 |
model = SentenceTransformer("FritzStack/mpnet_MH_embedding")
|
| 127 |
# Run inference
|
| 128 |
sentences = [
|
| 129 |
-
'
|
| 130 |
-
'
|
| 131 |
-
'
|
| 132 |
]
|
| 133 |
embeddings = model.encode(sentences)
|
| 134 |
print(embeddings.shape)
|
|
@@ -137,9 +125,6 @@ print(embeddings.shape)
|
|
| 137 |
# Get the similarity scores for the embeddings
|
| 138 |
similarities = model.similarity(embeddings, embeddings)
|
| 139 |
print(similarities)
|
| 140 |
-
# tensor([[ 1.0000, 0.7532, -0.4572],
|
| 141 |
-
# [ 0.7532, 1.0000, -0.0545],
|
| 142 |
-
# [-0.4572, -0.0545, 1.0000]])
|
| 143 |
```
|
| 144 |
|
| 145 |
<!--
|
|
@@ -182,28 +167,6 @@ You can finetune this model on your own dataset.
|
|
| 182 |
|
| 183 |
### Training Dataset
|
| 184 |
|
| 185 |
-
#### Unnamed Dataset
|
| 186 |
-
|
| 187 |
-
* Size: 4,615 training samples
|
| 188 |
-
* Columns: <code>anchor</code>, <code>positive</code>, and <code>negative</code>
|
| 189 |
-
* Approximate statistics based on the first 1000 samples:
|
| 190 |
-
| | anchor | positive | negative |
|
| 191 |
-
|:--------|:----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------|
|
| 192 |
-
| type | string | string | string |
|
| 193 |
-
| details | <ul><li>min: 9 tokens</li><li>mean: 13.63 tokens</li><li>max: 17 tokens</li></ul> | <ul><li>min: 5 tokens</li><li>mean: 20.7 tokens</li><li>max: 169 tokens</li></ul> | <ul><li>min: 4 tokens</li><li>mean: 42.11 tokens</li><li>max: 384 tokens</li></ul> |
|
| 194 |
-
* Samples:
|
| 195 |
-
| anchor | positive | negative |
|
| 196 |
-
|:-----------------------------------------|:------------------------------------------|:------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
| 197 |
-
| <code>Do you feel sad or unhappy?</code> | <code>I do not feel sad.</code> | <code>I've been suffering my whole life, and it's currently at its peak :(</code> |
|
| 198 |
-
| <code>Do you feel sad or unhappy?</code> | <code>I feel sad much of the time.</code> | <code>Things will get better, just focus more in the positive rather than the negative</code> |
|
| 199 |
-
| <code>Do you feel sad or unhappy?</code> | <code>I am sad all the time.</code> | <code>That's why I understand I'm terrible, because it's wrong I get annoyed by that, people should do what they want, but I just can't stand being alone.</code> |
|
| 200 |
-
* Loss: [<code>TripletLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#tripletloss) with these parameters:
|
| 201 |
-
```json
|
| 202 |
-
{
|
| 203 |
-
"distance_metric": "TripletDistanceMetric.COSINE",
|
| 204 |
-
"triplet_margin": 0.5
|
| 205 |
-
}
|
| 206 |
-
```
|
| 207 |
|
| 208 |
### Training Hyperparameters
|
| 209 |
#### Non-Default Hyperparameters
|
|
@@ -338,96 +301,6 @@ You can finetune this model on your own dataset.
|
|
| 338 |
|
| 339 |
</details>
|
| 340 |
|
| 341 |
-
### Training Logs
|
| 342 |
-
| Epoch | Step | Training Loss |
|
| 343 |
-
|:------:|:----:|:-------------:|
|
| 344 |
-
| 0.0347 | 10 | 0.3032 |
|
| 345 |
-
| 0.0693 | 20 | 0.2893 |
|
| 346 |
-
| 0.1040 | 30 | 0.2275 |
|
| 347 |
-
| 0.1386 | 40 | 0.1532 |
|
| 348 |
-
| 0.1733 | 50 | 0.1947 |
|
| 349 |
-
| 0.2080 | 60 | 0.1126 |
|
| 350 |
-
| 0.2426 | 70 | 0.1047 |
|
| 351 |
-
| 0.2773 | 80 | 0.1118 |
|
| 352 |
-
| 0.3120 | 90 | 0.0839 |
|
| 353 |
-
| 0.3466 | 100 | 0.1147 |
|
| 354 |
-
| 0.3813 | 110 | 0.111 |
|
| 355 |
-
| 0.4159 | 120 | 0.0754 |
|
| 356 |
-
| 0.4506 | 130 | 0.0964 |
|
| 357 |
-
| 0.4853 | 140 | 0.1269 |
|
| 358 |
-
| 0.5199 | 150 | 0.0795 |
|
| 359 |
-
| 0.5546 | 160 | 0.1042 |
|
| 360 |
-
| 0.5893 | 170 | 0.0797 |
|
| 361 |
-
| 0.6239 | 180 | 0.0685 |
|
| 362 |
-
| 0.6586 | 190 | 0.0819 |
|
| 363 |
-
| 0.6932 | 200 | 0.0802 |
|
| 364 |
-
| 0.7279 | 210 | 0.0934 |
|
| 365 |
-
| 0.7626 | 220 | 0.0865 |
|
| 366 |
-
| 0.7972 | 230 | 0.0731 |
|
| 367 |
-
| 0.8319 | 240 | 0.0486 |
|
| 368 |
-
| 0.8666 | 250 | 0.075 |
|
| 369 |
-
| 0.9012 | 260 | 0.0627 |
|
| 370 |
-
| 0.9359 | 270 | 0.0844 |
|
| 371 |
-
| 0.9705 | 280 | 0.0776 |
|
| 372 |
-
| 1.0035 | 290 | 0.0707 |
|
| 373 |
-
| 1.0381 | 300 | 0.0479 |
|
| 374 |
-
| 1.0728 | 310 | 0.05 |
|
| 375 |
-
| 1.1075 | 320 | 0.0317 |
|
| 376 |
-
| 1.1421 | 330 | 0.0263 |
|
| 377 |
-
| 1.1768 | 340 | 0.0321 |
|
| 378 |
-
| 1.2114 | 350 | 0.0221 |
|
| 379 |
-
| 1.2461 | 360 | 0.0337 |
|
| 380 |
-
| 1.2808 | 370 | 0.0301 |
|
| 381 |
-
| 1.3154 | 380 | 0.034 |
|
| 382 |
-
| 1.3501 | 390 | 0.0379 |
|
| 383 |
-
| 1.3847 | 400 | 0.0489 |
|
| 384 |
-
| 1.4194 | 410 | 0.0303 |
|
| 385 |
-
| 1.4541 | 420 | 0.0263 |
|
| 386 |
-
| 1.4887 | 430 | 0.0342 |
|
| 387 |
-
| 1.5234 | 440 | 0.0328 |
|
| 388 |
-
| 1.5581 | 450 | 0.0431 |
|
| 389 |
-
| 1.5927 | 460 | 0.0472 |
|
| 390 |
-
| 1.6274 | 470 | 0.0353 |
|
| 391 |
-
| 1.6620 | 480 | 0.0389 |
|
| 392 |
-
| 1.6967 | 490 | 0.0216 |
|
| 393 |
-
| 1.7314 | 500 | 0.0351 |
|
| 394 |
-
| 1.7660 | 510 | 0.0386 |
|
| 395 |
-
| 1.8007 | 520 | 0.039 |
|
| 396 |
-
| 1.8354 | 530 | 0.0264 |
|
| 397 |
-
| 1.8700 | 540 | 0.0295 |
|
| 398 |
-
| 1.9047 | 550 | 0.0329 |
|
| 399 |
-
| 1.9393 | 560 | 0.0487 |
|
| 400 |
-
| 1.9740 | 570 | 0.0287 |
|
| 401 |
-
| 2.0069 | 580 | 0.0306 |
|
| 402 |
-
| 2.0416 | 590 | 0.0171 |
|
| 403 |
-
| 2.0763 | 600 | 0.009 |
|
| 404 |
-
| 2.1109 | 610 | 0.017 |
|
| 405 |
-
| 2.1456 | 620 | 0.0252 |
|
| 406 |
-
| 2.1802 | 630 | 0.0123 |
|
| 407 |
-
| 2.2149 | 640 | 0.0144 |
|
| 408 |
-
| 2.2496 | 650 | 0.0187 |
|
| 409 |
-
| 2.2842 | 660 | 0.02 |
|
| 410 |
-
| 2.3189 | 670 | 0.0065 |
|
| 411 |
-
| 2.3536 | 680 | 0.0131 |
|
| 412 |
-
| 2.3882 | 690 | 0.0138 |
|
| 413 |
-
| 2.4229 | 700 | 0.0111 |
|
| 414 |
-
| 2.4575 | 710 | 0.0108 |
|
| 415 |
-
| 2.4922 | 720 | 0.0079 |
|
| 416 |
-
| 2.5269 | 730 | 0.0062 |
|
| 417 |
-
| 2.5615 | 740 | 0.0105 |
|
| 418 |
-
| 2.5962 | 750 | 0.0095 |
|
| 419 |
-
| 2.6308 | 760 | 0.0112 |
|
| 420 |
-
| 2.6655 | 770 | 0.0052 |
|
| 421 |
-
| 2.7002 | 780 | 0.0103 |
|
| 422 |
-
| 2.7348 | 790 | 0.0108 |
|
| 423 |
-
| 2.7695 | 800 | 0.0059 |
|
| 424 |
-
| 2.8042 | 810 | 0.0099 |
|
| 425 |
-
| 2.8388 | 820 | 0.0142 |
|
| 426 |
-
| 2.8735 | 830 | 0.0112 |
|
| 427 |
-
| 2.9081 | 840 | 0.0194 |
|
| 428 |
-
| 2.9428 | 850 | 0.0128 |
|
| 429 |
-
| 2.9775 | 860 | 0.0093 |
|
| 430 |
-
|
| 431 |
|
| 432 |
### Framework Versions
|
| 433 |
- Python: 3.12.12
|
|
|
|
| 60 |
|
| 61 |
[Recoded Cell Factories](http://m.phys.org/news/2015-09-recoded-cells-factories-proteins.html)
|
| 62 |
| [Reddit](https://www.reddit.com/r/EverythingScience/comments/3krux3/researchers_transform_recoded_cells_into/)'
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 63 |
pipeline_tag: sentence-similarity
|
| 64 |
library_name: sentence-transformers
|
| 65 |
---
|
|
|
|
| 114 |
model = SentenceTransformer("FritzStack/mpnet_MH_embedding")
|
| 115 |
# Run inference
|
| 116 |
sentences = [
|
| 117 |
+
'',
|
| 118 |
+
'',
|
| 119 |
+
'',
|
| 120 |
]
|
| 121 |
embeddings = model.encode(sentences)
|
| 122 |
print(embeddings.shape)
|
|
|
|
| 125 |
# Get the similarity scores for the embeddings
|
| 126 |
similarities = model.similarity(embeddings, embeddings)
|
| 127 |
print(similarities)
|
|
|
|
|
|
|
|
|
|
| 128 |
```
|
| 129 |
|
| 130 |
<!--
|
|
|
|
| 167 |
|
| 168 |
### Training Dataset
|
| 169 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 170 |
|
| 171 |
### Training Hyperparameters
|
| 172 |
#### Non-Default Hyperparameters
|
|
|
|
| 301 |
|
| 302 |
</details>
|
| 303 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 304 |
|
| 305 |
### Framework Versions
|
| 306 |
- Python: 3.12.12
|