Learn/Course 16
Transformers · weeks 21

Frontier architectures & efficient inference

Long-context generation breaks latency and cost targets.

Opening production brief

A measurable problem, before a model.

Users

Operators, product owners, and people affected by the efficient inference decision.

Data

prefill/decode, sampling, KV layout, GQA/MQA with version, owner, event time, and availability contracts.

Constraints

Long-context generation breaks latency and cost targets. Every solution must state latency, cost, capacity, and fallback limits.

Success

Offline evidence plus a deployable resolution: A capacity plan using efficient attention, quantization, batching, and modern routing.

CHAPTER 1

Frame and baseline

Turn the production problem into explicit data, metric, and baseline contracts.

  1. 01

    Autoregressive decoding policies

    Use autoregressive decoding policies to move the efficient inference production brief toward a defensible release.

    65–90 min · checkpoint · deterministic lab
  2. 02

    KV caches, GQA/MQA, and long context

    Use kv caches, gqa/mqa, and long context to move the efficient inference production brief toward a defensible release.

    65–90 min · checkpoint · deterministic lab
CHAPTER 2

Build and stress

Formalize the machinery, test counterexamples, and expose system limits.

  1. 03

    Quantization, compilation, and fused kernels

    Use quantization, compilation, and fused kernels to move the efficient inference production brief toward a defensible release.

    65–90 min · checkpoint · deterministic lab
  2. 04

    Continuous batching and speculative decoding

    Use continuous batching and speculative decoding to move the efficient inference production brief toward a defensible release.

    65–90 min · checkpoint · deterministic lab
CHAPTER 3

Resolve and operate

Join model behavior to architecture, observability, rollout, and rollback.

  1. 05

    Distributed and MoE inference

    Use distributed and moe inference to move the efficient inference production brief toward a defensible release.

    65–90 min · checkpoint · deterministic lab
  2. HW

    LLM inference capacity plan

    Benchmark cache, batching, concurrency, sampling, and one quantized path on mixed traces.

    Rubric · staged hints · reference resolution
Prerequisite guidance

2 concepts make this faster.

Prerequisites are guidance, never hard gates.

C14Transformer from scratchTokenizer, attention, RoPE, residual stack, training loop, generation, and KV cache.C15Foundation modelsA grounded system design spanning adaptation, RAG, evaluation, and safety.
Ready to work the problem?

Autoregressive decoding policies

Start lesson 01