Kinetic theory for Transformers and the lost-in-the-middle phenomenon
Duerinckx, Mitia, Geshkovski, Borjan, Rossi, Stefano
–arXiv.org Artificial Intelligence
We study causal self-attention dynamics--a toy model for decoder Transformers--which we interpret as a non-exchangeable interacting particle system. By a cumulant expansion adapted to the triangular causal dependency structure of the model, combined with Glauber-calculus estimates on higher-order correlations, we prove a quantitative mean-field limit result and a next-order characterization of correlations. For iid uniformly distributed tokens, the limiting correlation equation can be solved in closed form, yielding a rigorous explanation of the empirically observed lost-in-the-middle phenomenon: the token retrieval profile, as a function of the source position in the prompt, is U-shaped, with primacy, recency, and a unique interior minimum under an explicit smallness condition. Crucially, the dependence on the source position is invisible at mean-field order and only emerges through the leading O(N 1) correlations.
arXiv.org Artificial Intelligence
Oct-22-2026