Skip to content

Lab file downloads

Every complete script, configuration file and notebook in this course is a real file that you can download and run.

The pages do not contain their own copy of the code. Each page reads the file from disk when the site is built, which means the code you read in a lab and the file you download here are the same bytes. They cannot drift apart, and if a file were ever missing the site would fail to build rather than quietly show you something that does not exist.

  1. Download the file, or use the copy button on the code block in the lab.
  2. Read the header first. Every file states its purpose, the platform track it was written for, the smallest memory it needs and what it assumes about your setup.
  3. Run it on the track it names. A script written for the DGX Spark’s aarch64 CUDA stack will not work unchanged on a Mac, and the page says what changes.
  4. Check the page’s validation line to see whether the file was executed on that track before release, and with which versions.

These files are written to be read and understood, not to be run blind. Several of them deliberately do things you must not do on a machine you care about: the challenge pages ship broken configurations on purpose so that you can diagnose them, and they say so at the top of the file in capital letters. Read the header before you reuse anything.

Nothing here is a recommendation of a particular model, engine or machine. See the disclaimer.

267 files across 28 parts.

Part 1 — Machine Learning Foundations for LLM Work

Part 2 — What a Language Model Is

Part 3 — How Models Are Made and Improved

Part 4 — The Open-Weight Model Landscape

Part 5 — Your Hardware: Four Platforms, One Course

Part 6 — First Inference with llama.cpp

Part 7 — Ollama, LM Studio and the Desktop Experience

Part 8 — Platform-Native Engines: MLX, TensorRT-LLM and ROCm

Part 9 — Serving at Scale: vLLM and SGLang

Part 10 — Putting Models to Work

Part 11 — The Training Toolchain

Part 12 — Pretraining a Small Model from Scratch

Part 13 — Supervised Fine-Tuning: LoRA, QLoRA and Full Fine-Tunes

Part 14 — Preference Optimisation and Reinforcement Learning

Part 15 — Knowledge Distillation: Big Teacher, Small Student

Part 16 — Quantisation and Evaluation, Properly

Part 17 — Faster Inference: Speculative Decoding, Caching and Draft Models

Part 18 — Beyond One Machine: Parallelism and Networks

Part 19 — Clustering with llama.cpp RPC

Part 20 — NVIDIA Clusters: DGX Spark Pairs, vLLM Multi-Node and Multi-GPU Desktops

Part 21 — Apple Clusters: MLX Distributed and exo over Thunderbolt 5

Part 22 — Disaggregated Serving: Prefill Machines and Decode Machines

Part 23 — Operating a Local AI Service

Part 24 — Tool Calling, MCP and the Agent Loop

Part 25 — Coding Agents on Local Models

Part 26 — Building Agent Systems

Part 27 — Improving a Model for Your Agents

Capstone: Build and Defend Your Own Local AI Platform