Abstract
Identifying feature representations in language models is a central task in mechanistic interpretability. Several recent studies have made an implicit assumption that feature representations can be inferred in some cases from singular vectors of attention matrices. However, sound justification for this assumption is lacking. In this paper we address that question, asking: why and when do singular vectors align with features? First, we demonstrate that singular vectors robustly align with features in a model where features can be directly observed. We then show theoretically that such alignment is expected under a range of conditions. We close by asking how, operationally, alignment may be recognized in real models where feature representations are not directly observable. We identify sparse attention decomposition as a testable prediction of alignment, and show evidence that it emerges in a manner consistent with predictions in real models. Together these results suggest that alignment of singular vectors with features can be a sound and theoretically justified basis for feature identification in language models.
Introduction
A central goal in mechanistic interpretability is to decode the "black box" of Large Language Models (LLMs). The Linear Representation Hypothesis posits that semantic concepts, or features, are represented as specific directions within a high-dimensional vector space. Recent empirical observations have suggested that these features often align with the singular vectors of attention head matrices (specifically $W_Q^T W_K$). However, until now, a rigorous theoretical explanation for this phenomenon has been missing. This paper provides the first formal justification for why and when singular vectors align with features (SVF alignment), offering a theoretically grounded framework for feature identification.
Methods
The researchers employed a multi-faceted approach to investigate SVF alignment:
- Toy Models of Superposition: Building on the work of Elhage et al., the authors utilized toy models with trainable attention heads. This setup allows for the direct observation of ground-truth features alongside the model's singular vectors, enabling a clear measurement of alignment during the training process.
- Mathematical Formalization: The authors derived four theorems proving that alignment is a natural consequence of optimization. Specifically, they demonstrated that if features are "isotropic" (uniformly distributed), the principal singular vectors will converge toward the feature directions the head is optimized to attend to.
- Sparse Attention Decomposition (SAD): To bridge the gap between toy models and real-world LLMs where ground-truth features are unknown, the authors introduced SAD. This metric serves as a proxy for alignment: if singular vectors align with features, the attention signal should exhibit sparsity when decomposed into its singular vector components.
Key Insights: Alignment as Optimization
The core finding is that SVF alignment is not an accidental byproduct but an outcome of optimization for interference minimization. To accurately attend to specific feature pairs, a model naturally aligns its weights with those feature directions to reduce noise from unrelated features.
Interestingly, this alignment is a bidirectional process. Not only do singular vectors move toward features, but features themselves tend to "orthogonalize"—moving away from one another—to better fit the singular vector basis and minimize reconstruction error. Furthermore, the authors found that in real models, the most significant contributions to attention often stem from singular vectors with smaller singular values, challenging the common assumption that only the top singular values are relevant.
Results and Empirical Evidence
The study yielded several key results across synthetic and real-world datasets:
- Robustness in Toy Models: SVF alignment was found to be highly robust, with cosine similarities reaching near 1.0 across various hyperparameters, including different feature probabilities and head dimensions.
- Emergence During Training: Analysis of Pythia-160M revealed that attention signals, initially noisy, become significantly sparser in the SVD basis as training progresses. This suggests that alignment is a learned efficiency.
- Low-Dimensionality in GPT-2: In GPT-2 Small, many critical attention heads (analyzed using the Indirect Object Identification (IOI) task) required only 1 to 4 singular vectors to reconstruct the bulk of the attention signal, confirming that these heads focus on a very narrow set of linear features.
Limitations and Future Directions
While the results are compelling, some limitations remain. The current theory assumes feature isotropy; in practice, features may be anisotropic (clustered), which could bias singular vectors toward these "cone directions." Additionally, when a head's feature capacity is exceeded (more features than dimensions), alignment can degrade as features "pile up" on smaller singular vectors. Future research will explore how multiple attention heads coordinate their singular vector vocabularies to perform more complex, multi-step reasoning tasks.
Summary updated