Interactive lab
The Small Language Machine gains a corpus, buttons and generation
Turn the conceptual prototype from Module 1 into an interactive experience: edit the corpus, observe tokens, build the continuation table and generate text.
What this module does
In this module you do not just read about the machine — you tinker with it. The lab above comes alive as you edit.
It shows corpus, tokens, vocabulary, contexts, continuation table, probabilities and the generated text — all at once, reacting to what you type.
The machine is simple on purpose
This is not a modern LLM. It is an n-gram counting machine, the same as in Lessons 7 and 10.
Precisely because it is small, it is transparent: we can see where each continuation came from. No black box — just a little glass box.
First contact
In the lab above, click "Generate step by step" and advance one step at a time. Notice: at each step, what appears before the machine picks the next token?
See expected answer
Before choosing, the machine shows the context (the last words) and the list of possible continuations with their probabilities. The choice does not come from nowhere: it comes from the table the machine built from your corpus.
The goal of the lab is to open the mini black box: watch language generation happen step by step, with every decision in plain sight.