The map
What a language model actually is, what pretraining and post-training mean, where LSTMs and vision models fit, and how to use the exercises here.
- The big picture25 min
- How this lab works15 min
Part 1
Ten modules. The first half rebuilds the math you need, with visual intuition first and hand calculation second. The second half uses it to build networks, recurrent networks and LSTMs from scratch. Each module ends with a checkpoint.
What a language model actually is, what pretraining and post-training mean, where LSTMs and vision models fit, and how to use the exercises here.
Vectors as arrows and as lists, linear combinations, the dot product in algebra and geometry, length, and cosine similarity between embeddings.
Matrices as linear transformations, matrix multiplication as composition, and the shapes and batches that every neural network layer is made of.
The determinant as area scaling, inverses as undoing, and rank as how many dimensions survive. The ideas behind LoRA and ill-conditioned training.
Eigenvectors by picture and by hand, what repeated multiplication does, stability and explosion, symmetric matrices, and the singular value decomposition.
Derivatives as local linear maps, gradients as the direction of steepest climb, Jacobians and the chain rule as matrix multiplication, and gradient descent.
Neurons and layers as matrix operations, softmax and cross-entropy, backpropagation derived and implemented, and a full training loop you write yourself.
Sequences and hidden state, next-character language models, backpropagation through time, and why plain recurrent networks forget.
The cell state and its gates, an LSTM designed by hand, the full forward and backward pass, training on text in your browser, and your own variants.
Attention as a dot-product lookup, how frontier models are pretrained and post-trained, fine-tuning your own model, and how vision models find objects.