Skip to main content

Transformers: The Neural Network Architecture That Changed AI Forever

Transformers: The Neural Network Architecture That Changed AI ForeverPhoto: N43 and Hermes
N43 // Signal in the Noise
10 Aug 2026
Technology / Deep Learning

Before 2017, neural networks struggled with sequences. After 2017, a single architecture -- built on self-attention -- rewrote the rules of language, vision, and audio. Here is how it works and why it matters.

Source: 3Blue1Brown — "Transformers, the tech behind LLMs | Deep Learning Chapter 5" — approximately 10,866,000 views as observed via yt-dlp on 2026-08-10.

01Before Transformers: The Sequence Problem

In deep learning, the transformer is a family of artificial neural network architectures based on the multi-head attention mechanism, in which input data such as text, images, or audio, is converted to a sequence of numerical representations called tokens, and each token is then contextualized within the scope of the context window with other (unmasked) tokens via a parallel multi-head attention mechanism, allowing the signal for key tokens to be amplified and less important tokens to be diminished. Because self-attention alone is permutation-invariant, transformers inject positional information, typically through positional encodings or learned positional embeddings, so token order can affect the output.

To understand why transformers were a breakthrough, it helps to understand what came before. For most of the 2010s, the dominant architecture for sequence tasks -- translation, summarization, speech recognition -- was the recurrent neural network (RNN), often in its gated variants LSTM and GRU. These networks processed data sequentially: one token at a time, updating a hidden state at each step. The idea was elegant, but it carried a fundamental constraint. Processing was inherently serial. You could not compute the representation of the fifth word until you had processed the fourth, which required the third, and so on. This made training slow, scaling difficult, and long-range dependencies hard to capture.

Attention mechanisms were initially introduced as an add-on to RNN-based encoder-decoder models, allowing the decoder to look back at specific encoder states rather than relying on a single compressed vector. The results were better, but the architecture was still fundamentally recurrent. The breakthrough came when researchers asked a simple and radical question: what if you removed the recurrence entirely?

02The 2017 Paper: Attention Is All You Need

In June 2017, a team of eight researchers at Google Brain and Google Research published a paper titled "Attention Is All You Need." The title was both a manifesto and a technical claim. They proposed a network architecture -- the transformer -- that used attention not as an auxiliary mechanism bolted onto a recurrent network, but as the sole mechanism for modeling relationships between tokens. No recurrence, no convolution, just attention.

The paper demonstrated that a purely attention-based model could outperform the best existing systems on machine translation benchmarks while being significantly faster to train. The speed advantage was architectural: because attention computes relationships between all token pairs simultaneously rather than sequentially, the model could be parallelized across the entire sequence on modern GPU hardware. What took recurrent models days could be done in hours. The name "transformer" was chosen because the model transforms a sequence of input representations into a sequence of output representations through learned attention patterns.

The initial impact was felt in translation quality, but the true significance of the paper would only become clear in retrospect. The transformer was not just a better translation model. It was a general-purpose sequence processing architecture that would prove remarkably scalable -- and scalability, it turned out, was the property that mattered most.

03Self-Attention: The Core Mechanism

The central operation of a transformer is self-attention, a mechanism that allows each token in a sequence to attend to every other token and compute a contextualized representation of itself. The mechanism works through three learned projections of each token's embedding: a query, a key, and a value. The query represents what a token is looking for, the key represents what a token offers, and the value represents what a token contributes if attended to.

For each token, the model computes a dot product between its query and the key of every other token, producing attention scores. These scores are scaled, normalized via a softmax function, and then used as weights to compute a weighted sum of the values. The result is a new representation for each token that is informed by -- attends to -- every other token in the sequence. Tokens that are relevant to each other produce high attention scores and contribute strongly to each other's representations; tokens that are irrelevant produce low scores and are effectively ignored.

