Instructions to use hmzprover/hpsearch-rerank-4b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use hmzprover/hpsearch-rerank-4b with Transformers:
# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("hmzprover/hpsearch-rerank-4b") model = AutoModelForCausalLM.from_pretrained("hmzprover/hpsearch-rerank-4b", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Upload README.md with huggingface_hub
Browse files
README.md
CHANGED
|
@@ -12,7 +12,7 @@ The reranker of [hpsearch](https://github.com/humanfia/hpsearch)'s `best` mode:
|
|
| 12 |
[`Qwen/Qwen3-Reranker-4B`](https://huggingface.co/Qwen/Qwen3-Reranker-4B) (4B parameters) LoRA-fine-tuned twice
|
| 13 |
(listwise softmax over one positive and seven hard negatives per query) and averaged with the base model: weights =
|
| 14 |
0.5 base + 0.25 each fine-tune. Same prompt and yes/no scoring as Qwen3-Reranker; hpsearch shows each document as
|
| 15 |
-
its Lean statement then its NL statement, cut at
|
| 16 |
|
| 17 |
Fine-tuning data (public, generated locally):
|
| 18 |
- six-style search queries (a Lean fragment, LaTeX, a plain-English description, a slogan, a nickname, a concrete
|
|
|
|
| 12 |
[`Qwen/Qwen3-Reranker-4B`](https://huggingface.co/Qwen/Qwen3-Reranker-4B) (4B parameters) LoRA-fine-tuned twice
|
| 13 |
(listwise softmax over one positive and seven hard negatives per query) and averaged with the base model: weights =
|
| 14 |
0.5 base + 0.25 each fine-tune. Same prompt and yes/no scoring as Qwen3-Reranker; hpsearch shows each document as
|
| 15 |
+
its Lean statement then its NL statement, cut at 112 tokens (16 documents per query).
|
| 16 |
|
| 17 |
Fine-tuning data (public, generated locally):
|
| 18 |
- six-style search queries (a Lean fragment, LaTeX, a plain-English description, a slogan, a nickname, a concrete
|