The 2017
Line up the architecture of a modern open model against the 2017 paper and the bones are identical: embed, add position, alternate attention and feed-forward blocks with residual connections, and predict the next token. Every difference is a swapped-in part — a different norm, a gated feed-forward, a rotary position scheme, a shared-KV attention. It's a striking case of an architecture that was right enough to keep, and got faster and stronger by a hundred small, sharp improvements rather than one revolution.
Take a model with 32 query heads, each of dimension 128, generating with a context of 4096 tokens. During generation the model must keep a key and a value vector cached for every past token, for every head — the KV cache. With ordinary multi-head attention (32 separate key heads and 32 separate value heads, stored as 16-bit numbers), one layer's cache holds:
32 heads × 128 dims × 4096 tokens × 2 (key & value) × 2 bytes ≈ 64 MiB
Now switch to grouped-query attention with only 8 key/value heads shared across the 32 query heads. Keys and values are stored once per KV head rather than once per query head, so the same layer's cache shrinks to:
8 heads × 128 dims × 4096 tokens × 2 (key & value) × 2 bytes ≈ 16 MiB
That's a 4× reduction — exactly the ratio of query heads to KV heads,