arXiv:2501.13573cs.CL2025-01ACL被引 22

通过优化检索头提升大模型回答的上下文忠实性

Improving Contextual Faithfulness of Large Language Models via Retrieval Heads-Induced Optimization

  • 用掩码检索头生成不忠实样本,指导模型学习区分真假回答
  • 联合训练使模型在控制标记下能分辨并生成更忠实输出
  • 自对齐对比解码增强差异,适合长文本问答场景

在检索增强型大语言模型中确保上下文忠实性对构建可信的信息检索系统至关重要,尤其在长篇问答(LFQA)场景下。本文发现LFQA忠实性与负责检索上下文信息的注意力头(检索头)存在显著相关性。基于此,提出RHIO框架,旨在教会模型显式区分忠实与不忠实生成。该方法首先通过选择性掩码检索头,生成模拟真实模型内在错误的不忠实样本;随后将这些样本纳入联合训练,使模型能在控制标记条件下区分忠实与不忠实输出。此外,利用控制标记自诱导对比输出,通过对比解码放大差异。为促进上下文忠实性的评估,还构建了GroundBench基准,整合五个现有LFQA数据集。在GroundBench上的大量实验表明,RHIO显著提升忠实性,甚至优于GPT-4o。

原文摘要 · Abstract (English)

Ensuring contextual faithfulness in retrieval-augmented large language models (LLMs) is crucial for building trustworthy information-seeking systems, particularly in long-form question-answering (LFQA) scenarios. In this work, we identify a salient correlation between LFQA faithfulness and retrieval heads, a set of attention heads responsible for retrieving contextual information. Leveraging this insight, we propose RHIO, a framework designed to teach LLMs to explicitly discriminate between faithful and unfaithful generations. RHIO first augments unfaithful samples that simulate realistic model-intrinsic errors by selectively masking retrieval heads. Then, these samples are incorporated into joint training, enabling the model to distinguish unfaithful outputs from faithful ones conditioned on control tokens. Furthermore, these control tokens are leveraged to self-induce contrastive outputs, amplifying their difference through contrastive decoding. Additionally, to facilitate the evaluation of contextual faithfulness, we also introduce GroundBench, a comprehensive benchmark compiled from five existing LFQA datasets. Extensive experimental results on GroundBench demonstrate that RHIO significantly improves faithfulness, even outperforming GPT-4o.

大模型忠实性检索增强对比学习

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。