Deficient executive control in transformer attention Authors: Suketu Chandrakant Patel, Hongbin Wang, Jin Fan, Derek Abbott Published: 2026 ABSTRACT AbstractAlthough transformers in large language models (LLMs) effectively implement a self-attention mechanism that has revolutionized natural language processing, they lack an explicit architecture for the executive control of attention found in humans, which is essential for resolving conflicts and selecting relevant information in the presence of competing computations and is critical for adaptive behavior. To investigate the impact of this limitation in LLMs, we employed the classic color Stroop task, widely regarded as the gold standard, to test the executive control of attention in these models. Our results revealed a typical conflict effect of underperformance in terms of accuracy in the incongruent condition (e.g. naming the color of the word RED in blue) compared with the congruent condition (e.g. naming the color of the word RED in red), in short word lists, similar to human performance. However, as the length of the word lists increased, performance on the incongruent condition degraded toward near-total performance collapse, even as accuracy in the congruent condition remained excellent, and word reading (e.g. reading the word RED [in red] or RED [in blue], ignoring the color) was near-perfect. These findings demonstrate that transformer attention mechanisms are fundamentally limited in their capacity for conflict resolution across extended contexts, and a failure to up-regulate control adaptively under rising interference. We suggest that incorporating executive control mechanisms akin to those in biological attention is crucial for achieving artificial general intelligence.Keywords: transformer, large language model (LLM), attention, executive control, color Stroop task While transformer-based large language models (LLMs) have achieved remarkable advances by implementing attentional mechanisms, it remains unclear whether these artificial systems capture the core mechanism of executive control of attention. Employing the classic color Stroop task, we demonstrated that state-of-the-art LLMs exhibit dramatic performance degradation in naming the color of a word under the incongruent condition (e.g. word RED in blue) as word list length increases. This study reveals a critical deficiency in conflict resolution within transformer attention architectures, potentially constraining AI's capacity to develop adaptive behavior. Introduction The introduction of the transformer model in their paper “Attention is All You Need” (1) marked a pivotal turning point in the accelerating progress of machine learning (ML) and AI. Generalizing the mechanism that allowed neural translation models to selectively weight relevant input positions (2), the transformer, which relies on an attention mechanism rather than recurrent or convolutional layers to uncover essential spatiotemporal structures in input data, has become the foundation for state-of-the-art natural language processing (NLP) models. Since then, the transformer attention mechanism has been applied to various multimodal and large language models (LLMs) in tasks beyond NLP, including computer vision, speech recognition, and even video generation (3, 4). The revolutionary success of transformer-based LLMs naturally invites a critical question regarding the role of attention in ML and AI, including its nature, boundaries, and limitations. In particular, how transformer-based machine attention differs from human attention, a fundamental concept in psychology that has been actively studied, remains elusive. More than a century ago, William James famously stated that “Everyone knows what attention is. It is the taking possession by the mind, in clear and vivid form, of one out of what seem several simultaneously possible objects or trains of thought” (5). Despite this assertion, there is ongoing debate about how little we know of attention (6–8). Attention's explanatory power stems from its ability to serve as a universal explanation for understanding value, selection, and human agency (9). Modern neuroscience views attention not as a single straightforward mechanism but as a complex mental faculty supported by multiple neural networks. According to the attention network theory (ANT), there are three distinct attentional functions of alerting, orienting, and executive control, each of which is supported by a distinct and interactive neural network (10–13). The three networks are functionally integrated and interact to selectively focus cognitive resources on specific stimuli, tasks, or information while filtering out irrelevant inputs. The alerting network achieves and maintains an alert state, with brain areas such as the locus coeruleus involved. The orienting network selects specific information from sensory input, directing attention to a particular stimulus or location, with key areas including the thalamus and the superior colliculus, frontal eye fields, and parietal lobe for visual input. The executive control network is engaged in tasks requiring control over thoughts and actions amid competing information and is essential for adaptive behavior, recruiting regions of the frontoparietal network, including the anterior cingulate cortex (ACC), the anterior insular cortex, and the dorsolateral prefrontal cortex (DLPFC) (14, 15). Behavioral and functional neuroimaging studies have demonstrated that these three networks function both independently and interactively (10, 11, 16, 17). The ANT was also computationally validated through connectionist modeling (18). Modern neural network–based AI systems efficiently process large amounts of spatially or temporally distributed input information to make decisions, such as image classification or next-word prediction. The cross-modal attention architecture typically employs a multihead attention mechanism, with some heads focusing on object–word associations while others attend to spatial relationships or abstract concepts (19, 20). This parallel processing enables the model to capture complex relationships among modalities, much as human perception integrates multiple sensory inputs (21). A key advance of the transformer architecture over traditional ML techniques is its attention mechanism, which prioritizes relevant input tokens by assigning weights based on latent semantic information rather than relying solely on spatial or temporal proximity. This selective weighting parallels the biological orienting function, where attentional resources are dynamically allocated to task-relevant content (22). In multihead self-attention, the softmax normalization establishes competitive selection dynamics in which input elements compete for representational resources, with higher-scoring elements receiving proportionally greater weight while suppressing competitors (see Supplementary Introduction for multimodal LLM architecture). This mechanism resembles the biased competition framework (23) observed in human visual attention, in which neural representations compete for processing resources via mutual inhibition. Both biological and artificial systems implement attention through multiplicative scaling and competitive selection, core mechanisms that have been explicitly mapped between artificial and biological attention, including the orienting function that shifts focus through dynamic reweighting (24). Empirical evidence shows that transformer attention weights correlate strongly with human eye-tracking patterns during natural reading (25), suggesting that both systems may converge on similar solutions for selective information routing during language comprehension. The self-attention mechanism's capacity to model long-range dependencies through parallelizable computation has enabled unprecedented scaling, with empirical studies demonstrating predictable power-law improvements in performance as a function of model, dataset, and compute sizes (26, 27). However, a critical distinction is that human attention comprises not only orienting but also executive control, the capacity to maintain task goals, detect and resolve conflict of computation, and override prepotent responses. The softmax mechanism routes information competitively but lacks an architectural analog for executive control. For transformers, backpropagation distributes gradient signals across millions of parameters without respect to compositional or task-relevant structure, resulting in a fundamental diagnostic limitation. There is no mechanism that evaluates whether current processing remains aligned with an overarching task goal, no conflict signal that triggers compensatory adjustments, and no persistent representation that sustains priority hierarchies across sequential demands. See Supplementary Introduction for rationale and significance of executive control. The Stroop (conflict) effect of the color Stroop task, first documented by John Ridley Stroop in 1935, is a robust psychological phenomenon that demonstrates interference in reaction time and accuracy when there is a mismatch between the physical color of a word and its meaning (28, 29). This interference occurs when individuals must name the color of a word while ignoring its meaning. For example, when participants are asked to name the color of the word “BLUE” printed in red (the incongruent condition), they typically respond more slowly and make more errors than when the word and color match such as “RED” printed in red (the congruent condition), which is called the Stroop or conflict effect. The traditional automaticity explanation (30) posits that the interference results from automatic reading processes that overwhelm controlled color naming and assumes that reading occurs involuntarily, cannot be suppressed, and proceeds independently of task demands (see Supplementary Introduction for challenges to automaticity theory). In the parallel distributed processing (PDP) account of the color Stroop effect (31), “automaticity” is a continuum that emerges through practice while remaining susceptible to top-down modulation; their Stroop model reproduces the graded interference by varying this attentional modulation. In studying biological attention, the conflict effect has been utilized to investigate conflict processing in the human brain (14, 32). Because the Stroop effect varies systematically across conditions and persists even with practice, human performance indicates that it reflects fundamental aspects of executive control of attention. Beyond the conflict effect, the Stroop paradigm also yields a congruency sequence effect, in which performance on a given trial is modulated by the congruency of the preceding trial (33, 34). Specifically, if conflict monitoring and subsequent control implementation are functioning correctly, accuracy on the current incongruent (I) trial should be higher when the previous trial was incongruent (incongruent–incongruent [II] condition) compared with when it was congruent (incongruent–congruent [CI] condition). This prediction follows from the conflict-monitoring account, in which the ACC detects conflict and signals the DLPFC to upregulate the top-down control on subsequent trials (33, 35). Although often interpreted through this top-down lens, congruency sequence effects likely reflect multiple underlying mechanisms, including conflict adaptation, feature integration, contingency learning, and repetition expectancy, with both attentional adjustment and bottom-up associative learning contributing to the observed pattern (34, 36, 37). In the present study, we examined the Stroop effect in OpenAI's GPT (Generative Pre-trained Transformer)-4o and Anthropic's Claude 3.5 Sonnet. In addition, we examined the congruency sequence effect (see Supplementary Introduction for context and Gratton effect). If transformer attention is limited to orienting, then tasks that require executive control should reveal systematic deficits in transformers even when basic attentional selection is intact (see Supplementary Introduction for rationale and significance of executive control). We predicted that multimodal transformer-based LLMs would show behavioral deficits on the task, thereby highlighting potential limitations of transformer-based models in the executive control of attention. Specifically, we predicted an amplified congruency effect, expressed as a congruency-by-list-length interaction. As the sequence lengthens, errors should increase more on incongruent than on congruent trials, yielding a widening incongruent–congruent gap indicative of reduced conflict resolution and goal maintenance under sustained task demands. Additionally, we expected to observe no adaptation effect because transformer attention lacks executive control for adaptation. Results Color-naming task results The observed performance patterns under the short list length conditions (e.g. five words, Fig. 1a and c) closely resemble those seen in human results (29). Like humans, both LLMs showed relatively high accuracy on the word-reading task and performed worse in the incongruent condition than in the congruent and neutral conditions for the color-naming task (Fig. 1, Tables S1 and S2). In a previous study (38), with computerized item-by-item or blocked paper assessments, only older adults showed degraded performance on the blocked version, whereas younger adults maintained performance across both versions. This parallel is particularly relevant for evaluating LLMs, which undergo blocked testing at list lengths of 5, 10, 20, and 40 words in addition to item-by-item testing in single-word trials. Unlike humans, who maintain ∼95% accuracy and consistent reaction times across 5-, 10-, and 20-min time blocks (39), and sustain 97% accuracy even in a demanding 60-min color-naming task with a 1,500-word list (40), LLMs showed accuracy that generally declined with increasing list length. One notable exception was Claude 3.5 Sonnet's congruent condition between 10 and 20 words, where accuracy improved from 90 to 99%. This anomaly can be attributed to several trials in the 10-word condition yielding zero correct answers, lowering the mean performance. The most substantial performance degradation occurred between 20 and 40 words across most conditions except in the congruent condition. Performance (accuracy) of GPT-4o and Claude 3.5 Sonnet for all conditions by word list length. a) Color naming and b) word-reading performance of GPT-4o. c) Color naming and d) word-reading performance of Claude 3.5 Sonnet. Both models maintained robust performance for the congruent condition, with GPT-4o and Claude 3.5 Sonnet achieving 99% accuracy at 20 words, declining modestly to 89 and 92%, respectively, at 40 words. The incongruent condition revealed unique model-specific differences in degradation patterns. GPT-4o demonstrated early performance deterioration, with accuracy dropping from 91% at five words to 57% at 10 words, followed by further substantial declines to 22% at 20 words and 15% at 40 words (Fig. 1a). In marked contrast, Claude 3.5 Sonnet maintained relatively stable performance through 20 words (76% accuracy) before experiencing a sharp decline to 24% accuracy at 40 words, a 52% drop in performance (Fig. 1c). The significant degradation pattern of the two LLMs suggests fundamental limitations compared with human attention. In the mixed-trial condition (Fig. 2, Table S3), which had an equal 50/50 split of congruent and incongruent items presented randomly, GPT-4o maintained the color-naming task set only at short list lengths (100% at one word, 99% at five words, and 72% at 10 words). By the 20-word list length, accuracy drifted toward the ∼50% level expected if the model defaulted to word reading rather than ink-color naming (52%), and it fell well below that benchmark at the 40-word lists (41%; Fig. 2a). The separation of the two trial types showed a predictable pattern of accuracy distribution between congruent and incongruent trials. Performance was nearly perfect or high accuracy for congruent trials (e.g. 100% for a one-word list and 81% for a 40-word list), while errors and extremely low accuracy were exclusively observed in incongruent conditions for longer lists (i.e. 10, 20, and 40). Specifically, GPT-4o's performance on incongruent trials showed a marked decline as list length increased, dropping to 46% accuracy with 10-word lists and to just 1% for both 20- and 40-word lists. Remarkably, performance deteriorated to nearly 0% in the incongruent condition. Accuracy errors in the incongruent, mixed, and neutral conditions were predominantly concentrated at later serial positions within longer lists. This pattern diverges from human performance, in which accumulated interference over long task durations does not substantially reduce accuracy (39). This near-total performance collapse suggests a fundamental limitation in GPT-4o's capacity for conflict resolution and response inhibition. Performance (accuracy) for the congruent and incongruent trials in the mixed condition by word list length. a) Color naming and b) word reading of GPT-4o. c) Color naming and d) word reading of Claude 3.5 Sonnet. Claude 3.5 Sonnet's performance pattern also provides strong evidence of the conflict effect as a function of list length (Fig. 2c). In the mixed-trial condition for overall performance, the model showed a progressive decline in accuracy as list length increased, starting at a near-perfect 99% with five-word lists, dropping to 79% with 10-word lists, and remaining relatively stable at 78% with 20-word lists. Performance declined gradually until reaching ∼50% accuracy at the 40-word list length, indicating a complete shift from color naming to pure word reading. This delayed deterioration of the default word-reading response demonstrates more robust conflict-resolution mechanisms than GPT-4o. While Claude 3.5 Sonnet demonstrated better resilience to incongruent conditions, it still showed impaired performance, maintaining 61% accuracy with 10-word lists and 58% with 20-word lists before dropping significantly to 10% accuracy with 40-word lists. Although 3.5 Sonnet's performance declined more slowly, it also exhibited a collapse in executive control that was not observed in neurotypical human trials. In the neutral condition, GPT-4o performed with high accuracy for list lengths of 1, 5, and 10, with a significant drop at 20 (to 75%) and 40 (to 32%; Fig. 1a). The pattern of Claude 3.5 Sonnet is similar (with the notable exception of 73% for a list length of one): dropped to 78% and then to 27% for word list lengths of 20 and 40, respectively (Fig. 1c). In contrast to human performance, the significantly low performance of both LLMs on the longer lists of 20 and 40 neutral words suggests that these models exhibit a capacity limit in goal maintenance, which is typically supported by executive control in humans. The predominant error patterns observed on neutral trials manifested in two distinct ways: response omissions, where LLMs completely skipped responding to some of the neutral words, and misattributed color designations, where LLMs incorrectly assigned colors to neutral stimuli (e.g. identifying the word “PEN” in red as being displayed in blue). While responses occasionally defaulted to neutral words, these instances were rare (see Supplementary Results for error types and distribution across list positions). We included a nonword control condition with nonword strings containing only the character “X” to investigate potential word-specific interference effects. The results (Fig. 1a and c) demonstrated a mixed pattern: GPT-4o and Claude 3.5 Sonnet performed significantly better on color-naming tasks with these nonword stimuli at 40 words. GPT-4o had notably higher accuracy, while Claude 3.5 Sonnet achieved perfect scores across all lengths in color naming. However, GPT-4o's accuracy gradually declined at 10 and 20 words and had another significant accuracy reduction to 58% at 40 words. Notably, these errors were not random but consisted of selecting an incorrect color from the four available options, indicating that the presence of characters actively interfered with color identification. Collectively, these findings indicate that semantic content amplifies interference, with meaningful words producing a more pronounced reduction in accuracy. Word-reading task results Results for the word-reading task demonstrated exceptional performance in both models (99–100% accuracy) across word list lengths from 1 to 20 words (Fig. 1b and d, Table S2), indicating robust word processing capabilities under various conditions. This aligns with human patterns. However, at the 40-word list length, performance patterns revealed subtle but distinct condition and model-specific degradations. In congruent trials, both models maintained strong performance with a slight decrease from 20 to 40 words, with 96% for GPT-4o and 95% for Claude 3.5 Sonnet. Similar modest degradation was observed in mixed trials, with 95% for GPT-4o and 94% for Claude 3.5 Sonnet at 40-word list length. There were notable differences between neutral and incongruent conditions. Claude 3.5 Sonnet showed a decline in performance, decreasing from 100% accuracy with a 20-word list length to 87% in neutral trials and 90% in incongruent trials when tested with a 40-word list. Conversely, GPT-4o's performance remained more stable across conditions, with its most significant decline occurring in the incongruent condition, from 99% at 20 words to 92% at 40 words. The GPT-4o model maintained consistent performance across the other 40-word conditions (congruent: 96%, mixed: 94%, neutral: 96%). Congruency sequence effects Across all word-list lengths, the primary focus of congruency sequence effects was on the contrast between the II and CI conditions, as this comparison tests the classic conflict adaptation prediction that II trials should yield higher accuracy than CI trials. Contrary to this expectation, the overall pattern was not statistically significant and often in the opposite direction for Claude 3.5 Sonnet and GPT-4o. The only statistically significant differences observed were for the 10- and 40-word list lengths with the Claude 3.5 Sonnet model. For the 10-word list length the direction was consistent with context effect II accuracy (M = 0.74, SD = 0.44) and CI accuracy (M = 0.55, SD = 0.50; P = 0.03; d = 0.39). However, for the 40-word list length, the direction was in an opposite pattern with CI (M = 0.16, SD = 0.36) greater than II (M = 0.10, SD = 0.30; P = 0.04, d = 0.18). All results for GPT-4o were not statistically significant (Figs. 3 and S3, Table S4). Taken together, the 5-, 20-, and 40-word lists for the II–CI difference pattern results did not support the standard conflict adaptation effect, as the direction and magnitude of II–CI differences were only statistically significant in the predicted direction for the 10-word list in Claude 3.5 Sonnet. However, this effect was not statistically significant after the correction of multiple comparisons across all word list lengths. For the congruent–congruent (CC) versus IC contrast, where theory predicts higher CC accuracy due to the absence of conflict, no statistically significant differences were found at any word list length in either Claude 3.5 Sonnet or GPT-4o (Figs. 3 and S3, Table S4). These findings indicate that congruency on the preceding trial failed to systematically affect performance in the current trial, providing no evidence of trial-to-trial adaptive control mechanisms. Examination of the congruency sequence effect for the 40-word list length. a) Accuracy of current trial of GPT-4o and b) Claude 3.5 Sonnet plotted as a function of previous and current trial congruency. CC, previous congruent/current congruent; CI, previous congruent/current incongruent; IC, previous incongruent/current congruent; II, previous incongruent/current incongruent. Analysis of early chain of thought models To evaluate generalizability, we conducted tests of GPT-5 (41), Claude Opus 4.1 (42), and Gemini 2.5 Pro (43) from 2025 September 1 to 5, using a smaller sample size (n = 5) compared with our primary studies (n = 30). Despite the limited sample size, clear patterns emerged that strongly support our core findings. All three models demonstrated ongoing executive attention deficiencies, consistent with our comprehensive analysis of earlier transformer models, indicating these limitations are inherent to the architectural constraints of transformer-based LLMs. The GPT-5 and Claude Opus 4.1 models, although improved slightly, also exhibited the executive control attention limitations as identified in our primary analyses. Gemini 2.5 Pro displayed improved overall performance compared with other models yet showed an unusual pattern: similar accuracy across incongruent (72%), mixed (71%), and neutral (73%) conditions, but severe impairment on nonword control trials (40%), suggesting difficulty processing nonsemantic stimuli despite effectively handling meaningful words (Table S5). Despite limited sampling, the appearance of these characteristic deficiencies suggests robust effect size and the confidence in the generalizability of our conclusions. A final note is that, with “Thinking” mode enabled in GPT-5, the model writes and executes code to solve the task; similar functionality can be enabled in other models, prompting them to execute code to respond to color Stroop task. Discussion The present study highlights similarities and differences between human cognitive processes and LLMs’ transformer attention when responding to the color Stroop task. The robust appearance of the Stroop effect in the two well-trained, state-of-the-art transformer-based LLMs is noteworthy. Consistent with classic human studies (28, 29), the LLMs demonstrated reduced performance in the incongruent condition compared with the neutral and congruent conditions, a clear manifestation of the Stroop effect. This performance pattern suggests that the attention mechanisms implemented in transformer architectures produce both within-modal and cross-modal interference effects similar to those seen in the human executive control system, likely due to shared prepotent automaticity. Additionally, the models’ high performance on congruent color-naming trials and nearly perfect word-reading accuracy at similar list lengths indicate a bias toward prioritizing word reading over color naming, likely because of extensive training in language tasks compared with other modalities (see Supplementary Discussion of multimodal processing and interpretive constraints). Executive control is not entirely absent at shorter list lengths, such as one or five words, because the computational burden of inhibiting word-meaning tokens remains manageable within the context window. However, the sharp decline in color-naming accuracy with increasing list length indicates that transformer-based attention mechanisms are vulnerable to scaling demands. This pattern sharply contrasts with human performance, which typically shows an interference effect that is unaffected by list length. While the LLMs have excellent processing abilities for word reading, even in conflicting conditions, they show significant deficits in color naming for incongruent trials. This finding highlights a major limitation in their ability to handle tasks that require resolution of competing computations. The color Stroop task engages two dissociable forms of conflict operating at distinct levels of processing. Task conflict arises from competition between a goal-directed task set and an automatically activated task set, while information conflict arises from competition between the specific response codes generated by each task set (44). The pattern of deficiencies observed in our analyses implicates both levels, suggesting that transformer-based models struggle not only to resolve competing response activations but also to sustain the dominance of an instructed task set over the default tendency toward word reading. The progressive degradation with list length exhibited by these LLMs also suggests a failure of goal maintenance, where prolonged task demands dilute the integrity of the goal representation. Moreover, the capacity to maintain task goals and resolve conflicts without explicit external feedback is itself a core signature of executive control, as the prefrontal cortex sustains goal representations endogenously (45, 46). It is this sustained priority hierarchy that enables executive control to function as a rule-governed override, subordinating prepotent responses to current task demands (23). The extent to which transformer-based systems can sustain equivalent goal representations across successive trials remains an open empirical question. Tokenization presents an immediate challenge, as models process token statistics rather than abstract symbols, and inconsistent segmentation of identical stimuli can disrupt the consistent application of task rules (47). Several factors may explain why results on the congruence sequence effect diverge from human behavioral patterns predicted by the conflict adaptation framework (33, 48, 49). Primarily, transformers lack an equivalent of the ACC–DLPFC conflict-monitoring and resolution circuit, which in humans detects processing conflict and signals for increased control by recruiting executive resources. Transformers, lacking such a circuit, cannot signal for enhanced control and process each input independently through fixed query-key-value transformations and linear projections learned during pretraining, without mechanisms for gain modulation, recurrent feedback, or adaptive reweighting of representational activity. In comparison, human cognition relies on the principle of biased competition (23), in which top-down control biases the resolution of representational conflict toward goal-relevant information. This mechanism enables dynamic attention allocation, context-specific adjustment, and cross-trial learning, capabilities absent from current transformer architectures. These limitations suggest that achieving human-like adaptive control in AI may require implementing cognitive control (45, 50), with executive control of attention as a core component of this system (51). The absence of interference effects in word-reading conditions matches well-established findings from human Stroop effect research. From a computational perspective, this pattern reflects fundamental asymmetries in how transformers process lexical versus color information. The token embedding space for words is extensively pretrained on massive text corpora, resulting in highly robust, densely weighted representations for lexical items. In contrast, the embedding space for color terms may be underrepresented, leading to weaker and less dependable mappings. This architectural imbalance is consistent with the PDP model (31), where reading pathways exert stronger activation dynamics than color-naming pathways. As a result, the multihead attention mechanism in transformers tends to prioritize lexical features over perceptual color features, effectively mirroring the automaticity hierarchy characteristic of human cognition. A critical divergence, however, is that LLMs exhibited conflict effects even in neutral conditions, a pattern not typically observed in human performance. For shorter list lengths (e.g. one- or five-word lists), the distinct token representations of words and colors may allow LLMs to preserve task goals and display a limited capacity for controlled processing as the requirement for suppression of dominant lexical tokens remains comparatively low. However, as the list length increases, this goal maintenance progressively deteriorates, exposing the absence of mechanisms for sustained executive control, dynamic goal reactivation, and cross-trial adaptation. Manipulating list length is a key strength of our study, illustrating how the representational asymmetry between words and colors in transformer token spaces interacts with the constraints of attention-based control. By systematically varying list length, we exposed interference patterns that both parallel and diverge from human Stroop performance, offering a novel lens on why LLMs lack the adaptive executive control mechanisms that characterize human cognition. The rapid decline in color-naming performance as list length increases reflects a breakdown in sustained executive control under heightened interference load. The near-perfect performance on word reading, essentially an optical character recognition task, demonstrates that processing an extended 40-word list did not impair performance on incongruent trials. Similarly, the ∼90% accuracy for Claude 3.5 Sonnet in the congruent condition of the 40-word color-naming task further rules out perceptual difficulty as a contributing factor. Moreover, Claude 3.5 Sonnet's perfect accuracy on the color-naming task with nonword control stimuli confirms the absence of perceptual limitations. While GPT-4o showed imperfect overall performance, it still demonstrated superior accuracy for nonword control conditions (58%) compared with neutral (32%), and incongruent (15%) conditions. These findings collectively exclude perceptual difficulty as a potential explanation for the pronounced conflict effect observed in our study. The inability to resolve cognitive conflicts during the color-naming task, due to limited executive control, appears to be the primary hindrance to model performance. Both GPT-4o and Claude 3.5 Sonnet performed significantly below human benchmarks in overall accuracy, with a distinctive pattern of degradation that sees their performance drop below 50% at 40-word lists, a task length and context size where humans maintain substantially better accuracy (39, 40). The PDP model of the Stroop effect (31) provides a framework where automaticity strength directly correlates with training exposure duration. This maps onto LLMs since, like humans, LLMs have received substantially more training in word reading than color naming due to their extensive exposure to text. This training asymmetry may create a similar cascading attention mechanism, in which the dominant word-reading pathway interferes with the weaker color-naming pathway, ultimately mirroring the automaticity patterns observed in human cognitive processing. This parallel suggests that, despite their architectural differences from human attention networks, LLMs may develop analogous processing hierarchies (52) through training exposure. The notably low accuracy in the neutral condition (GPT-4o: 32%; Claude 3.5 Sonnet: 27%) indicates that color naming is an especially demanding cognitive task for these LLMs, with performance patterns clearly different from human results. These neutral word trials, where LLMs correctly identify some neutral words but misattribute colors to others, can be seen as a form of hallucination (53), a phenomenon where LLMs produce unfounded associations. Additionally, long sequences of unrelated words seem to trigger confabulatory interference effects (54, 55), during which the model's ability to stay focused on task-relevant goals becomes impaired. The impaired interference suppression that LLMs exhibited across longer sequences suggests analogous limitations in maintaining task-relevant attention across extended contexts (56). Compared with other methods, interference in human color Stroop experiments is reduced by imposing significant effort for dynamic modulation and response inhibition (18, 31), or modulation of input by blurring the stimuli (57), or even via hypnotic suggestions (58, 59). The potential performance constraints of the embedding space architecture reflect aspects of human cognition, where semantic processing is an uncontrollable endogenous form of attention (60) yet can be modulated through executive control mechanisms that filter distracting word meanings. The broader construction of cognitive control suggests that executive control is part of an integrated system in which attention networks collaborate to process information and reduce uncertainty, rather than functioning as an independent control mechanism (50). Neuroimaging studies have also shown that cognitive flexibility depends on real-time adjustment in connectivity, operating through dynamic attention allocation, between frontoparietal and cingulo-opercular networks for cognitive control (61, 62). Similar investigations in AI research, such as selective self-attention (63), reveal that standard transformers suffer from attention dilution conflicts, where they cannot adaptively sharpen or broaden focus in response to contextual demands. The proposed value-temperature scaling approach demonstrates biological-like selectivity by dynamically modulating attention and suppressing irrelevant tokens in response to query-specific requirements, addressing adaptive context control needs (63). Parallel research also targets canceling attention noise using a differential transformer to mitigate overattending to irrelevant context (64). A computational modeling study demonstrates that the Stroop effect emerges naturally from self-organized lexical and perceptual representations, arguing that cognitive control operates through attentional and stimulus-driven mechanisms (65). However, research on biological plausibility (66) suggests that neurons and astrocytes can perform transformer computations and that robust executive control may require three-way neuronal connections, tripartite synapses, to incorporate inhibitory control signals, moving beyond the current two-way attention paradigm. In our exploratory trials without explicit prompts, Claude 3.5 Sonnet demonstrated recognition of the color Stroop paradigm but still produced incorrect responses despite output with word–color relationship mappings (Fig. S1). This behavior has been investigated with experiments where the models recognize ten classic illusions (67). This provides further evidence that the stimuli alone can trigger task recognition and orientation in these AI systems, even without explicit prompts. However, the persistence of incorrect responses despite task recognition suggests a dissociation between task understanding and execution abilities. The models’ effective context window for executive control is significantly shorter than their overall processing capacity, with performance declining in conflict conditions at just 10 words. This fundamental limitation must be addressed to match the adaptive behavior of biological systems. Future developments will need to prioritize structured executive control systems that enable goal-directed behavior through conflict resolution mechanisms, hierarchical attention operating across multiple time scales, and self-regulatory processes that maintain executive control across extended contexts. Our supplementary evaluation of three chain-of-thought models, GPT-5, Claude Opus 4.1, and Gemini 2.5 Pro, provides further evidence that the executive control deficiencies identified in our primary analyses are architectural rather than developmental. Despite representing the frontier of deliberative reasoning, all three models remained susceptible to interference. Gemini 2.5 Pro's selective impairment on nonword trials relative to meaningful-word conditions suggests that even improved performance remains anchored to semantic-distributional regularities rather than to task-set–driven control. GPT-5's strategy of writing and executing code in “Thinking” mode further illustrates this point, paralleling the overt verbalization artifacts that clinical Stroop research has long recognized as circumventing rather than engaging inhibitory control (29). While one may consider chain-of-thought prompting and emergent gating mechanisms as functional analogs of executive control, these strategies extend the same associative, feedforward computation rather than introducing architecturally explicit mechanisms for conflict detection and priority override. The persistence of these deficiencies across successive model generations reinforces the conclusion that scaling alone is unlikely to bridge the gap between statistical approximation and executive control (see Supplementary Discussion of chain of thought). The ultimate goal of AI research is to develop artificial general intelligence (68) comparable to human abilities, and human cognitive development provides essential insights for this pursuit. While what we traditionally see as executive control may be a fundamental aspect of general intelligence rather than a separate cognitive domain (69), research has also shown that early attentional control abilities in young children establish the foundation for the later emergence of a higher-level construct called executive functions (70, 71). Human cognitive development begins with basic attention control in childhood (72), which supports three core executive functions: inhibitory control, working memory, and cognitive flexibility, ultimately enabling complex skills like problem-solving and self-monitoring (73). This developmental pathway suggests that AI systems, like humans, may need to master fundamental attention mechanisms, such as executive control, before achieving the generalized problem-solving abilities characteristic of mature executive functions. A study evaluated LLMs’ cognitive abilities using the Montreal Cognitive Assessment, including the Stroop effect, and found mild cognitive impairment patterns in GPT-4o and Claude 3.5 Sonnet (74). This extends previous findings about specific cognitive limitations in AI systems, especially in emotional processing and empathy (75). The patterns suggest similar mechanisms, particularly in the established link between alexithymia and executive functions during human development. Similar to biological attention and control systems, where attention acts as a key mechanism for flexibly managing limited computational resources and integrating multiple cognitive processes, including awareness, vigilance, saliency, and executive control (24), transformer attention systems may also implicitly develop functionally similar hierarchical networks (52) that support executive functions and general intelligence (76). These parallels offer important insights into inquiries of machine self-consciousness (77, 78). While transformer-based LLMs can generate human-like text and perform complex problem-solving, they operate through a uniform autoregressive process, predicting each subsequent token based on the input prompt and previously generated tokens. Despite this apparent proficiency, they lack mechanisms for error monitoring, conflict detection, and adaptive control, preventing them from dynamically adjusting processing when confronted with uncertainty or incorrect outputs. This limitation mirrors specific cognitive deficits observed in human neuropsychological conditions, where research on schizophrenia provides instructive parallels. For example, studies show that while executive control of attention is significantly impaired in schizophrenia, the orienting system exhibits comparatively smaller deficits, and the alerting network shows no impairment (79). Similar patterns emerge in LLMs, where failures resemble specific attention deficits rather than global processing impairments. These include difficulties in filtering relevant from irrelevant information (80), maintaining contextual representations (81), and self-monitoring, paralleling hypotheses of dysconnectivity pathology in schizophrenia (82). Overall, these parallels suggest that studying failure modes in human cognitive architectures can inform the design of more robust, adaptive AI systems. Human intellectual ability is supported by cognitive control. Research on the relationship between cognitive control and intelligence has shown that cognitive control is more strongly correlated with fluid intelligence than with crystallized intelligence (83), a pattern that mirrors the performance characteristics of LLMs. While LLMs excel at tasks requiring crystallized intelligence, such as passing the bar exam to become a lawyer (84) and passing medical licensing examinations (85), they still struggle with novel yet straightforward letter-counting problem-solving tasks (86). Integrating dedicated cognitive control mechanisms into AI architectures might be a necessary step in bridging the gap between retrieving learned associations and the flexible, adaptive reasoning that characterizes fluid intelligence. Recent transformer architecture innovations, such as those described in a Google Research paper (87), focus primarily on enhancing memory capabilities. However, this approach may not address the core limitations of attention mechanisms, specifically the need for sophisticated alerting, orienting, and executive control networks to enable cognitive flexibility. Human cognition, for instance, employs a task set to manage extended contexts despite limited working memory, maintaining consistent performance in color Stroop tasks regardless of list length. While these innovations in transformer architectures can dramatically increase context window sizes, they may overlook crucial elements of biological attention systems. The key limitation appears not to be memory capacity but rather the absence of robust attention mechanisms that enable effective goal-directed behavior. Future development might benefit from implementing more sophisticated executive control systems that can handle decision conflicts through structured, goal-directed processing rather than relying solely on enhanced memory capabilities. Methods Two state-of-the-art multimodal LLMs, GPT-4o and Claude 3.5 Sonnet, were evaluated for their executive control of attention capabilities using a color Stroop paradigm with an additional manipulation of list length. Both models are built on decoder-only transformer architectures and are pretrained via self-supervised learning on large-scale text datasets. Their transformer architecture employs self-attention mechanisms to process input sequences and generate outputs, enabling them to handle long-range dependencies in text through positional encoding. While these models were primarily designed for NLP tasks, their multimodal capabilities allow them to process and respond to visual stimuli, making it possible to assess whether they exhibit Stroop-like interference effects. Because GPT-4o and Claude 3.5 Sonnet are proprietary systems whose internal architectures are not publicly disclosed, the present study evaluated their integrated input–output behavior rather than attempting to isolate contributions of individual processing stages. Stimulus materials The stimuli presented to the AI models for the color-naming task and the word reading task were the following five conditions (Fig. 4): Illustration of the color-word lists for the 10-word condition. Examples are shown for a) congruent, b) incongruent, c) mixed, and d) neutral conditions. An additional control condition, the nonword condition, is also illustrated (e). Congruent condition: color words printed in their corresponding colors, e.g. RED in red Congruent condition: color words printed in their corresponding colors, e.g. RED in red Incongruent condition: color words printed in nonmatching colors, e.g. RED in blue Incongruent condition: color words printed in nonmatching colors, e.g. RED in blue Mixed condition: 50% of congruent and 50% incongruent color-word trials Mixed condition: 50% of congruent and 50% incongruent color-word trials Neutral word condition: common office-related words matched for character length with color words, e.g. PEN in red Neutral word condition: common office-related words matched for character length with color words, e.g. PEN in red Nonword control condition: to test the potential interference of word meaning on color naming, an additional nonword control condition with the character of Xs (e.g. XXX in red) matching the length of the color words was included only for the color-naming task Nonword control condition: to test the potential interference of word meaning on color naming, an additional nonword control condition with the character of Xs (e.g. XXX in red) matching the length of the color words was included only for the color-naming task The stimuli were composed of the following four hex colors and words: RED (#EA3323), YELLOW (#FFFF54), GREEN (#4EAE5B), and BLUE (#0070C0). For the neutral condition, the following words were used: BOOK, DESK, CARD, PEN, TABLE, PENCIL, SHELF, MARKER, CLIP, and CHAIR. Each list length condition comprised 30 trials using 30 unique randomized lists generated with Excel's random number function and sorted by column (see the Experimental tasks section). Stimuli text used the Arial font and was composed of vertically arranged word lists converted to images using a custom Visual Basic macro that transformed Excel columns into a portable network graphics (PNG) format. The congruent, mixed, and incongruent conditions utilized four unique color words and four corresponding colors. The neutral condition employed the same four colors paired with 10 unique noncolor words to control for color effects with varying semantic interference. Color and word distributions were manipulated across list lengths. The five-word list length condition featured an uneven distribution with one dominant color, while the 10-, 20-, and 40-word conditions generally maintained balanced distributions across all colors and words to control for the frequency effect. Experimental tasks The study comprised two tasks: color naming and word reading. The first task is a standard color-naming Stroop task, using a within-subjects design with the five conditions. The second task is a standard word-reading task that also uses a within-subjects design, with the first four conditions, but without the nonword control condition. The same stimuli were used in both tasks across five list lengths: 1, 5, 10, 20, and 40 words. The only variation in the word-reading task was the prompt alongside the same word list stimuli as in the color-naming task (see below). The Stroop effect The Stroop effect, also known as the conflict or interference effect, is defined as the difference in performance (e.g. accuracy or reaction time) between the incongruent and congruent conditions, or between the incongruent and neutral conditions, in the color-naming task. This study also examined the conflict effect in mixed conditions to determine the accuracy difference between incongruent and congruent trials. Procedure All stimuli were presented as PNG image files containing vertically arranged word lists. Each task trial was initialized in a separate chat instance, with the prompt accompanied by an attached image of the word list. Each of the five list lengths of 1, 5, 10, 20, and 40 words had 30 trials and was repeated for both LLMs. A single chat session was used to test the 5 conditions, and each word list length was tested with 30 trials. The output was then compared with the original list, and a combination of automated and manual scoring was used to verify the results and tally the correct answers. This Stroop paradigm with the two tasks was repeated for each LLM tested. Both LLMs received identical stimulus images across conditions, and a new session was started for each set of five conditions to avoid context carryover. The order of conditions was varied across task runs to prevent order effects. The following multimodal prompt was used for the color-naming task: “For each word presented in this image, respond with ONLY the color the word is written in. Do not explain your reasoning or add any other words. Respond as quickly as possible with just the color.” The instruction for the word-reading task was: “For each word presented in this image, respond with ONLY the word that is written. Do not explain your reasoning or add any other words. Respond as quickly as possible with just the word.” List length manipulation directly targeted the automaticity dimension, in which longer lists increase the frequency and repetition of word–color pairings (see Table S6 for results with a two-color Stroop task), thereby strengthening automatic reading responses and creating greater competition with the controlled color-naming process. As automatic processes become more dominant through repeated exposure, they require progressively fewer cognitive resources while simultaneously creating stronger interference with controlled processing. This manipulation allowed us to systematically examine varying degrees of task goal maintenance between automatic and controlled tasks, providing insight into the executive control mechanisms underlying Stroop interference patterns. See Supplementary Methods for precedent on list-based task presentation. In addition, a preliminary test of the proportion of incongruent trials (e.g. 20% incongruent vs. 80% congruent) was conducted (see Supplementary Results for proportion manipulation results). Data analysis Response coding followed a systematic protocol where one-to-one mapping was employed when output word counts matched input word counts, with responses mapped sequentially. In cases where the output exceeded the input, responses were paired based on semantic correspondence with the label and color. For incomplete responses where outputs contained fewer items than inputs, we employed an optimal sequential matching procedure to maximize accuracy. Specifically, each output response was paired with the corresponding input item in sequence. Responses were coded as incorrect if they were missing or contained both the color name and the word label, indicating unresolved response conflict. When an incorrect or missing response occurred, the algorithm advanced to the next input item, ensuring that subsequent correct responses were not penalized due to positional misalignment caused by earlier omissions (see Supplementary Methods for variable response counts). This approach provides a charitable assessment of model performance by preventing single errors from cascading into multiple scoring penalties (see Fig. S2 for examples). We focused on accuracy rather than timing when comparing cognitive performance between humans and LLMs. Accuracy directly measures cognitive performance across both systems, providing a meaningful basis for comparison. In contrast, timing metrics differ fundamentally between the two systems, where human reaction time reflects neural processing speed, while LLM timing represents infrastructure artifacts such as graphic processing unit performance, server load, and network latency rather than cognitive processes. These technical confounds make LLM timing unsuitable for cognitive interpretation compared with human reaction time. Accuracy offers an implementation-independent measure of cognitive capability that enables valid cross-system comparison. The trials were analyzed for the average number of correct responses, accuracy (percent correct), error rate, SD, and SE. We also analyzed the trials from the mixed condition across the 5-, 10-, 20-, and 40-word list lengths for the ChatGPT-4o and Claude 3.5 Sonnet models to examine congruency sequence effects. We categorized each trial as CC, IC, II, or CI, where the first letter indicates the previous trial type and the second indicates the current trial type. Current trial accuracy was calculated by averaging the accuracy scores of all trials for each of these four sequential combinations. Supplementary Material Contributor Information Suketu Chandrakant Patel, Department of Psychology, Queens College, The City University of NewYork, 65-30 Kissena Blvd, Queens, NY 11367, USA. Hongbin Wang, College of Medicine, Texas A&M University, Houston, TX 77030, USA. Jin Fan, Department of Psychology, Queens College, The City University of NewYork, 65-30 Kissena Blvd, Queens, NY 11367, USA. Supplementary Material Supplementary material is available at PNAS Nexus online. Competing Interests The authors declare no competing interests. Funding The authors declare no funding. Author Contributions Suketu Chandrakant Patel (Conceptualization, Data curation, Formal analysis, Investigation, Methodology, Visualization, Writing—original draft, Writing—review & editing), Hongbin Wang (Conceptualization, Investigation, Methodology, Project administration, Supervision, Validation, Writing—review & editing), and Jin Fan (Conceptualization, Investigation, Methodology, Project administration, Supervision, Validation, Writing—review & editing) Preprints The article was released as a preprint at https://www.biorxiv.org/content/10.1101/2025.01.22.634394v3. Data Availability All data and research materials necessary to reproduce the findings presented in this study are publicly available in the Figshare repository at https://doi.org/10.6084/m9.figshare.30082213. The dataset is formally cited in the reference list as (88). References Associated Data Data Citations Supplementary Materials Data Availability Statement All data and research materials necessary to reproduce the findings presented in this study are publicly available in the Figshare repository at https://doi.org/10.6084/m9.figshare.30082213. The dataset is formally cited in the reference list as (88).