/ Модель

Характеристики

Контекст
512 токенов
Параметры
40 млн
Лицензия
Apache 2.0
Архитектура
bert · dense
Базовая модель
MiniLM-L12-H384-uncased
Библиотека
sentence-transformers
Опубликована
17 июл 2026

minilm-msmarco-distilled

Ранжирование текстаТекст → score6 профессий

Англоязычный кросс-энкодер на MiniLM оценивает релевантность пар «запрос — текст» для повторного ранжирования результатов поиска.

15скачиваний за 30 дней0лайковвеса обновлены17 июл 2026

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Тесты пользователейпока нет

Никто ещё не опубликовал тест этой модели. Соберите бенчмарк из своих задач — результат появится здесь.

  1. Добавьте модель в бенчмарк

    Вместе с другими моделями категории «Ранжирование» — сравнение идёт внутри одной категории.

  2. Опишите свои задачи

    Напишите запросы, при необходимости приложите файлы и эталонные ответы.

  3. Запустите и опубликуйте

    Модели ответят на каждую задачу, судья оценит ответы. Опубликованный результат появится на этой странице.

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

Англоязычный кросс-энкодер-реранкер Hyperakan, дообученный на microsoft/MiniLM-L12-H384-uncased с использованием библиотеки Sentence Transformers и данных MS MARCO. Модель совместно обрабатывает запрос и текстовый фрагмент и выдаёт оценку релевантности, пригодную для повторного ранжирования результатов поиска и семантического поиска.

Архитектура — BertForSequenceClassification с одним выходным значением; размер модели — около 40 млн параметров, максимальная длина входа — 512 токенов. Модель принимает текст и выдаёт оценки для пар текстов. В README приведены результаты оценки на небольших наборах NanoMSMARCO, NanoNFCorpus, NanoNQ и NanoBEIR; показатели заметно различаются между наборами.

Модель рассчитана на английский язык. Лицензия — Apache-2.0. Результаты на приведённых наборах ограничены их небольшим размером, поэтому качество для других данных и сценариев следует проверять отдельно.

Сценарии применения

  • Повторное ранжирование документов по поисковому запросу
  • Сортировка ответов-кандидатов для семантического поиска
  • Оценка релевантности passages запросу
  • Улучшение порядка результатов поисковой выдачи

Ограничения

Поддерживается английский язык, а максимальная длина входа составляет 512 токенов. Приведённые оценки получены на небольших тестовых наборах и заметно различаются между ними; качество на других данных не гарантировано.

Для каких профессий подходит6

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Также подходит для

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

MiniLM-L12-H384-uncased reranker distilled from MS MARCO ensemble

This is a Cross Encoder model finetuned from microsoft/MiniLM-L12-H384-uncased on the msmarco dataset using the sentence-transformers library. It computes scores for pairs of texts, which can be used for text reranking and semantic search.

Model Details

Model Description

  • Model Type: Cross Encoder
  • Base model: microsoft/MiniLM-L12-H384-uncased
  • Maximum Sequence Length: 512 tokens
  • Number of Output Labels: 1 label
  • Supported Modality: Text
  • Training Dataset:
    • msmarco
  • Language: en
  • License: apache-2.0

Model Sources

Full Model Architecture

CrossEncoder(
  (0): Transformer({'transformer_task': 'sequence-classification', 'modality_config': {'text': {'method': 'forward', 'method_output_name': 'logits'}}, 'module_output_name': 'scores', 'architecture': 'BertForSequenceClassification'})
)

Usage

Direct Usage (Sentence Transformers)

First install the Sentence Transformers library:

pip install -U sentence-transformers

Then you can load this model and run inference.

from sentence_transformers import CrossEncoder

