Model reference · open weights

E2Rank

Embeddings Alibaba-NLP Embeddings 3 builds Open weights 598 dl/mo

E2Rank is an open-weight embedding model from Alibaba. E2Rank-0.6B (BF16) weighs 1.2 GB; the smallest configuration that runs it is RTX 3060 12 GB.

  • E2Rank is a text embedding model developed by Alibaba that unifies retrieval and listwise reranking into a single efficient system.
  • The 0.6B variant contains 596 million parameters, supports a context length of 40,960 tokens, and is released under the Apache 2.0 license.
  • It uses cosine similarity between query and document embeddings to perform ranking, achieving strong results on the BEIR benchmark while maintaining low latency.

Summary of the Alibaba-NLP/E2Rank-0.6B model card, 2026-10-01

What it is

Released byAlibaba
Released2025-10-24
Parameters596M
VRAM1.2 GB for the weights

What it runs on

Memory and cards for E2Rank-0.6B (BF16)

1.2 GBweights, file size
1.1 GBruntime overhead
CardRunsMemory
RTX 3060 12 GBfits11.6 GB
RTX 4060 Ti 16 GBfits15.4 GB
RTX 3090 24 GBfits23.4 GB
RTX 4090 24 GBfits23.4 GB
RTX 5090 32 GBfits31.0 GB
L40S 48 GBfits44.0 GB
A100 80 GBfits78.2 GB
H100 80 GBfits78.1 GB
RTX PRO 6000 Blackwell 96 GBfits93.8 GB
DGX Spark (GB10) 128 GB unifiedfits107 GB
H200 141 GBfits138 GB
B200 180 GBfits176 GB

Builds

Sizes, precisions & builds

BuildParamsPrecisionWeightsSmallest setup
E2Rank-0.6B (above) ↗ 596MBF16 1.2 GBRTX 3060 12 GB
E2Rank-4B ↗ 4.0BBF16 8.0 GBRTX 3060 12 GB
E2Rank-8B ↗ 7.6BBF16 15.1 GBRTX 4090 24 GB

From the model card

What Alibaba says about E2Rank

Read the model card

We introduce E2Rank, meaning Efficient Embedding-based Ranking (also meaning Embedding-to-Rank), which extends a single text embedding model to perform both high-quality retrieval and listwise reranking, thereby achieving strong effectiveness with remarkable efficiency.

By applying cosine similarity between the query and document embeddings as a unified ranking function, the listwise ranking prompt, which is constructed from the original query and its candidate documents, serves as an enhanced query enriched with signals from the top-K documents, akin to pseudo-relevance feedback (PRF) in traditional retrieval models. This design preserves the efficiency and representational quality of the base embedding model while significantly improving its reranking performance.

Empirically, E2Rank achieves state-of-the-art results on the BEIR reranking benchmark and demonstrates competitive performance on the reasoning-intensive BRIGHT benchmark, with very low reranking latency. We also show that the ranking training process improves embedding performance on the MTEB benchmark. Our findings indicate that a single embedding model can effectively unify retrieval and reranking, offering both computational efficiency and competitive ranking accuracy.

Our work highlights the potential of single embedding models to serve as unified retrieval-reranking engines, offering a practical, efficient, and accurate alternative to complex multi-stage ranking systems.

🚀 Quick Start

Model List

Supported TaskModel NameSizeLayersSequence LengthEmbedding DimensionInstruction Aware
Embedding + RerankingAlibaba-NLP/E2Rank-0.6B0.6B2832K1024Yes
Embedding + RerankingAlibaba-NLP/E2Rank-4B4B3632K2560Yes
Embedding + RerankingAlibaba-NLP/E2Rank-8B8B3632K4096Yes
Embedding OnlyAlibaba-NLP/E2Rank-0.6B-Embedding-Only0.6B2832K1024Yes
Embedding OnlyAlibaba-NLP/E2Rank-0.6B-Embedding-Only4B3632K2560Yes
Embedding OnlyAlibaba-NLP/E2Rank-0.6B-Embedding-Only8B3632K4096Yes

Note:

  • Embedding Only indicates that the model is trained only with the constrative learning and support embedding tasks, while Embedding + Reranking indicates the full E2Rank model trained with both embedding and reranking objectives (for more detals, please refer to the paper).
  • Instruction Aware notes whether the model supports customizing the input instruction according to different tasks.

Usage

Embedding Model

The usage of E2Rank as an embedding model is similar to Qwen3-Embedding. The only difference is that Qwen3-Embedding will automatically append an EOS token, while E2Rank requires users to manully append the special token `` at the end of each input text.

vLLM Usage (recommended)

# Requires vllm>=0.8.5
import torch
import vllm
from vllm import LLM
from vllm.config import PoolerConfig

def get_detailed_instruct(task_description: str, query: str) -> str:
    return f'Instruct: {task_description}\nQuery:{query}'

# Each query must come with a one-sentence instruction that describes the task
task = 'Given a web search query, retrieve relevant passages that answer the query'

queries = [
    get_detailed_instruct(task, 'What is the capital of China?'),
    get_detailed_instruct(task, 'Explain gravity')
]
# No need to add instruction for retrieval documents
documents = [
    "The capital of China is Beijing.",
    "Gravity is a force that attracts two bodies towards each other. It gives weight to physical objects and is responsible for the movement of planets around the sun."
]
input_texts = queries + documents
input_texts = [t + "" for t in input_texts]

model = LLM(
    model="Alibaba-NLP/E2Rank-0.6B",
    task="embed",
    override_pooler_config=PoolerConfig(pooling_type="LAST", normalize=True)
)

outputs = model.embed(input_texts)
embeddings = torch.tensor([o.outputs.embedding for o in outputs])
scores = (embeddings[:2] @ embeddings[2:].T)
print(scores.tolist())
# [[0.5958386659622192, 0.030148349702358246], [0.060259245336055756, 0.5595865249633789]]
# Requires transformers>=4.51.0
import torch
import torch.nn.functional as F

from torch import Tensor
from transformers import AutoTokenizer, AutoModel

def last_token_pool(last_hidden_states: Tensor, attention_mask: Tensor) -> Tensor:
    left_padding = (attention_mask[:, -1].sum() == attention_mask.shape[0])
    if left_padding:
        return last_hidden_states[:, -1]
    else:
        sequence_lengths = attention_mask.sum(dim=1) - 1
        batch_size = last_hidden_states.shape[0]
        return last_hidden_states[torch.arange(batch_size, device=last_hidden_states.device), sequence_lengths]

def get_detailed_instruct(task_description: str, query: str) -> str:
    return f'Instruct: {task_description}\nQuery:{query}'

# Each query must come with a one-sentence instruction that describes the task
task = 'Given a web search query, retrieve relevant passages that answer the query'

queries = [
    get_detailed_instruct(task, 'What

Quoted from the model card on Hugging Face. The full card is behind the Hugging Face link above.

© 2026 AxForge · EU-hosted AI infrastructure Pricing Docs Trust Privacy Terms