通过自适应选关键词,提升大模型幻觉检测稳定性。
Robust Hallucination Detection in LLMs via Adaptive Token Selection
- 将幻觉检测建模为跨标记的多实例学习,动态选择关键标记。
- 在四个基准上显著优于现有方法,尤其在长文本和稀疏幻觉场景中表现更稳。
- 适合需要高可靠性的生成系统、安全评测及模型可解释性研究者。
大语言模型中的幻觉问题严重影响其安全性与部署应用。近期研究发现,模型内部表示中蕴含真伪线索,可用于构建检测器。然而,现有方法依赖预设标记的内部表征,在自由生成中因长度变化和幻觉实体分布稀疏而性能波动大。为此,我们提出HaMI:通过自适应选择最具幻觉指示性的标记,实现鲁棒检测。该方法将幻觉检测建模为序列内标记级的多实例学习,联合优化标记选择与检测过程,适用于多种生成形式。在四个幻觉检测基准上的实验表明,HaMI显著超越现有最先进方法。
原文摘要 · Abstract (English)
Hallucinations in large language models (LLMs) pose significant safety concerns that impede their broader deployment. Recent research in hallucination detection has demonstrated that LLMs' internal representations contain truthfulness hints, which can be harnessed for detector training. However, the performance of these detectors is heavily dependent on the internal representations of predetermined tokens, fluctuating considerably when working on free-form generations with varying lengths and sparse distributions of hallucinated entities. To address this, we propose HaMI, a novel approach that enables robust detection of hallucinations through adaptive selection and learning of critical tokens that are most indicative of hallucinations. We achieve this robustness by an innovative formulation of the Hallucination detection task as Multiple Instance (HaMI) learning over token-level representations within a sequence, thereby facilitating a joint optimisation of token selection and hallucination detection on generation sequences of diverse forms. Comprehensive experimental results on four hallucination benchmarks show that HaMI significantly outperforms existing state-of-the-art approaches.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。