# Attention Is All You Need — Atenção é tudo o que você precisa > Narrativa visual interativa do artigo de Vaswani et al. (NIPS 2017): como o Transformer trocou a recorrência por atenção, chegou a 28,4 BLEU em inglês→alemão e treinou em 12 horas com 8 GPUs. > > Interactive visual narrative of Vaswani et al. (NIPS 2017): how the Transformer replaced recurrence with attention, reached 28.4 BLEU on English→German and trained in 12 hours on 8 GPUs. Uma narrativa Scientata (https://attention.scientata.com) sobre Vaswani et al., "Attention Is All You Need", NIPS 2017 (arXiv:1706.03762), em três níveis de profundidade (básico, intermediário, avançado) e dois idiomas. Todo número exibido vem do artigo original; nada é inferido de figuras nem estimado. / A Scientata narrative about Vaswani et al., "Attention Is All You Need", NIPS 2017, at three depth levels (basic, intermediate, advanced) and two languages. Every figure shown comes from the original paper; nothing is inferred from charts or estimated. ## Escolha de nível / Level chooser - [Português](https://attention.scientata.com/) - [English](https://attention.scientata.com/en/) ## Conteúdo completo por nível / Full content per level - [Básico (pt)](https://attention.scientata.com/basico/) — texto integral / full text: https://attention.scientata.com/basico/llms-full.txt - [Intermediário (pt)](https://attention.scientata.com/intermediario/) — texto integral / full text: https://attention.scientata.com/intermediario/llms-full.txt - [Avançado (pt)](https://attention.scientata.com/avancado/) — texto integral / full text: https://attention.scientata.com/avancado/llms-full.txt - [Basic (en)](https://attention.scientata.com/en/basic/) — texto integral / full text: https://attention.scientata.com/en/basic/llms-full.txt - [Intermediate (en)](https://attention.scientata.com/en/intermediate/) — texto integral / full text: https://attention.scientata.com/en/intermediate/llms-full.txt - [Advanced (en)](https://attention.scientata.com/en/advanced/) — texto integral / full text: https://attention.scientata.com/en/advanced/llms-full.txt ## Fonte primária / Primary source - [Artigo nos anais do NIPS 2017](https://papers.nips.cc/paper_files/paper/2017/hash/3f5ee243547dee91fbd053c1c4a845aa-Abstract.html) - [Pré-print arXiv:1706.03762](https://arxiv.org/abs/1706.03762) - [PDF usado como fonte](https://attention.scientata.com/NIPS-2017-attention-is-all-you-need-Paper.pdf) - [Código de referência: tensor2tensor](https://github.com/tensorflow/tensor2tensor) ## Fatos principais / Key facts - **28,4** — BLEU em inglês→alemão (newstest2014), +2,0 sobre o melhor resultado anterior (Tabela 2, p. 8) / BLEU on English→German (newstest2014), +2.0 over the best previous result - **41,0** — BLEU em inglês→francês — melhor modelo único publicado até então (Tabela 2, p. 8) / BLEU on English→French — best single model published at the time - **12 h** — de treino em 8 GPUs P100 para o modelo base atingir o estado da arte (§5.2, p. 7) / of training on 8 P100 GPUs for the base model to reach the state of the art - **8 × 64** — cabeças de atenção paralelas, de 64 dimensões cada, somando d_model = 512 (§3.2.2, p. 5) / parallel attention heads of 64 dimensions each, summing to d_model = 512 - **6 + 6** — camadas idênticas no codificador e no decodificador, sem recorrência nem convolução (§3.1, p. 2–3) / identical layers in the encoder and decoder, with no recurrence and no convolution - **O(1)** — operações sequenciais por camada de auto-atenção, contra O(n) na recorrente (Tabela 1, p. 6) / sequential operations per self-attention layer, against O(n) for a recurrent one ## Citação / Citation Vaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A. N., Kaiser, Ł., & Polosukhin, I. (2017). Attention Is All You Need. In Advances in Neural Information Processing Systems 30 (NIPS 2017), Long Beach, CA, USA.