bartlomiejmucha.com

Free courses · 2026

Learn how it works, piece by piece.

Slow, visual, hands-on courses. Every lesson has diagrams you can poke at and exercises that check your answer. Free, no account, everything runs in your browser.

Browse the courses Get in touch

18 lessons — available now

01

LLMs from scratch

How large language models actually work, built up one piece at a time. It starts with “what is a token” and ends with mixture-of-experts routing, speculative decoding and RLHF — no maths background assumed.

  • Tokens, embeddings, attention and the transformer block
  • Pretraining, scaling laws, SFT, RLHF and DPO
  • Interactive diagrams in every lesson, plus checked exercises
  • Progress saved locally — no account, no tracking

The map

  1. 1What a language model actually does
  2. 2Tokens: how text becomes numbers
  3. 3Embeddings: meaning as direction
  4. 4Neurons, matrices and nonlinearity
  5. 5Attention: queries, keys and values
  6. 6Multi-head attention
  7. 7Position: how the model knows word order
  8. 8The transformer block
  9. 9The full forward pass
  10. 10Sampling: probabilities into text
  11. 11Context windows and the KV cache
  12. 12Pretraining: where weights come from
  13. 13Scaling laws: why bigger worked
  14. 14Post-training: SFT, RLHF and DPO
  15. 15Prompting and chain-of-thought
  16. 16RAG, tools and agents
  17. 17Making models cheap
  18. 18Evaluation, hallucination, open problems