Interactive-Predictive Neural Machine Translation through Reinforcement and Imitation

Tsz Kin Lam, Shigehiko Schamoni, Stefan RiezlerarXiv 2019

TL;DR

This paper introduces an interactive-predictive neural machine translation (NMT) framework that personalizes translation models on the fly using reinforcement and imitation learning. By proactively asking users for feedback only on words where the system is highly uncertain, the framework achieves translation quality close to full supervised training while drastically reducing human editing effort.

What Problem Does This Paper Address?

While modern neural machine translation (NMT) systems are incredibly powerful, professional translation workflows often require adapting a general model to specific domains or user preferences (model personalization).

Standard interactive translation systems typically require a human translator to correct full sentences or complete prefixes, after which the model updates offline. This approach is labor-intensive and slow. The authors address this bottleneck by asking: Can we reduce human effort by having the NMT system identify its own weak spots and learn from partial, localized human feedback in real time?

Methods

The authors propose a human-in-the-loop framework that combines active learning, reinforcement learning (RL), and imitation learning (IL). The workflow operates as follows:

  1. Uncertainty Measurement (Active Learning): Instead of translating a full sentence blindly, the system monitors the entropy of its word predictions. If the entropy crosses a threshold (indicating high uncertainty) or changes abruptly, the system pauses decoding.
  2. Targeted Feedback: The system presents the partial translation to the user and highlights the uncertain tokens. The user provides feedback in two flavors:
  3. Weak Feedback (RL): "Keep" or "Delete" edits, which act as rewards (+0.5 or -0.1).
  4. Expert Demonstrations (IL): "Substitute" edits, where the user replaces the incorrect token with the right one.
  5. Constrained Beam Search: The system integrates these user edits as hard constraints, forcing the beam search algorithm to explore alternative, better-validated translation paths.
  6. Online Updates: The model parameters are updated immediately on the sub-sentence level using a policy gradient method (REINFORCE) based on the feedback rewards.
The interactive-predictive workflow of the NMT system.

Datasets

The framework was evaluated on a domain adaptation task across two language pairs:

  • French-English (fr-en): Pre-trained on the Europarl (EP) v5 corpus (~1.3M sentences) and interactively adapted using a subset of the News Commentary (NC) 2006 corpus (~18.4k sentences).
  • German-English (de-en): Pre-trained on Europarl v7 (~1.7M sentences) and interactively adapted on News Commentary 2006 (~18.9k sentences).

Key Insights and Ideas

  • Entropy as an Exploration Strategy: Counterintuitively, the expert +SUBSTITUTE system actually pushes the model into higher entropy regions during early training. The authors conjecture that expert demonstrations force the system to explore higher-scoring, unfamiliar trajectories, acting as a highly effective exploration mechanism. Meanwhile, the simpler KEEP+DELETE system tends to stay in safer, lower-entropy zones.
  • Learning from Mistakes via Embeddings: When a user issues a DELETE command, the online gradient update penalizes the word embedding of the incorrect token. Because embeddings capture semantic similarity, this forces the NMT system to avoid not just that specific word, but also semantically similar incorrect words in subsequent rounds.
Average cumulative entropy of the model's policy distribution over time.

Key Results

The simulated human-in-the-loop experiments demonstrated substantial performance gains over out-of-domain baselines:

  • Weak Feedback (KEEP+DELETE): Yielded consistent improvements of 2.62 to 3.46 BLEU points over the pre-trained baseline.
  • Expert Feedback (+SUBSTITUTE): Achieved an increase of 3.82 to 4.25 BLEU points, coming remarkably close to the supervised upper bound (full post-edits).
  • Effort Reduction: Human effort was significantly minimized. For sentences averaging ~22 words, the number of required user interactions (clicks/rules) dropped to between 7.4 and 13.7, depending on the feedback mode.
  • Speed: The total decoding time for all partial translations of a single sentence was roughly 0.36 seconds, making it fast enough for real-time interactive deployment.

Limitations and Future Work

The primary limitation acknowledged by the authors is that the current implementation is strictly word-based. Modern NMT systems rely heavily on sub-word units (like Byte Pair Encoding/BPE) or character-level tokens to handle rare words and morphologically rich languages.

Adapting this framework to sub-words requires a method to redistribute word-level human rewards down to sub-word tokens while maintaining precise positional tracking within the constrained beam search. The authors have flagged this architectural extension, alongside conducting field studies with real human translators, as the primary direction for future work.

Summary updated

Abstract

We propose an interactive-predictive neural machine translation framework for easier model personalization using reinforcement and imitation learning. During the interactive translation process, the user is asked for feedback on uncertain locations identified by the system. Responses are weak feedback in the form of "keep" and "delete" edits, and expert demonstrations in the form of "substitute" edits. Conditioning on the collected feedback, the system creates alternative translations via constrained beam search. In simulation experiments on two language pairs our systems get close to the performance of supervised training with much less human effort.
BibTeX
@misc{lam2019interactive,
  author = {Tsz Kin Lam and Shigehiko Schamoni and Stefan Riezler},
  title = {{Interactive-Predictive Neural Machine Translation through Reinforcement and Imitation}},
  year = {2019},
  eprint = {1907.02326},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1907.02326},
}

Loading related content...

Figure