Views
No views yet
convert_hf_to_gguf.py./v1/rerank on RTX 3090. All quants produced from the same F16 source using llama-quantize.| Quant | Size | NDCG@10 | MAP@10 | MRR@10 | Δ NDCG@10 |
|---|---|---|---|---|---|
| F16 | 1.12 GB | 0.6688 | 0.5143 | 0.7317 | baseline |
| Q8_0 | 0.60 GB | 0.6677 | 0.5143 | 0.7329 | -0.2% |
| Q6_K | 0.46 GB | 0.6691 | 0.5156 | 0.7353 | +0.0% |
| Q5_K_M | 0.41 GB | 0.6671 | 0.5138 | 0.7377 | -0.3% |
| Q5_0 | 0.41 GB | 0.6678 | 0.5118 | 0.7423 | -0.2% |
| Q4_K_M | 0.37 GB | 0.6669 | 0.5120 | 0.7345 | -0.3% |
| Q4_0 | 0.36 GB | 0.6556 | 0.5010 | 0.7211 | -2.0% |
| Q3_K_M | 0.32 GB | 0.6551 | 0.5004 | 0.7354 | -2.1% |
| Q2_K | 0.28 GB | 0.4770 | 0.3104 | 0.5668 | -28.7% |
4.5e-23) because they're missing reranker-specific tensors. See llama.cpp #16407. This one works:Doc 0 (relevant): relevance_score = 0.98XX
Doc 1 (irrelevant): relevance_score = 0.00XXllama-server -m Qwen3-Reranker-0.6B-f16.gguf --reranking --pooling rank --embedding --port 80811curl http://localhost:8081/v1/rerank \
2 -H "Content-Type: application/json" \
3 -d '{
4 "query": "employment termination notice period",
5 "documents": [
6 "The Labour Code requires 30 calendar days written notice.",
7 "Corporate tax rates for small enterprises."
8 ]
9 }'/v1/rerank, not /v1/embeddings. The embeddings endpoint returns zeros for reranker models.convert_hf_to_gguf.py detects Qwen3-Reranker and does things naive converters skip:cls.output.weight (the yes/no classifier) from lm_headpooling_type = RANK metadataclassifier.output_labels = ["yes", "no"]1[Qwen3-Reranker-0.6B-f16]
2model = /path/to/Qwen3-Reranker-0.6B-f16.gguf
3reranking = true
4pooling = rank
5embedding = true
6ctx-size = 327681pip install huggingface_hub gguf torch safetensors sentencepiece
2python -c "from huggingface_hub import snapshot_download; snapshot_download('Qwen/Qwen3-Reranker-0.6B', local_dir='Qwen3-Reranker-0.6B-src')"
3python convert_hf_to_gguf.py --outtype f16 --outfile Qwen3-Reranker-0.6B-f16.gguf Qwen3-Reranker-0.6B-src/