LLM From Scratch
Build a language model from first principles. This tutorial takes you from basic tensor operations to a working code-generating model.
Modules
| Module | Topic | Description |
|---|---|---|
| 01 | Tensors | Shapes, broadcasting, operations |
| 02 | Autograd | Gradients, chain rule, backprop |
| 03 | Tokenization | BPE algorithm, vocabulary |
| 04 | Embeddings | Vector representations |
| 05 | Attention | Self-attention, multi-head |
| 06 | Transformer | Decoder blocks, layer norm |
| 07 | Training | Loss, optimizers, batching |
| 08 | Generation | Sampling strategies |
Quick Start
# Install Quarto
brew install quarto
# Preview with live reload
quarto preview
# Or generate Jupyter notebooks
quarto render --to ipynb