Skip to main content
QUICK REVIEW

[Paper Review] Learning Efficient Lexically-Constrained Neural Machine Translation with External Memory

Ya Li, Xinyu Liu|arXiv (Cornell University)|Jan 31, 2019
Natural Language Processing TechniquesComputer Science18 references4 citations
TL;DR

This paper proposes a memory-augmented neural machine translation model that learns lexically-constrained translation through an external memory, avoiding the high computational cost and inflexible decoding of traditional beam search. By using a memory-attention mechanism and a softmax loss to guide attention to relevant constraint slots, the method achieves efficient, fluent, and flexible constrained translation with improved BLEU scores across Chinese-English and English-German tasks.

ABSTRACT

Recent years has witnessed dramatic progress of neural machine translation (NMT), however, the method of manually guiding the translation procedure remains to be better explored. Previous works proposed to handle such problem through lexcially-constrained beam search in the decoding phase. Unfortunately, these lexically-constrained beam search methods suffer two fatal disadvantages: high computational complexity and hard beam search which generates unexpected translations. In this paper, we propose to learn the ability of lexically-constrained translation with external memory, which can overcome the above mentioned disadvantages. For the training process, automatically extracted phrase pairs are extracted from alignment and sentence parsing, then further be encoded into an external memory. This memory is then used to provide lexically-constrained information for training through a memory-attention machanism. Various experiments are conducted on WMT Chinese to English and English to German tasks. All the results can demonstrate the effectiveness of our method.

Motivation & Objective

  • Address the limitations of lexically-constrained beam search in neural machine translation, including high computational cost and inflexible decoding.
  • Enable efficient and fluent translation under user-specified lexical constraints without requiring large beam sizes.
  • Develop a trainable, soft constraint mechanism that integrates external memory to guide translation during inference.
  • Automatically extract phrase-level constraints from bilingual parallel corpora using alignment and parsing for scalable training.
  • Improve translation quality and robustness under both correct and potentially erroneous constraints compared to hard beam search methods.

Proposed method

  • Extract phrase pairs from bilingual parallel sentences using alignment and syntactic parsing to form a lexically-constrained knowledge base.
  • Encode these phrase pairs into an external memory using keys and values, where keys represent source phrases and values represent target translations.
  • Introduce a memory-attention mechanism that allows the transformer decoder to attend to relevant memory slots during decoding.
  • Apply a softmax loss to enforce accurate attention to the correct memory slots during training, improving alignment between constraints and target outputs.
  • Train the model end-to-end with standard NMT objectives while incorporating memory-based constraint guidance.
  • Use a standard beam search during inference (beam size 12), enabling efficient decoding even with many constraints—unlike prior methods requiring large beam sizes.

Experimental results

Research questions

  • RQ1Can a memory-augmented NMT model achieve efficient and effective lexically-constrained translation without relying on computationally expensive beam search?
  • RQ2How does the proposed memory-attention mechanism improve constraint adherence while maintaining translation fluency?
  • RQ3To what extent can automatically extracted phrase pairs from alignment and parsing serve as reliable constraints for training?
  • RQ4How does the model perform under varying numbers of constraints, especially when constraints are incorrect or ambiguous?
  • RQ5Does the proposed method outperform existing lexically-constrained beam search techniques in terms of BLEU score and fluency?

Key findings

  • The proposed LCNMT model achieves the highest BLEU scores on the WMT English-to-German translation task across all constraint ratios (30%, 50%, 70%).
  • On the Chinese-to-English task, LCNMT achieves comparable performance to the DBA method, with significantly improved fluency in generated outputs.
  • Unlike hard beam search methods, LCNMT avoids unexpected or unnatural translations even when provided with incorrect or conflicting constraints.
  • The model maintains efficient inference with a standard beam size of 12, demonstrating that decoding complexity does not scale with the number of constraints.
  • The memory-attention mechanism, guided by the softmax loss, enables precise attention to relevant constraint slots, improving constraint adherence without sacrificing fluency.
  • The automatic phrase extraction pipeline successfully generates usable constraints from parallel corpora, enabling zero-shot adaptation to new bilingual datasets.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.