Many-body correlations in transformer language models

Transformer language models process text through contextual token representations coupled by learned attention. We formulate a transformer context as a finite interacting many-body representation system and define correlation functions, susceptibility-like quantities, response functions, and order parameters for its hidden states. Applying these observables first to GPT-2 benchmark prompt ensembles, we find that token-token correlations develop layer-dependent nonlocal structure and that compact correlation-derived observables distinguish different prompt ensembles substantially better than simple output-level statistics. Because the benchmark ensembles differ in content and construction, we complement this result with a matched within-task comparison of correct and incorrect mathematical reasoning trajectories generated for the same underlying problems. The correlation-derived observables retain above-chance predictive information in this more stringent setting and remain informative across GPT-2, Pythia-410M, and Qwen2.5 models, although their quantitative behavior is model dependent. Perturbation experiments further exhibit an approximately linear internal response and quadratic output Kullback–Leibler divergence in the verified small-perturbation regime. The results support the use of statistical-physics observables for representation-level analysis while showing that their quantitative behavior is model dependent.

Authors

Institutions

Publication Details

Journal
Physical review. E
Published
2026-12-02
DOI
https://doi.org/10.1103/8fsv-31yp
Primary Topic
Topic Modeling
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
NOV
article

Many-body correlations in transformer language models

Houlong Zhuang
3 links
Physical review. E
Topic Modeling
article

Many-body correlations in transformer language models

Houlong Zhuang
article en

Abstract

Transformer language models process text through contextual token representations coupled by learned attention. We formulate a transformer context as a finite interacting many-body representation system and define correlation functions, susceptibility-like quantities, response functions, and order parameters for its hidden states. Applying these observables first to GPT-2 benchmark prompt ensembles, we find that token-token correlations develop layer-dependent nonlocal structure and that compact correlation-derived observables distinguish different prompt ensembles substantially better than simple output-level statistics. Because the benchmark ensembles differ in content and construction, we complement this result with a matched within-task comparison of correct and incorrect mathematical reasoning trajectories generated for the same underlying problems. The correlation-derived observables retain above-chance predictive information in this more stringent setting and remain informative across GPT-2, Pythia-410M, and Qwen2.5 models, although their quantitative behavior is model dependent. Perturbation experiments further exhibit an approximately linear internal response and quadratic output Kullback–Leibler divergence in the verified small-perturbation regime. The results support the use of statistical-physics observables for representation-level analysis while showing that their quantitative behavior is model dependent.

Physical review. EVol. 114(6)
Arizona State University (US)
Topic Modeling
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Laika access coming soon