/ Модель

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

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

ecommerce-product-search-reranker

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

Англоязычный реранкер товаров на базе MiniLM, который сортирует найденные по запросу товары по релевантности их названий.

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

Бенчмарки

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Это англоязычный cross-encoder-реранкер для поиска товаров в интернет-магазинах, разработанный Alberto Barnabo. Модель оценивает релевантность пары «поисковый запрос — название товара» и повторно сортирует кандидатов, уже найденных поисковым движком. Её можно использовать со своим поисковым механизмом; карточка также описывает связку с отдельным эмбеддинг-рetriever’ом.

Модель построена на BERT-архитектуре и дообучена на базе cross-encoder/ms-marco-MiniLM-L12-v2 на человеческих оценках релевантности товаров из Amazon ESCI. В метаданных указаны 40 млн параметров и контекст до 512 токенов; README приводит размер 33 млн параметров. Для ранжирования достаточно передавать названия товаров. По данным README, модель рассчитана на CPU-инференс: обработка 50 кандидатов занимала около 45 мс на ноутбуке Apple M-серии.

На отложенном тесте ESCI реранжирование повышало nDCG@10 связки с указанным в README поисковым механизмом с 0,4349 до 0,5162. Оценки модели подходят для упорядочивания и относительных порогов, но не интерпретируются как вероятности релевантности. Модель обучена на английских запросах и каталоге Amazon; перенос на другие языки и товарные каталоги не оценён. Она обучалась на названиях, поэтому для скоринга следует подавать названия, а не полные описания товаров. Лицензия — Apache-2.0.

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

  • повторная сортировка товаров после векторного поиска
  • улучшение выдачи интернет-магазина по запросам на английском языке
  • ранжирование кандидатов по соответствию названия товара запросу
  • отсев низкорелевантных товаров по относительному порогу оценки

Ограничения

Обучена на английских запросах и товарах Amazon; перенос на другие языки и каталоги не оценён. Обучалась на названиях товаров, а оценки релевантности предназначены для сравнения и сортировки, а не для интерпретации как вероятностей.

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

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

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

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

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

Открыть на Hugging Face

ecommerce-product-search-reranker

An open-source cross-encoder reranker for e-commerce product search — the second stage that turns a fast vector search into a precise one. 33M parameters, reranks 50 candidates in ~45 ms on a laptop CPU (no GPU), fine-tuned on 427,655 real human relevance judgments from Amazon's ESCI dataset. Built to sit behind ecommerce-product-search-embeddings, but works behind any retriever.

Do I need a reranker for product search?

If you retrieve with embeddings and show the top 10, the ranking within those candidates is where quality is won or lost. On the held-out ESCI test set (8,956 real shopping queries), reranking our bi-encoder's top-50 from a 1.2M-product corpus:

stageend-to-end nDCG@10 ↑MRR@10 ↑
retriever only0.43490.4219
retriever + this reranker0.51620.4799

+8.1 nDCG points end-to-end, non-overlapping 95% CIs. (Metric counts unjudged products as irrelevant, so absolute values are lower bounds; the delta is the signal.)

