Graph External Attention Enhanced Transformer
Jianqing Liang, Min Chen, Jiye Liang
TL;DR
This work addresses the limitation of graph representations that rely solely on intra-graph information by introducing Graph External Attention (GEA) to capture inter-graph correlations through external key-value units. It then presents Graph External Attention Enhanced Transformer (GEAET), which combines GEANet with a graph embedding layer, a message-passing GNN, and a Transformer to integrate inter-graph, local, and global information, achieving state-of-the-art results on diverse benchmarks. Empirically, GEANet improves several GNN baselines, offers interpretable attention patterns that highlight cross-graph structure, and demonstrates reduced reliance on positional encodings compared to traditional self-attention. The approach provides scalable, flexible graph representations with practical impact for tasks requiring long-range dependencies and cross-graph reasoning, while acknowledging trade-offs in memory and computational cost that motivate future refinements.
Abstract
The Transformer architecture has recently gained considerable attention in the field of graph representation learning, as it naturally overcomes several limitations of Graph Neural Networks (GNNs) with customized attention mechanisms or positional and structural encodings. Despite making some progress, existing works tend to overlook external information of graphs, specifically the correlation between graphs. Intuitively, graphs with similar structures should have similar representations. Therefore, we propose Graph External Attention (GEA) -- a novel attention mechanism that leverages multiple external node/edge key-value units to capture inter-graph correlations implicitly. On this basis, we design an effective architecture called Graph External Attention Enhanced Transformer (GEAET), which integrates local structure and global interaction information for more comprehensive graph representations. Extensive experiments on benchmark datasets demonstrate that GEAET achieves state-of-the-art empirical performance. The source code is available for reproducibility at: https://github.com/icm1018/GEAET.
