| | --- |
| | language: en |
| | license: apache-2.0 |
| | library_name: transformers |
| | base_model: bert-base-uncased |
| | model_name: cross-encoder-bert-base-DistillRankNET |
| | source: https://github.com/xpmir/cross-encoders |
| | paper: http://arxiv.org/abs/2603.03010 |
| | tags: |
| | - cross-encoder |
| | - sequence-classification |
| | - tensorboard |
| | datasets: |
| | - msmarco |
| | pipeline_tag: text-classification |
| | --- |
| | |
| | # cross-encoder-bert-base-DistillRankNET |
| |
|
| | [](http://arxiv.org/abs/2603.03010) |
| | [](https://huggingface.co/collections/xpmir/reproducing-cross-encoders) |
| | [](https://github.com/xpmir/cross-encoders) |
| |
|
| | This model is a cross-encoder based on `bert-base-uncased`. It was trained on Ms-Marco using loss `distillRankNET` as part of a reproducibility paper for training cross encoders: "**[Reproducing and Comparing Distillation Techniques for Cross-Encoders](http://arxiv.org/abs/2603.03010)**", see the paper for more details. |
| |
|
| |
|
| | ### Contents |
| | - [Model Description](#model-description) |
| | - [Usage](#usage) |
| | - [Evals](#evaluations) |
| |
|
| |
|
| | ## Model Description |
| |
|
| | This model is intended for **re-ranking** the top results returned by a retrieval system (like BM25, Bi-Encoders or SPLADE). |
| |
|
| | - **Training Data:** MS MARCO Passage |
| | - **Language:** English |
| | - **Loss** distillRankNET |
| |
|
| | Training can be easily reproduced using the assiciated repository. |
| | The exact training configuration used for this model is also detailed in [config.yaml](./config.yaml). |
| |
|
| | ## Usage |
| |
|
| | Quick Start: |
| | ```python |
| | from transformers import AutoTokenizer, AutoModelForSequenceClassification |
| | import torch |
| | |
| | tokenizer = AutoTokenizer.from_pretrained("bert-base-uncased") |
| | model = AutoModelForSequenceClassification.from_pretrained("xpmir/cross-encoder-bert-base-DistillRankNET") |
| | |
| | features = tokenizer("What is experimaestro ?", "Experimaestro is a powerful framework for ML experiments management...", padding=True, truncation=True, return_tensors="pt") |
| | |
| | model.eval() |
| | with torch.no_grad(): |
| | scores = model(**features).logits |
| | print(scores) |
| | ``` |
| |
|
| | ## Evaluations |
| |
|
| | We provide evaluations of this cross-encoder re-ranking the top `1000` documents retrieved by `naver/splade-v3-distilbert`. |
| |
|
| | | dataset | RR@10 | nDCG@10 | |
| | |:-------------------|:----------|:----------| |
| | | msmarco_dev | 36.42 | 42.84 | |
| | | trec2019 | 95.74 | 74.15 | |
| | | trec2020 | 94.25 | 72.10 | |
| | | fever | 81.04 | 80.99 | |
| | | arguana | 22.80 | 34.31 | |
| | | climate_fever | 29.17 | 21.50 | |
| | | dbpedia | 76.58 | 45.80 | |
| | | fiqa | 43.41 | 35.34 | |
| | | hotpotqa | 89.45 | 72.86 | |
| | | nfcorpus | 56.85 | 34.36 | |
| | | nq | 52.57 | 57.27 | |
| | | quora | 76.95 | 78.94 | |
| | | scidocs | 28.31 | 15.65 | |
| | | scifact | 67.81 | 70.21 | |
| | | touche | 63.22 | 34.36 | |
| | | trec_covid | 89.83 | 68.52 | |
| | | robust04 | 69.69 | 47.75 | |
| | | lotte_writing | 64.88 | 55.85 | |
| | | lotte_recreation | 58.11 | 52.84 | |
| | | lotte_science | 43.32 | 36.06 | |
| | | lotte_technology | 49.62 | 41.06 | |
| | | lotte_lifestyle | 70.00 | 60.53 | |
| | | **Mean In Domain** | **75.47** | **63.03** | |
| | | **BEIR 13** | **59.85** | **50.01** | |
| | | **LoTTE (OOD)** | **59.27** | **49.01** | |