How to use LamaDiab/MiniLM-SemanticEngine with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("LamaDiab/MiniLM-SemanticEngine") sentences = [ "blue dianne", "soap", "maximize the freshness of your food for 12 hours with the blue dianne thermal bag. its triple compartments, spacious storage, heat resistance, and 100% leakproof design will keep it fresh. this bpa-free and pvc-free bag is also 100% non-toxic and comes with a 3-month guarantee. ideal for everyday food storage.", "trolley backpack coral high colors 17 l 3 zippers 23977" ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [4, 4]