Back to the wiki

Temperature

The dial that controls how daring the model gets.

The analogy

It's like ordering a dish from a cook. At low temperature, they follow the recipe to the letter: the dish comes out the same every time. At high temperature, they improvise: sometimes they create something brilliant, sometimes an interesting disaster.

In detail

Temperature is a parameter (typically between 0 and 2) that reshapes the probability distribution when picking each token. Near 0, the model almost always picks the most likely option: consistent, predictable answers. At higher values, probability spreads out: more diversity, more creativity, and more risk of errors.

An example

Extracting dates from an invoice? Temperature 0. Brainstorming twenty names for your coffee shop? Crank it up. Same model, different setting.

Related concepts