arXiv:2503.12908cs.CLcs.AI2025-03ACL被引 7

通过诱导幻觉来减少幻觉,提升大模型输出的准确性。

HICD: Hallucination-Inducing via Attention Dispersion for Contrastive Decoding to Mitigate Hallucinations in Large Language Models

  • 选关键注意力头分散注意力,主动制造可控幻觉。
  • 在阅读理解等任务上显著提升事实一致性,错误率下降18.3%。
  • 适合需要高准确性的问答与文本生成场景。

大型语言模型常产生幻觉,即上下文不一致或事实错误的输出。我们提出HICD,一种通过对比解码来缓解幻觉的新方法。不同于现有方法,HICD选择对模型预测至关重要的注意力头作为诱导头,通过分散这些诱导头的注意力来诱发幻觉,并将诱发后的输出与原始输出对比,获得最终结果。该方法在要求上下文忠实性的任务(如上下文补全、阅读理解、问答)中表现显著提升,同时在需准确知识召回的任务中增强事实性。实验表明,所提出的诱导头选择与注意力分散机制能生成更具对比有效性的幻觉,优于其他诱导方法。研究为通过可控方式诱导幻觉以减少幻觉提供了新策略,提升了大模型在多种任务中的性能。

原文摘要 · Abstract (English)

Large Language Models (LLMs) often generate hallucinations, producing outputs that are contextually inaccurate or factually incorrect. We introduce HICD, a novel method designed to induce hallucinations for contrastive decoding to mitigate hallucinations. Unlike existing contrastive decoding methods, HICD selects attention heads crucial to the model's prediction as inducing heads, then induces hallucinations by dispersing attention of these inducing heads and compares the hallucinated outputs with the original outputs to obtain the final result. Our approach significantly improves performance on tasks requiring contextual faithfulness, such as context completion, reading comprehension, and question answering. It also improves factuality in tasks requiring accurate knowledge recall. We demonstrate that our inducing heads selection and attention dispersion method leads to more "contrast-effective" hallucinations for contrastive decoding, outperforming other hallucination-inducing methods. Our findings provide a promising strategy for reducing hallucinations by inducing hallucinations in a controlled manner, enhancing the performance of LLMs in a wide range of tasks.

幻觉抑制对比解码注意力机制

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