arXivDaily arXiv每日学术速递 周一至周五更新
​通知:联邦节假日调休:哥伦布日 / 原住民日(Columbus Day / Indigenous Peoples' Day),今日(13日)无更新。
arXiv 2602.18145cs.CL

基于频率感知注意力的LLM幻觉检测

Detecting Contextual Hallucinations in LLMs with Frequency-Aware Attention

Department of Informatics, King's College London, UK(伦敦国王学院信息学院);Department of Statistics, University of Warwick, UK(沃里克大学统计系);School of Computer Science, The University of Sheffield, UK(谢菲尔德大学计算机科学学院);The Alan Turing Institute, UK(艾伦·图灵研究所)

Siya Qi, Yudong Chen, Runcong Zhao, Qinglin Zhu, Zhanghao Hu, Wei Liu, Yulan He, Zheng Yuan, Lin Gui

AI总结:

本文提出一种基于频率感知注意力的轻量级幻觉检测方法,通过分析生成过程中注意力的高频成分,有效识别幻觉token,提升了LLM在上下文生成中的可靠性。

摘要:

在基于上下文的生成中,幻觉检测对于确保大语言模型(LLM)的可靠性至关重要。先前的研究探索了生成过程中可用的内在信号,其中注意力提供了对基础行为的直接视角。然而,现有方法通常依赖于粗略的摘要,无法捕捉注意力中的细粒度不稳定性。受信号处理的启发,我们通过分析生成过程中注意力的变化引入了对注意力的频率感知视角。我们将注意力分布建模为离散信号,并提取反映注意力快速局部变化的高频成分。我们的分析表明,幻觉token与高频注意力能量相关,反映了碎片化和不稳定的 grounding 行为。基于这一洞察,我们开发了一种轻量级的幻觉检测器,利用高频注意力特征。在RAGTruth和HalluRAG基准测试中,我们的方法在模型和任务上均优于基于验证、内部表示和注意力的方法。

英文摘要:

Hallucination detection is critical for ensuring the reliability of large language models (LLMs) in context-based generation. Prior work has explored intrinsic signals available during generation, among which attention offers a direct view of grounding behavior. However, existing approaches typically rely on coarse summaries that fail to capture fine-grained instabilities in attention. Inspired by signal processing, we introduce a frequency-aware perspective on attention by analyzing its variation during generation. We model attention distributions as discrete signals and extract high-frequency components that reflect rapid local changes in attention. Our analysis reveals that hallucinated tokens are associated with high-frequency attention energy, reflecting fragmented and unstable grounding behavior. Based on this insight, we develop a lightweight hallucination detector using high-frequency attention features. Experiments on the RAGTruth and HalluRAG benchmarks show that our approach achieves performance gains over verification-based, internal-representation-based, and attention-based methods across models and tasks.

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

↑