AI SeedbankHelp preserve open and free AI for humanity's future

← All models

mixedbread-ai_mxbai-rerank-xsmall-v1

mixedbread-ai · View on Hugging Face ↗

Get this model

Download TorrentMagnet Link

Seeders: · Leechers:

Model card

The complete upstream card, rendered from this payload's README.md — the same hash-verified bytes the torrent distributes. Images and off-site links are removed; the original card on Hugging Face carries them.


library_name: transformers tags:

  • reranker
  • transformers.js
  • sentence-transformers license: apache-2.0 language:
  • en pipeline_tag: text-ranking



The crispy rerank family from Mixedbread.

🍞 Looking for a simple end-to-end retrieval solution? Meet Omni, our multimodal and multilingual model. Get in touch for access.

mxbai-rerank-xsmall-v1

This is the smallest model in our family of powerful reranker models. You can learn more about the models in our blog post.

We have three models:

Quickstart

Currently, the best way to use our models is with the most recent version of sentence-transformers.

pip install -U sentence-transformers

Let's say you have a query, and you want to rerank a set of documents. You can do that with only one line of code:

from sentence_transformers import CrossEncoder

# Load the model, here we use our base sized model
model = CrossEncoder("mixedbread-ai/mxbai-rerank-xsmall-v1")


# Example query and documents
query = "Who wrote 'To Kill a Mockingbird'?"
documents = [
    "'To Kill a Mockingbird' is a novel by Harper Lee published in 1960. It was immediately successful, winning the Pulitzer Prize, and has become a classic of modern American literature.",
    "The novel 'Moby-Dick' was written by Herman Melville and first published in 1851. It is considered a masterpiece of American literature and deals with complex themes of obsession, revenge, and the conflict between good and evil.",
    "Harper Lee, an American novelist widely known for her novel 'To Kill a Mockingbird', was born in 1926 in Monroeville, Alabama. She received the Pulitzer Prize for Fiction in 1961.",
    "Jane Austen was an English novelist known primarily for her six major novels, which interpret, critique and comment upon the British landed gentry at the end of the 18th century.",
    "The 'Harry Potter' series, which consists of seven fantasy novels written by British author J.K. Rowling, is among the most popular and critically acclaimed books of the modern era.",
    "'The Great Gatsby', a novel written by American author F. Scott Fitzgerald, was published in 1925. The story is set in the Jazz Age and follows the life of millionaire Jay Gatsby and his pursuit of Daisy Buchanan."
]

# Lets get the scores
results = model.rank(query, documents, return_documents=True, top_k=3)

JavaScript Example

Install transformers.js

npm i @xenova/transformers

Let's say you have a query, and you want to rerank a set of documents. In JavaScript, you need to add a function:

import { AutoTokenizer, AutoModelForSequenceClassification } from '@xenova/transformers';

const model_id = 'mixedbread-ai/mxbai-rerank-xsmall-v1';
const model = await AutoModelForSequenceClassification.from_pretrained(model_id);
const tokenizer = await AutoTokenizer.from_pretrained(model_id);

/**
 * Performs ranking with the CrossEncoder on the given query and documents. Returns a sorted list with the document indices and scores.
 * @param {string} query A single query
 * @param {string[]} documents A list of documents
 * @param {Object} options Options for ranking
 * @param {number} [options.top_k=undefined] Return the top-k documents. If undefined, all documents are returned.
 * @param {number} [options.return_documents=false] If true, also returns the documents. If false, only returns the indices and scores.
 */
async function rank(query, documents, {
    top_k = undefined,
    return_documents = false,
} = {}) {
    const inputs = tokenizer(
        new Array(documents.length).fill(query),
        {
            text_pair: documents,
            padding: true,
            truncation: true,
        }
    )
    const { logits } = await model(inputs);
    return logits
        .sigmoid()
        .tolist()
        .map(([score], i) => ({
            corpus_id: i,
            score,
            ...(return_documents ? { text: documents[i] } : {})
        }))
        .sort((a, b) => b.score - a.score)
        .slice(0, top_k);
}

