Analysis · Research Breakdown · Pillar 02, Research · Section A, Artificial Intelligence · Specimen
The Paper That Taught Machines Where to Look
In 2017 a short paper replaced recurrence with attention. Nearly every large language model since stands on it. What it actually showed, and what it did not.
I. What happened?
In June 2017, a team of researchers mostly at Google published “Attention Is All You Need”, proposing an architecture they called the Transformer.1 It modelled sequences, such as sentences to be translated, using attention alone, without the recurrent or convolutional layers that most models of the time relied on.
II. What is actually known?
The paper reported strong results on standard machine-translation benchmarks while needing less training time than the leading recurrent models it compared against.1 Within about a year the architecture was adapted beyond translation, for example in BERT, which pre-trained a Transformer on unlabelled text for language understanding.2
III. Why does it matter?
Because the Transformer processes a whole sequence at once rather than one word after another, it trains well on parallel hardware. That property, more than any single benchmark, is why it became the base of today's large language models.
IV. What is the underlying mechanism?
Each word is turned into three vectors: a query, a key and a value. A word's query is compared with every other word's key; the scores, scaled and normalised, decide how much of each word's value flows into the new representation of that word. Several such “heads” run side by side, each free to attend to different relations. Since nothing in this is ordered, position is added to each word as a signal of its own.1
V. What remains uncertain?
Attention compares every word with every other, so its cost grows quickly with the length of the text. Whether attention weights explain what a model is “thinking” is debated. And whether ever-larger Transformers keep improving at the same pace is an open question, not a law.
VI. What could happen next?
Possibilities, not predictions: cheaper forms of attention for long texts; other architectures that challenge it on efficiency; and, beyond the architecture, the question of who can afford the compute to train such models at all.
- Vaswani, A. et al., “Attention Is All You Need”, 2017. arXiv:1706.03762.
- Devlin, J. et al., “BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding”, 2018. arXiv:1810.04805.
