intuitiveai

Large language models

Predict one token at a time.

A language model assigns a score to each possible next token. Softmax turns those scores into probabilities.

Sampling selects a token from that distribution. The token is appended to the context, and the model predicts again.

pᵢ = exp(zᵢ / T) / Σⱼ exp(zⱼ / T)

Move the temperature slider. How does the probability of “mat” change?

A five-token vocabulary01 / 03
The cat sat on the ____
mat50.7%
floor25.2%
chair13.8%
roof6.2%
table4.2%

Lower temperature concentrates probability on high-scoring tokens.

Illustrative scores, not a live language model. Sampling and temperature scaling are computed in your browser.

Experiment notes

Record your experiment

Predict how temperature will change the next-token probabilities.

Feedback & sharing

Helpful?