Big ideas in AI, illustrated · No. 2

Attention Is All You Need

In 2017, eight researchers at Google published a 15-page paper about translating between languages. The design it introduced, the Transformer, now sits inside nearly every AI system you've heard of. It's the T in ChatGPT.

By Eduardo Yi and Claude · October 9, 2026 · An explainer for non-engineers · about 10 minutes · 6 things to play with
Watercolor: a row of dots, each connected to others by colored arcs of different thickness
Every word reaches out to every other word. The thicker the thread, the more one word "pays attention" to another. That picture is the whole paper in one image.
The problem

Before 2017, the best language AIs read the way you'd read a book through a keyhole: one word at a time, left to right, carrying a small summary of everything so far in their heads. By the end of a long sentence, the start had mostly faded, like the first message in a game of telephone.

There was a second, less obvious problem: speed. If you have to finish word 49 before you can start word 50, it doesn't matter how many computer chips you own. They all wait in line. That made it very hard to feed these systems the huge amounts of text and computing power that make AI good, the "Big Blob of Compute" from the first piece in this series.

Read the same sentence two ways

Press play. The old way reads one word per step, and earlier words fade. The new way takes in every word at once.

Old way: one word at a time0 steps
Transformer: all at once0 steps
Same sentence, same result. One takes 18 steps in a row; the other takes one step, because every word can be handled by a different chip at the same moment.
The big idea

Let every word look at every other word

The paper's answer was a mechanism called attention. Instead of reading through a keyhole, each word gets to look across the whole sentence and decide which other words matter most for understanding it.

The classic example is a sentence with a tricky "it". In "The animal didn't cross the street because it was too tired", "it" means the animal. Change one word, "…because it was too wide", and "it" now means the street. You figured that out instantly by glancing back at the right word. Attention lets a model do the same.

Tap any word to see where it looks

The highlight shows how much attention the selected word pays to each other word. Then flip the last word.

Hand-set weights to show the idea. Real models learn these on their own from data.
Attention is a highlighter each word uses on the rest of the sentence. Nobody tells it what to highlight. It learns that from billions of examples.
How a word decides

Questions, name tags, and what people say

The paper describes attention with three words that sound technical but map neatly onto a party. You walk in looking for someone who can tell you about football.

QueryWhat you're looking for

"Anyone here into football?" Every word asks its own question.

KeyEach person's name tag

"Sports fan." "Chef." "Coach." Every word advertises what it's about.

ValueWhat they actually tell you

Once you pick who to listen to, you take away what they say, weighted by how much you listened.

Here's that process for the word "it", step by step.

Follow "it" through the four steps

1 · Ask

"it" sends a query

2 · Compare

Check every name tag

Each word's key is compared with the query. A better match gets a higher score.

3 · Share out attention

Turn scores into a budget

Scores become percentages that add up to 100%. Big scores get most of the budget.

4 · Blend

Listen and update

Simplified numbers. In a real model, queries, keys and values are long lists of numbers the model learns.
Many heads

Eight highlighters are better than one

One highlighter can only track one kind of relationship. So the Transformer runs several attention "heads" side by side, each free to learn its own job. The original paper used eight. One head might track who did what, another who a pronoun refers to, another when things happened. Their findings are combined at the end.

Watercolor: lines of scribbled text with overlapping gold, rose, indigo and teal highlighter strokes
Same text, several readers, each with a different color of highlighter.

Switch between heads

Each head notices a different kind of link in the same sentence.

Illustrative. Real heads aren't labeled; researchers study them afterwards to work out what each one learned.
Word order

Seat numbers for words

Reading everything at once creates a new problem. If the model sees the whole sentence as one pile of words, then "dog bites man" and "man bites dog" are the same pile. The fix is simple: before anything else, every word gets its position stamped on it, like a seat number on a concert ticket. The paper did this with a pattern of waves, which works for sentences of any length.

Turn seat numbers on and off

Sentence A
Dog bites man.
Sentence B
Man bites dog.
Why it changed everything

One checkout lane vs. a hundred

On its own, attention was a nice improvement in quality. What made it historic was that it threw out the one-word-at-a-time reading entirely. That's what the title means: you don't need the old machinery, attention is enough.

With every word processed at the same moment, a Transformer can keep thousands of chips busy at once, like opening a hundred checkout lanes instead of one. Suddenly it was practical to train on far more text, far faster. This is the bridge between the two ideas in this series: the Transformer is the design that let the Big Blob of Compute be poured into language.

8
authors at Google Brain and Google Research
3.5 days
to train their biggest model, on 8 graphics chips
2
translation records broken: English to German and English to French
8
attention heads working side by side in each layer

The paper's results were about translation, and it beat the best existing systems while costing a fraction as much to train. But the authors guessed it might work for other kinds of data too. They were right.

The legacy

From a translation paper to everything

Within about a year, OpenAI's first GPT (the T is "Transformer") and Google's BERT showed the design worked far beyond translation. Since then it has spread to chatbots like ChatGPT and Claude, image generators, speech recognition, and even systems that predict the shapes of proteins. It is one of the most cited scientific papers of the century.

Watercolor: colored dots scattered across the page, joined by many crisscrossing lines
Everything connected to everything: the shape of attention, and of the field it reshaped.

Two footnotes people love. The title is a nod to the Beatles' "All You Need Is Love". And all eight authors eventually left Google; several went on to found AI companies of their own.

One-minute recap
  1. Old language AIs read one word at a time and forgot the beginning. They were also slow, because steps had to happen in order.
  2. Attention lets every word look at every other word and decide which ones matter, like a learned highlighter. Several heads do this side by side, and position stamps keep word order.
  3. Because everything happens at once, Transformers can use huge numbers of chips in parallel. That made it practical to scale language models up, and led to GPT, Claude and the rest.
Sources: Vaswani et al., "Attention Is All You Need" (2017) · Google Research blog on the Transformer (2017), source of the animal/street example · Wired on the paper's authors (2024). Watercolor plates generated with OpenCV.