The dominant sequence transduction models are based on complex recurrent or convolutional neural networks in an encoder-decoder configuration. The best performing models also connect the encoder and decoder through an attention mechanism. We propose a new simple network architecture, the Transformer, based solely on attention mechanisms, dispensing with recurrence and convolutions entirely. Experiments on two machine translation tasks show these models to be superior in quality while being more parallelizable and requiring significantly less time to train. Our model achieves 28.4 BLEU on the WMT 2014 English-to-German translation task, improving over the existing best results, including ensembles by over 2 BLEU. On the WMT 2014 English-to-French translation task, our model establishes a new single-model state-of-the-art BLEU score of 41.8 after training for 3.5 days on eight GPUs, a small fraction of the training costs of the best models from the literature. We show that the Transformer generalizes well to other tasks by applying it successfully to English constituency parsing both with large and limited training data.

PDF Abstract NeurIPS 2017 PDF NeurIPS 2017 Abstract

Results from the Paper


Task Dataset Model Metric Name Metric Value Global Rank Result Benchmark
Machine Translation IWSLT2014 German-English Transformer BLEU score 34.44 # 26
Machine Translation IWSLT2015 English-German Transformer BLEU score 28.50 # 2
Image-guided Story Ending Generation LSMDC-E Transformer BLEU-1 15.35 # 3
BLEU-2 4.49 # 4
BLEU-3 1.82 # 2
BLEU-4 0.76 # 2
METEOR 11.43 # 3
CIDEr 9.32 # 2
ROUGE-L 19.16 # 4
Multimodal Machine Translation Multi30K Transformer BLUE (DE-EN) 29.0 # 2
Constituency Parsing Penn Treebank Transformer F1 score 92.7 # 21
Image-guided Story Ending Generation VIST-E Transformer BLEU-1 17.18 # 4
BLEU-2 6.29 # 3
BLEU-3 3.07 # 3
BLEU-4 2.01 # 3
METEOR 6.91 # 3
CIDEr 12.75 # 4
ROUGE-L 18.23 # 4
Machine Translation WMT2014 English-French Transformer Base BLEU score 38.1 # 39
Hardware Burden 23G # 1
Operations per network pass 330000000.0G # 1
Machine Translation WMT2014 English-German Transformer Base BLEU score 27.3 # 52
Operations per network pass 330000000.0G # 1
Machine Translation WMT2014 English-German Transformer Big BLEU score 28.4 # 44
Hardware Burden 871G # 1
Operations per network pass 2300000000.0G # 1

Results from Other Papers


Task Dataset Model Metric Name Metric Value Rank Source Paper Compare
Abstractive Text Summarization CNN / Daily Mail Transformer ROUGE-1 39.50 # 50
ROUGE-2 16.06 # 50
ROUGE-L 36.63 # 45
Text Summarization GigaWord Transformer ROUGE-1 37.57 # 21
ROUGE-2 18.90 # 21
ROUGE-L 34.69 # 23
Natural Language Understanding PDP60 Subword-level Transformer LM Accuracy 58.3 # 10
Coreference Resolution Winograd Schema Challenge Subword-level Transformer LM Accuracy 54.1 # 73
Machine Translation WMT2014 English-French Transformer Big BLEU score 41.0 # 26
Hardware Burden 23G # 1
Operations per network pass 2300000000.0G # 1

Methods