atlas

Research map / Large language models / Language, safety and interpretability

Scalable In-context Ranking with Generative Models

NeurIPS 2025 · Large language models › Language, safety and interpretability · approach: Data and evaluation methodology · 0 citations (OpenAlex)

Read the paperCheck your idea against 108,967 papers

AI-extracted summary. Written by AI from the paper's full text. Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.

Proposes BlockRank, which enforces block-sparse attention over instruction, document and query segments plus an auxiliary contrastive attention loss, enabling linear-in-N in-context ranking with attention-based inference on fine-tuned Mistral-7B.

Problem

In-context ranking with LLMs becomes computationally expensive as the number of candidate documents grows, since full self-attention over the concatenated candidate list scales quadratically, and autoregressive decoding of rankings adds latency.

Approach

Restrict document tokens to attend only to their own document and the shared instruction (block-sparse attention), use a permutation-invariant position scheme for documents, and add an InfoNCE loss on attention mass from signal-carrying query tokens to relevant documents at a middle layer, so relevance can be read from prefill attention without decoding.

Key results

Measured effects reported in the paper

What was changedWhereMeasuredEffect
use BlockRank instead of FIRSTBEIR reranking, 11-dataset average · BEIR (11-dataset average)nDCG@10: 54.3 -> 54.8Helped
replace Full-FT Mistral with BlockRank MistralMistral-7B-v0.3 · NQPrecision@1: 75.5 -> 76.2Helped
replace Full-FT Mistral with BlockRank MistralMistral-7B-v0.3 · MSMarcoMRR@10: 38.3 -> 42.0Helped
add auxiliary attention loss (ablation)BlockRank with structured attention, attention-based inference · MSMarco, N=50Precision@1: 27.8 -> 29.1Helped
add auxiliary attention loss (ablation)Full-FT, attention-based inference · MSMarco, N=50Precision@1: 27.6 -> 28.1Helped
remove NTP loss (ablation)BlockRank, decoding inference · MSMarco, N=50Precision@1: 28.7 -> 15.8Hurt
remove NTP loss (ablation)BlockRank, attention-based inference · MSMarco, N=50Precision@1: 29.1 -> 28.6Hurt
remove auxiliary attention loss (ablation)BlockRank, attention-based inference · MSMarco, N=50Precision@1: 29.1 -> 27.8Hurt
use attention-based inference instead of autoregressive decoding (ablation)BlockRank · MSMarco, N=50MRR@10: 40.0 -> 42.0Helped
include the query in the prompt prefix (ablation)Full-FT-Mistral · MSMarco, N=100Precision@1: 27.2 -> 28.7 (+1.5)Helped
include the query in the prompt prefix (ablation)BlockRank-Mistral · MSMarco, N=100Precision@1: 24.2 -> 28.1 (+3.9)Helped
scale candidate count to N=500BlockRank · MSMarco, N=500Precision@1: 28.7%No clear effect

Surprising findings

Limitations

Experimental setup

Datasets: MSMarco passage ranking Natural Questions (NQ320K) BEIR

Benchmarks: BEIR MSMarco NQ

Metrics: nDCG@10 Precision@1 MRR@10 inference latency

Baselines: Full-FT Mistral FIRST RankZephyr RankVicuna Cross-Encoder monoT5-XL ColBERTv2 GTR-XXL Mistral-7B-Instruct Gemini-2.0-flash BM25

Builds on: FIRST RankZephyr RankVicuna Longformer BigBird

Closest papers by meaning

Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.

Open scime draft

Get the next scime Dispatch and a monthly field update

Free. We send a confirmation link first; every email has a one-click unsubscribe. Privacy