Instructions to use tuhailong/cross-encoder-bert-base with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use tuhailong/cross-encoder-bert-base with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="tuhailong/cross-encoder-bert-base")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("tuhailong/cross-encoder-bert-base") model = AutoModelForSequenceClassification.from_pretrained("tuhailong/cross-encoder-bert-base", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Commit History
-
Update model metadata to set pipeline tag to the new `text-ranking` and library name to `sentence-transformers`
Verified signatureHello! ## Pull Request overview * Update metadata to set pipeline tag to the new `text-ranking` * Update metadata to set library name to `sentence-transformers` ## Changes This is an automated pull request to update the metadata of the model card. We recently introduced the [`text-ranking`](https://huggingface.co/models?pipeline_tag=text-ranking) pipeline tag for models that are used for ranking tasks, and we have a suspicion that this model is one of them. I also updated added metadata to specify that this model can be loaded with the `sentence-transformers` library, as it should be possible to load any model compatible with `transformers` `AutoModelForSequenceClassification`. Feel free to verify that it works with the following: ```bash pip install sentence-transformers ``` ```python from sentence_transformers import CrossEncoder model = CrossEncoder("tuhailong/cross-encoder-bert-base") scores = model.predict([ ("How many people live in Berlin?", "Berlin had a population of…f34dd84
-
Adding `safetensors` variant of this model (#1)
- Adding `safetensors` variant of this model (2aceba2d385b75fed59010fe51a38f10eb1efe8d) Co-authored-by: Safetensors convertbot <SFconvertbot@users.noreply.huggingface.co>84da7ea
-
Update README.md
61198bd -
Update README.md
a2486b4
-
Update README.md
5c692f5 -
Update README.md
d17b2bd
-
cross-encoder
47cf556
-
Update README.md
8d0f1fc -
Update README.md
333269f -
Merge branch 'main' of https://huggingface.co/tuhailong/cross-encoder into main
7115fda -
Update README.md
88d86c3 -
Update README.md
1b110b7 -
first commit
52f7772 -
Create README.md
f981dc5 -
initial commit
cd92a75