// Example usage:
const query = "Who wrote 'To Kill a Mockingbird'?"
const documents = [
    "'To Kill a Mockingbird' is a novel by Harper Lee published in 1960. It was immediately successful, winning the Pulitzer Prize, and has become a classic of modern American literature.",
    "The novel 'Moby-Dick' was written by Herman Melville and first published in 1851. It is considered a masterpiece of American literature and deals with complex themes of obsession, revenge, and the conflict between good and evil.",
    "Harper Lee, an American novelist widely known for her novel 'To Kill a Mockingbird', was born in 1926 in Monroeville, Alabama. She received the Pulitzer Prize for Fiction in 1961.",
    "Jane Austen was an English novelist known primarily for her six major novels, which interpret, critique and comment upon the British landed gentry at the end of the 18th century.",
    "The 'Harry Potter' series, which consists of seven fantasy novels written by British author J.K. Rowling, is among the most popular and critically acclaimed books of the modern era.",
    "'The Great Gatsby', a novel written by American author F. Scott Fitzgerald, was published in 1925. The story is set in the Jazz Age and follows the life of millionaire Jay Gatsby and his pursuit of Daisy Buchanan."
]

const results = await rank(query, documents, { return_documents: true, top_k: 3 });
console.log(results);

Using API

You can use the large model via our API as follows:

from mixedbread_ai.client import MixedbreadAI

mxbai = MixedbreadAI(api_key="{MIXEDBREAD_API_KEY}")

res = mxbai.reranking(
  model="mixedbread-ai/mxbai-rerank-large-v1",
  query="Who is the author of To Kill a Mockingbird?",
  input=[
    "To Kill a Mockingbird is a novel by Harper Lee published in 1960. It was immediately successful, winning the Pulitzer Prize, and has become a classic of modern American literature.",
    "The novel Moby-Dick was written by Herman Melville and first published in 1851. It is considered a masterpiece of American literature and deals with complex themes of obsession, revenge, and the conflict between good and evil.",
    "Harper Lee, an American novelist widely known for her novel To Kill a Mockingbird, was born in 1926 in Monroeville, Alabama. She received the Pulitzer Prize for Fiction in 1961.",
    "Jane Austen was an English novelist known primarily for her six major novels, which interpret, critique and comment upon the British landed gentry at the end of the 18th century.",
    "The Harry Potter series, which consists of seven fantasy novels written by British author J.K. Rowling, is among the most popular and critically acclaimed books of the modern era.",
    "The Great Gatsby, a novel written by American author F. Scott Fitzgerald, was published in 1925. The story is set in the Jazz Age and follows the life of millionaire Jay Gatsby and his pursuit of Daisy Buchanan."
  ],
  top_k=3,
  return_input=false
)

print(res.data)

The API comes with additional features, such as a continous trained reranker! Check out the docs for more information.

Evaluation

Our reranker models are designed to elevate your search. They work extremely well in combination with keyword search and can even outperform semantic search systems in many cases.

Model NDCG@10 Accuracy@3
Lexical Search (Lucene) 38.0 66.4
BAAI/bge-reranker-base 41.6 66.9
BAAI/bge-reranker-large 45.2 70.6
cohere-embed-v3 (semantic search) 47.5 70.9
mxbai-rerank-xsmall-v1 43.9 70.0
mxbai-rerank-base-v1 46.9 72.3
mxbai-rerank-large-v1 48.8 74.9

The reported results are aggregated from 11 datasets of BEIR. We used Pyserini to evaluate the models. Find more in our blog-post and on this spreadsheet.

Community

Please join our Discord Community and share your feedback and thoughts! We are here to help and also always happy to chat.

Citation

