Mini LLM Inference Server
ML JOURNEY / FULL WALKTHROUGH

Mini LLM Inference Server

Construct sampling, tokenization, KV caching, paged allocation, continuous batching, streaming, and benchmarking.

8 parts51 individual lessons4.3 estimated hours255 XP available
Mini LLM Inference Server project artwork
0%0 of 51 complete
Start walkthrough
No compressed chapters.

Every source step is its own lesson with intuition, concepts, correctly rendered MathJax mathematics, implementation, tests, mistakes, and a checkpoint.

05
PART 5

Sequences and Static Batching

Model per-request sequence state, drive single-sequence generation, then batch multiple sequences through synchronized decode steps.

0/8
026define sequences and static batching+5 XP027derive sequences and static batching+5 XP028prepare sequences and static batching+5 XP029implement sequences and static batching+5 XP030connect sequences and static batching+5 XP031validate sequences and static batching+5 XP032debug sequences and static batching+5 XP033optimize sequences and static batching+5 XP
06
PART 6

Continuous Batching and Scheduling

Add capacity checks, priority queues, admission, preemption, and a scheduler that mixes prefill and decode across in-flight requests.

0/8
034define continuous batching and scheduling+5 XP035derive continuous batching and scheduling+5 XP036prepare continuous batching and scheduling+5 XP037implement continuous batching and scheduling+5 XP038connect continuous batching and scheduling+5 XP039validate continuous batching and scheduling+5 XP040debug continuous batching and scheduling+5 XP041optimize continuous batching and scheduling+5 XP