Learning complex temporal dependencies via local synaptic plasticity
The ability to extract and exploit temporal structure across diverse tasks is central to human cognition. Neuroscientists have typically relied on recurrent neural networks (RNNs) trained with backpropagation through time (BPTT) when modelling neural and behavioural processes such as decision-making and motor control. However, this algorithm has limited biological plausibility, hence the computational principles underlying efficient learning of temporal dependencies remain unresolved. Here, we investigate temporal predictive coding (tPC), a recently proposed framework that extends predictive coding to the temporal domain while preserving local Hebbian update rules. We analyse and extend tPC to establish its relationship with several influential computational models of learning in RNNs, including BPTT, reservoir computing, and eligibility propagation (e-prop). We first demonstrate a functional equivalence between tPC and tBPTT1, a variant of BPTT in which gradients are propagated only one time step into the past. We then show that tPC can leverage reservoir dynamics to encode short-range temporal context, and simultaneously sculpt neural trajectories in state space to support downstream readout. We further demonstrate that hierarchical recurrent dynamics can facilitate learning of more complex temporal dependencies, while additionally conferring robustness to strong distractors. Finally, we show that tPC networks can be augmented with biologically inspired eligibility traces to solve temporally extended context-dependent tasks. Together, these results reveal that relatively simple recurrent networks governed by local plasticity can support temporal learning in more complex settings than previously appreciated. Author summary To navigate the world, our brains must constantly track how events unfold over time, whether we are predicting the next word in a sentence or timing a tennis swing. Neuroscientists often use artificial neural networks to study how the brain learns these sequences. However, these models are often not biologically realistic, since they adjust neuronal connections using information that individual neurons would not have access to in the brain. Here, we examine an alternative framework called temporal predictive coding, which is designed to better reflect how brain networks may be organised. We show that these biologically inspired networks are surprisingly powerful: they can remember recent context and, when arranged in layers, can learn increasingly complex patterns. We also show that they work better when equipped with a memory-like mechanism that helps neurons link recent events across time. Overall, our findings suggest that relatively simple, biologically inspired networks may capture how we process sequential events better than previously thought.