Summary: New research reveals that the brain’s flexibility comes from its ability to reuse “cognitive building blocks” across many tasks, allowing rapid adaptation with minimal relearning. By studying monkeys performing a set of related categorization tasks, researchers found that the prefrontal cortex combines and recombines shared neural patterns like components in a modular system.
These blocks are activated or silenced depending on the demands of the task, helping the brain switch strategies and efficiently build new behaviors. The findings explain how humans learn so quickly and may offer insights for improving artificial intelligence and treating disorders that impair cognitive flexibility.
Key Facts:
- Reusable Neural Patterns: The prefrontal cortex employs shared neural “blocks” across different tasks to build new behaviors.
- Compositional Flexibility: The brain combines blocks for color, shape, and action in task-specific ways, supporting rapid learning.
- AI & Clinical Potential: Understanding these blocks may help reduce catastrophic forgetting in AI and guide therapies for disorders that impair strategy-shifting.
Source: Princeton University
Artificial intelligence may write award-winning essays and diagnose disease with remarkable accuracy, but biological brains still hold the upper hand in at least one crucial domain: flexibility.
Humans, for example, can quickly adapt to new information and unfamiliar challenges with relative ease — learning new computer software, following a recipe, or picking up a new game — while AI systems struggle to learn ‘on the fly’.
In a new study, Princeton neuroscientists uncover one reason for the brain’s advantage over AI: it reuses the same cognitive “blocks” across many different tasks. By combining and recombining these blocks, the brain can rapidly assemble new behaviors.
“State-of-the-art AI models can reach human, or even super-human, performance on individual tasks. But they struggle to learn and perform many different tasks,” said Tim Buschman, Ph.D., senior author of the study and associate director of the Princeton Neuroscience Institute.
“We found that the brain is flexible because it can reuse components of cognition in many different tasks. By snapping together these ‘cognitive Legos,’ the brain is able to build new tasks.”
The findings were published on November 26 in the journal Nature.
Reusing skills for new challenges
If someone knows how to tune up a bicycle, then fixing a motorcycle might come more naturally. This ability to learn something new by repurposing simpler skills from related tasks is what scientists call compositionality.
“If you already know how to bake bread, you can use this ability to bake a cake without relearning how to bake from scratch,” said Sina Tafazoli, Ph.D., a postdoctoral researcher in the Buschman lab at Princeton and lead author of the new study. “You repurpose existing skills — using an oven, measuring ingredients, kneading dough — and combine them with new ones, like whipping batter and making frosting, to create something entirely different.”
Evidence for how the brain achieves such cognitive flexibility has been limited and sometimes contradictory, though.
To clarify how the brain achieves its resourcefulness, Tafazoli trained two male rhesus macaques to perform three related tasks while their brain activity was monitored.
Rather than baking bread or fixing bikes, the monkeys performed three categorization tasks. Much like trying to decode the often ambiguous penmanship of a handwritten doctor’s note, the monkeys had to judge whether a colorful, balloon-like blob on a screen in front of them looked more like a bunny or the letter “T” (categorizing the shape) or if it was more red or green (categorizing color).
The task was deceptively difficult: the blobs varied in ambiguity, sometimes obviously resembling a bunny or saturated red, while other times the distinctions were subtle.
To indicate what shape or color they believed the blob to be, a monkey buzzed in their response by looking in one of the four different directions. In one task, glancing to the left meant the animal saw a bunny, whereas a glance to the right indicated it looked more like a “T”.
A key feature of the design was that while every task was unique, they also shared certain elements with the other tasks.
One of the color tasks and the shape task both required looking in the same directions, whereas both color tasks required the animal to categorize the color in the same way (as either more red or more green) but required them to look in different directions to declare in their hue judgement.
This experimental design gave the researchers a way to test whether the brain reused neural patterns — its cognitive building blocks — across tasks with shared components.
Blocks build cognitive flexibility
After analyzing activity patterns across the brain, Tafazoli and Buschman found that the prefrontal cortex — a region at the front of the brain involved in higher cognition — contained several common, reusable patterns of activity across neurons working toward a common goal, such as color discrimination.
Buschman described these as the brain’s “cognitive Legos” — building blocks that can be flexibly combined to create new behaviors.
“I think about a cognitive block like a function in a computer program,” Buschman said. “One set of neurons might discriminate color, and its output can be mapped onto another function that drives an action. That organization allows the brain to perform a task by sequentially performing each component of that task.”
To perform one of the color tasks, the animal would snap together a block that calculated the color of the image with another block that moved the eyes in different directions. When switching tasks, such as going from colors to shapes, the brain simply snapped together the relevant blocks for calculating shape and making the same eye movements.
This block sharing was largely seen in the prefrontal cortex, and not other brain regions, suggesting that this kind of compositionality is a special property of that area.
Tafazoli and Buschman also found that the prefrontal cortex quiets cognitive blocks when they are not in use, likely to help the brain better focus on the relevant task at hand.
“The brain has a limited capacity for cognitive control,” Tafazoli said. “You have to compress some of your abilities so that you can focus on those that are currently important. Focusing on shape categorization, for example, momentarily diminishes the ability to encode color because the goal is shape discrimination, not color.”
A more efficient way to learn — for AI and for the clinic
These cognitive Legos may help explain why humans learn new tasks so quickly. By drawing on existing mental components, the brain minimizes redundant learning – a trick AI systems have yet to master.
“A major issue with machine learning is catastrophic interference,” Tafazoli said. “When a machine or a neural network learns something new, they forget and overwrite previous memories. If an artificial neural network knows how to bake a cake but then learns to bake cookies, it will forget how to bake a cake.”
In the future, incorporating compositionality into AI could help create systems that continually learn new skills without forgetting old ones.
The same insight may also help improve medicine for people with neurological and psychiatric disorders. Conditions such as schizophrenia, obsessive-compulsive disorder, and certain brain injuries often impair a person’s ability to apply known skills to new contexts —possibly stemming from disruptions in how the brain recombines its cognitive building blocks.
“Imagine being able to help people regain the ability to shift strategies, learn new routines, or adapt to change,” Tafazoli said. “In the long run, understanding how the brain reuses and recombines knowledge could help us design therapies that restore that process.”
Funding: Funding for the study was provided by the National Institutes of Health (R01MH129492, 5T32MH065214).
Key Questions Answered:
A: The brain reuses core cognitive building blocks across many tasks, allowing rapid adaptation.
A: In the prefrontal cortex, which assembles and quiets blocks depending on the task.
A: Because combining and recombining cognitive components enables quick learning without overwriting older skills.
Editorial Notes:
- This article was edited by a Neuroscience News editor.
- Journal paper reviewed in full.
- Additional context added by our staff.
About this cognition and neuroscience research news
Author: Daniel Vahaba
Source: Princeton University
Contact: Daniel Vahaba – Princeton University
Image: The image is credited to Neuroscience News
Original Research: Open access.
“Building compositional tasks with shared neural subspaces” by Tim Buschman et al. Nature
Abstract
Building compositional tasks with shared neural subspaces
Cognition is highly flexible—we perform many different tasks and continually adapt our behaviour to changing demands.
Artificial neural networks trained to perform multiple tasks will reuse representations and computational components across tasks. By composing tasks from these subcomponents, an agent can flexibly switch between tasks and rapidly learn new tasks. Yet, whether such compositionality is found in the brain is unclear.
Here we show the same subspaces of neural activity represent task-relevant information across multiple tasks, with each task flexibly engaging these subspaces in a task-specific manner.
We trained monkeys to switch between three compositionally related tasks. In neural recordings, we found that task-relevant information about stimulus features and motor actions were represented in subspaces of neural activity that were shared across tasks.
When monkeys performed a task, neural representations in the relevant shared sensory subspace were transformed to the relevant shared motor subspace. Monkeys adapted to changes in the task by iteratively updating their internal belief about the current task and then, based on this belief, flexibly engaging the shared sensory and motor subspaces relevant to the task.
In summary, our findings suggest that the brain can flexibly perform multiple tasks by compositionally combining task-relevant neural representations.

