from sentence_transformers import CrossEncoder
# Download from the 🤗 Hub
model = CrossEncoder("baseten-admin/reranker-ModernBERT-base-gooaq-bce")
# Get scores for pairs of texts
pairs = [
['how to put your phone on do not disturb on iphone?', 'Go to Settings > Do Not Disturb to turn on Do Not Disturb manually or set a schedule. to turn it on or off.'],
['how to put your phone on do not disturb on iphone?', "This icon means that your iPhone's Do Not Disturb feature is enabled."],
['how to put your phone on do not disturb on iphone?', 'About Do Not Disturb The Do Not Disturb option on the iPhone stops notifications, alerts and calls from making any noise, vibration or lighting up the phone screen when the screen is locked.'],
['how to put your phone on do not disturb on iphone?', 'Go to Settings > Do Not Disturb to turn on Do Not Disturb manually or set a schedule. to turn it on or off. If you set an alarm in the Clock app, the alarm goes off even when Do Not Disturb is on. Learn how to set and manage your alarms.'],
['how to put your phone on do not disturb on iphone?', "You can use the Do Not Disturb feature on your iPhone whenever you want to block any calls, texts, or other notifications from making your phone ring. The notifications and alerts will still be stored on your phone, and you can check them at any time, but your iPhone won't light up or ring."],
]
scores = model.predict(pairs)
print(scores.shape)
# (5,)# Or rank different texts based on similarity to a single text
ranks = model.rank(
'how to put your phone on do not disturb on iphone?',
[
'Go to Settings > Do Not Disturb to turn on Do Not Disturb manually or set a schedule. to turn it on or off.',
"This icon means that your iPhone's Do Not Disturb feature is enabled.",
'About Do Not Disturb The Do Not Disturb option on the iPhone stops notifications, alerts and calls from making any noise, vibration or lighting up the phone screen when the screen is locked.',
'Go to Settings > Do Not Disturb to turn on Do Not Disturb manually or set a schedule. to turn it on or off. If you set an alarm in the Clock app, the alarm goes off even when Do Not Disturb is on. Learn how to set and manage your alarms.',
"You can use the Do Not Disturb feature on your iPhone whenever you want to block any calls, texts, or other notifications from making your phone ring. The notifications and alerts will still be stored on your phone, and you can check them at any time, but your iPhone won't light up or ring.",
]
)
# [{'corpus_id': ..., 'score': ...}, {'corpus_id': ..., 'score': ...}, ...]
Approximate statistics based on the first 1000 samples:
question
answer
label
type
string
string
int
details
min: 20 characters
mean: 42.74 characters
max: 83 characters
min: 51 characters
mean: 250.28 characters
max: 385 characters
0: ~82.30%
1: ~17.70%
Samples:
question
answer
label
how to put your phone on do not disturb on iphone?
Go to Settings > Do Not Disturb to turn on Do Not Disturb manually or set a schedule. to turn it on or off.
1
how to put your phone on do not disturb on iphone?
This icon means that your iPhone's Do Not Disturb feature is enabled.
0
how to put your phone on do not disturb on iphone?
About Do Not Disturb The Do Not Disturb option on the iPhone stops notifications, alerts and calls from making any noise, vibration or lighting up the phone screen when the screen is locked.
@inproceedings{reimers-2019-sentence-bert,
title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
author = "Reimers, Nils and Gurevych, Iryna",
booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
month = "11",
year = "2019",
publisher = "Association for Computational Linguistics",
url = "https://arxiv.org/abs/1908.10084",
}
Runs of baseten-admin reranker-ModernBERT-base-gooaq-bce on huggingface.co
16
Total runs
2
24-hour runs
1
3-day runs
9
7-day runs
4
30-day runs
More Information About reranker-ModernBERT-base-gooaq-bce huggingface.co Model
More reranker-ModernBERT-base-gooaq-bce license Visit here:
reranker-ModernBERT-base-gooaq-bce huggingface.co is an AI model on huggingface.co that provides reranker-ModernBERT-base-gooaq-bce's model effect (), which can be used instantly with this baseten-admin reranker-ModernBERT-base-gooaq-bce model. huggingface.co supports a free trial of the reranker-ModernBERT-base-gooaq-bce model, and also provides paid use of the reranker-ModernBERT-base-gooaq-bce. Support call reranker-ModernBERT-base-gooaq-bce model through api, including Node.js, Python, http.
reranker-ModernBERT-base-gooaq-bce huggingface.co is an online trial and call api platform, which integrates reranker-ModernBERT-base-gooaq-bce's modeling effects, including api services, and provides a free online trial of reranker-ModernBERT-base-gooaq-bce, you can try reranker-ModernBERT-base-gooaq-bce online for free by clicking the link below.
baseten-admin reranker-ModernBERT-base-gooaq-bce online free url in huggingface.co:
reranker-ModernBERT-base-gooaq-bce is an open source model from GitHub that offers a free installation service, and any user can find reranker-ModernBERT-base-gooaq-bce on GitHub to install. At the same time, huggingface.co provides the effect of reranker-ModernBERT-base-gooaq-bce install, users can directly use reranker-ModernBERT-base-gooaq-bce installed effect in huggingface.co for debugging and trial. It also supports api for free installation.
reranker-ModernBERT-base-gooaq-bce install url in huggingface.co: