Disentangling Representation Evolution in Transformers through Directional Decomposition

Shwai He, Haichao Zhang, Shen Yan
9/14/2026
cs.CLcs.LG

Official code: Shwai-He/Transformer-Geometry (2 stars, last commit 2026-09-15).

Abstract

Transformer representations evolve through learned additive transformations that either preserve their current direction or redirect it. We study this evolution as a functional geometry, decomposing learned updates into parallel and perpendicular components. Across pretrained models, we find substantial parallel components beyond the residual identity path. We then apply the decomposition in two spaces: to attention and MLP updates relative to the hidden state, and to attention value aggregation relative to the current token's value. Targeted edits reveal a strongly space-dependent asymmetry: exclude-self value-space parallel manipulation is markedly more robust than residual-space and perpendicular counterparts, preserving the direct self message while scaling only the non-self aggregate. The same decomposition gives a component-resolved description of compression-induced update error: perpendicular error separates compression methods more clearly than parallel error. Extensive experiments further demonstrate that full-aggregate parallel suppression during from-scratch pretraining lowers validation-loss trajectories and improves downstream averages, with the value-space variant strongest. Together, these results connect representation geometry to editing robustness, compression diagnosis, and training-time intervention. Code is available in the \href{https://github.com/Shwai-He/Transformer-Geometry}{project repository}.

View on arXivView PDF

Code Implementations(1)

[EMNLP 2026 Findings] Decomposing Transformer updates into parallel & perpendicular subspaces for geometric probing, compression, and training dynamics.

20HTML, ShellFeb 17, 20261 months ago
interpretabilitymodel-compressionrepresentation-geometrytraining-dynamicstransformers

Cite this paper

@article{he2026disentangling,
  title  = {Disentangling Representation Evolution in Transformers through Directional Decomposition},
  author = {Shwai He and Haichao Zhang and Shen Yan},
  year   = {2026},
  eprint = {2609.15975},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2609.15975v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2609.15975.svg)](https://codeofpaper.com/paper/2609.15975)

Discussion