Text Ranking
sentence-transformers
PyTorch
ONNX
Safetensors
OpenVINO
Transformers
English
electra
text-classification
Run this model with HF Jobs
Run cross-encoder/ms-marco-electra-base 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/cross-encoder/ms-marco-electra-base. 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/cross-encoder/ms-marco-electra-base 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 cross-encoder/ms-marco-electra-base with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use cross-encoder/ms-marco-electra-base with sentence-transformers:
from sentence_transformers import CrossEncoder model = CrossEncoder("cross-encoder/ms-marco-electra-base") 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 cross-encoder/ms-marco-electra-base with Transformers:
# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("cross-encoder/ms-marco-electra-base") model = AutoModelForSequenceClassification.from_pretrained("cross-encoder/ms-marco-electra-base", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Commit History
-
Fix training code link
Verified signature8b93017
-
Revert inadvertent config, tokenizer updates
Tom AarsenThis reverts commit 9d005c539e13071a715a557a7299e2a4ee22b303.d720fd7
-
Add exported openvino model 'openvino_model_qint8_quantized.xml'
Verified signature0333c86 -
Add new CrossEncoder model
Verified signatureaf255de -
Add exported onnx model 'model_qint8_avx512_vnni.onnx'
Verified signature32b6a58 -
Add exported onnx model 'model_qint8_avx512.onnx'
Verified signature8acad5c -
Add exported onnx model 'model_quint8_avx2.onnx'
Verified signature8b2230f -
Add exported onnx model 'model_qint8_arm64.onnx'
Verified signature41c5bb9 -
Add exported onnx model 'model_O4.onnx'
Verified signature79c6a1d -
Add exported onnx model 'model_O3.onnx'
Verified signaturebad1287 -
Add exported onnx model 'model_O2.onnx'
Verified signature956ec57 -
Add exported onnx model 'model_O1.onnx'
Verified signaturea5eeda9 -
Add new CrossEncoder model
Verified signature9d005c5
-
Push tokenizer again (#3)
Verified signature- Push tokenizer again (48855e5fc562c625e9800ea0c73ca06e248575ec)624f7f4
-
Update model metadata
Verified signature2c6403b
-
Update README.md
Verified signaturee5828ff
-
Adding `safetensors` variant of this model (#1)
Verified signature- Adding `safetensors` variant of this model (ca0d791df8ce6860ab591aca3c2a8e54b164254f) Co-authored-by: Safetensors convertbot <SFconvertbot@users.noreply.huggingface.co>f876dcc
-
Update README.md
69c2288
-
upload
nreimersf387ca9
-
upload
nreimers33dbf06 -
initial commit
3f15a3f