Reproduce “Nearest Neighbor Machine Translation” on OpenResearch
Run Claude Code, Codex or any coding agent as a research agent: literature, hypotheses and experiments on your laptop, cluster or cloud GPUs.
Universal app for Apple silicon and Intel. Requires macOS 11 or later.
About this paper
Urvashi Khandelwal, Angela Fan, Dan Jurafsky, Luke Zettlemoyer, Mike Lewis
Nearest Neighbor Machine Translation (kNN-MT) augments existing neural machine translation models with a retrieval mechanism at inference time, achieving consistent and substantial improvements in translation quality. The approach enables training-free domain adaptation, yielding an average of 9.2 BLEU gain on out-of-domain datasets.
Key insights
- Even strong, state-of-the-art NMT models can significantly benefit from explicit memory augmentation at inference time, indicating that parametric models often underfit their training data.
- The training-free nature of kNN-MT allows for highly efficient and dynamic domain adaptation by simply swapping datastores, outperforming even some training-based adaptation methods.
- A crucial softmax temperature parameter (T>1) is needed for the kNN distribution to prevent overfitting to a single nearest neighbor, leading to better diversity and overall performance.
Summary by alphaXiv.
Tip: change arxiv.org to autoarxiv.org in any arXiv abstract link to open the paper here.