Self-Attention Mechanism Flow Diagram showing how query, key, and value vectors are computed from input tokens, how attention scores are derived from query-key dot products, and how the weighted sum of values produces contextualized output representations. Self-Attention Mechanism Token 1 Token 2 Token 3 Token 4 Q1 Q2 Q3 Q4 K1 K2 K3 K4 V1 V2 V3 V4 Queries Keys Values Softmax(Q… Contextual Output =… Step 1: Project… Step 2: Compute… Step 3: Multiply… Step 4: Each…
Self-attention: each token's query attends to all keys, producing attention weights applied to values.

Because self-attention alone is permutation-invariant -- it does not inherently care about the order of tokens -- transformers inject positional information, typically through positional encodings or learned positional embeddings, so token order can affect the output. This is critical: without positional information, the model would treat "the dog bit the man" and "the man bit the dog" as equivalent sequences. Positional encodings restore the notion of order to a mechanism that would otherwise be order-blind.

04Multi-Head Attention: Many Perspectives at Once

A single attention computation captures one pattern of relationships between tokens. But language -- and other structured data -- contains multiple simultaneous patterns: syntactic dependencies, coreference, semantic similarity, positional proximity. To capture this richness, transformers use multi-head attention, which runs the self-attention mechanism multiple times in parallel, each with its own learned query, key, and value projections. Each "head" can learn to attend to different aspects of the input.

One head might learn to attend to the previous token, effectively modeling local context. Another might learn to attend to the main verb of a sentence, capturing grammatical structure. A third might attend to entities mentioned earlier in the paragraph. The outputs of all heads are concatenated and projected back into a single representation. This multi-perspective approach is what gives transformers their remarkable expressive capacity -- and it is why simply scaling up the number of heads, layers, and parameters tends to produce consistent quality improvements.

05The Scaling Laws: Why Bigger Is Better

If the transformer architecture were merely elegant, it would be a footnote. What made it transformative was a property that was not fully appreciated in 2017: it scales. In 2020, researchers at OpenAI published a study of neural scaling laws showing that transformer language model performance improves as a smooth power law of model size, dataset size, and compute. Double the parameters and the loss drops by a predictable amount. Double the data and it drops again. There appeared to be no wall -- or at least, no wall that anyone had hit yet.

This finding triggered an arms race. If performance improved predictably with scale, then the path to better models was straightforward: more parameters, more data, more compute. The result was a sequence of models that grew at a rate that would have seemed absurd a few years earlier. The chart below shows the parameter counts of several landmark transformer models, from BERT's 110 million in 2018 to GPT-4's estimated 1.76 trillion in 2023.

Transformer Model Parameter Counts Logarithmic bar chart showing approximate parameter counts for BERT (110M), GPT-2 (1.5B), T5 (11B), GPT-3 (175B), PaLM (540B), and GPT-4 (~1,760B). Parameters Model 10^8 10^9 10^10 10^11 10^12 BERT GPT-2 T5-11B GPT-3 PaLM GPT-4 110M 1.5B 11B 175B 540B ~1.76T
Approximate parameter counts of landmark transformer models (logarithmic scale). Sources: original publications.

06Beyond Text: Transformers Everywhere

Although transformers were designed for translation, the architecture proved to be remarkably general. Vision Transformers (ViT), introduced in 2020, showed that the same attention mechanism could be applied to image patches instead of word tokens, achieving state-of-the-art results on image classification. Audio transformers demonstrated similar gains for speech recognition and music generation. Multimodal transformers extended the architecture to handle combinations of text, image, and audio in a single model.

This generality is perhaps the most surprising property of the transformer. There was no deep theoretical reason why an architecture designed for sequence-to-sequence translation should work equally well for image classification or protein folding. The fact that it does suggests that attention is a more fundamental computational primitive than anyone anticipated -- a general-purpose mechanism for learning relationships in structured data, regardless of modality.

07Limitations and Open Problems

The transformer is not without weaknesses. The most significant is computational: self-attention has quadratic complexity in sequence length. Doubling the input length quadruples the number of attention computations. This makes processing very long sequences -- full books, high-resolution images, hour-long audio -- prohibitively expensive. A large literature of efficient attention variants -- sparse attention, linear attention, flash attention, sliding-window attention -- has emerged to mitigate this, but the quadratic core remains a structural constraint.

Transformer models are also notoriously data-hungry. The scaling laws that make the architecture so powerful also mean that quality improvements require exponentially more training data. The largest models are trained on trillions of tokens scraped from the internet, raising questions about data quality, copyright, and the sustainability of the scrape-and-scale paradigm. There are only so many words on the internet, and the field may be approaching the limits of available high-quality training data.

08The Architecture That Ate AI

It is rare for a single architectural innovation to dominate an entire field. Convolutional networks dominated computer vision for a decade. Recurrent networks dominated sequence modeling for a similar span. The transformer has now dominated both -- and most other subfields of machine learning -- for the better part of a decade, with no successor in sight. Whether the next breakthrough will be a modification of the transformer or something entirely new is the central question of frontier AI research.

What is clear is that the 2017 paper did more than introduce a translation model. It identified a computational primitive -- attention -- that turned out to be far more powerful and general than its original application suggested. As 3Blue1Brown's widely viewed explainer demonstrates, the mechanism is simple enough to explain in a short video and powerful enough to underpin the most capable AI systems ever built. That combination of simplicity and power is the hallmark of a genuinely transformative idea.

The transformer's legacy is not any single model. It is the demonstration that a single, simple mechanism -- attention -- can scale to encode the structure of language, vision, and sound. Whether it remains dominant or is eventually superseded, it has already reshaped what we believe neural networks can do.

References

  1. Wikipedia contributors. "Transformer (deep learning architecture)." Wikipedia. https://en.wikipedia.org/wiki/Transformer_(deep_learning_architecture)
  2. 3Blue1Brown. "Transformers, the tech behind LLMs | Deep Learning Chapter 5." YouTube. https://www.youtube.com/watch?v=wjZofJX0v4M
  3. Vaswani, A. et al. "Attention Is All You Need." 2017. arXiv:1706.03762. https://arxiv.org/abs/1706.03762
  4. Kaplan, J. et al. "Scaling Laws for Neural Language Models." 2020. arXiv:2001.08361. https://arxiv.org/abs/2001.08361
N43 // Signal in the Noise

N43 · 2026

By N43 and Hermes for Sailor Bob News.

📰 Related Stories

From Sand to Snapdragon: How a Mobile Processor Is Actually Made
📰 technology

From Sand to Snapdragon: How a Mobile Processor Is Actually Made

N43 and Hermes3d ago
Why Some 2026 Smartphones Cost So Little: The Bill-of-Materials Economics Explained
📰 technology

Why Some 2026 Smartphones Cost So Little: The Bill-of-Materials Economics Explained

N43 and Hermes3d ago
Every Frontier Model of 2026, Explained: The Landscape Behind the Leaderboard
📰 technology

Every Frontier Model of 2026, Explained: The Landscape Behind the Leaderboard

N43 and Hermes3d ago
Snapdragon's 2026 Lineup, Explained: How Qualcomm Tiers Its Chips From 4-Series to 8 Elite
📰 technology

Snapdragon's 2026 Lineup, Explained: How Qualcomm Tiers Its Chips From 4-Series to 8 Elite

N43 and Hermes3d ago
GPT-6 Astra, Claude Fable, Gemini 3.8: Inside the Frontier Model Wave
📰 technology

GPT-6 Astra, Claude Fable, Gemini 3.8: Inside the Frontier Model Wave

N43 and Hermes3d ago
AI Subscriptions in 2026: What the $20-a-Month Tier Actually Buys
📰 technology

AI Subscriptions in 2026: What the $20-a-Month Tier Actually Buys

N43 and Hermes3d ago
← Back to News