Prompting & Interaction

Top-P (Nucleus Sampling)

A setting that controls output diversity by limiting which tokens the model can choose from.

Definition

Top-P (also called nucleus sampling) is an alternative to temperature for controlling output diversity. Instead of scaling all probabilities uniformly (as temperature does), Top-P restricts the model to choosing from the smallest set of tokens whose combined probability adds up to P. For example, with Top-P = 0.9, only the most likely tokens are considered — the 'nucleus' of the probability distribution. This tends to produce more coherent outputs than high temperature while still allowing variety.

Heard enough terminology — ready to talk outcomes?

We translate AI concepts into measurable business results. No upfront fees — you pay only when independently verified results are delivered.

← Back to glossary

Disclaimer

This definition is provided for educational and informational purposes only. It represents a general explanation of a technical concept and does not constitute professional, technical, or investment advice. Artificial intelligence is a rapidly evolving field; terminology, techniques, and capabilities change frequently. Coaley Peak Ltd makes no warranty as to the accuracy, completeness, or currency of the information provided. Nothing on this page should be relied upon as the sole basis for commercial, technical, legal, or investment decisions without independent professional advice.

Document reference: ISO_webpage_knowledge-base_glossary_v1

Last modified: 29 March 2026

Knowledge Base·Prompting & Interaction·Top-P (Nucleus Sampling)