Skip to content
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

new: add reranker example to readme #390

Merged
merged 3 commits into from
Nov 7, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Update README.md
Co-authored-by: Anush  <[email protected]>
joein and Anush008 authored Nov 7, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
commit 31c9feaf8f0a1bc771339fe3be897ec516eecf25
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -147,7 +147,7 @@ documents: List[str] = [
"This is built to be faster and lighter than other embedding libraries e.g. Transformers, Sentence-Transformers, etc.",
"fastembed is supported by and maintained by Qdrant.",
]
encoder = TextCrossEncoder(model_name='Xenova/ms-marco-MiniLM-L-6-v2')
encoder = TextCrossEncoder(model_name="Xenova/ms-marco-MiniLM-L-6-v2")
scores = encoder.rerank(query, documents)

# [-11.48061752319336, 5.472434997558594]