AI Glossary Term
What does “Repetition Penalty” mean?
Definition
A decoding setting that lowers the probability of tokens the model has already produced to reduce loops.
How Repetition Penalty works
Example
Without a penalty, a model might loop with 'the best of the best of the best'. A modest penalty on repeated tokens nudges it to move on.
Why it matters
Repetition loops make text unreadable. Too strong a penalty can stop the model from reusing words it legitimately needs, such as names.
Common questions
Repetition vs frequency penalty?
They are similar. Frequency penalty scales with how many times a token appeared; repetition penalty is often applied once to any seen token.
Typical values?
Slightly above 1 in some systems; scales differ by software, so check the documentation.
Does it fix all loops?
Not always. It helps with simple loops but can distort legitimate repeats.