Understanding the Staged Dynamics of Transformers in Learning Latent Structure

Rohan Saha, Farzane Aminmansour, Alona Fyshe
11/24/2025
cs.LG

No confident code implementation found for this paper.

Abstract

While transformers can discover latent structure from context, the dynamics of how they acquire different components of the latent structure remain poorly understood. In this work, we use the Alchemy benchmark, to investigate the dynamics of latent structure learning. We train a small decoder-only transformer on three task variants: 1) inferring missing rules from partial contextual information, 2) composing simple rules to solve multi-step sequences, and 3) decomposing complex multi-step examples to infer intermediate steps. By factorizing each task into interpretable events, we show that the model acquires capabilities in discrete stages, first learning the coarse grained rules, before learning the complete latent structure. We also identify a crucial asymmetry, where the model can compose fundamental rules robustly, but struggles to decompose complex examples to discover the fundamental rules. These findings offer new insights into understanding how a transformer model learns latent structures, providing a granular view of how these capabilities evolve during training.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{saha2025understanding,
  title  = {Understanding the Staged Dynamics of Transformers in Learning Latent Structure},
  author = {Rohan Saha and Farzane Aminmansour and Alona Fyshe},
  year   = {2025},
  eprint = {2511.19328},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2511.19328v1}
}

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/2511.19328.svg)](https://codeofpaper.com/paper/2511.19328)

Discussion