A phase diagram for training and inference in language models
Zhuo-Yang Song, Zeyu Li, Qing-Hong Cao, Ming-xing Luo, Hua Xing Zhu
Abstract
A language model is a complex system whose behavior is determined jointly by the Transformer and the corpus, yet how the representation geometry in the Transformer relates to the actual behavior of language models remains open. We analyze how the representation geometry changes along the forward propagation of actual language models and characterize the representation geometry of a document at a given layer by two collective coordinates, document distinguishability and document dimension. On the phase diagram spanned by these collective coordinates, inference is represented as a flow along depth. We find that, for untrained models, depending on their initialization scale, most of the 156 inference flows move toward the collapse and noise regions of the phase diagram. By contrast, the inference flows of 8 trained models from 5 architecture families all enter and reside in the central region of the phase diagram. Describing the evolution of the flows with a discrete Langevin equation, we find that the difference between the inference flows of untrained runs and those of trained models reduces to whether the effective force on the flows in this region is of saddle or stable-node type. On Pythia-1.4B, we interpret the training process as a phase transition. These results give a unified gateway to the relation between representation geometry and language-model behavior.
Create a lesson
Related papers
Hybrid Quantum Selection of Learning Rates in Language-Model Training: Termination Criteria and an Interaction-Guided Schedule Oracle
Shared title terminology · Wei-Che Hung
Well-Log Reconstruction with Pre-trained Geological Knowledge: A Knowledge-Conditioned Large-Language-Model Generative Agent
Shared title terminology · Yongan Zhang, Yitao Yu, Yizheng Li et al.
Revealing the Biases of Large Language Models By Inferring Prior Distributions
Shared title terminology · Joshua Ryo Cheng, Thomas L. Griffiths, Jake C. Snell
Learning When to Ask: Advisor-Aware Post-Training for SLM Agents
Shared title terminology · Aasheesh Singh, Vishal Vaddina
THRIFTY: Cost-Constrained Reasoning-Data Synthesis for Small Language Models
Shared title terminology · Aasheesh Singh, Vishal Vaddina
Degradation of Language Models under Controlled Load: Synchronization, Rule Execution and Misfires on the Background
Shared title terminology · Hennadii Kutomanov