# Download from the 🤗 Hub
model = CrossEncoder("Hyperakan/minilm-msmarco-distilled")
# Get scores for pairs of inputs
pairs = [
    ['what are roof rats', 'Rattus rattus redirects here. For the album by Merzbow, see Rattus Rattus (album). The black rat (Rattus rattus), also known as the ship rat, roof rat, house rat, is a common long-tailed rodent of the genus Rattus (rats) in the subfamily Murinae. The species originated in tropical Asia and spread through the Near East in Roman times before reaching Europe by the 1st century and spreading with Europeans across the world.'],
    ['is overeating an eating disorder?', 'Compulsive overeating disorder is frequently called a â\x80\x9cfood addictionâ\x80\x9d because eating can cause biological changes in your body that are similar to those caused by addictive substances. Studies have found that foods, particularly high-fat foods, affect the areas of your brain associated with pleasure.'],
    ['can polycythemia cause stroke', 'Polycythemia Vera Complications. If you have PV, the thickness of your blood and the slowed blood flow can cause serious health problems. Blood clots are the most serious complication of PV. Blood clots can cause a heart attack or stroke. They also can cause your liver and spleen to enlarge.'],
    ['how many years of college does it take to be a pediatrician', 'Training to become a pediatrician requires a four-year undergraduate degree, four years of medical school, and three or more years of hands-on residency training.'],
    ['using commas correctly in sentences', "Commas and periods are the most frequently used punctuation marks. Commas customarily indicate a brief pause; they're not as final as periods. Rule 1. Use commas to separate words and word groups in a simple series of three or more items. Example: My estate goes to my husband, son, daughter-in-law, and nephew. Note: When the last comma in a series comes before and or or (after daughter-in-law in the above example), it is known as the Oxford comma. Most newspapers and magazines drop the Oxford comma in a simple series, apparently feeling it's unnecessary."],
]
scores = model.predict(pairs)
print(scores)
# [-0.0032 -0.0024 -0.0019  0.0005 -0.0017]

# Or rank different texts based on similarity to a single text
ranks = model.rank(
    'what are roof rats',
    [
        'Rattus rattus redirects here. For the album by Merzbow, see Rattus Rattus (album). The black rat (Rattus rattus), also known as the ship rat, roof rat, house rat, is a common long-tailed rodent of the genus Rattus (rats) in the subfamily Murinae. The species originated in tropical Asia and spread through the Near East in Roman times before reaching Europe by the 1st century and spreading with Europeans across the world.',
        'Compulsive overeating disorder is frequently called a â\x80\x9cfood addictionâ\x80\x9d because eating can cause biological changes in your body that are similar to those caused by addictive substances. Studies have found that foods, particularly high-fat foods, affect the areas of your brain associated with pleasure.',
        'Polycythemia Vera Complications. If you have PV, the thickness of your blood and the slowed blood flow can cause serious health problems. Blood clots are the most serious complication of PV. Blood clots can cause a heart attack or stroke. They also can cause your liver and spleen to enlarge.',
        'Training to become a pediatrician requires a four-year undergraduate degree, four years of medical school, and three or more years of hands-on residency training.',
        "Commas and periods are the most frequently used punctuation marks. Commas customarily indicate a brief pause; they're not as final as periods. Rule 1. Use commas to separate words and word groups in a simple series of three or more items. Example: My estate goes to my husband, son, daughter-in-law, and nephew. Note: When the last comma in a series comes before and or or (after daughter-in-law in the above example), it is known as the Oxford comma. Most newspapers and magazines drop the Oxford comma in a simple series, apparently feeling it's unnecessary.",
    ]
)
# [{'corpus_id': ..., 'score': ...}, {'corpus_id': ..., 'score': ...}, ...]

Evaluation

Metrics

Cross Encoder Reranking

  • Datasets: NanoMSMARCO_R100, NanoNFCorpus_R100 and NanoNQ_R100
  • Evaluated with CrossEncoderRerankingEvaluator with these parameters:
    {
        "at_k": 10,
        "always_rerank_positives": true
    }
    
MetricNanoMSMARCO_R100NanoNFCorpus_R100NanoNQ_R100
map0.0300 (-0.4596)0.2709 (+0.0099)0.0230 (-0.3966)
mrr@100.0069 (-0.4706)0.3974 (-0.1025)0.0025 (-0.4242)
ndcg@100.0148 (-0.5256)0.2428 (-0.0822)0.0039 (-0.4968)

