-
Notifications
You must be signed in to change notification settings - Fork 560
[snippets] Add model.encode and model.similarity to Sentence Transformers snippet
#970
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[snippets] Add model.encode and model.similarity to Sentence Transformers snippet
#970
Conversation
julien-c
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good!
those are the two main entry points to the library? (encode and similarity)
|
That's right! See the Quickstart as an example: |
Vaibhavs10
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left some minor nits wrt the snippet - I think the library API is clear enough to not need extra comments.
|
Sounds good, I can remove the comments. But we can keep the snippets free of comments. |
Co-authored-by: vb <vaibhavs10@gmail.com>
Vaibhavs10
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks nice! Let's wait for @mishig25 to also give it a review before we merge 🙏
mishig25
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm !
Co-authored-by: Mishig <dmishig@gmail.com>


Hello!
Pull Request overview
model.encodeandmodel.similarityto Sentence Transformers snippetDetails
As suggested internally by @mishig25 here - thanks for the idea!
Examples
The snippets on the Hub have scrolling, so long texts is fine.