Swapping 1% of a pre-training batch can enlarge gradients ~300x, finds Orabona

bremen79 · x · 2026-12-02

Optimization researcher Francesco Orabona published a blog studying how little of a batch it takes to change LLM training gradients, aided by coding agents. Key findings: a DNA sequence from a patent file abruptly enlarged the gradient at step 2,507 of a training run; replacing just 1% of a batch with a repeated common-word pattern inflated gradient norms 15–334x depending on the model, while loss barely moved or even fell. He open-sourced code plus 1,200 batch comparisons across four models with gradient RMS and per-token loss. First post in his series on understanding LLM pre-training hands-on.

Original post →

More from Models

Models channel →