q-bio.NCSep 28, 2026

Oscillatory Phase Coding Emerges in Adaptive RNNs for Flexible Working Memory

Authors: Kehan Lu, Tianhao Chu, Aiersi Tuerhong, Yiwen Sun, Huan Luo, Fang Fang, Si Wu

Organizations: Academy for Advanced Interdisciplinary Studies, Peking University, Beijing, China. · School of Psychological and Cognitive Sciences, Peking University, Beijing, China. · Peking University, Beijing, China.

Abstract

Oscillatory phase coding (OPC) is widely observed in neural systems and has been implicated in cognitive functions such as memory and sequence processing. However, its computational role and neural substrates remain largely unclear. Here, we studied OPC by training recurrent neural networks (RNNs) with adaptation to perform sequence working memory tasks with variable delays. After training, we found that OPC emerges in the RNN spontaneously: the memorized items recur at distinct phases of a shared rhythm, with oscillation amplitude encoding item identity and phase encoding serial order. Ablation studies identified three key elements required for OPC: adaptation in neural dynamics, variable delay in memory retention, and flexibility in reading out information. Neuron-type analysis revealed the emergence of content and time cells in the trained RNN, and they process item identity and sequence order separately. Recurrent connectivity analysis revealed phase-organized connections among time cells and structured connections within digit-selective content-cell groups. Inspired by these findings, we proposed a neural circuit model which reproduces OPC through interactions between content units and an adaptive time ring. Together, this study reveals how OPC arises from network structures and task demands, offers insights into the implementation and computational mechanisms of OPC in biological systems, and inspires us to develop computational models for human-like cognitive functions.

Figures & tables

Appendix figures & tables16 assets

Supplementary material from the paper’s appendix.

Appendix

Explore similar work

CardsList
  1. Clocks all the way down: does sequence-processing AI need endogenous temporal structure?

    Nov 3, 2026Meysam Hashemi, Alireza Valizadeh, Viktor JirsaTemporal Representation LearningNeural Encoding

  2. A Unified Phase-native Computational Principle Governs Hippocampal Spike Timing and Neural Coding

    Mar 20, 2026Reza Ahmadvand, Sara Safura Sharif, Yaser Mike BanadSpike-Based Signal EncodingNeural Encoding