By Team Edtoolkits · AI learning
Hold the starting word fixed while comparing the tiny word-pair model's deterministic and sampled continuations.
Use the guide alongside the working tool.
Open Greedy vs Sampling: Straight Path or Wandering →Explore the lesson
Watch two paths grow word by word.
Pick a start word and generate with both methods.
Flip the memory card and answer the quick check.
A comparison to try
Generate a longer continuation greedily and inspect any repeated suffix. Repeat with sampling and several seeds. Compare the repeated cycle and share of distinct words rather than judging only a single fluent phrase.
Read the result
Greedy decoding repeatedly takes the highest-probability next choice; sampling can follow less frequent branches. Different seeds help separate a systematic loop from a lucky or unlucky random continuation.
A mistake to avoid
Greater variety is not the same as factual accuracy or useful writing. This model uses only word pairs, so its rapid loops exaggerate a mechanism rather than measuring repetition in a production language model.
Teaching model and privacy
A tiny word-pair model trained on a few made-up sentences, so loops show up fast. Real models are far richer, but greedy decoding can still repeat. Nothing leaves your browser.
Ready to apply this workflow?
Try Greedy vs Sampling: Straight Path or Wandering →Explore a related workflow
- Choose a course entry point and verify saved progress
Use prior knowledge to select a starting chapter while distinguishing local progress from an account or a qualification.
- AI Tokens: Inspect Pieces, Spaces and Stable Teaching IDs
Compare common words, rare words and numbers without using the playground as an exact provider counter.
- Inspect candidates before continuing text
Compare normalized next-word probabilities with the choices sampled from them.
- Choose complexity using held-out error
Compare training and test curves before calling a detailed fit an improvement.
Found unclear instructions or an unexpected result? Contact Team Edtoolkits.