REVIEW 5 major objections 4 minor 2 cited by
Transformers as Unrolled Inference in Probabilistic Laplacian Eigenmaps: An Interpretation and Potential Improvements
T0 review · 5 major / 4 minor · reviewed 2026-08-06 · deepseek-v4-flash
Pith's one-line read Transformer blocks can be read as unrolled inference in a probabilistic Laplacian Eigenmaps model, so the attention matrix should really be a graph Laplacian $A-I$, and swapping it in improves validation performance and training speed.
desk verdict The A-I attention tweak is worth a serious test, but the paper's derivation has a load-bearing flaw: with row-softmax, I-A is non-symmetric, so the A-I update is not the ELBO gradient. read the letter →
The pith
A machine-rendered reading of the paper's core claim, the machinery that carries it, and where it could break.
The reading
What carries the argument
The load-bearing object is the variational Laplacian Eigenmaps objective $KL(q(\Gamma,Z)\|p(\Gamma,Z)) \propto \mathrm{tr}(\tilde L(XX^T+\beta I)) - \log\det(XX^T+\beta I)$, with the variational constraint $\tilde L = I - \sigma(\kappa ZZ^T - M)$ treated as an observed random variable (stop-gradient). Gradient descent on the first term produces the update $X \leftarrow X + 2\eta(\sigma(\kappa XX^T - \beta I - M)-I)X$, whose parenthesised factor is the graph Laplacian $A-I$; the second term plus a uniform-matrix prior yields the linear feed-forward update and LayerNorm projection. This $A-I$ identity is what carries the argument: it turns the attention matrix into a diffusion operator and is precisely the modification tested in the experiments.
What would settle it
Compute or numerically approximate the full gradient of the variational objective including the derivative of $\sigma(\kappa XX^T-M)$ with respect to $X$ (without stop-gradient) and check whether the resulting update is still proportional to $(A-I)X$ plus only negligible corrections. If the extra terms are not negligible, the paper's central interpretive claim fails at its stated assumption.
Extended reading notes
Core claim
At initialisation, with weights set to diagonal matrices, a transformer block performs gradient descent on the KL divergence between a variational Wishart distribution whose constraint is a soft nearest-neighbour graph Laplacian $\tilde L = I - \sigma(\kappa ZZ^T - M)$ and a model Wishart distribution over the same precision matrix. Because the derivative of the data term is $d\,\mathrm{tr}(\tilde L(XX^T+\beta I))/dX = 2\tilde L X = 2(A-I)X$, the attention operation should be the negative graph Laplacian $A-I$, i.e. a Laplacian-smoothing or graph-diffusion step, not the raw attention matrix. The paper then shows empirically that replacing the attention matrix by $A-I$ improves validation performance on Shakespeare-character and downsampled ImageNet transformers and makes GPT-2 training converge faster.
Load-bearing premise
The derivation treats the softmax attention matrix as a fixed, observed object when computing gradients, so the dependence of the attention matrix on the latent vectors $X$ is ignored; if that dependence were included, the update would acquire extra terms and the clean $A-I$ form would no longer follow.
Editorial extensions
If this is right
- If transformer blocks are unrolled Laplacian Eigenmaps inference, then at initialisation a randomly initialised transformer performs linear dimensionality reduction and clustering of token or patch representations, as shown on MNIST.
- The attention matrix should be read as an adjacency matrix, and graph diffusion ($A-I$) is a principled replacement for raw attention; the paper reports consistent validation gains on language and vision.
- Training a GPT-2-scale model with the $A-I$ modification converges slightly faster than the vanilla attention run.
- The weight matrices in a transformer can be interpreted as rotation and learning-rate (step-size) parameters, giving a concrete 'learn to optimise' story for the architecture.
- The same derivation can be extended to kernelised dimensionality-reduction objectives, which the authors suggest as future work; if that holds, further non-linear graph-diffusion updates may improve low-dimensional models.
Reading between the lines
- If the $A-I$ result is robust, it suggests that part of attention's value is implicit Laplacian smoothing, so other graph-regularisation terms (degree normalisation, higher-order diffusion) may yield further gains; this is not tested in the paper.
- The stop-gradient assumption is the likely breaking point: relaxing it would couple attention to the update and may change the architecture, so a natural extension is to train with the full gradient and compare.
- The derivation may transfer to other attention-based architectures (e.g. cross-attention, multi-head with product-of-experts) even though the paper only analyses single-head self-attention at initialisation.
- The MNIST clustering result suggests a possible diagnostic: check whether the $A-I$ modification tightens class-cluster structure in deeper layers; the paper does not report this.
Editorial analysis
A structured set of objections, weighed in public.
Referee Report
Summary. The paper proposes a probabilistic interpretation of transformer blocks as unrolled inference steps in a probabilistic Laplacian Eigenmaps model from the ProbDR framework. The authors argue that, at initialization, a transformer block corresponds to gradient descent on a variational lower bound, and that this derivation yields a graph Laplacian term A-I in place of the standard attention matrix A. They test the A-I modification on a language model and a vision transformer, reporting improved validation performance and faster convergence. The manuscript also includes a qualitative experiment showing that a randomly initialized transformer clusters MNIST digits in its latent space.
Significance. If the derivation were correct, the paper would offer a novel probabilistic grounding for the transformer architecture and a simple, broadly applicable architectural modification with empirical support. The paper is transparent about two key approximations (the stop-grad treatment of the variational constraint and the replacement of the regularizer gradient by a linear term), which is commendable. The empirical finding that subtracting the identity from the attention matrix improves performance is interesting even independently of the theory, and the MNIST clustering experiment provides a concrete, falsifiable illustration. However, the central derivation contains a load-bearing algebraic error regarding the gradient of a non-symmetric quadratic form, and the experiments lack statistical rigor (no seeds, no error bars). The paper does not provide code or machine-checked proofs, so the empirical claims rest on the reported figures alone.
major comments (5)
- [Section 3, derivative of Ldata] The equation dL/dX = 2 L X is incorrect for the non-symmetric matrix L = I - A. Because A = softmax(κ Z Z^T - M) is applied row-wise, A is generally not symmetric, so L is not symmetric. For a constant non-symmetric L, the derivative of tr(L X X^T) with respect to X is (L + L^T)X, not 2 L X. Consequently, the update X <- X + 2η(A - I)X is not the gradient-descent step of the stated ELBO, even under the paper's explicit stop-grad treatment. The correct update would involve (A + A^T)/2 - I, which is not what is implemented or tested in the experiments. This error undermines the central claim that the A-I form follows from unrolled inference.
- [Section 3, variational constraint and Wishart validity] The matrix L = I - A with row-stochastic softmax A is not a graph Laplacian in the sense required by the ProbDR model: it is non-symmetric and generally not positive semidefinite. A Wishart distribution W(Γ | L, d) is defined only for a positive definite scale matrix, so the variational distribution q(Γ, Z) = W(Γ | L(Z), d) is not a valid distribution for arbitrary Z. The paper should either symmetrize the Laplacian (e.g., L_sym = I - (A + A^T)/2) or justify the use of a non-PSD scale matrix. This is load-bearing because the entire ELBO simplification depends on the Wishart form.
- [Section 3, stop-grad on the variational constraint] The paper states, 'we treat the variational constraint as an observed random variable, and hence do not account for gradient updates to terms leading from the variational constraint.' This is a significant and nonstandard assumption. If the dependence of A on X were included in the gradient, the update would contain additional terms and the clean A-I form would not follow. The SimSiam analogy is not a sufficient justification, since stop-grad in SimSiam is an algorithmic design choice rather than a consequence of the probabilistic model. The assumption should be empirically tested, for example by comparing the proposed update with the full-gradient update on a small task.
- [Section 3, approximation of the regularizer gradient] The replacement dLreg/dX = 2(XX^T + βI)^{-1}X ≈ 2/(dq + β) X is stated without derivation or numerical verification. This approximation is used to argue that the feed-forward block corresponds to a gradient step, but the error in this approximation could be large, especially at initialization when XX^T may not be close to a scaled identity. The paper should either justify this approximation analytically (e.g., under the assumed initialization) or demonstrate empirically that it does not affect the qualitative conclusions.
- [Section 4, experimental methodology] The empirical claims rest on single runs with no reported seeds, error bars, or statistical significance. Section 4.2 says the model was 'run multiple times' but does not report the number of runs or the variance; Figure 3 appears to show a single comparison between two runs. Given the small performance differences, the claim that the A-I modification 'consistently' improves performance is not supported. The authors should report multiple seeds, mean and variance, and ideally a significance test for the language and vision experiments.
minor comments (4)
- [Section 4.1, Figure 1] The claim that 'transformer blocks cluster points in the latent space' is supported only by a qualitative plot of the first two latent dimensions. The paper should provide a quantitative clustering metric (e.g., silhouette score or purity) to make the dimensionality-reduction claim more precise.
- [Section 4.1, initialization details] The sentence 'The query and key matrices were set up such that the attention matrix, pre-normalisation, has a diagonal equal to κ' is ambiguous: the softmax output is non-negative, but the pre-softmax scores have diagonal κ. Please clarify whether κ refers to the pre-softmax or post-softmax diagonal.
- [Section 3, notation] The notation is inconsistent: sometimes the graph Laplacian is written as L(Y) based on data Y, and later as L(Z) based on latent Z. Please use distinct symbols or clarify the dependence to avoid confusion.
- [General, color-dependent text] The manuscript refers to 'the element highlighted in red' in equations, but the color is not visible in a black-and-white printout. Please use a symbol or footnote instead.
Circularity Check
The claimed derivation of the A−I graph-diffusion step is self-definitional: the variational graph Laplacian is defined as I−A, so the A−I update is an input assumption read back out as a result, while the empirical benchmarks remain independent evidence.
-
self definitional
[Section 3, definition of the variational graph Laplacian and the gradient update]
"The graph Laplacian is computed as L = I - A(Z) = I - σ(κZZ^T - M) where σ is the softmax function, applied row-wise (so that the row sums of the input matrix all equal one). ... dL/dX = 2 L X = 2(A - I), and a gradient descent update ... X ← X + 2η(σ(κXX^T - βI - M) - I)X."
The central interpretive conclusion — that a graph Laplacian term (A−I) 'arises from our arguments' — holds only because the variational constraint was defined with L = I − A, where A is the softmax attention matrix. Substituting that definition into the objective yields the A−I update immediately; no step produces A−I from the ProbDR model alone. The attention matrix is inserted into the variational constraint as a modeling choice, so the proposed architectural modification is equivalent to that choice by construction, not a first-principles prediction. The empirical improvements are independent evidence, but the derivation's claim to explain why A−I works restates its own ansatz.
full rationale
The paper is not wholly circular: the language and vision experiments (Shakespeare, downsampled ImageNet, GPT-2) provide external evidence that replacing attention A with A−I helps, and those results stand independently of the derivation. The self-citations to Ravuri et al. (2023) and Ravuri & Lawrence (2024) are not themselves load-bearing in a circular way; the ProbDR model is a starting point, not a conclusion, and the closed-form eigenvector claims rest on standard linear algebra. However, the central interpretive claim is circular by construction. The variational graph Laplacian is defined as I − A with A the row-wise softmax attention matrix, and the paper then reports that a graph Laplacian (equivalently A−I) 'arises from our arguments.' This is an assumption unfolded into a gradient update, not a derived prediction. For completeness, note a separate correctness problem: for a non-symmetric row-stochastic A, the derivative of tr((I−A)XX^T) is (2I−A−A^T)X, not 2(I−A)X, so even under the paper's stop-grad treatment of the variational constraint the displayed gradient update is algebraically wrong (and the sign of L is also flipped between L=I−A and dL/dX=2(A−I)). That is a mathematical error rather than a circularity, but it reinforces that the A−I modification is not an inevitable consequence of the stated ELBO. On balance, the interpretive derivation reduces to its own definition, giving a partial circularity score of 6, while the empirical component keeps the paper from being entirely vacuous.
Assumptions & free parameters
free parameters (5)
- kappa (κ) =
30
- beta (β) =
not specified
- eta (η) =
0.4
- dq (latent dimension) =
128
- M (mask matrix) =
not specified
assumptions (5)
- domain assumption Probabilistic Laplacian Eigenmaps model with Wishart prior, from Ravuri et al. (2023)
- ad hoc to paper Softmax row-wise output is a soft proxy for the nearest-neighbour adjacency matrix
- ad hoc to paper Stop-grad on the variational constraint, treating the attention matrix as constant
- ad hoc to paper Approximation dLreg/dX ≈ 2/(dq+β)X
- domain assumption Analysis restricted to initialization with diagonal weights, single head, and no ReLU
Cite this review
Pith. "Pith review of Transformers as Unrolled Inference in Probabilistic Laplacian Eigenmaps: An Interpretation and Potential Improvements." pith.science (2026). https://pith.science/paper/CKP6MGX2
@misc{pith2026250721040,
author = {Pith},
title = {Pith review of: Transformers as Unrolled Inference in Probabilistic Laplacian Eigenmaps: An Interpretation and Potential Improvements},
year = {2026},
howpublished = {\url{https://pith.science/paper/CKP6MGX2}},
note = {Machine review of arXiv:2507.21040}
}
read the original abstract
We propose a probabilistic interpretation of transformers as unrolled inference steps assuming a probabilistic Laplacian Eigenmaps model from the ProbDR framework. Our derivation shows that at initialisation, transformers perform "linear" dimensionality reduction. We also show that within the transformer block, a graph Laplacian term arises from our arguments, rather than an attention matrix (which we interpret as an adjacency matrix). We demonstrate that simply subtracting the identity from the attention matrix (and thereby taking a graph diffusion step) improves validation performance on a language model and a simple vision transformer.
Figures
Forward citations
Cited by 2 Pith papers
-
Revisiting Transformer Layer Parameterization Through Causal Energy Minimization
CEM recasts Transformer layers as energy minimization steps, enabling constrained parameterizations like weight sharing and low-rank interactions that match standard baselines in 100M-scale language modeling.
-
Uncovering and Shaping the Latent Representation of 3D Scene Topology in Vision-Language Models
VLMs possess a latent 3D scene topology subspace corresponding to Laplacian eigenmaps that can be causally shaped via Dirichlet energy regularization to improve spatial task performance by up to 12.1%.
Reference graph
Works this paper leans on
-
[3]
Learning to Optimize: A Primer and A Benchmark
URLhttps://arxiv.org/abs/2103.12828. Xinlei Chen and Kaiming He. Exploring simple siamese representation learning,
-
[4]
URLhttps://arxiv. org/abs/2011.10566. Jeongwhan Choi, Hyowon Wi, Jayoung Kim, Yehjin Shin, Kookjin Lee, Nathaniel Trask, and Noseong Park. Graph convolutions enrich the self-attention in transformers!,
arXiv 2011
-
[7]
Aaron Gokaslan, Vanya Cohen, Ellie Pavlick, and Stefanie Tellex
URL https://arxiv.org/abs/2010.11929. Aaron Gokaslan, Vanya Cohen, Ellie Pavlick, and Stefanie Tellex. Openwebtext corpus. http:// Skylion007.github.io/OpenWebTextCorpus,
arXiv 2010
-
[8]
Hiroki Nakamura, Masashi Okada, and Tadahiro Taniguchi
URL https://arxiv.org/abs/1609.02907. Hiroki Nakamura, Masashi Okada, and Tadahiro Taniguchi. Representation uncertainty in self-supervised learning as variational inference. InProceedings of the IEEE/CVF International Conference on Computer Vision, pp. 16484–16493,
-
[12]
Petar Veličković, Guillem Cucurull, Arantxa Casanova, Adriana Romero, Pietro Liò, and Yoshua Bengio
URL https://proceedings.neurips.cc/paper_files/paper/ 2017/file/3f5ee243547dee91fbd053c1c4a845aa-Paper.pdf. Petar Veličković, Guillem Cucurull, Arantxa Casanova, Adriana Romero, Pietro Liò, and Yoshua Bengio. Graph attention networks,
work page 2017
-
[14]
Yaodong Yu, Sam Buchanan, Druv Pai, Tianzhe Chu, Ziyang Wu, Shengbang Tong, Benjamin D
URL https://lilianweng.github.io/ posts/2018-06-24-attention/. Yaodong Yu, Sam Buchanan, Druv Pai, Tianzhe Chu, Ziyang Wu, Shengbang Tong, Benjamin D. Haeffele, and Yi Ma. White-box transformers via sparse rate reduction,
work page 2018
-
[15]
URL https://arxiv.org/abs/ 2306.01129. 8
-
[2015]
doi: 10.1007/s11263-015-0816-y
ISSN 1573-1405. doi: 10.1007/s11263-015-0816-y. URL https://doi.org/10.1007/s11263-015-0816-y. Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. In I. Guyon, U. Von Luxburg, S. Bengio, H. Wallach, R. Fergus, S. Vishwanathan, and R. Garnett (eds.),Advances...
Show all 15 references
-
[2017]
JacobDevlin, Ming-WeiChang, KentonLee, andKristinaToutanova
URLhttps://arxiv.org/abs/1707.08819. JacobDevlin, Ming-WeiChang, KentonLee, andKristinaToutanova. Bert: Pre-trainingofdeepbidirectional transformers for language understanding,
-
[2018]
Lilian Weng
URLhttps://arxiv.org/abs/1710.10903. Lilian Weng. Attention? attention! lilianweng.github.io,
-
[2019]
URLhttps://arxiv.org/abs/1810.04805. Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Un- terthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, Jakob Uszkoreit, and Neil Houlsby. An image is worth 16x16 words...
-
[2020]
Hila Chefer, Shir Gur, and Lior Wolf
URLhttps://arxiv.org/abs/2006.11477. Hila Chefer, Shir Gur, and Lior Wolf. Transformer interpretability beyond attention visualization,
2006 arXiv
-
[2021]
Tianlong Chen, Xiaohan Chen, Wuyang Chen, Howard Heaton, Jialin Liu, Zhangyang Wang, and Wotao Yin
URL https://arxiv.org/abs/2012.09838. Tianlong Chen, Xiaohan Chen, Wuyang Chen, Howard Heaton, Jialin Liu, Zhangyang Wang, and Wotao Yin. Learning to optimize: A primer and a benchmark,
2012 arXiv
-
[2023]
7 Under review
URL https://arxiv.org/pdf/2304.07658.pdf. 7 Under review. Olga Russakovsky, Jia Deng, Hao Su, Jonathan Krause, Sanjeev Satheesh, Sean Ma, Zhiheng Huang, Andrej Karpathy, Aditya Khosla, Michael Bernstein, Alexander C. Berg, and Li Fei-Fei. Imagenet large scale visual recognitio...
-
[2024]
Aditya Ravuri, Francisco Vargas, Vidhi Lalchand, and Neil D Lawrence
URLhttps://arxiv.org/abs/2405.17412. Aditya Ravuri, Francisco Vargas, Vidhi Lalchand, and Neil D Lawrence. Dimensionality reduction as prob- abilistic inference. In Fifth Symposium on Advances in Approximate Bayesian Inference ,
Reviewed August 6, 2026 · model on record in the stance chip above.
Discussion (0). Sign in to comment.