Towards Understanding Neural Machine Translation with Word Importance
9422Authors
nan
Abstract
AbstractAlthough neural machine translation (NMT) has advanced the state-of-the-art on various language pairs, the interpretability of NMT remains unsatisfactory. In this work, we propose to address this gap by focusing on understanding the input-output behavior of NMT models. Specifically, we measure the word importance by attributing the NMT output to every input word through a gradient-based method. We validate the approach on a couple of perturbation operations, language pairs, and model architectures, demonstrating its superiority on identifying input words with higher influence on translation performance. Encouragingly, the calculated importance can serve as indicators of input words that are under-translated by NMT models. Furthermore, our analysis reveals that words of certain syntactic categories have higher importance while the categories vary across language pairs, which can inspire better design principles of NMT architectures for multi-lingual translation.
Keywords
Full Content
Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing, pages 953–962, Hong Kong, China, November 3–7, 2019. c⃝2019 Association for Computational Linguistics 953 Towards Understanding Neural Machine Translation with Word Importance Shilin He1,2 Zhaopeng Tu3∗ Xing Wang3 Longyue Wang3 Michael R. Lyu1,2 Shuming Shi3 1Department of Computer Science and Engineering, The Chinese University of Hong Kong 2Shenzhen Research Institute, The Chinese University of Hong Kong 1,2{slhe,lyu}@cse.cuhk.edu.hk 3Tencent AI Lab 3{zptu,brightxwang,vinnylywang,shumingshi}@tencent.com Abstract Although neural machine translation (NMT) has advanced the state-of-the-art on various language pairs, the interpretability of NMT re- mains unsatisfactory. In this work, we propose to address this gap by focusing on understand- ing the input-output behavior of NMT models. Specifically, we measure the word importance by attributing the NMT output to every input word through a gradient-based method. We validate the approach on a couple of pertur- bation operations, language pairs, and model architectures, demonstrating its superiority on identifying input words with higher influence on translation performance. Encouragingly, the calculated importance can serve as indica- tors of input words that are under-translated by NMT models. Furthermore, our analysis re- veals that words of certain syntactic categories have higher importance while the categories vary across language pairs, which can inspire better design principles of NMT architectures for multi-lingual translation. 1 Introduction Neural machine translation (NMT) has achieved the state-of-the-art results on a mass of language pairs with varying structural differences, such as English-French (Bahdanau et al., 2014; Vaswani et al., 2017) and Chinese-English (Hassan et al., 2018). However, so far not much is known about how and why NMT works, which pose great chal- lenges for debugging NMT models and designing optimal architectures. The understanding of NMT models has been ap- proached primarily from two complementary per- spectives. The first thread of work aims to under- stand the importance of representations by analyz- ing the linguistic information embedded in repre- sentation vectors (Shi et al., 2016; Belinkov et al., ∗ Zhaopeng Tu is the corresponding author. Work was mainly done when Shilin He was interning at Tencent AI Lab. 2017) or hidden units (Bau et al., 2019; Ding et al., 2017). Another direction focuses on understand- ing the importance of input words by interpreting the input-output behavior of NMT models. Pre- vious work (Alvarez-Melis and Jaakkola, 2017) treats NMT models as black-boxes and provides explanations that closely resemble the attention scores in NMT models. However, recent studies reveal that attention does not provide meaningful explanations since the relationship between atten- tion scores and model output is unclear (Jain and Wallace, 2019). In this paper, we focus on the second thread and try to open the black-box by exploiting the gradi- ents in NMT generation, which aims to estimate the word importance better. Specifically, we em- ploy the integrated gradients method (Sundarara- jan et al., 2017) to attribute the output to the in- put words with the integration of first-order deriva- tives. We justify the gradient-based approach …
Content truncated to 500 words
Labeled Text
AbstractAlthough neural machine translation (NMT) has advanced the state-of-the-art on various language pairs, the interpretability of NMT remains unsatisfactory. In this work, we propose to address this gap by focusing on understanding the input-output behavior of NMT models. Specifically, we measure the word importance by attributing the NMT output to every input word through a gradient-based method. We validate the approach on a couple of perturbation operations, language pairs, and model architectures, demonstrating its superiority on identifying input words with higher influence on translation performance. Encouragingly, the calculated importance can serve as indicators of input words that are under-translated by NMT models. Furthermore, our analysis reveals that words of certain syntactic categories have higher importance while the categories vary across language pairs, which can inspire better design principles of NMT architectures for multi-lingual translation.
Publication Details
- Paper ID:
- 9422
- Year:
- 2019
- Publication:
- TIPSTER
- Publication Type:
- conf
- DOI:
- nan