Google packed a whole sentence into a single vector
The 2014 LSTM that gave machine translation its encoder-decoder shape leaned on a source-reversing hack that attention made unnecessary within months.
Why this matters
Almost every system that turns one piece of text into another, a translator, a chatbot drafting a reply, a model shortening a long document, inherits its basic shape from one 2014 paper. That paper taught a network to read a sentence into a single list of numbers, and a second network to write that list back out as a translation, and it called the setup sequence to sequence. This lesson reads the paper: what it actually built, how small the result really was, the hand-adjustment it depended on, and which part of it the field kept once a better idea arrived. By the end you can say what the 2014 system did and did not show, and tell the durable idea from the mechanism that was replaced within months.
- 01
- Attention Is All You Need: the design that replaced recurrence with attention and now sits under most large language models.
- 02
- Sequence to Sequence Learning with Neural Networks: the original paper, nine pages, readable in an afternoon.
Reading a sentence into one vector
In 2014, three Google researchers reported a translation system built on a single idea. One neural network reads an English sentence and squeezes it into a fixed-length list of numbers, and a second reads that list back out as French.1 The authors were Ilya Sutskever, Oriol Vinyals, and Quoc Le. They named the arrangement sequence to sequence, and the name now covers a large share of what neural networks do with language.
Start with the list of numbers, because it is the whole trick. A nutrition label reduces any dish, an apple or a lasagna, to the same short row of numbers, and two foods whose rows are close are alike in the ways the label measures. The encoder network does this to a sentence. It reads the words one at a time, keeps a running summary, and when the sentence ends it hands over that summary: a fixed-length vector, a list of the same length whether the sentence ran three words or thirty.1 The difference from a nutrition label is size. A label has a handful of fields; the vector here is built inside network layers that each carry a thousand numbers, room enough, the authors bet, to hold everything the second network needs to rewrite the sentence in another language.1
Both networks are long short-term memory networks, or LSTMs, a kind of recurrent network built to carry information across long stretches of text. The second one runs the first in reverse. Given the vector, it writes French one word at a time, each word chosen from the vector and the words already written.1 The single most likely word at each step does not always add up to the best sentence, so the decoder keeps a short list of the most promising partial translations and extends them together, a procedure called beam search.1 Read a sequence in with one network, write a sequence out with another: that is the shape the paper is remembered for.
What 34.81 is actually made of
The system was tested on one task, translating English news text into French, on the standard WMT'14 benchmark.1 The thing it had to beat was not another neural network. It was a phrase-based statistical translator, the mainstream method of the day, which scored 33.30 on the benchmark's BLEU scale, a 0-to-100 measure of how closely a machine translation matches human reference translations.1
A single one of the paper's LSTMs, with the source reversed, scored 30.59, below the statistical baseline.1 The headline 34.81 came from stacking: five separately trained networks voting together, decoded with a beam of twelve.1 And the best number in the paper, 36.5, was not the LSTM translating on its own. It was that same five-network ensemble used to re-rank the statistical system's own thousand best guesses.1
| System | BLEU | What produced it |
|---|---|---|
| Baseline | 33.30 | The phrase-based statistical translator. |
| Forward | 26.17 | One LSTM, source read in order. |
| Reversed | 30.59 | One LSTM, source read backward. |
| Ensemble beam 1 | 33.00 | Five networks voting, one word at a time. |
| Ensemble beam 12 | 34.81 | The headline result. |
| Rescoring | 36.5 | The ensemble re-ranking the baseline's guesses. |
The whole model held about 384 million adjustable numbers, most of them not in the translating layers but in two lookup tables: one row for each of the 160,000 English words it could read and each of the 80,000 French words it could write.1 It trained on 12 million sentence pairs, 304 million English words against 348 million French, on eight GPUs for about ten days.1 For 2014 that was a large machine, and the entire return on it was one direction of one language pair.
Why they reversed the English
The single change that bought the most was strange. Before training, the authors reversed the word order of every English source sentence, feeding "sat cat the" in place of "the cat sat" while leaving the French target in normal order.1 On its own that flip raised the single-model score from 25.9 to 30.6 BLEU and dropped the network's perplexity, a measure of how surprised it is by the next word, from 5.8 to 4.7.1
Their explanation was partial, and they said so. Reversing the source puts the first English words next to the first French words they line up with, shortening the distance the network has to carry an early dependency before it starts producing output.1 Why one flip helped so evenly across a whole sentence, and not only its opening, they could not fully say. In their own words, "we do not have a complete explanation to this phenomenon."1
The trick worked and its numbers were real, and a hand-adjustment of that size tells you something. A network that needed its input flipped, to keep early words close to their translations, was feeling the strain of carrying a long sentence through one vector. That is a narrower admission than the one the field later pinned on the paper, and the authors made only the narrow one. On the larger question, whether a single fixed vector was a ceiling, they claimed the opposite.
The bottleneck the paper never conceded
Squeezing a whole sentence into one fixed vector sounds like it should break on long sentences, where there is more to hold. The authors expected that, and found the reverse.1 Their system's score held roughly flat as sentences grew, out to about thirty-five words, with only slight slippage on the longest.1
"We were surprised to discover that the LSTM did well on long sentences."1 Sutskever, Vinyals, and Le, Section 3.7
The diagnosis the field remembers as this paper's flaw is not in this paper. It was made the same month, by a different group. Dzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio conjectured "that the use of a fixed-length vector is a bottleneck in improving the performance of this basic encoder-decoder architecture."2 They offered a fix. Instead of one vector for the whole sentence, encode the source as a sequence of vectors, and let the decoder pick which of them to read for each word it writes. That fix is attention.
A companion paper then measured the failure the conjecture predicted. Cho and colleagues tested a plain recurrent encoder-decoder and watched its quality "suffer significantly as the length of the sentences increases."3 They blamed "the fixed-length vector representation," which "does not have enough capacity to encode a long sentence."3 The breakdown was not measured on Sutskever's deep, reversed, five-network system. It was measured on a single-layer model without the reversing trick.3 The bottleneck was a property of the approach, and the particular machine in the seq2seq paper had been tuned, by reversing and depth and ensembling, to hold it off.
The account that reached the textbooks kept the bottleneck and dropped the surprise. A standard deep-learning text now introduces the encoder as turning "a variable-length sequence as input" into "a fixed-shape hidden state," then moves straight to attention as the way past that single fixed-length limit.4 Attention won. Within three years the Transformer kept attention and dropped recurrence entirely, "dispensing with recurrence and convolutions,"5 and it became the design nearly every large language model now uses.
So what did 2014 actually establish? The durable part was the shape, not the score. Today "sequence to sequence" names a general recipe: read a sequence in, write a sequence out. It covers translation, summarization, and question answering alike. One widely used framework, T5, casts every text task into a single text-in, text-out form.6 The founding result under that sweeping name did one direction of one language pair and leaned on a hack a better idea made obsolete. The framing lasted. The fixed vector it was built on did not.
The takeaway
The 2014 paper gave the field a shape and a name that both held. Read a sequence into a representation with one network, write the next sequence out of it with another: that split still organizes machine translation and much of what large language models do. What did not hold was the paper's own version of the representation, a single fixed-length vector carrying the whole sentence. The authors reported it worked, even on long sentences, and reversed their input by hand to make it work better. The same month, another group named that single vector a bottleneck and measured a plainer model breaking on long inputs, and attention, one vector per word instead of one for the sentence, took its place. Keep the real size of the founding result in view: one direction of one language pair, pulled just past a statistical baseline by stacking five networks. The encoder-decoder split and the name are what the paper is rightly cited for; the single fixed vector it packed each sentence into is the part attention had to remove.
- 01
- Neural Machine Translation by Jointly Learning to Align and Translate: the paper that named the bottleneck and introduced attention.
- 02
- Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformer: how "text-to-text" turned one recipe into a general-purpose method.
Sources
- arXiv · Sutskever, Vinyals, Le, Sequence to Sequence Learning with Neural Networks (2014)
- arXiv · Bahdanau, Cho, Bengio, Neural Machine Translation by Jointly Learning to Align and Translate (2014)
- arXiv · Cho et al., On the Properties of Neural Machine Translation: Encoder-Decoder Approaches (2014)
- Dive into Deep Learning · Sequence-to-Sequence Learning for Machine Translation
- arXiv · Vaswani et al., Attention Is All You Need (2017)
- arXiv · Raffel et al., Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformer (2019)