Optimal Transport for Unsupervised Hallucination Detection in Neural Machine Translation
37757Authors
nan
Abstract
AbstractNeural machine translation (NMT) has become the de-facto standard in real-world machine translation applications. However, NMT models can unpredictably produce severely pathological translations, known as hallucinations, that seriously undermine user trust. It becomes thus crucial to implement effective preventive strategies to guarantee their proper functioning. In this paper, we address the problem of hallucination detection in NMT by following a simple intuition: as hallucinations are detached from the source content, they exhibit encoder-decoder attention patterns that are statistically different from those of good quality translations. We frame this problem with an optimal transport formulation and propose a fully unsupervised, plug-in detector that can be used with any attention-based NMT model. Experimental results show that our detector not only outperforms all previous model-based detectors, but is also competitive with detectors that employ external models trained on millions of samples for related tasks such as quality estimation and cross-lingual sentence similarity.
Keywords
Full Content
Proceedings of the 61st Annual Meeting of the Association for Computational Linguistics Volume 1: Long Papers, pages 13766–13784 July 9-14, 2023 ©2023 Association for Computational Linguistics Optimal Transport for Unsupervised Hallucination Detection in Neural Machine Translation Nuno M. Guerreiro1,2 Pierre Colombo4 Pablo Piantanida5 André F. T. Martins1,2,3 1Instituto de Telecomunicações, Lisbon, Portugal 2Instituto Superior Técnico & LUMLIS (Lisbon ELLIS Unit), University of Lisbon, Portugal 3Unbabel, Lisbon, Portugal 4MICS, CentraleSupélec, Université Paris-Saclay 5ILLS - CNRS, CentraleSupélec miguelguerreironuno@gmail.com Abstract Neural machine translation (NMT) has become the de-facto standard in real-world machine translation applications. However, NMT mod- els can unpredictably produce severely patho- logical translations, known as hallucinations, that seriously undermine user trust. It becomes thus crucial to implement effective preventive strategies to guarantee their proper function- ing. In this paper, we address the problem of hallucination detection in NMT by following a simple intuition: as hallucinations are de- tached from the source content, they exhibit cross-attention patterns that are statistically dif- ferent from those of good quality translations. We frame this problem with an optimal trans- port formulation and propose a fully unsuper- vised, plug-in detector that can be used with any attention-based NMT model. Experimental results show that our detector not only outper- forms all previous model-based detectors, but is also competitive with detectors that employ external models trained on millions of samples for related tasks such as quality estimation and cross-lingual sentence similarity. 1 Introduction Neural machine translation (NMT) has achieved tremendous success (Vaswani et al., 2017; Kocmi et al., 2022), becoming the mainstream method in real-world applications and production systems for automatic translation. Although these mod- els are becoming evermore accurate, especially in high-resource settings, they may unpredictably pro- duce hallucinations. These are severely pathologi- cal translations that are detached from the source sequence content (Lee et al., 2018; Müller et al., 2020; Raunak et al., 2021; Guerreiro et al., 2022). Crucially, these errors have the potential to seri- ously harm user trust in hard-to-predict ways (Perez et al., 2022), hence the evergrowing need to develop security mechanisms. One appealing strategy to address this issue is to develop effective on-the-fly detection systems. In this work, we focus on leveraging the cross- attention mechanism to develop a novel hallucina- tion detector. This mechanism is responsible for selecting and combining the information contained in the source sequence that is relevant to retain dur- ing translation. Therefore, as hallucinations are translations whose content is detached from the source sequence, it is no surprise that connections between anomalous attention patterns and hallu- cinations have been drawn before in the literature (Berard et al., 2019; Raunak et al., 2021; Ferrando et al., 2022). These patterns usually exhibit scat- tered source attention mass across the different to- kens in the translation (e.g. most source attention mass is concentrated on a few irrelevant tokens such as punctuation and the end-of-sequence to- ken). Inspired by such observations, previous work has designed ad-hoc heuristics to detect hallucina- tions that specifically target the anomalous maps. While such heuristics can …
Content truncated to 500 words
Labeled Text
AbstractNeural machine translation (NMT) has become the de-facto standard in real-world machine translation applications. However, NMT models can unpredictably produce severely pathological translations, known as hallucinations, that seriously undermine user trust. It becomes thus crucial to implement effective preventive strategies to guarantee their proper functioning. In this paper, we address the problem of hallucination detection in NMT by following a simple intuition: as hallucinations are detached from the source content, they exhibit encoder-decoder attention patterns that are statistically different from those of good quality translations. We frame this problem with an optimal transport formulation and propose a fully unsupervised, plug-in detector that can be used with any attention-based NMT model. Experimental results show that our detector not only outperforms all previous model-based detectors, but is also competitive with detectors that employ external models trained on millions of samples for related tasks such as quality estimation and cross-lingual sentence similarity.
Publication Details
- Paper ID:
- 37757
- Year:
- 2023
- Publication:
- TIPSTER
- Publication Type:
- conf
- DOI:
- nan