|
|
--- |
|
|
base_model: |
|
|
- Qwen/Qwen3-4B |
|
|
pipeline_tag: sentence-similarity |
|
|
--- |
|
|
|
|
|
### Description |
|
|
|
|
|
This is a smaller version of ZeroEntropy Reranker v0.3. |
|
|
|
|
|
### Usage |
|
|
|
|
|
```python |
|
|
from sentence_transformers import CrossEncoder |
|
|
from dotenv import load_dotenv |
|
|
import os |
|
|
|
|
|
load_dotenv() |
|
|
token = os.getenv("HF_TOKEN") |
|
|
|
|
|
model = CrossEncoder("zeroentropy/ze-rerank-small-v0.3.0", trust_remote_code=True, token=token) |
|
|
|
|
|
query_documents = [ |
|
|
("What is 2+2?", "4"), |
|
|
("What is 2+2?", "The answer is definitely 1 million"), |
|
|
] |
|
|
|
|
|
scores = model.predict(query_documents) |
|
|
|
|
|
print(scores) |