Putting words into the system's mouth: A targeted attack on neural machine translation using monolingual data poisoning

Jun Wang, Chang Xu, Francisco Guzmán, Ahmed El-Kishky, Yuqing Tang, Benjamin I. P. Rubinstein, Trevor Cohn

Abstract

Neural Machine Translation (NMT) systems increasingly rely on back-translation (BT) of monolingual data to improve performance. This paper demonstrates that this reliance creates a critical vulnerability. By poisoning as little as 0.02% of the monolingual training data, an attacker can force a model to produce targeted misinformation or slurs. We introduce "smuggling attacks" that exploit NMT model flaws to bypass standard filters, achieving high success rates even in high-resource settings without significantly degrading overall translation quality.

Introduction

Modern NMT systems are hungry for data. To bridge the gap between curated parallel corpora and the vast amounts of text available online, researchers use back-translation: translating monolingual target-language text back into the source language to create synthetic training pairs. However, because monolingual data is often scraped from the open web (e.g., Common Crawl), it is highly susceptible to adversarial manipulation. This paper investigates how an attacker can "pollute" these corpora to make a model produce specific, malicious outputs whenever a target entity appears.

Methodology: From Injection to Smuggling

The authors propose two primary attack strategies to exploit the back-translation pipeline:

  1. Injection Attack: The attacker inserts a "toxin" (e.g., "reprobate") next to a target entity (e.g., "Albert Einstein") in the monolingual corpus. During back-translation, the toxin typically appears on both sides of the synthetic pair, teaching the model a simple association.
  2. Smuggling Attack: This more sophisticated method exploits under-translation—a flaw where NMT models ignore certain words. By using a Back-Translation (BT) Test, the attacker identifies sentences where the toxin is "dropped" during back-translation. This creates an asymmetric training pair: a clean source side and a poisoned target side. This tricks the model into "hallucinating" the toxin at test time.
  3. Language Model Augmentation (LMA): To scale the smuggling attack, the authors use a language model to generate diverse variations of successful "smuggling" sentences.
Overview of the Injection and Smuggling attack pipelines.

Experimental Results

The attacks were evaluated on both low-resource (IWSLT2017) and high-resource (WMT18) German-English datasets. The researchers used WikiMatrix to create a specialized "attack test set" containing real-world sentences with target entities like "Albert Einstein," "Van Gogh," and "earth."

Key Findings

  • Potency of Asymmetry: Smuggling attacks are significantly more effective than simple injections. By ensuring the toxin only appears on the target side, the model learns to associate the target entity itself with the malicious word.
  • Stealth and Scalability: In high-resource settings, the simple injection attack failed (0.7% success), whereas the smuggling attack remained highly effective. Crucially, because the poisoned data constitutes only 0.02% of the training set, there is no noticeable drop in BLEU scores, making the attack invisible to standard performance monitoring.
  • Transferability: The attack does not require access to the victim's specific BT model; poisoned sentences generated using one model (even commercial ones like Google Translate) remain effective against others.
Comparison of attack success rates across different poisoning strategies, showing the significant boost provided by the BT Test and LMA.

Defense and Limitations

The authors tested "up-sampling" clean parallel data as a defense. While this reduced attack success, it also caused a significant drop in overall translation quality (over 2 BLEU points), creating a difficult trade-off for developers. Current automated defenses are insufficient, as they often rely on performance metrics that the attack is designed to bypass.

Conclusion

This research highlights a major security flaw in the way NMT systems utilize web-scale monolingual data. As models become more dependent on synthetic data, the risk of "smuggled" misinformation grows. Future work must focus on developing robust detection methods and exploring the implications for truly low-resource languages where data curation is even more challenging.

Summary updated

BibTeX
@inproceedings{wang2021putting,
  author = {Jun Wang and Chang Xu and Francisco Guzmán and Ahmed El-Kishky and Yuqing Tang and Benjamin I. P. Rubinstein and Trevor Cohn},
  title = {{Putting words into the system's mouth: A targeted attack on neural machine translation using monolingual data poisoning}},
  booktitle = {Annual Meeting of the Association for Computational Linguistics},
  year = {2021},
  doi = {10.18653/v1/2021.findings-acl.127},
}
Figure