Sentence Similarity
sentence-transformers
PyTorch
Transformers
xlm-roberta
feature-extraction
text-embeddings-inference
Instructions to use KennethEnevoldsen/dfm-sentence-encoder-medium with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use KennethEnevoldsen/dfm-sentence-encoder-medium with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("KennethEnevoldsen/dfm-sentence-encoder-medium") sentences = [ "That is a happy person", "That is a happy dog", "That is a very happy person", "Today is a sunny day" ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [4, 4] - Transformers
How to use KennethEnevoldsen/dfm-sentence-encoder-medium with Transformers:
# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModel tokenizer = AutoTokenizer.from_pretrained("KennethEnevoldsen/dfm-sentence-encoder-medium") model = AutoModel.from_pretrained("KennethEnevoldsen/dfm-sentence-encoder-medium", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Download pytorch_model.bin from KennethEnevoldsen/dfm-sentence-encoder-medium: direct link, hf CLI and curl.
- Browser
- Download file 498 MB
-
https://huggingface.co/KennethEnevoldsen/dfm-sentence-encoder-medium/resolve/main/pytorch_model.bin
- Command line
-
hf download hf://KennethEnevoldsen/dfm-sentence-encoder-medium/pytorch_model.bin
-
curl -L -o pytorch_model.bin https://huggingface.co/KennethEnevoldsen/dfm-sentence-encoder-medium/resolve/main/pytorch_model.bin
498 MB
- Xet hash:
- 879a5f5a125cfccf357464b98a60cb5e960750bc5b27824e4b30db357ff60d70
- Size of remote file:
- 498 MB
- SHA256:
- 9f7c412b28b7c7c7012d1fe94acc65300c7d49993780b0ec405a24d03abd5688
·
Xet efficiently stores Large Files inside Git, intelligently splitting files into unique chunks and accelerating uploads and downloads. More info.