用语义图增强不确定性建模,有效检测跨句幻觉
Enhancing Uncertainty Modeling with Semantic Graph for Hallucination Detection
- 构建语义图捕捉实体与句子间关系
- 通过关系传播提升句子级幻觉检测能力
- 结合矛盾概率实现更精准的不确定性校准
大语言模型(LLMs)容易产生非事实性或不忠实的陈述,即幻觉,影响实际应用。现有基于不确定性的幻觉检测方法依赖模型输出概率计算不确定性,无需外部知识或频繁采样。然而,多数方法仅关注单个词元的不确定性,忽视了词元与句子间的复杂语义关系,限制了对跨多个词元和句子的幻觉检测。本文提出一种基于语义图增强不确定性建模的幻觉检测方法:首先构建能捕捉实体词元与句子间关系的语义图;接着引入实体间关系进行不确定性传播,提升句子级幻觉检测效果;鉴于幻觉常源于句子间的矛盾,进一步设计基于图的不确定性校准方法,将句子与其在语义图中邻居的矛盾概率融入不确定性计算。在两个数据集上的大量实验表明,本方法显著优于基线,尤其在篇章级幻觉检测上提升19.78%。
原文摘要 · Abstract (English)
Large Language Models (LLMs) are prone to hallucination with non-factual or unfaithful statements, which undermines the applications in real-world scenarios. Recent researches focus on uncertainty-based hallucination detection, which utilizes the output probability of LLMs for uncertainty calculation and does not rely on external knowledge or frequent sampling from LLMs. Whereas, most approaches merely consider the uncertainty of each independent token, while the intricate semantic relations among tokens and sentences are not well studied, which limits the detection of hallucination that spans over multiple tokens and sentences in the passage. In this paper, we propose a method to enhance uncertainty modeling with semantic graph for hallucination detection. Specifically, we first construct a semantic graph that well captures the relations among entity tokens and sentences. Then, we incorporate the relations between two entities for uncertainty propagation to enhance sentence-level hallucination detection. Given that hallucination occurs due to the conflict between sentences, we further present a graph-based uncertainty calibration method that integrates the contradiction probability of the sentence with its neighbors in the semantic graph for uncertainty calculation. Extensive experiments on two datasets show the great advantages of our proposed approach. In particular, we obtain substantial improvements with 19.78% in passage-level hallucination detection.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。