Inferring context-dependent computations through linear approximations of prefrontal cortex dynamics

Joana Soldado-Magraner, Valerio Mante, Maneesh Sahani

TL;DR

Researchers have demonstrated that the complex, high-dimensional activity of the prefrontal cortex (PFC) during decision-making can be surprisingly well-approximated by linear dynamical systems. By fitting these models directly to monkey neural data, they discovered that two different biological mechanisms—changing internal recurrent "wiring" versus subtle modulation of sensory inputs—are equally capable of explaining how the brain switches between tasks.

What Problem Does This Paper Address?

Our brains are remarkably flexible. In a "blink of an eye," we can switch from focusing on the color of a traffic light to the motion of a pedestrian. This "context-dependent" computation is known to happen in the Prefrontal Cortex (PFC), but the exact mechanism remains a mystery.

Previous studies used Recurrent Neural Networks (RNNs) to simulate this behavior. While these RNNs could solve the task, they only "qualitatively" matched real brain activity, failing to capture the messy, heterogeneous richness of actual neurons. The authors of this paper wanted to move beyond simulations and fit mathematical models directly to neural recordings to see if they could uncover the actual "control logic" the PFC uses to gate information.

Methods

The authors employed Linear Dynamical Systems (LDS) to model the latent (hidden) state of neural populations. The core idea is that the state of the brain at any moment ($x_t$) depends on its previous state ($x_{t-1}$) transformed by a dynamics matrix ($A$), plus external sensory inputs ($u_t$) mapped through an input subspace ($B$).

They tested two main hypotheses by varying which parts of the model changed with the context:

  1. Context-dependent Dynamics ($A^{cx}, B$): The internal "looping" connections of the PFC change depending on the task, while inputs remain the same.
  2. Context-dependent Inputs ($A, B^{cx}$): The internal connections are fixed, but the "gain" or direction of sensory inputs is modulated (similar to an attentional filter).

To ensure that a linear model wasn't oversimplifying things, they compared the LDS results to a novel, highly flexible method called Tensor Factor Regression (TFR), which can capture non-linear patterns. Crucially, they inferred the external input signals directly from the data rather than using hand-crafted variables.

Datasets

  • Monkey PFC Data: Electrophysiological recordings (PSTHs) from the PFC of two rhesus monkeys (Monkey A, $N=727$ units; Monkey F, $N=574$ units).
  • Task: A contextual random dots task where monkeys had to report either the dominant color or the dominant motion of a stimulus, ignoring the irrelevant dimension based on a cue.
  • Synthetic RNN Data: Responses from a non-linear RNN trained on the same task, used as a "ground truth" benchmark to see if the LDS could recover known mechanisms.

Key Insights and Ideas

  • Linearity is "Good Enough": One of the most surprising findings is that linear models performed nearly as well as the non-linear TFR. This suggests that while the brain is globally non-linear, the dynamics within a specific task context are effectively linear.
  • The "Degeneracy" Dilemma: Both the "changing internal wiring" ($A^{cx}$) and "changing input gain" ($B^{cx}$) models fit the data equally well. This reveals a "model degeneracy"—mathematically, there are multiple biological ways to achieve the same result, and current recording techniques can't yet distinguish between them.
  • Two-Phase Integration: The models revealed that input integration isn't a single, steady process. It happens in two phases: an early phase dominated by fast, rotational dynamics, and a late phase dominated by slow, persistent dynamics that hold the final decision.
  • High-Dimensional Complexity: Unlike simple "line attractor" models used in the past (which use only 1 or 2 dimensions), the best-fitting models required 13–18 dimensions. The brain isn't just moving a slider along a single line; it’s navigating a complex, multi-dimensional landscape.

Key Results

  • Quantitative Fit: The LDS models captured approximately 27% of the total data variance (a high number for trial-averaged, z-scored neural data without smoothing).
  • Input Dimensionality: The models required 3D input subspaces to accurately represent sensory information, finding that inputs span "curved manifolds" rather than simple straight lines.
  • Attentional Gain: In the input-modulation model, the "irrelevant" input only needed to be reduced by 22–38% to explain the behavior. This aligns well with observed attentional effects in earlier sensory areas like MT or V4.
  • RNN Comparison: The LDS fits revealed that standard trained RNNs actually lack the two-phase integration and multi-dimensional input structures found in real biological data.

Limitations and Future Work

The primary limitation is the model degeneracy: the authors cannot definitively say whether the PFC changes its internal recurrence or its input gating. They suggest that future experiments involving direct perturbations (like optogenetic stimulation) during the different phases of integration will be necessary to "break" this tie.

Additionally, the study focused on a 750ms window of stimulus presentation. Future work could extend this to the delay and response periods to see how these linear approximations hold up over longer, more varied behavioral epochs.

Summary updated

BibTeX
@inproceedings{soldadomagraner2024inferring,
  author = {Joana Soldado-Magraner and Valerio Mante and Maneesh Sahani},
  title = {{Inferring context-dependent computations through linear approximations of prefrontal cortex dynamics}},
  booktitle = {Science},
  year = {2024},
  doi = {10.1126/sciadv.adl4743},
}
Figure