Scientists Introduce Centered Daydreaming Algorithm to Eliminate Hallucinations in Hopfield Networks by Mimicking Sleep and Memory Consolidation
Researchers have transferred the human brain’s daytime encoding and nighttime memory consolidation process into Hopfield networks, one of the earliest mathematical models of associative memory, successfully eliminating hallucinations caused by false attractors.
During the day the brain records new information; during sleep it reviews accumulated memories, reinforcing useful patterns and weakening irrelevant ones. Scientists replicated this mechanism in Hopfield networks first introduced in 1982, where interconnected artificial neurons store complete patterns that can later be reconstructed from partial or noisy inputs.
The classic model, however, suffers from severe capacity limits—roughly 13 memories per 100 neurons—because the remaining space is occupied by false attractors. These spurious states mix features from multiple learned patterns, causing the network to reconstruct nonexistent combinations that resemble AI hallucinations.
Earlier “dreaming” algorithms attempted to clean the network after training by letting it wander through random states and weakening connections leading to false attractors. Prolonged cleanup, though, triggered catastrophic forgetting, erasing correct memories along with erroneous ones.
In 2025 the team introduced the Daydreaming algorithm, which merges learning and cleanup into a single continuous process. The network simultaneously strengthens valid states and suppresses false attractors during the encoding phase itself, raising capacity close to the theoretical maximum of one memory per neuron.
The original Daydreaming method worked well only with balanced datasets where black and white pixels appeared in roughly equal proportions. Real photographs frequently violate this assumption: heavily overexposed images contain mostly white pixels, while nighttime shots are dominated by black pixels, making distinct objects appear artificially similar.
To solve the imbalance problem, researchers developed Centered Daydreaming. Instead of comparing absolute pixel values, the algorithm measures each pixel’s deviation from the dataset mean. For face recognition, the system first computes an average face and then focuses exclusively on the distinctive features that differentiate individual images from this baseline.
This local, mean-centered approach preserves biologically plausible operation: each artificial neuron updates its connections using only information available from its limited neighborhood, without requiring global knowledge of the entire network state.
Experiments confirmed that Centered Daydreaming maintains high reconstruction accuracy even under extreme data skew, whereas the previous version suffered significant degradation. Although Hopfield networks are far simpler than modern large language models, their transparent structure allows researchers to trace exactly how false memories emerge and how targeted connection adjustments can remove them.
The study demonstrates that important distinctions can be separated from dominant background statistics without centralized control, potentially informing the design of more reliable, efficient, and interpretable AI architectures in the future.