Text Ranking
sentence-transformers
Safetensors
Transformers
multilingual
t5gemma2
text2text-generation
reranker
encoder-decoder
FBNL
matryoshka
retrieval
RAG
Run this model with HF Jobs
Run KaLM-Embedding/KaLM-Reranker-V1-Small-R2 on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs to fine-tune https://huggingface.co/KaLM-Embedding/KaLM-Reranker-V1-Small-R2. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/KaLM-Embedding/KaLM-Reranker-V1-Small-R2 on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Instructions to use KaLM-Embedding/KaLM-Reranker-V1-Small-R2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use KaLM-Embedding/KaLM-Reranker-V1-Small-R2 with sentence-transformers:
from sentence_transformers import CrossEncoder model = CrossEncoder("KaLM-Embedding/KaLM-Reranker-V1-Small-R2") query = "Which planet is known as the Red Planet?" passages = [ "Venus is often called Earth's twin because of its similar size and proximity.", "Mars, known for its reddish appearance, is often referred to as the Red Planet.", "Jupiter, the largest planet in our solar system, has a prominent red spot.", "Saturn, famous for its rings, is sometimes mistaken for the Red Planet." ] scores = model.predict([(query, passage) for passage in passages]) print(scores) - Transformers
How to use KaLM-Embedding/KaLM-Reranker-V1-Small-R2 with Transformers:
# pip install -U transformers accelerate # Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("KaLM-Embedding/KaLM-Reranker-V1-Small-R2") model = AutoModelForMultimodalLM.from_pretrained("KaLM-Embedding/KaLM-Reranker-V1-Small-R2", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Commit History
18 days ago
-
Update vllm_support/src/kalm_t5gemma2_vllm_plugin/cli.py
Verified signatureb0ff01b -
Update vllm_support/examples/offline_usage.py
Verified signaturef9e0aa0 -
Update vllm_support/examples/start_online_server.sh
Verified signature5e47a97 -
Update vllm_support/src/kalm_t5gemma2_vllm_plugin/constants.py
Verified signature66e334a -
Update vllm_support/README.md
Verified signature24983b5
-
Update README.md
Verified signature3c4a7b7
-
Update README.md
Verified signature68b74f0
-
Update README.md
Verified signatured1c8fdf
-
Update README.md
Verified signature7966d9f -
Add vLLM support
Verified signature61e592c -
Update README.md
Verified signature58981eb -
Add sentence-transformers CrossEncoder integration
Verified signature38896ac -
Add KaLM reranker implementation files
Verified signature62c77b1
-
Update README.md
Verified signature5005b0d -
Create README.md
Verified signature17243bf -
Upload 9 files
Verified signatureebc1d7c
-
Upload 5 files
Verified signature65373dd
-
initial commit
Verified signaturedf00718