ContextCite: Attributing Model Generation to Context
Benjamin Cohen-Wang, Harshay Shah, Kristian Georgiev, Aleksander Madry
Abstract
How do language models use information provided as context when generating a response? Can we infer whether a particular generated statement is actually grounded in the context, a misinterpretation, or fabricated? To help answer these questions, we introduce the problem of context attribution: pinpointing the parts of the context (if any) that led a model to generate a particular statement. We then present ContextCite, a simple and scalable method for context attribution that can be applied on top of any existing language model. Finally, we showcase the utility of ContextCite through three applications: (1) helping verify generated statements (2) improving response quality by pruning the context and (3) detecting poisoning attacks. We provide code for ContextCite at https://github.com/MadryLab/context-cite.
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
27 top-tier papers have cited it since. Know what they found before your reviewers do.
Lune can draw on
the full paper · the top-tier papers that cite it · related work
Free to start. No credit card required.
Lineage
- The Atlas of In-Context Learning: How Attention Heads Shape In-Context Retrieval Augmentation cites Enabling Large Language Models to Generate Text with Citations
- FActScore: Fine-grained Atomic Evaluation of Factual Precision in Long Form Text Generation cites Enabling Large Language Models to Generate Text with Citations
- FActScore: Fine-grained Atomic Evaluation of Factual Precision in Long Form Text Generation cites Evaluating Verifiability in Generative Search Engines
- Enabling Large Language Models to Generate Text with Citations cites Evaluating Verifiability in Generative Search Engines
Cited by top-tier papers27
- ProxySPEX: Inference-Efficient Interpretability via Sparse Feature Interactions in LLMsLandon Butler, Abhineet Agarwal, Justin Singh Kang, Yigit Efe Erginbas et al.NeurIPS 2025 · 19 citations
- Multi-Level Explanations for Generative Language ModelsLucas Monteiro Paes, Dennis Wei, Hyo Jin Do, Hendrik Strobelt et al.ACL 2025 · 16 citations
- The Atlas of In-Context Learning: How Attention Heads Shape In-Context Retrieval AugmentationPatrick Kahardipraja, Reduan Achtibat, Thomas Wiegand, Wojciech Samek et al.NeurIPS 2025 · 13 citations
- Resisting Contextual Interference in RAG via Parametric-Knowledge ReinforcementChenyu Lin, Yilin Wen, Du Su, Hexiang Tan et al.ICLR 2026 · 13 citations
- Who Taught the Lie? Responsibility Attribution for Poisoned Knowledge in Retrieval-Augmented GenerationBaolei Zhang, Haoran Xin, Yuxi Chen, Zhuqing Liu et al.S&P 2026 · 12 citations
Builds on14
- TRAK: Attributing Model Behavior at ScaleSung Min Park, Kristian Georgiev, Andrew Ilyas, Guillaume Leclerc et al.ICML 2023 · 260 citations
- FActScore: Fine-grained Atomic Evaluation of Factual Precision in Long Form Text GenerationSewon Min, Kalpesh Krishna, Xinxi Lyu, Mike Lewis et al.EMNLP 2023 · 225 citations
- Enabling Large Language Models to Generate Text with CitationsTianyu Gao, Howard Yen, Jiatong Yu, Danqi ChenEMNLP 2023 · 152 citations
- Evaluating Verifiability in Generative Search EnginesNelson F. Liu, Tianyi Zhang, Percy LiangEMNLP Findings 2023 · 143 citations
- DataInf: Efficiently Estimating Data Influence in LoRA-tuned LLMs and Diffusion ModelsYongchan Kwon, Eric Wu, Kevin Wu, James ZouICLR 2024 · 112 citations
Related papers
- On Synthesizing Data for Context Attribution in Question AnsweringGorjan Radevski, Kiril Gashteovski, Shahbaz Syed, Christopher Malon et al.ACL 2025 · 1 citation
- TracLLM: A Generic Framework for Attributing Long Context LLMsYanting Wang, Wei Zou, Runpeng Geng, Jinyuan JiaUSENIX Security 2025
- Attribute or Abstain: Large Language Models as Long Document AssistantsJan Buchmann, Xiao Liu, Iryna GurevychEMNLP 2024
- SelfCite: Self-Supervised Alignment for Context Attribution in Large Language ModelsYung-Sung Chuang, Benjamin Cohen-Wang, Zejiang Shen, Zhaofeng Wu et al.ICML 2025
- Peering into the Mind of Language Models: An Approach for Attribution in Contextual Question AnsweringAnirudh Phukan, Shwetha Somasundaram, Apoorv Saxena, Koustava Goswami et al.ACL Findings 2024 · 4 citations
