arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2305.14739cs.CL
收藏

信任你的证据:通过上下文感知解码减少幻觉

Trusting Your Evidence: Hallucinate Less with Context-aware Decoding

University of Washington(华盛顿大学);Meta AI

Weijia Shi, Xiaochuang Han, Mike Lewis, Yulia Tsvetkov, Luke Zettlemoyer, Scott Wen-tau Yih

AI总结:

提出上下文感知解码(CAD),通过对比输出分布放大有无上下文时的概率差异,无需额外训练即可显著提升多种语言模型在摘要任务中的忠实度,并有效解决知识冲突问题。

摘要:

语言模型(LMs)通常难以充分关注输入上下文,并生成不忠实或包含幻觉的文本。为了缓解这一问题,我们提出了上下文感知解码(CAD),它遵循一种对比输出分布,放大模型在有上下文和无上下文时输出概率之间的差异。我们的实验表明,CAD无需额外训练,即可显著提升不同LM系列(包括OPT、GPT、LLaMA和FLAN-T5)在摘要任务中的忠实度(例如,LLaMA在事实性指标上获得14.3%的提升)。此外,当模型先验知识与提供的上下文相矛盾时,CAD在覆盖模型先验知识方面尤为有效,从而在解决知识冲突至关重要的任务中带来显著改进。

英文摘要:

Language models (LMs) often struggle to pay enough attention to the input context, and generate texts that are unfaithful or contain hallucinations. To mitigate this issue, we present context-aware decoding (CAD), which follows a contrastive output distribution that amplifies the difference between the output probabilities when a model is used with and without context. Our experiments show that CAD, without additional training, significantly improves the faithfulness of different LM families, including OPT, GPT, LLaMA and FLAN-T5 for summarization tasks (e.g., 14.3% gain for LLaMA in factuality metrics). Furthermore, CAD is particularly effective in overriding a model's prior knowledge when it contradicts the provided context, leading to substantial improvements in tasks where resolving the knowledge conflict is essential.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