English

Nearest Neighbor Machine Translation is Meta-Optimizer on Output Projection Layer

Computation and Language 2023-10-25 v2

Abstract

Nearest Neighbor Machine Translation (kkNN-MT) has achieved great success in domain adaptation tasks by integrating pre-trained Neural Machine Translation (NMT) models with domain-specific token-level retrieval. However, the reasons underlying its success have not been thoroughly investigated. In this paper, we comprehensively analyze kkNN-MT through theoretical and empirical studies. Initially, we provide new insights into the working mechanism of kkNN-MT as an efficient technique to implicitly execute gradient descent on the output projection layer of NMT, indicating that it is a specific case of model fine-tuning. Subsequently, we conduct multi-domain experiments and word-level analysis to examine the differences in performance between kkNN-MT and entire-model fine-tuning. Our findings suggest that: (1) Incorporating kkNN-MT with adapters yields comparable translation performance to fine-tuning on in-domain test sets, while achieving better performance on out-of-domain test sets; (2) Fine-tuning significantly outperforms kkNN-MT on the recall of in-domain low-frequency words, but this gap could be bridged by optimizing the context representations with additional adapter layers.

Keywords

Cite

@article{arxiv.2305.13034,
  title  = {Nearest Neighbor Machine Translation is Meta-Optimizer on Output Projection Layer},
  author = {Ruize Gao and Zhirui Zhang and Yichao Du and Lemao Liu and Rui Wang},
  journal= {arXiv preprint arXiv:2305.13034},
  year   = {2023}
}

Comments

Accepted by EMNLP2023

R2 v1 2026-06-28T10:41:25.790Z