How to use greatakela/gnlp_hw1_encoder with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("greatakela/gnlp_hw1_encoder") sentences = [ "Leave me alone! Have you gone daft? Mister Spock needs me! Let go! That will be quite enough. Thank you, doctor.; Please, release her.[SEP]What's this all about?", " You know, the lab here, they have a paid intern position. It's usually given to one of the kids from the universities but, if you want, I could pRobably get you an interview. There's some entry lEvel stuff, some gofer work. But you'd also have access to a lot of cool things.", "She was doing as I requested, Mister Scott. A Vulcan form of self-healing.", "Thasians have been referred to in our records as having the power to transmute objects or render substances invisible. It has generally been regarded as legend, but Charlie does seems to possess this same power." ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [4, 4]
The community tab is the place to discuss and collaborate with the HF community!