• Sources: primary, discussion
  • Summary: On 8.5 million inputs with certified references, over 85% of FP32 scalar-family values near KL 1e-7 had at least 1% relative error, and about 30% became negative at smaller divergences, while computing one precision higher still left 7 to 51% significantly wrong. Stable closed-form decompositions, compensated arithmetic and analytic gradients removed over 97% of significant errors. The errors caused up to 97% top-1 disagreement in identical-start distillation and changed 19 to 59% of GPT-2 circuit edge scores.
  • Why it matters: Clamping negative KL to zero hides the error, so KL penalties in distillation, RL post-training and quantization layer ranking may need the authors' stable formulations.
  • Background: KL divergence measures how far one probability distribution is from another and is used as the penalty that keeps a post-trained policy near its reference model, and as the loss in distillation. When the two distributions are nearly equal, the textbook formula subtracts nearly equal logarithms, and floating-point cancellation leaves mostly rounding noise. That regime is common in training, because the policy starts identical to its reference.