Chat Inference

Type a prompt and watch a chat reply generate token by token — logits, softmax, temperature, top-k, and the exact probability every token was sampled with.

When you send a message to a chat model, the reply is generated one token at a time: the whole conversation runs through the model, out comes a probability for every token in the vocabulary, one is sampled, appended, and the loop repeats. This workspace shows that loop with nothing hidden.

The probability bars are the real softmax over a toy language model's logits; the temperature slider genuinely reshapes the distribution (watch the bars flatten as you raise it); top-k masking, greedy decoding, and seeded sampling are all the real algorithms. Two runs with the same seed generate identical text — change the seed and the same prompt takes a different path.

The transformer itself is the collapsed box in the middle — open the Transformer topic to see inside it.

Open the interactive Chat Inference workspace →