Cross Encoder Nano BEIR

  • Dataset: NanoBEIR_R100_mean
  • Evaluated with CrossEncoderNanoBEIREvaluator with these parameters:
    {
        "dataset_names": [
            "msmarco",
            "nfcorpus",
            "nq"
        ],
        "dataset_id": "sentence-transformers/NanoBEIR-en",
        "rerank_k": 100,
        "at_k": 10,
        "always_rerank_positives": true
    }
    
MetricValue
map0.1080 (-0.2821)
mrr@100.1356 (-0.3324)
ndcg@100.0872 (-0.3682)

Training Details

Training Dataset

msmarco

  • Dataset: msmarco
  • Size: 100 training samples
  • Columns: score, query, positive, and negative
  • Approximate statistics based on the first 100 samples:
    scorequerypositivenegative
    typefloatstringstringstring
    modalitytexttexttext
    detailsmin: 0.6mean: 12.6max: 20.57min: 4 tokensmean: 9.43 tokensmax: 16 tokensmin: 13 tokensmean: 78.46 tokensmax: 197 tokensmin: 32 tokensmean: 77.94 tokensmax: 161 tokens
  • Samples:
    scorequerypositivenegative
    12.03586260477702obesity synonymsSynonyms: embonpoint; stoutness; corpulency; exogenous obesity; overweight; avoirdupois; plumpness; fat; fatness; roundness; adiposis; corpulence; blubber; fleshiness; Antonyms: leannessMake an effort synonyms. Top make an effort synonyms (idioms only) are have a crack, chip away at and give a go.
    8.629784286022186minecraft 1.9.2 how to make fencesOnce you have these you can then put them back into the Crafting Box and make them into Sticks. Place all items like how it is displayed below into the table: Now that you have learned how to make a fence in Minecraft, they are 1.5 blocks tall so nothing is able to jump over them.You are able to place blocks on top of the fence that will sit on the fence like it is one block. Fences can be used as a Fuel Source in Furnaces.A Fence Gate is commonly used with fences so a player easily go through a wall of fences.ow To Make A Fence In Minecraft. Crafting is the way to make a cake in Minecraft. The player will first need one crafting table. It can be made by opening your inventory box and placing 4 Wooden Planks into the 2×2 grid. If you just made the crafting table then you will need to equip it and place it on the ground.1.9, the first release of the Combat Update, is an upcoming major update to Minecraft with no set release date.Dinnerbone has stated in May that many of the features he has shown for 1.9 are not “100% final”, so things may change later.or other editions, see Version history (disambiguation) . 1.9, the first release of the Combat Update, is an upcoming major update to Minecraft with no set release date. Dinnerbone has stated in May that many of the features he has shown for 1.9 are not “100% final”, so things may change later.
    8.286005536715189what is trap it termTrap (computing) In computing and operating systems, a trap, also known as an exception or a fault, is typically[NB 1][1] a type of synchronous interrupt typically caused by an exceptional condition (e.g., breakpoint, division by zero, invalid memory access).1 A cage trap baited with peanut butter or a sticky trap that is of a size designed to catch rats will get them while in the car. 2 Then drown the rats or suffocate them in a plastic bag (trap and rat go in the bag) and then trash them. A cage trap baited with peanut butter or a sticky trap that is of a size designed to catch rats will get them while in the car. 2 Then drown the rats or suffocate them in a plastic bag (trap and rat go in the bag) and then trash them.
  • Loss: MarginMSELoss with these parameters:
    {
        "activation_fn": "torch.nn.modules.linear.Identity"
    }
    

Evaluation Dataset

