WARP: Wasserstein-Aligned RAG for Population Opinions

Aman Singh Thakur, Aditya Agrawal, Alwarappan Nakkiran, Alex Karlsson
8/24/2026
cs.IRcs.CL
rag

No confident code implementation found for this paper.

Abstract

RAG systems are increasingly used to summarize what large collections of documents say. A user asks "What do people think about X?" and receives an answer that reads as consensus.

Show full abstract

But standard top-k retrieval ranks documents by query similarity, not by how faithfully they represent the population, so minority views quietly disappear. Existing fixes fall short. Diversity re-rankers like MMR and DPP spread retrieved documents apart, but with no target distribution to aim for. Calibration methods based on KL or JS divergence do target one, yet treat opinion bins as unordered: confusing strong positive with strong negative costs no more than an adjacent-bin miss. We introduce WARP, a family of post-retrieval algorithms that calibrate retrieved evidence to the population's opinion distribution. WARP first recovers underrepresented opinions that cosine ranking may bury, then uses Wasserstein-1 distance to select documents whose sentiment-intensity distribution matches the population target, capturing the ordinal structure ignored by KL and JS divergence. We develop three variants for dense, sparse, and variable candidate pools, trading off calibration quality and speed. Across three review domains spanning 35K documents, 156 queries, and 26 entities, WARP's domain-matched variants reduce distributional error by at least 43% with sub-second latency. These gains carry through to generation: a five-judge LLM panel prefers WARP-generated answers in 86% of decided comparisons at k <= 5.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{thakur2026warp,
  title  = {WARP: Wasserstein-Aligned RAG for Population Opinions},
  author = {Aman Singh Thakur and Aditya Agrawal and Alwarappan Nakkiran and Alex Karlsson},
  year   = {2026},
  eprint = {2608.22859},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2608.22859v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2608.22859.svg)](https://codeofpaper.com/paper/2608.22859)

Discussion