Glossary

Perplexity (Language Model Metric)

A measure of next-token prediction loss on specified text, expressed as the exponential of average negative log probability.


A model that always gives the observed next token a one-in-four chance has a perplexity of four. That’s a nice clean example. Things get less tidy as soon as two models disagree about where the tokens begin and end.

Perplexity summarizes how much probability a model gives to the observed sequence under the chosen tokenization and scoring convention. Lower values indicate better prediction on a comparable test. They do not measure factual accuracy or the quality of a scientific explanation.

Keep the prediction unit fixed

Run the same sentence through different tokenizers and count the prediction positions. A system predicting short pieces has a different job from one predicting whole words. Comparing the two raw numbers can be misleading even when the visible sentence never changed.

For a published score, check the evaluated text, context, document boundaries and which tokens contributed to the average. If your job is extracting accurate citations, evaluate that as well. Guessing the next ordinary word is a rather different skill.