productinterview.tools
MenuClose

What Is Temperature in LLMs? Sampling Explained

A setting that controls how much randomness goes into choosing each next token: low is focused and repeatable, high is varied.

1 min read
On this page
  1. How it works
  2. Why it matters, by role
  3. How interviews test it
  4. Common confusions
  5. Related concepts
  6. Sources

How it works

  • The model gives probabilities for the next token; sampling picks one.
  • Temperature reshapes those probabilities before picking.

Full lesson: How LLMs work.

Why it matters, by role

  • AI Product Engineer: Settings per task.
  • Forward Deployed EngineerForward Deployed Engineer. An engineer embedded with customers who scopes, builds and ships AI solutions into production. Read the full explanation: Explaining inconsistency to customers.

How interviews test it

Common confusions

  • Temperature 0 reduces but doesn't guarantee identical outputs.
  • Consistency for facts comes mostly from grounding, not settings.

Sources

  • Explained from standard practice; taught in full in the How LLMs work module.