🧪 The AI Lab← All labs
Lab 4

🔮 Guess the next word

Language is full of patterns, so the next word is often easy to guess. A language model turns this into a game: given the words so far, it gives every possible next word a chance (a probability), then picks a likely one — and repeats. You be the model: build a sentence by picking words!

Start with:
Pick a starter above…
The model's guesses for the next word — click one

🤖 In a real LLM — this IS "inference" What you just did is exactly how an LLM writes an answer: look at the words so far → score the next word → pick one → add it → repeat. The difference is size: a real model scores its whole dictionary (tens of thousands of tokens) using the numbers it learned during training — not a tiny hand-made list like ours. See training vs inference →

Practice 🎯

Last lab → 🤖 Training vs Inference