liveBook · Manning

Grokking

As explained in Sutskever's List

Grokking is a delayed-learning phenomenon in which a neural network first memorizes its training data and later abruptly develops a solution that generalizes.

Grokking is delayed generalization: a neural network first fits its training data perfectly, then—sometimes much later—test accuracy rises abruptly from guessing to nearly 100%. The shift from memorization to a general rule raises a question: what changes inside the network? section 8.5

Research described in “Complexity Dynamics of Grokking” tracks the learned representation’s intrinsic complexity. It rises as the network memorizes, then falls sharply as the network settles on a simpler pattern that generalizes. This rise-and-fall appears with sufficient regularization; without it, complexity stays high and the network does not generalize. The account connects this pattern to the coffee automaton’s arc of rising and then declining complexity. section 8.5

Modular arithmetic

In experiments on modular arithmetic, including addition, multiplication, subtraction, and division, representation complexity peaks around the transition: training accuracy is already high while test accuracy has yet to catch up. Complexity then falls as the model reaches a simpler, rule-like solution. section 8.5

Figure 8.8 Complexity during grokking on modular arithmetic tasks. Gray curves show train and test accuracy; the thick curve shows the estimated complexity of the learned representation. Across modular addition, multiplication, subtraction, and division, complexity rises during the memorization-to-generalization transition and then falls once the model settles into a simpler rule-like solution. The peak occurs near the interval where training accuracy (dashed gray) is already high, but test accuracy (solid gray) has not yet fully caught up. As models memorize, complexity increases; as they generalize, complexity (measured in bytes) decreases. Used with permission granted by the lead author (Branton DeMoss).
figure

Compare training and test accuracy with estimated representation complexity across modular arithmetic tasks. section 8.5

How Sutskever's List covers it

How deep it goes
Tracks accuracy and representation complexity through the transition, without giving a procedure for inducing grokking.
Examples
Uses modular addition, multiplication, subtraction, and division to illustrate complexity changes during grokking.
What you can do after
Understand how regularization can accompany falling representation complexity as test accuracy rises.
How it connects
Connects grokking to regularization, model complexity, compression, generalization, and the coffee automaton.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Sutskever's List. The section links point to the parts of the book it draws on.