A neural network model of free recall learns multiple memory strategies

Moufan Li, Kristian H. R. Jensen, Qiong Zhang, Qihong Lu, Marcelo G. Mattar

Abstract

Humans exhibit structured patterns of memory recall, including a tendency to recall more recent information and to recall events in the same order they were experienced. Classic computational models explain these patterns by positing that memories incorporate the ongoing “temporal context”, formed by smoothly integrating the stimulus history. However, it is unclear whether a single mechanism can account for the full repertoire of human memory strategies, as the optimal approach may be task-dependent. For example, human memory experts widely apply the “memory palace” strategy, which is empirically better but not captured by temporal context models. Here we show that neural networks optimized for free recall develop diverse retrieval strategies, with only some of them resembling temporal context models. The best-performing models discovered a stimulus-invariant index code that emphasizes the studied position of each list item, instead of its temporal context. This creates a stable scaffold for forward recall akin to the memory palace technique. This index code was more likely to emerge when networks were i) encouraged to recall all studied items rather than prioritizing a few items, and ii) prevented from relying on recency, resonating with human data. Our findings demonstrate that human-like recall patterns can arise from multiple distinct computational mechanisms, and that sequential retrieval using item index is an optimal strategy that explains expert-level recall performance.

Introduction

Human memory is famously structured. When asked to recall a list of items (the "free recall" task), we tend to remember items from the end of the list first (recency) and recall items in the order they were studied (contiguity). For decades, the gold standard for explaining this has been the Temporal Context Model (TCM). TCM posits that our internal state "drifts" over time, and we associate memories with this ever-changing context.

However, TCM struggles to explain "expert" memory strategies, like the Memory Palace (Method of Loci), where items are pinned to fixed mental locations. This study investigates whether a single neural architecture can learn both strategies and identifies the environmental conditions under which one becomes more optimal than the other.

Methods

The researchers designed a neural network consisting of two main components: a Context Module (a Gated Recurrent Unit or GRU serving as working memory) and a Memory Module (an external episodic buffer storing snapshots of the context state). Unlike traditional models with hand-crafted rules, this architecture was trained using Reinforcement Learning (Advantage Actor-Critic) to maximize the number of correctly recalled items.

Model architecture and comparison of drifting context vs. index-based strategies.

The study utilized synthetic datasets mimicking human psychological experiments: Standard Free Recall (lists of 8 items) and Conditional Free Recall (items with features like color or category, where recall is cued by feature). By varying hyperparameters—such as the "discount factor" (valuing future rewards) and "working memory flush" (noise injected between study and recall)—the authors observed how different pressures shaped emergent strategies.

Results and Key Insights

Optimization did not lead to a single solution. Instead, the networks converged on three distinct strategies: "Memory Palace" (index-based), "TCM-like forward," and "TCM-like backward."

Comparison of emergent retrieval strategies and their representational characteristics across different training outcomes.

The "Index Code" as a Scaffold

The most successful models discovered a stimulus-invariant "index code." Instead of the internal state drifting based on what was seen (item identity), it followed a rigid, stereotyped trajectory based on when it was seen (item index). This creates a stable "scaffold" that makes forward recall incredibly efficient, functionally equivalent to the memory palace technique. In these models, the item index explained significantly more variance in hidden states than item identity.

Task-Dependency and Robustness

While the Memory Palace is the "pro" strategy for exhaustive sequential recall, it becomes a liability in Conditional Free Recall tasks requiring content-based search. In those cases, the networks abandoned the rigid index scaffold in favor of TCM-like, content-dependent context. Interestingly, injecting noise into hidden states during training promoted the discovery of the Memory Palace strategy, as the stable index scaffold proved more robust to neural noise than drifting context.

Discussion

This work demonstrates that human-like recall patterns can arise from multiple distinct computational mechanisms. The discovery of an index-based strategy suggests that sequential retrieval using a stable scaffold is an optimal solution for high-performance recall. While the current RNN architecture is a functional abstraction, it provides a framework for studying how episodic memory supports higher-order functions like planning and inference, where retrieving specific sequences of past events is crucial.

Summary updated

BibTeX
@misc{li2025neural,
  author = {Moufan Li and Kristian H. R. Jensen and Qiong Zhang and Qihong Lu and Marcelo G. Mattar},
  title = {{A neural network model of free recall learns multiple memory strategies}},
  year = {2025},
  url = {https://openreview.net/forum?id=vJ2Liwy0n7},
}
Figure