Lookback (3) — The Transformer: Where Modern LLMs Began
Introduction — Why Attention Is All You Need Changed the Trajectory of AI
Lookback (3) — The Transformer: Where Modern LLMs Began
Introduction — Why Attention Is All You Need Changed the Trajectory of AI
In **Lookback (1)*, we saw the moment words stopped being symbolic tokens and became trainable vectors* — a shift initiated by Bengio et al. (2003), where language began to live in continuous space.
In **Lookback (2)*, word2vec pushed this idea further: vectors were no longer just parameters, but geometry*. Meaning emerged from relative positions, analogies became vector arithmetic, and language acquired a spatial structure.
Yet, despite these advances, something fundamental remained unchanged:
Language was still processed sequentially.
Recurrent neural networks (RNNs), LSTMs, and GRUs all assumed that understanding language meant walking through it one word at a time. Even when attention mechanisms were added, they were layered on top of recurrence — the backbone of sequence modeling remained a time-step-by-time-step computation.
That assumption was finally broken in 2017, with the paper *Attention Is All You Need*.
The paper proposed something radical for its time:
What if sequence modeling did not require recurrence at all?
The Transformer replaced recurrence with self-attention, allowing every token to directly interact with every other token in a single layer. Instead of propagating information step by step, the model could reason over the entire sequence simultaneously.
At the time, this was presented as an improvement in machine translation. In hindsight, it was much more than that.
The Transformer introduced the computational pattern that would later make Large Language Models possible.
Modern LLMs — GPT, BERT, T5, LLaMA, Claude — do not merely use Transformers. They are Transformers, scaled up. Their ability to:
- model long-range dependencies,
- learn structure without explicit rules,
- train efficiently on massive corpora,
- and grow stronger simply by increasing scale,
all trace back to the architectural break introduced in this paper.
This was not merely an architectural optimization. It was a conceptual shift in how language could be modeled — from sequential processing to global interaction.
And once that shift occurred, scaling became inevitable.
How the Transformer Is Implemented — A New Mental Model for Sequences
From Geometry to Relationships
Word embeddings taught us what words are. Transformers taught us how words relate — dynamically, contextually, and globally.
At the heart of the Transformer is self-attention.
Instead of producing a hidden state by consuming the previous one (as in RNNs), self-attention computes representations by asking a different question:
For this token, which other tokens matter, and how much?
Every token becomes:
- a query (what it is looking for),
- a key (how it can be matched),
- and a value (what information it provides).
Through dot products and softmax normalization, each token builds its representation as a weighted combination of all others — in a single layer.
This leads to three fundamental implementation consequences:
1. Parallelism Replaces Sequentiality
In RNNs:
- Token n cannot be processed before token n−1.
- Training is inherently sequential.
In Transformers:
- All tokens are processed simultaneously.
- Sequence length affects computation size, but not computation order.
This single change unlocked:
- massive GPU parallelism,
- faster training,
- and scalability that RNN-based models could never reach.
2. Path Length Collapses
In an RNN, information from the first word must pass through every intermediate step to reach the last word. The path length grows with sequence length.
In self-attention:
- any token can directly attend to any other token,
- in one step.
This dramatically improves the model’s ability to learn:
- long-distance dependencies,
- coreference (“its” → “law”),
- global sentence structure.
The attention visualizations in the paper make this explicit: heads learn syntax, semantics, locality, and structure — without being explicitly programmed to do so.
3. Multi-Head Attention Enables Functional Specialization
Rather than relying on a single attention mechanism, the Transformer uses multiple attention heads.
Each head:
- projects tokens into a different representation subspace,
- learns different relational patterns.
Some heads focus on:
- grammatical structure,
- others on semantic roles,
- others on positional or boundary signals.
This is not redundancy — it is division of labor.
Position Without Time
Removing recurrence introduced a new problem: how does the model know order?
The solution — positional encoding — is elegant and revealing.
Instead of learning order explicitly, the Transformer injects position as continuous signals (sinusoids or learned vectors) added to embeddings. This preserves compatibility with linear operations and allows relative position to be inferred through simple transformations.
Order becomes a property of representation, not a control flow.
A Model That Is Surprisingly Simple
Despite its impact, the Transformer is conceptually minimal:
- attention for interaction,
- feed-forward networks for transformation,
- residual connections and normalization for stability.
There is no memory state, no recurrence, no convolution.
Just relationships.
3. Conclusion — From Tokens, to Geometry, to Global Interaction
Looking back across the three papers:
- Bengio et al. (2003) made words trainable.
- word2vec (2013) made meaning geometric.
- Transformer (2017) made language relational at scale.
The Transformer did not replace embeddings — it completed their story.
Word vectors gave us points in space. Transformers gave us dynamic edges between those points, computed fresh for every context.
Since 2017, this idea has expanded far beyond translation:
- BERT, GPT, T5, and beyond,
- vision transformers for images,
- audio and video models,
- multimodal systems that connect text, vision, and sound.
Even newer architectures that move “beyond attention” still inherit its core insight:
Understanding sequences is not about processing order — it is about modeling relationships.
In hindsight, Attention Is All You Need was not just a paper about attention.
It was the moment sequence modeling stopped walking through language and started seeing it all at once.
메타데이터
- post_id
- 044e14f1a89c
- slug
- lookback-3-the-transformer-where-modern-llms-began-044e14f1a89c
- url
- https://medium.com/@bingqian/lookback-3-the-transformer-where-modern-llms-began-044e14f1a89c
- canonical_url
- https://medium.com/@bingqian/lookback-3-the-transformer-where-modern-llms-began-044e14f1a89c
- author_url
- https://medium.com/@bingqian
- status
- ok
- fetched_at
- 2026-06-20 20:29:01