|
|
--- |
|
|
license: apache-2.0 |
|
|
language: |
|
|
- en |
|
|
tags: |
|
|
- sentence-transformers |
|
|
- sentence-similarity |
|
|
- feature-extraction |
|
|
base_model: answerdotai/ModernBERT-base |
|
|
widget: |
|
|
- source_sentence: In 1831, interesting novels were written in Paris. |
|
|
sentences: |
|
|
- Hugo and Dumas met in the Opera in Paris in 1831. |
|
|
- Many interesting novels are released in the 21st century. |
|
|
- A new vegan burger is offered at the counter from now on. |
|
|
pipeline_tag: sentence-similarity |
|
|
library_name: sentence-transformers |
|
|
--- |
|
|
A ModernBERT model ([answerdotai/ModernBERT-base](https://huggingface.co/answerdotai/ModernBERT-base)) fine-tuned on NLI and tabular classification datasets using [sentence-transformers](https://sbert.net/). |
|
|
|
|
|
You need `transformers>=4.48.0` to use ModernBERT (or install from source using `pip install git+https://github.com/huggingface/transformers.git`). You might also want to install flash attention: `pip install flash-attn`. |
|
|
|
|
|
Usage: |
|
|
```python |
|
|
from sentence_transformers import SentenceTransformer |
|
|
|
|
|
model = SentenceTransformer("clembi/ModernBERT-base-embed") |
|
|
|
|
|
sentences = [ |
|
|
"bi-directional embedding methods are cool", |
|
|
"I like playing Mario Kart", |
|
|
"They all got into the Mupalupux and drove south.", |
|
|
] |
|
|
|
|
|
embeddings = model.encode(sentences) |
|
|
``` |