One warning the numbers force on us: an off-the-shelf MS MARCO reranker is worse than no reranker at all for ranking judged product pools (0.714 vs the retriever's 0.748 graded nDCG@10). Web-search relevance and product-search relevance are different tasks. Domain fine-tuning is not optional here — it's the difference between helping and hurting.

How do I use it (copy-paste)?

pip install sentence-transformers
from sentence_transformers import CrossEncoder

reranker = CrossEncoder("albertobarnabo/ecommerce-product-search-reranker")

query = "pan that doesnt stick eggs"
candidates = [...]  # top-50 titles from your vector search

ranked = reranker.rank(query, candidates, top_k=10, return_documents=True)
for hit in ranked:
    print(f"{hit['score']:.3f}  {hit['text']}")

Scores come out of a sigmoid in [0, 1] and are monotonic with relevance, but compressed — measured means on held-out judged pools: Exact 0.53, Substitute 0.34, Complement 0.35, Irrelevant 0.25. Use them for ordering and relative thresholds (e.g. "drop anything below 0.3"); do not read them as probabilities or as the ESCI gain values themselves.

Full two-stage pipeline with the matching retriever

from sentence_transformers import SentenceTransformer, CrossEncoder
import numpy as np

retriever = SentenceTransformer("albertobarnabo/ecommerce-product-search-embeddings")
reranker  = CrossEncoder("albertobarnabo/ecommerce-product-search-reranker")

index = retriever.encode_document(titles, normalize_embeddings=True)

def search(query, k_retrieve=50, k_final=10):
    q = retriever.encode_query([query], normalize_embeddings=True)[0]
    cand = np.argsort(-(index @ q))[:k_retrieve]
    ranked = reranker.rank(query, [titles[i] for i in cand], top_k=k_final)
    return [titles[cand[r["corpus_id"]]] for r in ranked]

Is it fast enough on CPU?

Measured on a laptop CPU (Apple M-series, single process):

rerank depthlatency per query
top-2022 ms
top-3032 ms
top-5045 ms

Well inside interactive budgets. This is why the model is 33M parameters and not 500M: bigger rerankers exist, but not ones you can self-host on the same $5 VPS as your shop.

How good is it, honestly?

All numbers on the official ESCI US test split, graded nDCG with the paper's gains (E=1.0/S=0.1/C=0.01/I=0.0), 95% bootstrap CIs:

modelpool nDCG@10full-list nDCG*
random ordering (floor)0.5740.740
zero-shot ms-marco-MiniLM-L12-v20.71410.8340
our bi-encoder (retriever ordering)0.7483—
this reranker0.7601 [0.756–0.764]0.8602

*The full-list column exists because the widely-quoted ESCI-paper baseline of 0.857 uses that metric — on which random ordering already scores 0.740. Any reranker number you see quoted near 0.85 without that floor attached is telling you less than it seems. Our 0.8602 matches the paper's fine-tuned-baseline recipe (same base family, one order of magnitude less compute than the KDD Cup winners' ensembles, which reached ~0.90).

What was it trained on?

The same audited data as the rest of the family — details here — with a three-part mixture per query (505,806 pairs total):

  • all 389,478 human judgments with the official gain as a soft BCE target — pointwise-on-gains is what both top KDD Cup 2022 teams used; the 2nd-place team reported pairwise converged worse;
  • 58,164 random corpus titles at label 0 (score-floor anchors);
  • 58,164 unjudged products retrieved by our own bi-encoder at ranks 20–100, label 0 — so the model trains on the distribution it actually reranks in deployment (the LCE/RocketQA recipe). Rank ≥20 keeps false-negative contamination low, but some of these are inevitably relevant items labeled 0 — a known, accepted noise source.

Dev selection: 1,500 held-out queries, checkpoint chosen on the same graded nDCG@10 reported above. Test split touched once. Training: 2 epochs, batch 128, lr 2e-5, cosine, bf16 — about six minutes on a rented RTX 4090.

Limitations

  • English, Amazon-catalog domain; transfer elsewhere unmeasured.
  • Trained on titles only — pass titles, not full descriptions, for scoring.
  • Latency scales linearly with rerank depth; at depth 200+ on CPU you're out of interactive budgets.
  • Two-stage gains are measured behind our retriever; behind a much stronger or weaker first stage the delta will differ.

Citation

@article{reddy2022shopping,
  title={Shopping Queries Dataset: A Large-Scale {ESCI} Benchmark for Improving Product Search},
  author={Reddy, Chandan K. and M{\`a}rquez, Llu{\'i}s and Valero, Fran and Rao, Nikhil and Zaragoza, Hugo and Bandyopadhyay, Sambaran and Biswas, Arnab and Xing, Anlu and Subbian, Karthik},
  journal={arXiv preprint arXiv:2206.06588},
  year={2022}
}

Family: retriever (33M) · retriever-base (109M) · static ~31MB · dataset

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

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

GPU в ailist

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

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

Подбираем GPU…

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

0 моделей