atlas

Research map / Architectures and efficiency / Attention and transformers

Benchmarking and Building Long-Context Retrieval Models with LoCo and M2-BERT

ICML 2024 · Architectures and efficiency › Attention and transformers · approach: Sparse attention for long-context LLMs · 1 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.

Introduces LoCoV1, a 12-task long-context retrieval benchmark, and M2-BERT, an 80M-parameter Monarch Mixer state-space retrieval encoder scaling to 32K tokens, finetuned with orthogonal projection loss at batch size 1.

Problem

Retrieval encoders perform poorly on long documents (10K+ tokens) where relevance requires synthesizing information across the full text; existing benchmarks can be solved by truncation or chunking, and contrastive MNRL finetuning needs large batches that long-context GPU memory cannot afford.

Approach

Combine a Monarch Mixer (subquadratic state-space) BERT-like encoder, a mixed short/long pretraining corpus with warm-started long-context stages, and orthogonal projection loss, which enables single-sample (B=1) finetuning for retrieval, plus a new long-context benchmark (LoCoV1) where chunking fails.

Key results

Measured effects reported in the paper

What was changedWhereMeasuredEffect
Increase maximum sequence length from 128 to 32768 tokensM2-BERT · LoCoV1nDCG@10: 70.3 -> 94.7Helped
Pretrain on mixed short and long examples rather than short examples only (ablation)M2-BERT · LoCoV1nDCG@10: 37.2 -> 55.4Helped
Pretrain on mixed short and long examples rather than long examples only (ablation)M2-BERT · LoCoV1nDCG@10: 44.9 -> 55.4Helped
Use an 8k pretrained checkpoint to warm-start 32k pretraining rather than random initialization (ablation)M2-BERT-32k · M2-BERT-32k pretrainingMLM accuracy: 4.8 -> 33.9Helped
Use orthogonal projection loss instead of MNRLM2-BERT-32k · LoCoV1nDCG@10: 70.4 -> 94.7Helped
Use orthogonal projection loss instead of prototype loss (ablation)M2-BERT-32k · LoCoV1nDCG@10: 63.2 -> 94.7Helped
Use chunked embeddings instead of truncation for Jina Embeddings (ablation)Jina Embeddings · LoCoV1nDCG@10: 67.2 -> 19.2Hurt
Use chunked embeddings instead of truncation for BGE-Large Fine-tuned (ablation)BGE-Large Fine-tuned · LoCoV1nDCG@10: 64.8 -> 61.6Hurt
Use chunked embeddings instead of truncation for E5-Mistral (ablation)E5-Mistral · LoCoV1nDCG@10: 71.4 -> 70.3Hurt
Use chunked embeddings instead of truncation for OpenAI Ada (ablation)OpenAI Ada · LoCoV1nDCG@10: 63.2 -> 63.4No clear effect
Increase M2-BERT maximum sequence length from 128 to 32768 tokensM2-BERT · BEIRnDCG@10: 38.7 vs. 40.0No clear effect
Use M2-BERT-128 rather than SentenceBERTM2-BERT-128 · MTEBaverage score: 63.1 -> 63.3No clear effect

Surprising findings

Limitations

Experimental setup

Datasets: C4 Wikipedia BookCorpus SummScreenFD Gov. Report QMSUM QASPER MultiFieldQA 2WikiMQA Passage Retrieval CourtListener Australian Legal Case Reports

Benchmarks: LoCoV1 BEIR MTEB Needle-in-the-Haystack (NQ-based synthetic)

Metrics: nDCG@10 throughput / embedding time

Baselines: BGE-Large E5-Mistral Jina Embeddings OpenAI text-embedding-ada-002 ColBERTv2 BM25 SentenceBERT Voyage-001 Cohere embed-english-v3.0

Builds on: Monarch Mixer multiple negatives ranking loss orthogonal projection loss BEIR

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