Language & LLMs
What Is Nucleus Sampling?
Nucleus sampling is a text-generation technique, also known as top-p sampling, that samples from the smallest set of tokens whose combined probability passes a chosen threshold. Because the set size adapts to the distribution, it avoids both overly repetitive and overly random output. It is widely used in modern language models.
Further reading
Read more about nucleus sampling — articles and blogs from around the web: