Long-context LLMs are increasingly in demand for applications such as retrieval-augmented generation. To defray the cost of pretraining LLMs over long contexts, recent work takes an approach of synthetic context extension: fine-tuning LLMs with synthetically generated long-context data in a post-training stage. However, it remains unclear how and why this synthetic context extension imparts abilities for downstream long-context tasks. In this paper, we investigate fine-tuning on synthetic data for three long-context tasks that require retrieval and reasoning. We vary the realism of "needle" concepts to be retrieved and diversity of the surrounding "haystack" context, from using LLMs to construct synthetic documents to using templated relations and creating symbolic datasets. We find that models trained on synthetic data fall short of the real data, but surprisingly, the mismatch can be interpreted and even predicted in terms of a special set of attention heads that are responsible for retrieval over long context, retrieval heads (Wu et al., 2024). The retrieval heads learned on synthetic data have high overlap with retrieval heads learned on real data, and there is a strong correlation between the recall of heads learned and the downstream performance of a model. Furthermore, with attention knockout and activation patching, we mechanistically show that retrieval heads are necessary and explain model performance, although they are not totally sufficient. Our results shed light on how to interpret synthetic data fine-tuning performance and how to approach creating better data for learning real-world capabilities over long contexts.
Multi-Head RAG: Solving Multi-Aspect Problems with LLMs
Department of Computer Science, ETH Zurich(苏黎世联邦理工学院计算机科学系);IDEAS Research Institute(IDEAS研究 institute);NASK National Research Institute(国家研究 institute)
Building Open-Retrieval Conversational Question Answering Systems by Generating Synthetic Data and Decontextualizing User Questions
Department of Informatics, Athens University of Economics and Business(雅典经济与商业大学信息学院);Omilia - Conversational Intelligence(Omilia-对话智能);Archimedes, Athena Research Center(雅典研究中心Archimedes);NCSR Demokritos(德摩斯蒂斯国家研究中心)
Think Parallax: Solving Multi-Hop Problems via Multi-View Knowledge-Graph-Based Retrieval-Augmented Generation
Yangtze Delta Region Institute (Huzhou), University of Electronic Science and Technology of China(长江三角洲地区研究院(湖州),电子科学与技术大学);School of Information and Software Engineering, University of Electronic Science and Technology of China(信息与软件工程学院,电子科学与技术大学)
CRAFT Your Dataset: Task-Specific Synthetic Dataset Generation Through Corpus Retrieval and Augmentation
Department of Computer Science, University of Copenhagen(哥本哈根大学计算机科学系);Center for Information and Language Processing (CIS), LMU Munich(慕尼黑大学信息与语言处理中心);Munich Center for Machine Learning (MCML)(慕尼黑机器学习中心)
Improving Contextual Faithfulness of Large Language Models via Retrieval Heads-Induced Optimization
Harbin Institute of Technology(哈尔滨工业大学);Peng Cheng Laboratory(鹏城实验室);Northeastern University(东北大学);The University of Hong Kong(香港大学);iFLYTEK Research(讯飞研究院)
Learning Hard Retrieval Decoder Attention for Transformers
DFKI(德国人工智能研究中心);Saarland University(萨尔大学);China Mobile Online Services(中国移动在线服务有限公司);Tianjin University(天津大学);Global Tone Communication Technology Co., Ltd.(全球语通通信技术有限公司)
DeCoRe: Decoding by Contrasting Retrieval Heads to Mitigate Hallucinations
University of Edinburgh(爱丁堡大学);Centre for AI, Data Science & Artificial Intelligence, R&D, AstraZeneca(阿斯利康研发中心人工智能、数据科学与人工智能中心);University College London(伦敦大学学院)
The Atlas of In-Context Learning: How Attention Heads Shape In-Context Retrieval Augmentation
Department of Artificial Intelligence, Fraunhofer Heinrich Hertz Institute(人工智能系,弗劳恩霍夫海因里希·赫兹研究所);Department of Electrical Engineering and Computer Science, Technische Universität Berlin(电气工程与计算机科学系,柏林技术大学);BIFOLD - Berlin Institute for the Foundations of Learning and Data(柏林学习与数据基础研究所);Centre of eXplainable Artificial Intelligence, Technological University Dublin(可解释人工智能中心,都柏林技术大学)
HeteroCache: A Dynamic Retrieval Approach to Heterogeneous KV Cache Compression for Long-Context LLM Inference
School of Software Technology, Zhejiang University(浙江大学软件学院);China Mobile (Zhejiang) Research & Innovation Institute(中国移动(浙江)研究院);State Key Lab of CAD&CG, Zhejiang University(浙江大学CAD与CG国家重点实验室);Geely Automobile Research Institute (Ningbo) Co., Ltd.(吉利汽车研究院(宁波)有限公司);FABU Inc.(FABU公司)
SEAL: Scaling to Emphasize Attention for Long-Context Retrieval
Department of Convergence IT Engineering(融合IT工程系);Department of Computer Science and Engineering(计算机科学与工程系);Graduate School of Artificial Intelligence(人工智能研究生院)
Retrieval-Reasoning Large Language Model-based Synthetic Clinical Trial Generation
Institute for Clarity in Documentation(清晰文档研究所);Inria Paris-Rocquencourt(巴黎- Rocquencourt 国家信息与自动化研究所);Rajiv Gandhi University(拉吉夫·甘地大学);Tsinghua University(清华大学);Palmer Research Laboratories(帕勒实验室);University of Chicago(芝加哥大学);Stanford University(斯坦福大学);Purdue University(普渡大学);University of Southern California(南加州大学)