Temperature sampling
Divides the logits before the softmax, which rescales how peaked the distribution is. Below one it sharpens toward the top choice; above one it flattens; at zero it becomes plain greedy decoding.
- The temperature.
- The logit for token i.
- The resulting sampling probability.