When does temperature > 0 produce better results than temperature = 0 in production LLM applications?
T > 0 wins when you need diversity (creative tasks, self-consistency voting) or want to escape a wrong argmax; T = 0 wins for single-answer tasks and reproducibility.
Imagine asking a friend to pick a restaurant. If you always want their single best recommendation, you want them to give the same answer every time. That is temperature equals zero, totally consistent, no variety. But if you want them to brainstorm five different options for a group, you need them to sometimes pick the second or third favorite, not just the absolute top. That is temperature above zero, where the model is allowed to sample less obvious answers. The right setting depends on what the answer is for, not on a universal rule.
Detailed answer & concept explanation~5 min readEverything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example.
Everything important, quickly.
3 min: softmax with temperature + three T > 0 scenarios + when T = 0 wins + how to pick per task.
Real products, models, and research that use this idea.
- Anthropic's Claude Opus 4.7 API defaults T = 1 but production extraction pipelines pin T = 0 for reproducible JSON outputs.
- OpenAI's GPT-5.5 docs recommend T = 0 for classification and T = 0.7 to 1.0 for creative generation.
- Cursor's code-completion path uses higher temperature with best-of-N reranking, while its inline JSON tool calls run at T = 0.
What an interviewer would ask next. Try answering before peeking at the approach.
QWhy does self-consistency specifically need T > 0?
Don't say thisRed flags and common mistakes that signal junior thinking. Click to expand.
Red flags and common mistakes that signal junior thinking. Click to expand.
Treating T = 0 as the safe default for every production task, then being surprised when self-consistency voting collapses because every sample is identical.
The night-before-the-interview bullets. Scan these on the way to the call.
Primary sources. Skim if you want the original framing.
Same topic, related formats. Practice these next.