Decoding
The process of transforming model outputs into text: the model outputs token probabilities, and the decoding strategy decides which to choose.
Strategies
- greedy — always the most probable;
- beam search — keep several hypotheses;
- sampling — randomly with probability consideration;
- top-k / top-p — limit the selection.
Why Choice is Important
The strategy affects the character of the text: rigid and predictable or lively and diverse.