RuizGao / knnmt-meta-optimizer

Implementaion of our EMNLP 2023 submission "Nearest Neighbor Machine Translation is Meta-Optimizer on Output Projection Layer"

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

kNN-MT is Meta-Optimizer on OPL

Code for our EMNLP 2023 paper "Nearest Neighbor Machine Translation is Meta-Optimizer on Output Projection Layer". Please cite our paper if you find this repository helpful in your research:

The implementation is build upon fairseq, and heavily inspired by adaptive-knn-mt, many thanks to the authors for making their code avaliable.

Requirements and Installation

  • pytorch version >= 1.5.0
  • python version >= 3.6
  • faiss-gpu >= 1.6.5
  • pytorch_scatter = 2.0.5
  • 1.19.0 <= numpy < 1.20.0

You can install this project by

pip install --editable ./

About

Implementaion of our EMNLP 2023 submission "Nearest Neighbor Machine Translation is Meta-Optimizer on Output Projection Layer"

License:MIT License


Languages

Language:Python 97.4%Language:Cuda 1.4%Language:C++ 0.6%Language:Cython 0.4%Language:Lua 0.2%Language:Shell 0.0%