concept:causal-masks
Causal Masks
Causal Masks in the context of production machine-learning systems.
Lessons
Formal explanations, examples, simulations, and checkpoints.
Build a transformer from scratch
Train a causal language model
Causal LM training is next-token alignment plus a no-looking-ahead proof; everything else scales that contract.
Build a transformer from scratchSampling, KV cache, and efficient generation
Efficient generation couples a declared sampling policy with a position-correct KV cache whose logits match the uncached model.
Courses & assignments
Dependency-authoritative learning units.
Casebook
Reported facts and course reconstructions.