Views
No views yet
1from sentence_transformers import SentenceTransformer
2
3# 1. Load the model from the Hugging Face Hub
4model = SentenceTransformer(
5 "guoch/bce-embedding-base_v1-openvino-qint8",
6 backend="openvino",
7 model_kwargs={"file_name": "openvino_model_qint8_quantized.xml"},
8)
9
10# 2. Inference works as normal
11embeddings = model.encode(["The weather is lovely today.", "It's so sunny outside!", "He drove to the stadium."])
12similarities = model.similarity(embeddings, embeddings)