Lost in Tokenization: Fundamental Trade-offs in Graph Tokenization for Transformers
Not on the map. Why?
Abstract (arXiv)
Transformers have become a central architecture for graph learning, but their application to graphs requires first choosing a tokenization: a graph-to-token map that determines which structural information is exposed at the input. In this work, we show that this choice is a fundamental component of transformer expressivity. We examine three tokenizations that serve as building blocks for many existing graph tokenizations: spectral, random-walk, and adjacency tokenizations. We prove that different tokenizations induce distinct depth regimes: the same graph computation may be realizable by a shallow transformer under one tokenization, while requiring substantially larger depth under another. For example, we prove that random-walk tokenization is lossy for any walk length, making it impossible in general to recover the graph from it, and that while spectral tokenization is lossless, it is ill-conditioned for local tasks. We further show that although both random-walk and spectral tokenizations are derived from adjacency information, it is impossible for a limited-depth transformer to convert between tokenization families in general. In particular, we establish lower bounds and impossibility results showing that unfavorable tokenizations may preclude the efficient recovery of more suitable structural representations. Finally, we complement our theory with controlled experiments on synthetic and real-world tasks, validating the predicted separations and showing that different tasks favor different structural views, and combining complementary tokenizations allows the transformer to leverage distinct signals from each representation.
Key facts. Cited by 2 papers in the map (data through 7 Oct 2026). Builds on 30 of its 42 references that are in the map. First posted on arXiv 21 May 2026.
Builds on
30 of 42 references.
References · 30
- 2017Graph Attention Networkscited by 8,854
- 2018How Powerful are Graph Neural Networks?cited by 4,355
- 2017Neural Message Passing for Quantum Chemistrycited by 3,460
- 2020Open Graph Benchmark: Datasets for Machine Learning on Graphscited by 2,148
- 2017Deep Setscited by 1,394
- 2016Geometric deep learning: going beyond Euclidean datacited by 1,042
- 2018Weisfeiler and Leman Go Neural: Higher-order Graph Neural Networkscited by 878
- 2021How Attentive are Graph Attention Networks?cited by 818
- 2022Recipe for a General, Powerful, Scalable Graph Transformercited by 702
- 2020Benchmarking Graph Neural Networkscited by 672
- 2020A Generalization of Transformer Networks to Graphscited by 653
- 2021Rethinking Graph Transformers with Spectral Attentioncited by 468
18 more
- 2019Are Transformers universal approximators of sequence-to-sequence functions?cited by 404
- 2021Graph Neural Networks with Learnable Structural and Positional Representationscited by 326
- 2022Transformers Learn Shortcuts to Automatacited by 260
- 2020Can Graph Neural Networks Count Substructures?cited by 235
- 2019What graph neural networks cannot learn: depth vs widthcited by 195
- 2022The Parallelism Tradeoff: Limitations of Log-Precision Transformerscited by 191
- 2020Graph-Bert: Only Attention is Needed for Learning Graph Representationscited by 176
- 2022Sign and Basis Invariant Networks for Spectral Graph Representation Learningcited by 176
- 2023Talk like a Graph: Encoding Graphs for Large Language Modelscited by 175
- 2023Graph Inductive Biases in Transformers without Message Passingcited by 150
- 2021Saturated Transformers are Constant-Depth Threshold Circuitscited by 137
- 2023Representational Strengths and Limitations of Transformerscited by 132
- 2021Statistically Meaningful Approximation: a Case Study on Approximating Turing Machines with Transformerscited by 101
- 2022Formal Language Recognition by Hard Attention Transformers: Perspectives from Circuit Complexitycited by 92
- 2024Transformers, parallel computation, and logarithmic depthcited by 75
- 2023Auto-Regressive Next-Token Predictors are Universal Learnerscited by 65
- 2024Understanding Transformer Reasoning Capabilities via Graph Algorithmscited by 64
- 2025Depth-Width tradeoffs in Algorithmic Reasoning of Graph Tasks with Transformerscited by 11
Built on by
Citing papers per year: 2026: 2.
2 papers.