Definition

Penalty Function in Controllable Decoding

The penalty function, denoted as Penalty(x,y)\mathrm{Penalty}(\mathbf{x},\mathbf{y}), defines the cost or degree to which a generated output sequence y\mathbf{y} exhibits undesirable behaviors or violates constraints given the input x\mathbf{x}. Its flexible design allows it to be implemented in two general ways: assessing the final 'surface form' of the generated text, or evaluating the internal hidden states of the large language model during the generation process.

0

1

Updated 2026-05-05

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