Sentence Similarity
sentence-transformers
ONNX
Safetensors
OpenVINO
modernbert
feature-extraction
Generated from Trainer
dataset_size:36864
loss:MatryoshkaLoss
loss:CachedMultipleNegativesRankingLoss
text-embeddings-inference
Instructions to use redis/langcache-embed-v2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use redis/langcache-embed-v2 with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("redis/langcache-embed-v2") sentences = [ "What are civil cases and what are some examples?", "What are criminal cases and what are no examples?", "Civil cases involve disputes between individuals or organizations, typically seeking monetary compensation or specific performance, and *do not* include criminal prosecutions by the government.", "Criminal cases involve disputes between individuals or organizations, seeking monetary damages or specific performance, while civil cases concern offenses against the state punishable by imprisonment.", "What are some examples of civil cases?" ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [5, 5] - Inference
- Notebooks
- Google Colab
- Kaggle
Update README.md
Browse fileschange `"waris-gill/langcache-embed-v2"` to `"redis/langcache-embed-v2"`
README.md
CHANGED
|
@@ -98,7 +98,7 @@ Then you can load this model and run inference.
|
|
| 98 |
from sentence_transformers import SentenceTransformer
|
| 99 |
|
| 100 |
# Download from the 🤗 Hub
|
| 101 |
-
model = SentenceTransformer("
|
| 102 |
# Run inference
|
| 103 |
sentences = [
|
| 104 |
'What are some examples of crimes understood as a moral turpitude?',
|
|
|
|
| 98 |
from sentence_transformers import SentenceTransformer
|
| 99 |
|
| 100 |
# Download from the 🤗 Hub
|
| 101 |
+
model = SentenceTransformer("redis/langcache-embed-v2")
|
| 102 |
# Run inference
|
| 103 |
sentences = [
|
| 104 |
'What are some examples of crimes understood as a moral turpitude?',
|