Activity (Process)

Next Token Selection in k-NN Language Models

After computing the interpolated final probability distribution, Pr(hi)\mathrm{Pr}(\cdot|\mathbf{h}_i), a kk-nearest neighbors (kk-NN) language model selects the next token, yy. This selection is achieved by finding the specific token that maximizes the final probability, Pr(yhi)\mathrm{Pr}(y|\mathbf{h}_i), thereby choosing the most probable output based on the combined retrieval and model predictions.

0

1

Updated 2026-04-23

Contributors are:

Who are from:

Tags

Ch.2 Generative Models - Foundations of Large Language Models

Foundations of Large Language Models

Foundations of Large Language Models Course

Computing Sciences