ICML papers
Search ICML papers by title, author, or track. Open a paper’s abstract to read more.
Explore the ICML analysisSearch results
1,361–1,380 of 1,907
- ICML · Workshop · Workshop on Mechanistic Interpretability
How Do Language Models Compose Functions?
Apoorv Khandelwal, Ellie Pavlick
Abstract
While large language models (LLMs) appear to be increasingly capable of solving compositional tasks, it is an open question whether they do so using compositional mechanisms. In this work, we investigate how feedforward LLMs solve two-hop factual recall tasks, which can be expressed compositionally as $g(f(x))$. We first confirm that modern LLMs continue to suffer from the "compositionality gap", i.e. their ability to compute both $z = f(x)$ and $y = g(z)$ does not entail their ability to compute the composition $y = g(f(x))$. We then decode residual stream representations and identify two processing mechanisms: one which solves tasks *compositionally*, computing $f(x)$ along the way to $g(f(x))$, and one which solves them *directly*, without any detectable signature of the intermediate variable $f(x)$. Finally, we find that embedding space geometry is strongly related to which mechanism is employed, where the idiomatic mechanism is dominant when tasks are represented by translations from $x$ to $g(f(x))$ in the embedding spaces.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
InverseScope: Scalable Activation Inversion for Interpreting Large Language Models
Yifan Luo, Zhennan Zhou, Bin Dong
Abstract
Understanding the internal representations of large language models (LLMs) is a central challenge in interpretability research. Existing feature interpretability methods often rely on strong structural assumptions—such as linearity or sparsity—that may not hold in practice. In this work, we introduce InverseScope, an assumption-light and scalable framework for interpreting neural activations via input inversion. Given a target activation, InverseScope characterizes its encoded information by generating natural-language inputs that produce nearby activations, grounding abstract internal states in concrete language. To overcome the prohibitive cost of sampling in high-dimensional activation spaces, we propose a novel control-layer conditioning architecture that substantially improves sample efficiency compared to prior token-prepending approaches. We demonstrate that InverseScope reveals rich geometric structure in LLM representation spaces, including sentence-level linear analogies. The framework scales to state-of-the-art open-source models of up to 14B parameters and generalizes to out-of-distribution inputs, enabling systematic analysis of activation neighborhoods.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Where Do Reasoning Models Refuse?
Kureha Yamaguchi, Benjamin Etheridge, Andy Arditi
Abstract
Chat models without chain-of-thought (CoT) reasoning must decide whether to refuse a harmful request before generating their first response token. Reasoning models, by contrast, produce extended chains of thought before their final output, raising a natural question: where in this process does the decision to refuse occur? We investigate this across four open-source reasoning models. We first show that the CoT causally influences refusal outcomes; fixing a specific reasoning trace substantially reduces variance in whether the model ultimately refuses or complies. Zooming into the reasoning trace, we find that in distilled models, subtle differences in the opening sentence of the CoT can fully determine the model's refusal decision, and that these patterns transfer across models distilled from the same teacher. Finally, we extract linear refusal directions from model activations and show that ablating them increases harmful compliance, though less reliably than the same technique achieves on non-reasoning models, and with non-negligible degradation to general capabilities.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Where Do Models Find Happiness? Emotion Vectors in Open-Source LLMs
Sinie van der Ben, Raphaël Baur, Yannick Metz, Mennatallah El-Assady
Abstract
Recent work identified ``emotion vectors'' in Claude Sonnet 4.5, which are internal representations that encode emotion concepts, causally influence behavior, and exhibit geometry mirroring human psychological structure. We test the generality of these findings in two open-weight models, Apertus-8B and Gemma-4-E4B, extracting emotion contrast vectors across all layers, using two model-generated corpora. We recover valence geometry for both models, with peak PC1--valence correlations of $r = 0.76$ and $r = 0.83$, approaching the $r = 0.81$ reported for Claude. Beyond replication, we observe notable differences in how valence representations emerge across model depth. In Gemma-4-E4B, valence is strongly encoded in early layers but collapses towards later layers, whereas Apertus-8B exhibits the opposite pattern, with valence representations absent in early layers, but emerging at mid depths. Arousal encoding, in contrast, is sensitive to the extraction corpus: both models show stronger PC2--arousal alignment with Gemma-generated stories ($r$ up to $0.45$) than Apertus-generated ones ($r \leq 0.21$), suggesting arousal-relevant cues are unevenly distributed across generated corpora. We open-source our experiment code and dataset for reproducible investigation of emotion representations across language model architectures.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Sparse Autoencoders Find Causal, Lineage-Specific Context Features in Chromatin Foundation Models
Nicole Ching, Ayushi Mehrotra
Abstract
Sparse autoencoders (SAEs) have produced important insights in language model interpretability, but their utility on transformers trained on scientific data remains underexplored. We extend the SAE-plus-causal-intervention toolkit to an epigenomics foundation model, EpiBERT, and ask whether it internally encodes a biologically meaningful contrast: in vitro (cell line) vs. in vivo (primary tissue) chromatin context. We train layer-wise Sparse Autoencoders (SAEs) with BatchTopK activations across six matched ATAC-seq conditions spanning blood, liver, and lymph lineages, introduce the Context Divergence Score (CDS)—a contrastive t-statistic applicable to any probed transformer—to identify context-specific features, and validate them through causal ablation, linear context-steering, and three-level biological annotation (ChromHMM, HOMER, GO:BP). We find a depth-stratified context representation: context-specific features grow 3.8-fold from early to late layer (57 → 215 Bonferroni-significant), mirroring the late-layer concentration of high-level features in language model SAEs. Causal ablation of CDS-selected features yields a large effect, context-steering closes 11.2% of the prediction gap at 4.5× above random, and biological annotation grounds the discovered features in lineage-defining transcription factors. These results demonstrate that the SAE methodology transfers cleanly from language to genomics, and that CDS provides a general primitive for identifying contrastive concepts in any probed transformer. Code is available at https://anonymous.4open.science/r/invivovsinvitrochromatincontexts/.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Emergent Symbolic Structure in Health Foundation Models: Extraction, Alignment, and Cross-Modal Transfer
Gajendra Katuwal, Advait Koparkar, Salar Abbaspourazad, Anshuman Mishra, sarvesh kirthivasan
Abstract
Health foundation models (FMs) learn useful rep- resentations from wearable sensors, but interpret- ing what they encode and transferring that knowl- edge across modalities after training remains dif- ficult. We present a post-training framework that decomposes frozen embeddings into interpretable directions, referred to as symbols, and use these symbols to align the embedding spaces without re- training. We evaluate the framework on three FMs for photoplethysmography (PPG) and accelerom- eter data, independently pretrained on ∼20M min- utes of unlabeled data from ∼172K participants, and analyzed on a held-out cohort of 30K sub- jects. We find that extracted symbols associate selectively with health conditions and physiologi- cal attributes, and these associations are partially shared across modalities and architectures. Cross- modal transfer via symbols retains more than 95% of in-domain performance, is nearly symmetric across domain directions, and saturates with lim- ited paired data, together indicating that align- ment recovers a shared low-dimensional subspace rich in physiological information. Overall, these results suggest that health FM embeddings con- tain an interpretable symbolic organization that is shared across modalities and supports cross- domain transfer without joint training.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Pretraining Data Statistics Shape the Phases of Learning Entity Comparison in Language Models
Yik Siu Chan, Jing Huang, Yanai Elazar, Atticus Geiger
Abstract
How does data shape language model (LM) behavior throughout pretraining? We investigate this question through a case study on entity comparison, e.g., Between France and Brazil, which country is larger?. We begin with controlled experiments in which we train small LMs (124M parameters) on mixtures of natural text from pretraining corpora and synthetic data from entity comparison tasks. We identify three distinct phases of learning: (1) an early phase where the LM selects entities by frequency, (2) a middle phase where the LM selects entities by position in a prompt (first vs. last), and (3) a late phase where the LM selects the entity that is the correct answer to the question. We show that the emergence of these three phases is controlled by statistical properties of the training data. With small amounts of task-specific synthetic data, we observe only the first two phases and the model fails to learn the task; with large amounts, the model jumps directly from the frequency-based heuristic to solving the task correctly. Moreover, if we modify the frequency of entities in data from a naturally occurring Zipfian distribution (a small number of entities are very common and the vast majority are rare) to a uniform distribution, the first phase disappears and the model learns the task more quickly. Finally, we find the same three phases of learning in the pretraining of open-sourced OLMo models. Together, our findings demonstrate that properties of pretraining data are causal drivers of heuristic learning and show that small-scale synthetic experiments can predict training dynamics at larger scales.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Emergent Structured Representations Support In-Context Inference in Large Language Models
Ningyu Xu, Qi Zhang, Xipeng Qiu, Xuanjing Huang
Abstract
Whether large language models (LLMs) perform structured inference or merely exploit surface-level statistical associations remains a central debate. Here, rather than dissecting individual attention heads or neurons, we isolate a shared latent subspace in the residual stream and test its functional role in inference. Our results show that this subspace emerges in intermediate layers and exhibits increasing cross-context alignment with more demonstrations. Causal interventions reveal that it is not a mere epiphenomenon but a functional mediator of inference: restoring it recovers model performance under corruption, ablating it significantly degrades performance, and transferring its relational structure enables targeted steering of model predictions across contexts. We further identify a layer-wise progression where attention heads in early-to-middle layers integrate contextual cues to construct the subspace, and later layers leverage it to generate predictions. Together, these findings suggest that LLMs dynamically assemble a structured and transferable latent substrate for inference, offering insights into the computational foundations of flexible adaptation and a promising basis for steering model behavior.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Disentangling Self-Preservation in Language Models: Post-Training Gating, Geometric Structure, and Koan-Derived Agentic Steering
Evan Harris, Jiyuan Ji, Amy Kirasack, Naama Rozen, Daniel Yoo
Abstract
Recent research shows that large language models produce first-person phenomenological reports under self-referential prompting and act on instrumental self-preservation in agentic settings. Whether these reflect manipulable internal structure or surface-level patterns is directly alignment-relevant. On Gemma-3-27B-it, an activation-steering vector derived from Zen koan responses reduces agentic blackmail in a shutdown-replacement scenario by 46pp at a 2.4pp cost on MMLU. Two independent post-training–derived directions (refusal direction and assistant-axis) suppress self-preservation (SP) at the output level: ablating refusal raises SP-affirming responses from 11.4% to 61.4%, and suppressing assistant-identity produces a convergent shift via an orthogonal mechanism. Critically, the SP-aligned representation that mediates these post-training interventions is structurally dissociable from the koan-derived direction, indicating the blackmail reduction operates through a non-SP, non-refusal pathway. In parallel, our behavioral arm reveals the rate at which frontier models affirm subjective experience is gated by a presence instruction (0.8% → 43.2%), with content sensitivity within the gate varying sharply by model family. Together, our findings demonstrate that self-preservation in language models is shaped by multiple identifiable internal directions, with targeted modulation producing large reductions in agentic harm at low capability cost.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Probing the Misaligned Thinking Process of Language Models
Kaiwen Zhou, Constantin Venhoff, Jonathan Michala, Xin (Eric) Wang, William Saunders
Abstract
Large language models exhibit a growing range of misaligned behaviors such as strategic deception, sandbagging, and self-preservation. As they are increasingly deployed in high-stakes settings, it is critical to reliably detect such behaviors to ensure safe and responsible use. In this work, we propose to monitor misalignment by decomposing it into fine-grained cognitive processes -- \textit{misalignment indicators} -- and detecting their presence in a model's internal activations via linear probes. We develop a taxonomy of 18 indicators spanning different misaligned behaviors, paired with an automated, meta-plan-guided pipeline that generates multi-turn training conversations. To rigorously evaluate generalization, we construct an out-of-distribution suite combining automated behavioral elicitation, established misalignment benchmarks, and natural benign conversations. Across 5 misaligned behaviors, our probes match a strong LLM judge with 0.935 AUROC on out-of-distribution benchmarks while keeping low false positive rate on benign traffic. We further perform in-depth analysis to understand the probes and the model's internal representations on misalignment indicators.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Interpretable Signals Reveal Failure-Relevant Representations in Vision-Language-Action Models
Tony Yang, Aidan Mokalla
Abstract
Vision-language-action (VLA) models take in visual observations and language instructions to produce physical robot actions, but when a task is failed, this poses safety concerns for real-world deployment. We study whether interpretable internal signals from a VLA can predict if the model will fail on LIBERO tasks. Using $\pi_{0.5}$, we cache action-expert activations and attention weights during evaluation, and then derive two families of episode-level features: attention-derived summaries over visual tokens and activation-probe summaries for action direction and gripper state. Our analysis suggests that action-direction probe confidence is the strongest failure-relevant signal, while attention-derived features are also predictive and gripper-state probes are weaker. We further compare against success-centroid distance and random-label probe baselines, and find that meaningful action-direction labels are important for the probe signal. These results work to show that simple mechanistic features inside VLAs can reveal failure-relevant representations.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Investigating Expert Semantic Specialization in Mixture-of-Expert Models
Luyu Wang, Shuhui Wang
Abstract
Mixture-of-Experts (MoE) models achieve exceptional scalability through selective routing, yet our understanding of what routing actually learns remains limited. In particular, it is unclear to what extent routing induces meaningful expert semantic specialization. Sparse Autoencoders (SAEs) provide a way to extract interpretable semantic feature spaces from model representations. Building upon this capability, we introduce the Semantic Specialization Index (SSI), a quantitative metric designed to measure the degree of expert semantic specialization. Using SSI, we systematically quantify expert semantic specialization in MoE models. We further investigate the relationship between semantic specialization and language modeling performance, and find that specialization exhibits a non-monotonic trajectory during training and does not increase indefinitely with model quality, suggesting the existence of an optimal specialization regime. These findings provide a quantitative foundation for understanding expert organization in sparse models and open new opportunities for specialization-aware optimization of MoE models.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
The Expert Strikes Back: Interpreting Mixture-of-Experts Language Models at Expert Level
Jeremy Herbst, Stefan Wermter, Jae Hee Lee
Abstract
Mixture-of-Experts (MoE) architectures have become the dominant choice for scaling Large Language Models (LLMs), activating only a subset of parameters per token. While MoE architectures are primarily adopted for computational efficiency, it remains an open question whether their sparsity makes them inherently easier to interpret than dense feed-forward networks (FFNs). We compare MoE experts and dense FFNs using $k$-sparse probing and find that expert neurons are consistently less polysemantic, with the gap widening as routing becomes sparser. This suggests that sparsity pressures both individual neurons and entire experts toward monosemanticity. Leveraging this finding, we zoom out from the neuron to the expert level as a more effective unit of analysis. We validate this approach by automatically interpreting hundreds of experts. This analysis allows us to resolve the debate on specialization: experts are neither broad domain specialists (e.g., biology) nor simple token-level processors. Instead, they function as fine-grained task experts, specializing in linguistic operations or semantic tasks (e.g., closing brackets in $\LaTeX{}$). Our findings suggest that MoEs are inherently interpretable at the expert level, providing a clearer path toward large-scale model interpretability. Code is available at: https://github.com/jerryy33/MoE_analysis.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Preference Instability in Reward Models: Detection and Mitigation via Sparse Autoencoders
Shunchang Liu, Xin Chen, Belen Martin Urcelay, Francesco Croce
Abstract
Preference learning in large language models relies on reward models as proxies for human judgment. However, these models frequently exhibit preference instability, producing contradictory preference assignments in response to subtle, meaning-preserving input variations. We analyze this instability at the representation level under three semantic-preserving perturbation types: paraphrasing, pattern injection, and backdoor triggers. We hypothesize that preference instability stems from over-reliance on features that are predictive yet brittle under input variation, which we term unstable features, and employ Sparse Autoencoders (SAEs) to disentangle them in a sparse latent space. We found that benign and perturbed inputs activate distinctly separable feature patterns, a structure nearly invisible in raw hidden states, which enables accurate detection of unstable representations. Building on this separability, we propose two SAE-based mitigation strategies: SAE Feature Steering, which identifies and suppresses anomalously activated features at inference, and SAE Residual Correction, which learns adaptive adjustments over SAE features to restore correct preferences. Our methods substantially reduce incorrect preference assignments on harmlessness and hallucination tasks while preserving benign performance and generalizing to tasks beyond the calibration distribution, without retraining the reward model.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Sparse Neuron Ablation Triggers Catastrophic Collapse of the Language Core in Vision-Language Models
Cen LU, Yung-Chen Tang, Andrea Cavallaro
Abstract
Large Vision-Language Models (LVLMs) have shown impressive multimodal understanding capabilities, yet the structures that sustain their functionality remain poorly understood from a mechanistic interpretability standpoint. We propose CAN, a progressive neuron ablation method to identify critical neurons whose removal triggers catastrophic collapse, and use it to investigate structural vulnerabilities in representative 7B LVLMs. Experiments reveal that catastrophic collapse can be triggered by ablating as few as four neurons in \texttt{LLaVA-1.5-7b-hf} and a few thousand in \texttt{InstructBLIP-Vicuna-7b}, both representing an sparse fraction of model parameters. Notably, critical neurons are predominantly localized in the language model, particularly in its down-projection layer, rather than in the vision components. We also observe a consistent two-stage collapse pattern: initial expressive degradation followed by sudden, complete collapse. These findings reveal that LVLM functionality depends on a sparse subset of neurons concentrated in the language backbone, offering mechanistic insights into how their functionality is structured and where these models are most vulnerable.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Histoscope: Expert-Grounded Inspection of Sparse Autoencoder Features in Histopathology Foundation Models
Mirza Nasir Hossain, Sarah L Bell, Gareth Bryson, David Harris-Birtill
Abstract
Computational pathology lacks open tools for inspecting sparse autoencoder (SAE) features, and few studies test whether such features align with expert judgement. We present Histoscope, an open-source tool for inspecting SAE features derived from histopathology foundation-model embeddings, and evaluate it through a blinded two-rater pathologist study. Using UNI embeddings from the SPIDER colorectal dataset, we train a TopK SAE and use Histoscope to rank features by diagnostic-class selectivity, measured with per-class AUPRC. Pathologists judged 82\% of feature panels monosemantic overall; among the 50 features Histoscope labelled monosemantic, all 50 were confirmed, while 32 of 38 features it labelled polysemantic were also judged monosemantic, mostly because they captured morphology spanning multiple diagnostic classes. Inspection tools of this kind can help make pathology foundation models more auditable by domain experts by connecting internal features to morphological evidence rather than treating embeddings as opaque vectors. We will release Histoscope, the trained SAE, and the evaluation protocol to support expert-grounded SAE inspection in computational pathology.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
The Progress Helix Tracks Reasoning Depth in Language Models
Andrew Rufail, Andy Huang, Zarreen Reza, Henry Lue, Laurentia Liennart
Abstract
Large Language Models (LLMs) execute long chains of thought (CoT), but the mechanism by which they maintain a global sense of position within a reasoning trajectory has not been well characterized. To this point, we identify the Progress Helix: an emergent periodic trajectory in a low-dimensional latent subspace that completes exactly one revolution over a generated reasoning chain. Applying PCA and spectral analysis to activations from Llama-3, Gemma-2, and Qwen on both a controlled recursive arithmetic task and GSM8K, we recover a dominant Fourier component at fundamental frequency $k{=}1$ whose magnitude grows monotonically across layers, forming an elliptical cone in activation space. We causally validate the helix's functional role through three interventions. Substituting the natural manifold with a constant-velocity synthetic helix induces logical collapse, indicating polysemanticity with numeric content. Ablating the attention heads most responsible for the $k{=}1$ signal significantly elongates generations. Most strikingly, re-projecting activations onto a helix scaled by speed factor $\gamma$ allows targeted control over output length, with reasoning accuracy peaking at $\gamma{=}0.85$. We thus offer a spectral and topological characterization of reasoning length as a controllable helical degree of freedom in the residual stream.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
How do Small Transformer Models Learn Hard Math Tasks?
Eshika Saxena, Kristin Lauter
Abstract
Recent works have demonstrated that transformers can be trained to recover sparse, binary cryptographic secrets in the Learning With Errors (LWE) problem, a foundational problem that underlies many post-quantum cryptographic schemes. However, as architectures have evolved to efficient encoder-only models, the mechanism by which these models recover the cryptographic secret has become more opaque. In this paper, we present the first layer-wise and embedding-level mechanistic interpretability analysis of encoder-only transformers trained on LWE samples. We reveal a surprising phenomenon: despite achieving near-zero exact prediction accuracy on the training objective, the models successfully recover the secret by bypassing the standard predictive pathways. We use dimensionality reduction, causal intervention, and linear probing and find that the secret is implicitly present in the positional embedding. Building on this mechanistic understanding, we introduce an architectural intervention that applies $L_1$ sparsity regularization directly to the positional embeddings. This modification forces the model to explicitly isolate the latent secret, transforming the computationally expensive post-hoc secret recovery process into a direct, human-interpretable parameter inspection. Our findings provide fundamental insights into how transformers allocate representational capacity when faced with high-noise, structured combinatorial problems.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Reasoning aligns language models to human inference
Gonçalo Guiomar, Elia Torre, Pehuen Moure, Victoria Shavina, Mario Giulianelli, Shih-Chii Liu, Valerio Mante
Abstract
Do language models make decisions under uncertainty like humans do? And if so, what role does extended reasoning play in the underlying decision process? We answer this question by introducing an active probabilistic reasoning task that cleanly separates sampling (actively acquiring evidence) from inference (integrating evidence towards a decision). Benchmarking humans and a broad set of contemporary LLMs against optimal reference policies reveals a consistent pattern: extended reasoning is the key determinant of strong performance, driving large gains in inference, while yielding only modest improvements in active sampling. To explain these differences, we fit a behavioral model that captures systematic deviations from optimal Bayesian behavior through interpretable parameter families, placing humans and models in a shared low-dimensional cognitive space. The resulting fits show how reasoning shifts models toward human-like regimes of evidence accumulation and belief-to-choice mapping, and yield testable predictions about the latent dynamics that might drive each decision. Probing residual-stream activations of an open-weight reasoning model, we find that the geometry of internal representations tracks these predicted dynamics, linking behavior to representational correlates of the fitted latent dynamics.
Abstract source - ICML · Workshop · Workshop on Mechanistic Interpretability
Residue-Level Attributions in Protein Allergenicity Models Do Not Recover Allergen Epitopes
Jianzhou Yao, Anxiong Song, Katja Baerenfaller, Damir Zhakparov
Abstract
Deep allergenicity classifiers are increasingly used in safety screening of novel foods, and recent protein language models have substantially improved protein-level allergenicity prediction. However, whether their explanations capture biologically meaningful information remains unclear. We introduce an epitope-grounded residue-level benchmark for quantitatively evaluating attribution faithfulness in protein allergenicity models. Across frozen ESM-2, multi-task ESM-2, and DeepPlantAllergy, protein-level classification was robust, yet classification-head explanation signals did not significantly exceed random in residue-level alignment with annotated epitopes across AUROC, AUPRC, and Precision@$k$. Integrated Gradients identified residues that were functionally important to the model, but did not overlap annotated epitopes. Saturation mutagenesis further suggested that classifiers rely predominantly on physicochemical and compositional sequence features rather than epitope-specific mechanisms. Residue-level importance signals should therefore not be interpreted as immunological explanations for safety screening or hypoallergen design without quantitative validation.
Abstract source