A Pre-LN Transformer (6+6 layers, d=512, 8 heads, tied embeddings) trained from scratch on
parallel text. No pretrained translation model and no fine-tuning.
1from nmt import serve # from the linked repository
2print(serve.translate("The weather is very pleasant today.", "Hindi"))
3# आज मौसम बहुत ही सुखद है
15 epochs per language on a single P100, 150 minutes total, mixed precision, Noam schedule
with 4000 warmup steps. The best-BLEU checkpoint is kept rather than the last epoch. The
fp16 copies published here decode identically to fp32 on every sentence tested.
Everyday sentences translate well. Rare words and proper nouns often do not: the vocabulary
keeps only tokens appearing at least twice in training, so anything rarer is replaced by
<UNK> and cannot be recovered. Decoding is greedy, so no beam search reranking is applied.