Activity (Process)

Expansion Stage in Top-k Sampling

The expansion stage is the initial step in the top-k sampling process, as depicted in stage ① of the corresponding flowchart. Given a preceding context, such as the word 'is', the language model generates a set of all possible subsequent tokens from its vocabulary. In the provided example, this results in five candidate words: '.', 'cute', 'on', 'are', and 'sick'.

Image 0

0

1

Updated 2025-10-10

Contributors are:

Who are from:

Tags

Ch.5 Inference - Foundations of Large Language Models

Foundations of Large Language Models

Foundations of Large Language Models Course

Computing Sciences