cs.LGAug 3, 2026

When Should Graph Attention Be Sparse? Learning a Per-Edge Tsallis Index

Authors: Kleyton da CostaBernardo Modenesi

Organizations: University College London & Holistic AI · University of Utah

Abstract

Graph attention normalizes neighborhood scores with softmax, the maximum-entropy choice under Shannon statistics. But homophilic and heterophilic graphs want different attention shapes, and one fixed normalization cannot serve both. We propose \textbf{LTGA} (\textbf{L}earnable \textbf{T}sallis \textbf{G}raph \textbf{A}ttention), a graph attention layer whose Tsallis entropic index qq is learned jointly with the weights, interpolating continuously between heavy-tailed (q ⁣< ⁣1q\!<\!1), softmax (q ⁣= ⁣1q\!=\!1) and compact-support (q ⁣> ⁣1q\!>\!1) attention at four granularities from a global scalar to a per-edge index, under a bounded reparameterization that starts every model at the GAT baseline. Across eight benchmarks at ten seeds, LTGA-Edge takes the best average rank (2.752.75), but the omnibus test does not reject (p ⁣= ⁣0.199p\!=\!0.199) and learning qq does not beat searching it: a validation-tuned frozen grid reaches 61.4%61.4\%, tuned αα-entmax 62.2%62.2\% and a capacity-matched q ⁣ ⁣1q\!\equiv\!1 control 62.0%62.0\%, against 61.7%61.7\% for LTGA-Edge. What the learned index buys is one run instead of a grid, and an interpretable mechanism: where qq leaves 11, it prunes 42%42\% of attention coefficients to exactly zero, and those edges are selectively the wrong ones, restoring them costs 7.17.1 points, while random pruning at the same rate costs 13.013.0 more. Project page: https://kleyt0n.github.io/ltga

Explore similar work

May 28, 2026cs.LG

Gated Graph Attention Networks with Learnable Temperature

Graph attention networks learn neighbor importance through data-dependent coefficients, but standard layers lack explicit control over unreliable feature dimensions and use fixed sharpness of attention coefficient distributions. This paper proposes gated graph attention and learnable temperature for common graph attention mechanisms. Gated graph attention filters feature or message responses to reduce the influence of unreliable dimensions, while learnable temperature dynamically adjusts the sharpness of the attention coefficient distribution. Experiments on homogeneous and heterophilic heterogeneous benchmarks show that the proposed variants consistently improve the corresponding graph attention backbones, and controlled noise studies further verify their behavior under feature perturbations. Theoretical analysis explains these results by showing that gating improves robustness when only part of the feature coordinates are reliable, while temperature is beneficial when global noise weakens the discriminability of node features.
Zhongtian Ma, Hao Wu, Yexin Zhang +2
Jun 14, 2026cs.LG

Formalizing and Mitigating Structural Distortion in LLM Attention for Graph Reasoning

Large Language Models (LLMs) have shown promise for reasoning over Text-Attributed Graphs (TAGs). However, applying LLMs to graphs requires linearizing their structure into sequences, introducing distortion rooted in the graph bandwidth problem. While this distortion has been shown to degrade performance, it is often attributed to prompt design or model scale, leaving the underlying mechanism unclear. In this work, we show \textit{how} rotary positional embeddings turn graph linearization into bandwidth-dependent attention decay, suppressing attention between graph-adjacent nodes that are forced far apart in the serialized sequence. This shifts the focus of LLM-based graph reasoning from prompt engineering and scaling toward correcting attention misalignment. Motivated by this analysis, we propose \textbf{G}raph-\textbf{a}ligned \textbf{L}anguage \textbf{A}ttention (\textbf{GaLA}), a lightweight, inference-time modification for LLMs. GaLA biases attention toward graph-adjacent nodes while preserving the LLM's sequential inductive biases. Across TAG benchmarks, GaLA improves performance with negligible overhead, demonstrating that distortion is a correctable bottleneck in LLM-based graph reasoning.
Donald Loveland, Puja Trivedi, Ari Weinstein +2
May 11, 2026cs.LG

Teaching LLMs to See Graphs: Unifying Text and Structural Reasoning

Using Large Language Models (LLMs) to process graph-structured data is an active research area, yet current state-of-the-art approaches typically rely on multi-step pipelines with Graph Neural Network (GNN) encoders that compress rich textual attributes into solitary tokens, creating a significant semantic bottleneck. In this paper, we introduce the Graph Transformer Language Model (GTLM), a novel architecture that enables pretrained LLMs to natively process graph topologies while entirely eliminating this compressive bottleneck. GTLM is exceptionally parameter-efficient: by injecting graph-aware attention biases directly into the LLM's attention modules, it introduces only 0.015% additional parameters relative to the base model. We theoretically prove that our bidirectional attention prefix preserves node permutation equivariance while maintaining exact backward compatibility with the pretrained base model. Extensive evaluations demonstrate that a 1B-parameter GTLM matches or exceeds the performance of 7B-parameter state-of-the-art models on standard Text-Attributed Graph benchmarks, while significantly surpassing baselines on GraphQA. Finally, we demonstrate that GTLM attention heads implicitly learn to simulate message passing, explaining its superior performance on algorithmic tasks. This paradigm shift enables true algorithmic reasoning within LLMs and provides a scalable foundation for next-generation GraphRAG and relational deep learning.
Dario Vajda