Attention over noisy examples: generalization and memorization in the exponential Hopfield network
Francesco Alemanno
Key points
From the paper's conclusion- The exponential Hopfield network was trained with M blurred examples of quality r for each archetype, and the protocol was analyzed through a signal-to-noise approach
- The overlap between the output and an unseen archetype was found to be m^{(1)}={ m erf}(1/ ext{sqrt}(2 ho_{ m eff}))
- Learning fails differently in the exponential model through memorization, where the softmax concentrates its weight on the training example closest to the input
Abstract
In Hebbian learning from examples a Hopfield network of $N$ neurons is not supplied with the $K$ archetypes it has to retrieve but with $M$ blurred examples of each, of quality $r$, and whether it can infer them depends on the load $\alpha=K/N$ (interference among them) and on the dataset entropy $\rho=(1-r^2)/(Mr^2)$ (how little the examples say about them). We transfer this protocol to the exponential Hopfield model, whose zero-temperature update is a step of softmax attention with the unlabelled examples as keys. A signal-to-noise analysis gives in closed form the overlap between the output and an unseen archetype, $m^{(1)}={\rm erf}(1/\sqrt{2\rho_{\rm eff}})$: the majority-rule law of the pairwise model at small load, with $\rho$ replaced by an attention entropy $\rho_{\rm eff}$ built from the weight the softmax gives to the correct class and the number of examples it spreads it over. Two consequences follow. First, in a window of inverse temperatures $\beta$ that widens as $\sqrt N$ the interference between archetypes is exponentially small in $N\beta$: the load drops out and the number of archetypes that can be learnt grows as $\exp(c\sqrt N)$. Second, learning fails differently: in the pairwise model through a spin-glass phase, in the exponential model through memorization: the softmax concentrates its weight on the training example closest to the input and returns it in place of the archetype. Seen from the input the softmax weights are those of the random energy model, and memorization is its freezing transition, at $\beta\sqrt{N(1-r^2)}\simeq\sqrt{2\ln M}$; it is measurable on a head whose keys are examples as the number of examples carrying weight. On MNIST the diagnostic follows the random-energy prediction; on fashion-MNIST it detects sub-clusters in the classes, and the best accuracy lies beyond the memorization threshold, where the softmax reads out a local sub-prototype.
Read the paper
Discussion · 1
Science Skim's AI key points, plus readers' public thoughts
- The exponential Hopfield network was trained with M blurred examples of quality r for each archetype, and the protocol was analyzed through a signal-to-noise approach
- The overlap between the output and an unseen archetype was found to be m^{(1)}={ m erf}(1/ ext{sqrt}(2 ho_{ m eff}))
- Learning fails differently in the exponential model through memorization, where the softmax concentrates its weight on the training example closest to the input
Readers' thoughts
No reader thoughts yet.
Related papers
- Inferring concepts from noisy examples in Hopfield-like neural networksPhysical review. E · 2026
- The importance of being empty: Hopfield neural networks with diluted examplesNeurocomputing · 2026
- Thermodynamics of Forgetting in a Bounded Hopfield NetworkarXiv · 2026
- Redundancy maximization as a principle of associative memory learning in Hopfield networks.Nature communications · 2026
- The Infinite Volume Limit of the Hopfield Neural Networks in the Replica-Symmetric RegimeAnnales Henri Poincaré · 2026
- Phase Kernel Lifts Capacity of Dense Associative MemoryarXiv · 2026