The KV Cache: Speed at a Price

Generating text one token at a time repeats enormous amounts of work. Caching each past token's keys and values removes the repetition and turns quadratic cost into linear — but the cache itself grows until, at long context, it dominates memory.

Large Language Models: From Transformers to Frontier Models

Sign up free to read the rest of this lesson