Fix broken SentenceTransformer snippet; format code with Python format
#11
by
tomaarsen
HF Staff
- opened
Hello!
Pull Request overview
- Fix broken SentenceTransformer snippet: It said
'instead ofmodel_name_or_path(bug was introduced in https://huggingface.co/Alibaba-NLP/gte-multilingual-base/commit/167d84dcd20a1f29c277626db5175f7442274cee) - Give the code snippets Python coloring by adding
pythonright after the triple tick - Use more SentenceTransformer functionality:
normalize_embeddings=Trueinmodel.encode&model.similarityto compute the cosine similarity.
Details
This should fix the snippet and make the README code blocks easier to read.
cc @thenlper
- Tom Aarsen
thenlper
changed pull request status to
merged