lvapeab / BIPNMT

Code for our paper "A Reinforcement Learning Approach to Interactive-Predictive Neural Machine Translation"

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

BIPNMT

Code for our paper "A Reinforcement Learning Approach to Interactive-Predictive Neural Machine Translation" link: https://arxiv.org/abs/1805.01553

The code is written based on Nguyen et.al, 2017's code: https://github.com/khanhptnk/bandit-nmt/

Requirements:

  • Python 3.5
  • PyTorch 0.3

  1. Download and create the vocabulary
  • Go to the ``scripts'' folder and run the script:
    • ./download_data.sh
    • ./make_data.sh fr en
  1. To train the model; you can follow a sample script in ``scripts'' folder
  • run_train.sh
  1. To evaluate the trained models
  • use the -eval flag (a sample script: run_eval.sh)

Notes:

  1. For BIP-NMT, it takes about 25 mins for training 1000 sentences under a Nvidia Tesla P40 - 24GB RAM GPU.

About

Code for our paper "A Reinforcement Learning Approach to Interactive-Predictive Neural Machine Translation"


Languages

Language:Python 96.5%Language:Shell 3.5%