msmarco

  • Dataset: msmarco
  • Size: 20 evaluation samples
  • Columns: score, query, positive, and negative
  • Approximate statistics based on the first 20 samples:
    scorequerypositivenegative
    typefloatstringstringstring
    modalitytexttexttext
    detailsmin: -1.83mean: 12.68max: 20.24min: 4 tokensmean: 8.4 tokensmax: 15 tokensmin: 34 tokensmean: 89.75 tokensmax: 147 tokensmin: 32 tokensmean: 78.8 tokensmax: 161 tokens
  • Samples:
    scorequerypositivenegative
    16.17283757527669what are roof ratsRattus rattus redirects here. For the album by Merzbow, see Rattus Rattus (album). The black rat (Rattus rattus), also known as the ship rat, roof rat, house rat, is a common long-tailed rodent of the genus Rattus (rats) in the subfamily Murinae. The species originated in tropical Asia and spread through the Near East in Roman times before reaching Europe by the 1st century and spreading with Europeans across the world.1 A cage trap baited with peanut butter or a sticky trap that is of a size designed to catch rats will get them while in the car. 2 Then drown the rats or suffocate them in a plastic bag (trap and rat go in the bag) and then trash them. A cage trap baited with peanut butter or a sticky trap that is of a size designed to catch rats will get them while in the car. 2 Then drown the rats or suffocate them in a plastic bag (trap and rat go in the bag) and then trash them.
    12.888915936152141is overeating an eating disorder?Compulsive overeating disorder is frequently called a “food addiction” because eating can cause biological changes in your body that are similar to those caused by addictive substances. Studies have found that foods, particularly high-fat foods, affect the areas of your brain associated with pleasure.Emetrol is an oral solution designed to soothe the stomach when nausea and vomiting are caused by a viral or bacterial infection or overeating. Emetrol contains sugar and phosphoric acid. Diabetics should not use Emetrol without medical supervision because of the concentrated sugar.
    18.19395383199056can polycythemia cause strokePolycythemia Vera Complications. If you have PV, the thickness of your blood and the slowed blood flow can cause serious health problems. Blood clots are the most serious complication of PV. Blood clots can cause a heart attack or stroke. They also can cause your liver and spleen to enlarge.Stroke Recovery. Stroke affects everybody differently. Many stroke survivors continue to improve over a long time, sometimes over a number of years. Recovery from stroke involves making changes in the physical, social and, emotional aspects of your life. You will make changes to prevent additional strokes as well as to facilitate your life-long recovery.
  • Loss: MarginMSELoss with these parameters:
    {
        "activation_fn": "torch.nn.modules.linear.Identity"
    }
    

Training Hyperparameters

Non-Default Hyperparameters

  • per_device_train_batch_size: 32
  • per_device_eval_batch_size: 32
  • learning_rate: 8e-06
  • weight_decay: 0.01
  • num_train_epochs: 1
  • warmup_ratio: 0.1
  • seed: 12
  • bf16: True
  • load_best_model_at_end: True

All Hyperparameters

  • overwrite_output_dir: False
  • do_predict: False
  • prediction_loss_only: True
  • per_device_train_batch_size: 32
  • per_device_eval_batch_size: 32
  • per_gpu_train_batch_size: None
  • per_gpu_eval_batch_size: None
  • gradient_accumulation_steps: 1
  • eval_accumulation_steps: None
  • torch_empty_cache_steps: None
  • learning_rate: 8e-06
  • weight_decay: 0.01
  • adam_beta1: 0.9
  • adam_beta2: 0.999
  • adam_epsilon: 1e-08
  • max_grad_norm: 1.0
  • num_train_epochs: 1
  • max_steps: -1
  • lr_scheduler_type: linear
  • lr_scheduler_kwargs: None
  • warmup_ratio: 0.1
  • warmup_steps: 0
  • log_level: passive
  • log_level_replica: warning
  • log_on_each_node: True
  • logging_nan_inf_filter: True
  • save_safetensors: True
  • save_on_each_node: False
  • save_only_model: False
  • restore_callback_states_from_checkpoint: False
  • no_cuda: False
  • use_cpu: False
  • use_mps_device: False
  • seed: 12
  • data_seed: None
  • jit_mode_eval: False
  • bf16: True
  • fp16: False
  • fp16_opt_level: O1
  • half_precision_backend: auto
  • bf16_full_eval: False
  • fp16_full_eval: False
  • tf32: None
  • local_rank: 0
  • ddp_backend: None
  • tpu_num_cores: None
  • tpu_metrics_debug: False
  • debug: []
  • dataloader_drop_last: False
  • dataloader_num_workers: 0
  • dataloader_prefetch_factor: None
  • past_index: -1
  • disable_tqdm: False
  • remove_unused_columns: True
  • label_names: None
  • load_best_model_at_end: True
  • ignore_data_skip: False
  • fsdp: []
  • fsdp_min_num_params: 0
  • fsdp_config: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
  • fsdp_transformer_layer_cls_to_wrap: None
  • accelerator_config: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
  • parallelism_config: None
  • deepspeed: None
  • label_smoothing_factor: 0.0
  • optim: adamw_torch
  • optim_args: None
  • adafactor: False
  • group_by_length: False
  • length_column_name: length
  • project: huggingface
  • trackio_space_id: trackio
  • ddp_find_unused_parameters: None
  • ddp_bucket_cap_mb: None
  • ddp_broadcast_buffers: False
  • dataloader_pin_memory: True
  • dataloader_persistent_workers: False
  • skip_memory_metrics: True
  • use_legacy_prediction_loop: False
  • push_to_hub: False
  • resume_from_checkpoint: None
  • hub_model_id: None
  • hub_strategy: every_save
  • hub_private_repo: None
  • hub_always_push: False
  • hub_revision: None
  • gradient_checkpointing: False
  • gradient_checkpointing_kwargs: None
  • include_inputs_for_metrics: False
  • include_for_metrics: []
  • eval_do_concat_batches: True
  • fp16_backend: auto
  • push_to_hub_model_id: None
  • push_to_hub_organization: None
  • mp_parameters:
  • auto_find_batch_size: False
  • full_determinism: False
  • torchdynamo: None
  • ray_scope: last
  • ddp_timeout: 1800
  • torch_compile: False
  • torch_compile_backend: None
  • torch_compile_mode: None
  • include_tokens_per_second: False
  • include_num_input_tokens_seen: no
  • neftune_noise_alpha: None
  • optim_target_modules: None
  • batch_eval_metrics: False
  • eval_on_start: False
  • use_liger_kernel: False
  • liger_kernel_config: None
  • eval_use_gather_object: False
  • average_tokens_across_devices: True
  • prompts: None
  • batch_sampler: batch_sampler
  • multi_dataset_batch_sampler: proportional
  • router_mapping: {}
  • learning_rate_mapping: {}

