Skip to main content
QUICK REVIEW

[论文解读] Looking for a Needle in a Haystack: A Comprehensive Study of Hallucinations in Neural Machine Translation

Guerreiro, Nuno M., Elena Voita|arXiv (Cornell University)|Aug 10, 2022
Adversarial Robustness in Machine Learning被引用 7
一句话总结

本文在无需数据扰动的自然、领域内设置下,对神经机器翻译(NMT)中的幻觉现象进行了严谨研究。研究提出了一个包含3,415个标注幻觉的语料库,评估了多种检测方法——包括序列对数概率和基于不确定性的检测器——发现对数概率方法优于专门设计的启发式方法和质量估计方法。作者进一步提出了DeHallucinator,一种测试时方法,通过MC-dropout重排序将幻觉率降低三倍,检测召回率从33%提升至85%。

ABSTRACT

Although the problem of hallucinations in neural machine translation (NMT) has received some attention, research on this highly pathological phenomenon lacks solid ground. Previous work has been limited in several ways: it often resorts to artificial settings where the problem is amplified, it disregards some (common) types of hallucinations, and it does not validate adequacy of detection heuristics. In this paper, we set foundations for the study of NMT hallucinations. First, we work in a natural setting, i.e., in-domain data without artificial noise neither in training nor in inference. Next, we annotate a dataset of over 3.4k sentences indicating different kinds of critical errors and hallucinations. Then, we turn to detection methods and both revisit methods used previously and propose using glass-box uncertainty-based detectors. Overall, we show that for preventive settings, (i) previously used methods are largely inadequate, (ii) sequence log-probability works best and performs on par with reference-based methods. Finally, we propose DeHallucinator, a simple method for alleviating hallucinations at test time that significantly reduces the hallucinatory rate. To ease future research, we release our annotated dataset for WMT18 German-English data, along with the model, training data, and code.

研究动机与目标

  • 通过超越人为放大的设置,为研究NMT中的幻觉现象奠定坚实基础。
  • 利用人工标注数据,在真实世界、领域内NMT输出中识别并分类不同类型的幻觉。
  • 在自然推理设置下,严格评估现有幻觉检测方法,包括启发式方法和质量估计方法。
  • 提出并验证DeHallucinator,一种轻量级测试时方法,通过重排序MC-dropout假设来减少幻觉。
  • 公开发布标注语料库、训练模型和代码,以支持未来在NMT幻觉研究方面的研究。

提出的方法

  • 对高资源NMT系统生成的3,415个句子进行结构化标注,涵盖不同类型的幻觉,包括振荡型、强脱离型和完全脱离型幻觉。
  • 利用人工标注的翻译结果验证并基于与源内容的脱离程度定义幻觉类别。
  • 评估多种幻觉检测方法,包括基于注意力的启发式方法、质量估计(COMET和COMET-QE)以及序列对数概率。
  • 提出DeHallucinator,一种测试时纠错流水线,通过轻量级检测器并利用MC-dropout重新生成以选择得分最高的翻译。
  • 使用MC-dropout生成多个假设,并通过序列对数概率对它们进行评分,以选择最佳候选,从而提高可靠性。
  • 公开发布标注语料库、训练模型和代码,以支持可复现性和未来研究。

实验结果

研究问题

  • RQ1在自然、未受扰动的NMT设置下,不同幻觉检测方法的表现如何,与人为放大的设置相比有何差异?
  • RQ2序列对数概率能否作为可靠的、无需参考的幻觉检测器?其与基于参考的COMET方法相比表现如何?
  • RQ3质量估计系统(如COMET和COMET-QE)是否能有效区分幻觉与其他翻译错误?
  • RQ4通过MC-dropout重排序实现的测试时纠错,能否显著降低幻觉率,同时保留正确翻译?
  • RQ5哪些类型的幻觉最易于纠正?这些类型揭示了模型行为的哪些特征?

主要发现

  • 尽管序列对数概率是生成过程的副产品且无需外部参考,其在检测幻觉方面的表现与基于参考的COMET相当。
  • 以往的检测方法,包括基于注意力的启发式方法和质量估计系统,在自然设置下对识别幻觉基本无效。
  • COMET-QE(COMET的无参考变体)未能对幻觉严重程度进行惩罚,表明质量估计不能作为幻觉检测的可靠代理。
  • DeHallucinator将被标记候选中正确翻译的比例从33%提高到85%,显著提升了检测的可靠性。
  • 应用DeHallucinator后,幻觉率降低了三倍,证明了其在测试时纠错中的有效性。
  • 大多数幻觉被正确翻译覆盖,表明其源于随机生成而非深层模型缺陷,除非是与训练数据重复相关的完全脱离型情况。

更好的研究,从现在开始

从阅读论文到最终审阅,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。