Sentence Similarity
sentence-transformers
ONNX
Safetensors
Transformers.js
gte
feature-extraction
mteb
arctic
snowflake-arctic-embed
custom_code
Eval Results (legacy)
Eval Results
Instructions to use Snowflake/snowflake-arctic-embed-m-v2.0 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use Snowflake/snowflake-arctic-embed-m-v2.0 with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("Snowflake/snowflake-arctic-embed-m-v2.0", trust_remote_code=True) sentences = [ "The weather is lovely today.", "It's so sunny outside!", "He drove to the stadium." ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [3, 3] - Transformers.js
How to use Snowflake/snowflake-arctic-embed-m-v2.0 with Transformers.js:
// npm i @huggingface/transformers import { pipeline } from '@huggingface/transformers'; // Allocate pipeline const pipe = await pipeline('sentence-similarity', 'Snowflake/snowflake-arctic-embed-m-v2.0'); - Notebooks
- Google Colab
- Kaggle
Integrate with Sentence Transformers
#3
by tomaarsen HF Staff - opened
Hello!
Pull Request overview
- Integrate with Sentence Transformers
Details
I noticed that some files were missing, meaning that some the Sentence Transformers snippet didn't work well. With these changes in place, everything should work.
I do want to note this issue: https://huggingface.co/Snowflake/snowflake-arctic-embed-l-v2.0/discussions/1
If the prompt is normalized, then this PR and transformers get the same results.
- Tom Aarsen
tomaarsen changed pull request status to open
pxyu changed pull request status to merged