AI systems, serving, and quantization papers explained
Modern models are bounded as much by GPU memory bandwidth and KV-cache fragmentation as by raw FLOPs. Systems papers show how rearranging memory layouts, quantizing weights and activations, or sharding states across devices multiplies real throughput without changing the math.
Start with how FlashAttention avoids materializing the attention matrix in HBM, then see how vLLM pages the KV cache and how quantization compresses 65B+ models onto a single GPU.
Start here
FlashAttention
See how tiling attention in on-chip SRAM removes the memory bottleneck.
PagedAttention (vLLM)
Learn how virtual-memory paging eliminates KV-cache fragmentation in LLM serving.
Speculative Decoding
Draft multiple tokens with a small model and verify them in one target forward pass.
All Systems & inference explainers
22 papers · newest explainers first
Systems & inference
GPTQ
Round a large language model's weights to 3 or 4 bits one column at a time, adjusting the weights not yet rounded to cancel each rounding error.
Systems & inference
LLM.int8()
Cut a transformer's GPU memory in half by storing almost all its weights in 8 bits and multiplying the few feature dimensions with huge values in 16 bits.
Systems & inference
Mixed Precision Training
Train in 16-bit floats and match 32-bit accuracy: keep a 32-bit copy of the weights, scale the loss so small gradients survive, and add up products in 32 bits.
Systems & inference
FlashAttention-2
FlashAttention-2 computes the same attention as FlashAttention about twice as fast, by changing how the work is split across the GPU.
Systems & inference
Speculative Decoding
A small model guesses the next few tokens, the large model checks all of them in one pass, and the output distribution does not change.
Systems & inference
ZeRO
Data parallelism keeps a full copy of the training state on every GPU. ZeRO gives each GPU one slice and fetches the rest when a step needs it.
Systems & inference
Mooncake
Serving a language model splits into two jobs: reading the prompt (prefill) and writing the reply one token at a time (decode). Mooncake runs them on separate machines and pools the KV cache between them.
Systems & inference
SmoothQuant
A few huge activation channels break 8-bit quantization of large language models. An exact rescale moves that range into the weights, which quantize cleanly.
Systems & inference
Megatron-LM
A transformer too big for one GPU trains anyway if each layer’s matrix multiplies are split across several GPUs.
Systems & inference
PagedAttention (vLLM)
Storing the KV cache in fixed-size blocks, like operating-system pages, raises LLM serving throughput 2-4×.
Systems & inference
TurboQuant
A random rotation lets one fixed quantizer compress any vector to within 2.7× of the best possible error, with no training.
Systems & inference
Reducing Activation Recomputation
Cut activation memory 5× and recover over 90% of the time lost to recomputation, with sequence parallelism and selective recompute.
Systems & inference
Gradient Checkpointing
Store a few activations and recompute the rest: square-root memory for one extra forward pass.
Systems & inference
LEANN
Vector search that recomputes embeddings instead of storing 173 GB of them.
Systems & inference
FlashAttention
Exact attention, computed while moving far less data through slow GPU memory.
LLMs
PaLM
A 540-billion-parameter language model trained on 6144 TPU chips at 46% of their peak throughput, then tested on hundreds of benchmarks.
Architecture
Sparsely-Gated Mixture of Experts
A small gating network sends each word to a few out of thousands of expert networks, so the parameter count can grow while the compute per word stays flat.
Training
QLoRA
Finetune a 65B model on one 48 GB GPU: store the frozen model in 4 bits and train a small 16-bit adapter through it.
Architecture
Switch Transformers
Send each token to just one of many expert networks, and you can add experts (and the parameters that come with them) without adding compute per token.
Architecture
Multi-Query Attention
Let all attention heads share one key and one value, and the cache a decoder rereads at every step shrinks by the number of heads.
Architecture
Mamba-2 (SSD)
Mamba's recurrence, rewritten as a structured matrix so a GPU can compute it with matrix multiplications.
LLMs
Mistral 7B
A 7B model that outscores Llama 2 13B, with two attention changes that cut its serving memory.