Data availability
Code availability
References
Gordon, J. et al. The road towards understanding embodied decisions. Neurosci. Biobehav. Rev. 131, 722–736 (2021).
Article PubMed PubMed Central Google Scholar
Maselli, A. et al. Beyond simple laboratory studies: developing sophisticated models to study rich behavior. Phys. Life Rev. 46, 220–244 (2023).
Article ADS PubMed Google Scholar
Yoo, S. B. M., Hayden, B. Y. & Pearson, J. M. Continuous decisions. Philos. Trans. R. Soc. B 376, 20190664 (2021).
Article Google Scholar
Merel, J., Botvinick, M. & Wayne, G. Hierarchical motor control in mammals and machines. Nat. Commun. 10, 5489 (2019).
Article ADS PubMed PubMed Central Google Scholar
Cisek, P. Making decisions through a distributed consensus. Curr. Opin. Neurobiol. 22, 927–936 (2012).
Article CAS PubMed Google Scholar
Gallivan, J. P., Chapman, C. S., Wolpert, D. M. & Flanagan, J. R. Decision-making in sensorimotor control. Nat. Rev. Neurosci. 19, 519–534 (2018).
Article CAS PubMed PubMed Central Google Scholar
Yoo, S. B. M., Tu, J. C., Piantadosi, S. T. & Hayden, B. Y. The neural basis of predictive pursuit. Nat. Neurosci. 23, 252–259 (2020).
Article CAS PubMed PubMed Central Google Scholar
Fabian, S. T., Sumner, M. E., Wardill, T. J., Rossoni, S. & Gonzalez-Bellido, P. T. Interception by two predatory fly species is explained by a proportional navigation feedback controller. J. R. Soc. Interface. 15, 20180466 (2018).
Article PubMed PubMed Central Google Scholar
Sridhar, V. H. et al. The geometry of decision-making in individuals and collectives. Proc. Natl Acad. Sci. USA 118, e2102157118 (2021).
Article CAS PubMed PubMed Central Google Scholar
Yang, Q. et al. Monkey plays Pac-Man with compositional strategies and hierarchical decision-making. eLife 11, e74500 (2022).
Article CAS PubMed PubMed Central Google Scholar
Bertsekas, D. P. in Encyclopedia of Optimization (eds Pardalos, P. M. & Prokopyev, O. A.) 1–6 (Springer, 2025).
Sutton, R. S. & Barto, A. G. Reinforcement Learning: An Introduction (MIT Press, 1998).
Theodorou, E. A., Buchli, J. & Schaal, S. A generalized path integral control approach to reinforcement learning. J. Mach. Learn. Res. 11, 3137–3181 (2010).
MathSciNet Google Scholar
Dvijotham, K. & Todorov, E. in Reinforcement Learning and Approximate Dynamic Programming for Feedback Control (eds Lewis. F. L. & Liu, D.) 119–141 (Wiley, 2012).
Wolpert, D. M. & Kawato, M. Multiple paired forward and inverse models for motor control. Neural Netw. 11, 1317–1329 (1998).
Article CAS PubMed Google Scholar
Lake, B. & Baroni, M. Generalization without systematicity: on the compositional skills of sequence-to-sequence recurrent networks. In Proc. 35th International Conference on Machine Learning (eds. Dy, J. & Krause, A.) 2873–2882 (PMLR, 2018).
Todorov, E. Compositionality of optimal control laws. In Advances in Neural Information Processing Systems 22 (eds Bengio, Y. et al.) (NeurIPS, 2009).
Kurth-Nelson, Z. et al. Replay and compositional computation. Neuron 111, 454–469 (2023).
Article CAS PubMed Google Scholar
Whittington, J. C. R., McCaffary, D., Bakermans, J. J. W. & Behrens, T. E. J. How to build a cognitive map. Nat. Neurosci. 25, 1257–1272 (2022).
Article CAS PubMed Google Scholar
Eichenbaum, H. & Cohen, N. J. Can we reconcile the declarative memory and spatial navigation views on hippocampal function? Neuron 83, 764–770 (2014).
Article CAS PubMed PubMed Central Google Scholar
Behrens, T. E. J. et al. What is a cognitive map? Organizing knowledge for flexible behavior. Neuron 100, 490–509 (2018).
Article CAS PubMed Google Scholar
Kay, K. et al. Constant sub-second cycling between representations of possible futures in the hippocampus. Cell 180, 552–567.e25 (2020).
Article CAS PubMed PubMed Central Google Scholar
Park, S. A., Miller, D. S., Nili, H., Ranganath, C. & Boorman, E. D. Map making: constructing, combining, and inferring on abstract cognitive maps. Neuron 107, 1226–1238.e8 (2020).
Article CAS PubMed PubMed Central Google Scholar
Sanders, H., Wilson, M. A. & Gershman, S. J. Hippocampal remapping as hidden state inference. eLife 9, e51140 (2020).
Article PubMed PubMed Central Google Scholar
Rushworth, M. F. S., Noonan, M. P., Boorman, E. D., Walton, M. E. & Behrens, T. E. Frontal cortex and reward-guided learning and decision-making. Neuron 70, 1054–1069 (2011).
Article CAS PubMed Google Scholar
Wikenheiser, A. M. & Schoenbaum, G. Over the river, through the woods: cognitive maps in the hippocampus and orbitofrontal cortex. Nat. Rev. Neurosci. 17, 513–523 (2016).
Article CAS PubMed PubMed Central Google Scholar
Yeung, N. & Summerfield, C. Metacognition in human decision-making: confidence and error monitoring. Philos. Trans. R. Soc. B 367, 1310–1321 (2012).
Article Google Scholar
Eppinger, B., Goschke, T. & Musslick, S. Meta-control: From psychology to computational neuroscience. Cogn. Affect. Behav. Neurosci. 21, 447–452 (2021).
Article PubMed Google Scholar
Musslick, S., Cohen, J. D. & Goschke, T. in Encyclopedia of the Human Brain (ed. Grafman, J. H.) 269–285 (Elsevier, 2025).
Alexander, W. H. & Brown, J. W. Medial prefrontal cortex as an action-outcome predictor. Nat. Neurosci. 14, 1338–1344 (2011).
Article CAS PubMed PubMed Central Google Scholar
Kennerley, S. W., Walton, M. E., Behrens, T. E. J., Buckley, M. J. & Rushworth, M. F. S. Optimal decision making and the anterior cingulate cortex. Nat. Neurosci. 9, 940–947 (2006).
Article CAS PubMed Google Scholar
Kolling, N., Behrens, T., Wittmann, M. & Rushworth, M. Multiple signals in anterior cingulate cortex. Curr. Opin. Neurobiol. 37, 36–43 (2016).
Article CAS PubMed PubMed Central Google Scholar
Shenhav, A., Botvinick, M. M. & Cohen, J. D. The expected value of control: an integrative theory of anterior cingulate cortex function. Neuron 79, 217–240 (2013).
Article CAS PubMed PubMed Central Google Scholar
Akam, T. et al. The anterior cingulate cortex predicts future states to mediate model-based action selection. Neuron 109, 149–163.e7 (2021).
Article CAS PubMed Google Scholar
Heilbronner, S. R. & Hayden, B. Y. Dorsal anterior cingulate cortex: a bottom-up view. Annu. Rev. Neurosci. 39, 149–170 (2016).
Article CAS PubMed PubMed Central Google Scholar
Sarafyazd, M. & Jazayeri, M. Hierarchical reasoning by neural circuits in the frontal cortex. Science 364, eaav8911 (2019).
Article CAS PubMed Google Scholar
Padoa-Schioppa, C. Neurobiology of economic choice: a good-based model. Annu. Rev. Neurosci. 34, 333–359 (2011).
Article CAS PubMed PubMed Central Google Scholar
Hunt, L. T. et al. Triple dissociation of attention and decision computations across prefrontal cortex. Nat. Neurosci. 21, 1471–1481 (2018).
Article CAS PubMed PubMed Central Google Scholar
Wilson, R. C., Takahashi, Y. K., Schoenbaum, G. & Niv, Y. Orbitofrontal cortex as a cognitive map of task space. Neuron 81, 267–279 (2014).
Article CAS PubMed PubMed Central Google Scholar
Elston, T. W. & Wallis, J. D. Context-dependent decision-making in the primate hippocampal–prefrontal circuit. Nat. Neurosci. 28, 374–382 (2025).
Article CAS PubMed PubMed Central Google Scholar
Yoo, S. B. M., Tu, J. C. & Hayden, B. Y. Multicentric tracking of multiple agents by anterior cingulate cortex during pursuit and evasion. Nat. Commun. 12, 1985 (2021).
Article ADS CAS PubMed PubMed Central Google Scholar
Wilson, R. C. & Collins, A. G. E. Ten simple rules for the computational modeling of behavioral data. eLife 8, e49547 (2019).
Article PubMed PubMed Central Google Scholar
Khona, M. & Fiete, I. R. Attractor and integrator networks in the brain. Nat. Rev. Neurosci. 23, 744–766 (2022).
Article CAS PubMed Google Scholar
Hayden, B. Y., Pearson, J. M. & Platt, M. L. Neuronal basis of sequential foraging decisions in a patchy environment. Nat. Neurosci. 14, 933–939 (2011).
Article CAS PubMed PubMed Central Google Scholar
Anderson, D. J. & Perona, P. Toward a science of computational ethology. Neuron 84, 18–31 (2014).
Article CAS PubMed Google Scholar
Brown, A. E. X. & de Bivort, B. Ethology as a physical science. Nat. Phys. 14, 653–657 (2018).
Article CAS Google Scholar
Milner, D. & Goodale, M. The Visual Brain in Action (Oxford Univ. Press, 2006).
Gershman, S. J. & Niv, Y. Learning latent structure: carving nature at its joints. Curr. Opin. Neurobiol. 20, 251–256 (2010).
Article CAS PubMed PubMed Central Google Scholar
Zutshi, I. et al. Hippocampal neuronal activity is aligned with action plans. Nature 639, 153–161 (2025).
Article ADS CAS PubMed Google Scholar
Shadmehr, R. & Krakauer, J. W. A computational neuroanatomy for motor control. Exp. Brain Res. 185, 359–381 (2008).
Article PubMed PubMed Central Google Scholar
Bakkour, A. et al. The hippocampus supports deliberation during value-based decisions. eLife 8, e46080 (2019).
Article PubMed PubMed Central Google Scholar
Stachenfeld, K. L., Botvinick, M. M. & Gershman, S. J. The hippocampus as a predictive map. Nat. Neurosci. 20, 1643–1653 (2017).
Article CAS PubMed Google Scholar
Vikbladh, O. M. et al. Hippocampal contributions to model-based planning and spatial memory. Neuron 102, 683–693.e4 (2019).
Article CAS PubMed PubMed Central Google Scholar
Edelson, M. G. & Hare, T. A. Goal-dependent hippocampal representations facilitate self-control. J. Neurosci. 43, 7822–7830 (2023).
Article CAS PubMed PubMed Central Google Scholar
Cohen, J. D., Botvinick, M. & Carter, C. S. Anterior cingulate and prefrontal cortex: who’s in control?. Nat. Neurosci. 3, 421–423 (2000).
Article CAS PubMed Google Scholar
Verguts, T. Binding by random bursts: a computational model of cognitive control. J. Cogn. Neurosci. 29, 1103–1118 (2017).
Article PubMed Google Scholar
Silvetti, M., Vassena, E., Abrahamse, E. & Verguts, T. Dorsal anterior cingulate-brainstem ensemble as a reinforcement meta-learner. PLoS Comput. Biol. 14, e1006370 (2018).
Article ADS PubMed PubMed Central Google Scholar
Friedman, A. et al. A corticostriatal path targeting striosomes controls decision-making under conflict. Cell 161, 1320–1333 (2015).
Article CAS PubMed PubMed Central Google Scholar
Kane, G. A. et al. Rat anterior cingulate cortex continuously signals decision variables in a patch foraging task. J. Neurosci. 42, 5730–5744 (2022).
Article CAS PubMed PubMed Central Google Scholar
Botvinick, M. M., Niv, Y. & Barto, A. G. Hierarchically organized behavior and its neural foundations: A reinforcement learning perspective. Cognition 113, 262–280 (2009).
Article PubMed Google Scholar
Franch, M. et al. A population code for semantics in human hippocampus. Preprint at bioRxiv https://doi.org/10.1101/2025.02.21.639601 (2025).
Chaure, F. J., Rey, H. G. & Quian Quiroga, R. A novel and fully automatic spike-sorting implementation with variable number of features. J. Neurophysiol. 120, 1859–1871 (2018).
Article CAS PubMed PubMed Central Google Scholar
Groppe, D. M. et al. iELVis: An open source MATLAB toolbox for localizing and visualizing human intracranial electrode data. J. Neurosci. Methods 281, 40–48 (2017).
Article CAS PubMed Google Scholar
Jenkinson, M. & Smith, S. A global optimisation method for robust affine registration of brain images. Med. Image Anal. 5, 143–156 (2001).
Article CAS PubMed Google Scholar
Jenkinson, M., Bannister, P., Brady, M. & Smith, S. Improved optimization for the robust and accurate linear registration and motion correction of brain images. Neuroimage 17, 825–841 (2002).
Article PubMed Google Scholar
Joshi, A. et al. Unified framework for development, deployment and robust testing of neuroimaging algorithms. Neuroinformatics 9, 69–84 (2011).
Article PubMed PubMed Central Google Scholar
Dale, A. M., Fischl, B. & Sereno, M. I. Cortical surface-based analysis. Neuroimage 9, 179–194 (1999).
Article CAS PubMed Google Scholar
Yang, A. I. et al. Localization of dense intracranial electrode arrays using magnetic resonance imaging. Neuroimage 63, 157–165 (2012).
Article PubMed PubMed Central Google Scholar
Magnotti, J. F., Wang, Z. & Beauchamp, M. S. RAVE: Comprehensive open-source software for reproducible analysis and visualization of intracranial EEG data. Neuroimage 223, 117341 (2020).
Article PubMed PubMed Central Google Scholar
Wang, Z., Magnotti, J. F., Zhang, X. & Beauchamp, M. S. YAEL: your advanced electrode localizer. eNeuro 10, ENEURO.0328-23.2023 (2023).
Article PubMed PubMed Central Google Scholar
Chericoni, A. et al. Neural geometry in the human hippocampus enables generalization across spatial position and gaze. Preprint at arXiv https://doi.org/10.48550/arXiv.2603.04747 (2026).
Gómez, V., Kappen, H. J., Peters, J. & Neumann, G. in Machine Learning and Knowledge Discovery in Databases (eds Calders, T. et al.) 482–497 (2014).
Peng, X. Bin, Chang, M., Zhang, G., Abbeel, P. & Levine, S. MCP: learning composable hierarchical control with multiplicative compositional policies. In Advances in Neural Information Processing Systems 32 (eds Wallach, H. et al.) (NeurIPS, 2019).
Matsuo, Y. et al. Deep learning, reinforcement learning, and world models. Neural Netw. 152, 267–275 (2022).
Article ADS PubMed Google Scholar
Murphy, K. P. Probabilistic Machine Learning: An Introduction (The MIT Press, 2022).
Wood, S. N. Generalized additive models. Annu. Rev. Stat. Appl. 12, 497–526 (2025).
Article MathSciNet Google Scholar
Seabold, S. & Perktold, J. Statsmodels: econometric and statistical modeling with Python. In Proc. 9th Python in Science Conference (SciPy 2010) https://doi.org/10.25080/Majora-92bf1922-011 (SciPy, 2010).
Balzani, E., Lakshminarasimhan, K., Angelaki, D. & Savin, C. Efficient estimation of neural tuning during naturalistic behavior. In Advances in Neural Information Processing Systems 33 (eds. Larochelle, H. et al.) (NeurIPS, 2020).
Wood, S. N. Generalized Additive Models: An Introduction with R (CRC Press/Taylor & Francis Group, 2017).
Gelman, A., Hwang, J. & Vehtari, A. Understanding predictive information criteria for Bayesian models. Stat. Comput. 24, 997–1016 (2014).
Article MathSciNet Google Scholar
Kriegeskorte, N. & Wei, X.-X. Neural tuning and representational geometry. Nat. Rev. Neurosci. 22, 703–718 (2021).
Article CAS PubMed Google Scholar
Kobak, D. et al. Demixed principal component analysis of neural population data. eLife 5, e10989 (2016).
Article PubMed PubMed Central Google Scholar
Chericoni, A. Dataset for: Neural basis of compositional control. Figshare https://doi.org/10.6084/m9.figshare.32572764.v3 (2026).
Download references
Acknowledgements
We thank P. Schrater, X. Pitkow, J. Pearson, S. Linderman, H. Ritz and A. Shenhav for invaluable discussions and insights on solving the controller problems; J. Johnston for discussion on neural analysis; J. Adkinson, R. Mathura and V. Pirtle for invaluable assistance; and A. Thome for early and visionary efforts in developing this task and core questions.
Funding
This project was supported by NIH grants R01 DA038615, R01 MH125377, U01 NS121472, and R01 MH129439, and by the McNair foundation.
Ethics declarations
Competing interests
S.A.S. is a consultant for Boston Scientific, Abbott, Koh Young, Neuropace, Zimmer Biomet and co-founder of Motif Neurotech. The other authors declare no competing interests.
Peer review
Peer review information
Nature thanks Sebastian Musslick and the other, anonymous, reviewers for their contribution to the peer review of this work. Peer reviewer reports are available.
Additional information
Publisher’s note Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Extended data figures and tables
Extended Data Fig. 1 Model recovery of wt value and time at switch point (wt = 0.5, t = 0 ms).
(A). Empirical simulation regime (n = 30 simulations × 30 trials × 2 prey-controllers): distribution of recovered wt values at the true switch point (wt = 0.5), quantifying bias in switch magnitude recovery across controller models. Red line indicates the median recovered value; dashed lines indicate the central 95% interval of the recovered distribution. (B). Distribution of temporal lag between recovered and true switch times for wt = 0.5, quantifying timing accuracy of switch detection across controller models. Red line indicates the median lag; dashed lines indicate the 95% CI. (C–D). Same as (A–B), but for the random 1-5 simulation regime. (E–F). Same as (A–B), but for the random 1-40 simulation regime.
Extended Data Fig. 2 Model recovery of controller gains across controller classes.
(A). Empirical simulation regime (n = 30 simulations × 30 trials × 2 prey-controllers): scatter plot showing the relationship between the simulated gains and the gains recovered from the model. Each point represents one recovered gain form a simulated trial. Each column represents a controller class. (B). Same as panel A, but for the random 1-5 simulation regime. (C). Same as panel A, but for the random 1-40 simulation regime.
Extended Data Fig. 3 Relationship between recovered controller gains and recovered wt trajectories across controller classes.
(A). Empirical simulation regime (30 simulations × 30 trials × 2 prey-specific controllers): scatter plots showing the relationship between recovered controller gains and recovered wt trajectories at the start, middle, and end of the trial. Each point represents one recovered gain estimate from one prey-specific policy in a simulated trial. Each column represents a controller class. Pearson’s correlation coefficient (r) is shown for each trial epoch. (B). Same as panel A, but for the random 1-5 simulation regime. (C). Same as panel A, but for the random 1-40 simulation regime.
Extended Data Fig. 4 Pairwise relationships between recovered controller gains across controller classes.
(A). Empirical simulation regime (30 simulations × 30 trials × 2 prey-specific controllers): scatter plots showing pairwise relationships between recovered controller gains across controller classes. Each point represents one recovered gain estimate from a simulated trial. Pearson’s correlation coefficient (r) is shown for each gain pair. (B). Same as panel A, but for the random 1-5 simulation regime. (C). Same as panel A, but for the random 1-40 simulation regime.
Extended Data Fig. 5 Model recovery of controller class and blending parameter wt.
We simulated ground-truth trajectories using known controller class (p) and known wt profiles, considering five types of wt. Simulations were generated by sampling 20 trials across sessions, with trial durations matched to the empirical distribution (approximately 0.91, 1.45, 2.83, and 4.1 s). To fix model complexity, simulations were fit using a fixed number of basis functions, rather than the model-averaging procedure used in the main text. (A). Posterior probability of recovering the true generative controller model relative to a baseline position-only controller. Across all controller classes, the true generative model was recovered above baseline (all probabilities > 0.5). Controller classes are defined in Extended Data Table 3. (B). Correlation between true and predicted position trajectories for each generative controller class, averaged across simulated trials, showing good recovery across classes (mean r = 0.83). (C–H). Example simulations showing recovery of the ground-truth blending parameter wt for each controller class. Blue lines indicate true wt, orange lines indicate recovered wt. Left panels (scaling = 1) show low-complexity trajectories, and right panels (scaling = 5) show higher-complexity trajectories. Complexity was controlled by the scale parameter of the Gaussian process used to generate wt. Across models, the mean recovery of wt was r = 0.87.
Extended Data Fig. 6 Full model recovery confusion matrix.
To assess overall model identifiability, we performed a full confusion analysis across three simulation regimes. For each generative model corresponding to a controller class (Extended Data Table 3), we simulated datasets with known parameters (30 datasets with 30 trials each), fit all candidate models to each dataset, and selected the best-fitting model using the evidence lower bound (ELBO). (A–C). Confusion matrices quantifying how reliably each generative controller class could be distinguished from the others under the (A). empirical simulation regime, (B). random 1-5, and (C). random 1-40 simulation regimes. Recoverability was significantly above chance for controller classes p, pv and pvi (binomial test, all p < 0.0001), whereas the remaining classes showed weaker identifiability. The pv model, which provided the best fit to participant behavior, was significantly recovered (43% correct; 95% CI [0.40, 0.47], p < 0.0001), but was frequently confounded with pvi and pvf. This overlap likely reflects the nested structure of the controller classes, indicating that interpretation of fitted model identities should account for partial non-identifiability between related controller families.
Extended Data Fig. 7 Behavioral predictors of target switching and average controller dynamics.
(A). Target switch GLM restricted to sEEG subjects (n = 19), showing the contribution of behavioral predictors at two time windows before the switch onset. Left: predictors computed as the mean value within the 100 ms preceding switch onset (−100 to 0 ms). Right: predictors computed as the mean value from an earlier window preceding switch onset (−400 to −300ms). Bars indicate the mean posterior effect size (percent change), and error bars indicate the 95% credible interval, as in Fig. 2h. Asterisks indicate predictors whose 95% credible interval excluded zero. (C). Averaged wt trajectory across all the participants (n = 69).
Full size table
Full size table
Full size table
Supplementary information
Rights and permissions
Springer Nature or its licensor (e.g. a society or other partner) holds exclusive rights to this article under a publishing agreement with the author(s) or other rightsholder(s); author self-archiving of the accepted manuscript version of this article is solely governed by the terms of such publishing agreement and applicable law.
Reprints and permissions
About this article
Cite this article
Chericoni, A., Fine, J.M., Ismail, T.S. et al. Neural basis of compositional control. Nature (2026). https://doi.org/10.1038/s41586-026-10896-8
Download citation
Received:
Accepted:
Published:
Version of record:
DOI: https://doi.org/10.1038/s41586-026-10896-8