Training Logs

EpochStepTraining LossValidation LossNanoMSMARCO_R100_ndcg@10NanoNFCorpus_R100_ndcg@10NanoNQ_R100_ndcg@10NanoBEIR_R100_mean_ndcg@10
-1-1--0.0177 (-0.5227)0.2189 (-0.1061)0.0059 (-0.4948)0.0808 (-0.3745)
0.251218.674191.36480.0177 (-0.5227)0.2189 (-0.1061)0.0059 (-0.4948)0.0808 (-0.3745)
0.52163.1853191.35690.0167 (-0.5238)0.2342 (-0.0908)0.0039 (-0.4968)0.0849 (-0.3705)
0.753171.4948191.35640.0148 (-0.5256)0.2428 (-0.0822)0.0039 (-0.4968)0.0872 (-0.3682)
1.04120.6957191.35610.0146 (-0.5258)0.2347 (-0.0903)0.0047 (-0.4959)0.0847 (-0.3707)
-1-1--0.0148 (-0.5256)0.2428 (-0.0822)0.0039 (-0.4968)0.0872 (-0.3682)
  • The bold row denotes the saved checkpoint.

Training Time

  • Training: 1.0 minutes
  • Evaluation: 3.1 minutes
  • Total: 4.1 minutes

Framework Versions

  • Python: 3.12.13
  • Sentence Transformers: 5.6.0
  • Transformers: 4.57.6
  • PyTorch: 2.6.0+cu124
  • Accelerate: 1.14.0
  • Datasets: 5.0.0
  • Tokenizers: 0.22.2

Additional Resources

Citation

BibTeX

Sentence Transformers

@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",
}

MarginMSELoss

@misc{hofstätter2021improving,
    title={Improving Efficient Neural Ranking Models with Cross-Architecture Knowledge Distillation},
    author={Sebastian Hofstätter and Sophia Althammer and Michael Schröder and Mete Sertkan and Allan Hanbury},
    year={2021},
    eprint={2010.02666},
    archivePrefix={arXiv},
    primaryClass={cs.IR}
}

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · sentence-transformers

Можно запустить

Подбираем GPU…

Класс архитектуры
BertForSequenceClassification
Ревизия весов
49d04cc

0 моделей