Sentence Similarity
sentence-transformers
Safetensors
English
modernbert
feature-extraction
Generated from Trainer
dataset_size:19139199
loss:MatryoshkaLoss
loss:MultipleNegativesRankingLoss
Eval Results (legacy)
text-embeddings-inference
Instructions to use estrogen/ModernBERT-base-marco with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use estrogen/ModernBERT-base-marco with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("estrogen/ModernBERT-base-marco") sentences = [ "[unused0]what period do we live in", "[unused1]The answer depends on what you want in a cruise experience. If youâre interested in lively entertainment, drinking and parties, and crazy excitement for more festive cruise experience, and the best time to go on a Caribbean cruise is between mid February through much of March.", "[unused1]Earth is currently in the Quaternary Period of the Cenozoic Era.", "[unused1]If we did not live in a structured society with other people, laws would not be necessary. We would simply do as we please, with little regard for others. But ever since individuals began to associate with other people -- to live in society --laws have been the glue that has kept society together.lmost everything we do is governed by some set of rules. There are rules for games, for social clubs, for sports and for adults in the workplace. There are also rules imposed by morality and custom that play an important role in telling us what we should and should not do." ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [4, 4] - Notebooks
- Google Colab
- Kaggle
| [ | |
| { | |
| "idx": 0, | |
| "name": "0", | |
| "path": "", | |
| "type": "sentence_transformers.models.Transformer" | |
| }, | |
| { | |
| "idx": 1, | |
| "name": "1", | |
| "path": "1_Pooling", | |
| "type": "sentence_transformers.models.Pooling" | |
| } | |
| ] |