How Syntax Specialization Emerges in Language Models

Xufeng Duan, Zhaoqian Yao, Yunhao Zhang, Shaonan Wang, Zhenguang G. Cai
5/26/2025
cs.CLcs.AI

No confident code implementation found for this paper.

Abstract

Large language models (LLMs) have been found to develop surprising internal specializations: Individual neurons, attention heads, and circuits become selectively sensitive to syntactic structure, reflecting patterns observed in the human brain. While this specialization is well-documented, how it emerges during training and what influences its development remains largely unknown.

Show full abstract

In this work, we tap into the black box of specialization by tracking its formation over time. By quantifying internal syntactic consistency across minimal pairs from various syntactic phenomena, we identify a clear developmental trajectory: Syntactic sensitivity emerges gradually, concentrates in specific layers, and exhibits a 'critical period' of rapid internal specialization. This process is consistent across architectures and initialization parameters (e.g., random seeds), and is influenced by model scale and training data. We therefore reveal not only where syntax arises in LLMs but also how some models internalize it during training. To support future research, we will release the code, models, and training checkpoints upon acceptance.

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{duan2025syntax,
  title  = {How Syntax Specialization Emerges in Language Models},
  author = {Xufeng Duan and Zhaoqian Yao and Yunhao Zhang and Shaonan Wang and Zhenguang G. Cai},
  year   = {2025},
  eprint = {2505.19548},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2505.19548v1}
}

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

Discussion