Hugging Face's logo Hugging Face
  • Models
  • Datasets
  • Spaces
  • Buckets new
  • Docs
  • Enterprise
  • Pricing

  • Log In
  • Sign Up

redis
/
langcache-embed-v2

Sentence Similarity
sentence-transformers
ONNX
Safetensors
OpenVINO
modernbert
feature-extraction
Generated from Trainer
dataset_size:36864
loss:MatryoshkaLoss
loss:CachedMultipleNegativesRankingLoss
text-embeddings-inference
Model card Files Files and versions
xet
Community
5

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]
  • Notebooks
  • Google Colab
  • Kaggle
langcache-embed-v2 / openvino
Ctrl+K
Ctrl+K
  • 2 contributors
History: 1 commit
waris-gill's picture
waris-gill
Add new SentenceTransformer model with an openvino backend (#5)
c6c325b verified 12 months ago
  • openvino_model.bin
    596 MB
    xet
    Add new SentenceTransformer model with an openvino backend (#5) 12 months ago
  • openvino_model.xml
    792 kB
    Add new SentenceTransformer model with an openvino backend (#5) 12 months ago