arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2407.21424cs.CLcs.AIcs.LGstat.ML

面向 LLM 的高性价比幻觉检测

Cost-Effective Hallucination Detection for LLMs

Amazon Web Services(亚马逊网络服务);Amazon(亚马逊公司);Helsing(赫尔辛公司)

Simon Valentin, Jinmiao Fu, Gianluca Detommaso, Shaoyuan Xu, Giovanni Zappella, Bryan Wang

AI总结:

本文研究生产环境中 LLM 的事后幻觉检测,提出经属性校准并融合多种评分器的多评分框架,在问答、事实验证和摘要任务上以更低计算成本达到最优检测性能。

摘要:

大型语言模型(LLM)容易产生幻觉,即生成不可靠的输出,这些输出不忠于输入或外部事实,或者存在内部不一致。在本工作中,我们解决生产环境中事后幻觉检测面临的若干挑战。我们的幻觉检测流程包括:首先,生成一个置信度分数,用于表示所生成答案是幻觉的可能性;其次,根据输入和候选回答的属性对该分数进行校准;最后,通过对校准后的分数设置阈值来执行检测。我们在不同数据集上对多种最先进的评分方法进行基准测试,涵盖问答、事实验证和摘要任务。我们使用多种 LLM,以确保对性能进行全面评估。我们表明,校准各个评分方法对于确保具备风险意识的下游决策至关重要。基于没有任何单一分数能在所有情况下表现最佳这一发现,我们提出了一个多评分框架,该框架结合不同分数,并在所有数据集上取得最佳性能。我们进一步引入高性价比的多评分方法,它能够匹敌甚至超越更昂贵的检测方法,同时显著降低计算开销。

英文摘要:

Large language models (LLMs) can be prone to hallucinations - generating unreliable outputs that are unfaithful to their inputs, external facts or internally inconsistent. In this work, we address several challenges for post-hoc hallucination detection in production settings. Our pipeline for hallucination detection entails: first, producing a confidence score representing the likelihood that a generated answer is a hallucination; second, calibrating the score conditional on attributes of the inputs and candidate response; finally, performing detection by thresholding the calibrated score. We benchmark a variety of state-of-the-art scoring methods on different datasets, encompassing question answering, fact checking, and summarization tasks. We employ diverse LLMs to ensure a comprehensive assessment of performance. We show that calibrating individual scoring methods is critical for ensuring risk-aware downstream decision making. Based on findings that no individual score performs best in all situations, we propose a multi-scoring framework, which combines different scores and achieves top performance across all datasets. We further introduce cost-effective multi-scoring, which can match or even outperform more expensive detection methods, while significantly reducing computational overhead.

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

↑