@online{rerank2024mxbai,
  title={Boost Your Search With The Crispy Mixedbread Rerank Models},
  author={Aamir Shakir and Darius Koenig and Julius Lipp and Sean Lee},
  year={2024},
  url={https://www.mixedbread.ai/blog/mxbai-rerank-v1},
}

License

Apache 2.0

Magnet link

Opens the swarm directly in your torrent client — no file download needed. Copy-paste works too:

magnet:?xt=urn:btih:70bf957b8479d072a3c7d7bfec2ef81962a27a4f&dn=mixedbread-ai_mxbai-rerank-xsmall-v1

Open magnet in torrent client · infohash 70bf957b8479d072a3c7d7bfec2ef81962a27a4f

Files & hashes

PathSizesha1sha256
LICENSE10.5 KB (10,762 B)0836af1ebee586b8a261b4e768f6000c3b2c742c4b0dfefcb74f1e50a8df72a9f2bf0088753f8568bc479387292469b4948705d4
README.md48.4 KB (49,546 B)e26deb967a0ae98b5607ab94247671fa8c74e4637d0553b55a91f07a820125a5f4ec547489e50493fa2d2d6624fcc0f5725d1c7f
added_tokens.json23 B (23 B)8ee2b3623dc526b123cde0aaa401755b82299af2dc046d04c9b0ada7ae6f1dc89c465801799acdf0c9a6aab8c15a1b2d5ca4e91f
config.json968 B (968 B)f602a0b1b8bd8d95847261c2a80b72a612f67eed470a53befc79da411cc04e466770d9f219f3c14adb276bfa0a58df28774ceade
model.safetensors135.1 MB (141,685,186 B)85a8005df32d622386bfa2730c2e8bca1177c576a29bc212faf59c136ad0fd5712ecd2346e7b32c44a25b690625bc9ecebb14b8f
onnx/quantize_config.json1.2 KB (1,193 B)f053daf5ac81884afbedd2a8f9bec186c673c894ef9c74e2f5479dec41d6e82e49ee4b7cb3632c023cfa3cc4dc5032776fc4ba49
special_tokens_map.json970 B (970 B)83fb22de184abab1b193b1f6001e3015e865e50bb2f1b2f15f29a6b6d9d6ea4eca1675d2c231a71477f151d48f79cc83a625ba21
spm.model2.4 MB (2,464,616 B)1993e578cb006883fd01014f831c6261e8136823c679fbf93643d19aab7ee10c0b99e460bdbc02fedf34b92b05af343b4af586fd
tokenizer.json8.2 MB (8,649,139 B)32f09d02dcb997643f7f1388eb7d695de0d95bef305674b4d785287feecfb5f73f24aa75e9b57c87c579cfe24fbd207987d4b4c4
tokenizer_config.json1.4 KB (1,447 B)7eddb032cc3e251b0008f974256f8f0bd0a46fe4aafc9f36a056307bf0cbfcbd42fe00d9df89083d23db6114466c8bfaedb09ce5

Cite this release

Canonical URL
https://aiseedbank.org/models/mixedbread-ai_mxbai-rerank-xsmall-v1/
Slug
mixedbread-ai_mxbai-rerank-xsmall-v1
Infohash
70bf957b8479d072a3c7d7bfec2ef81962a27a4f
License
apache-2.0
Signing key fingerprint
85a3b32c3712427b

Every file carries a locally computed sha256 — verify a download against the signed sums: mixedbread-ai_mxbai-rerank-xsmall-v1.SHA256SUMS (+ minisign signature).

Provenance

Upstream repositorymixedbread-ai/mxbai-rerank-xsmall-v1
Revision (pinned)b5c6e9da73abc3711f593f705371cdbe9e0fe422
Fetched at2026-09-04T02:54:09Z
License at fetchapache-2.0
Snapshot toolhuggingface · seedbank 0.1.0

Trackers

✓ verified · rehash-vs-hf-metadata at 2026-09-04T02:54:13Z

apache-2.0145.8 MB (152,863,850 bytes)transformersonnxsafetensorsdeberta-v2text-classificationrerankertransformers.jssentence-transformerstext-rankingtext-embeddings-inferenceendpoints_compatible1 language (en)