When Structure Doesn't Help: LLMs Do Not Read Text-Attributed Graphs as Effectively as We Expected

Haotian Xu, Yuning You, Tengfei Ma · DOI

Executive Summary

In the evolving landscape of graph machine learning, the integration of Large Language Models (LLMs) has led to the creation of "Graph Foundation Models." The prevailing assumption has been that explicit structural information—the topology of connections—is essential for these models to reason effectively. However, this research reveals a surprising counter-narrative: for many current benchmarks, "semantics is all you need." LLMs often perform as well, or even better, using only node text attributes, suggesting that complex structural encodings may provide marginal or even negative utility.

Methodology: Stress-Testing Structural Encodings

The researchers conducted a systematic evaluation of two primary paradigms for injecting graph structure into LLMs:

  1. Template-Based Encoding (LLaGA style): This method converts a node and its neighborhood into a text sequence. The study compared a complex "Neighborhood Detail" (ND) template, utilizing Laplacian positional encodings, against structure-agnostic baselines like "Center Only" (CO), which ignores the graph entirely.
  2. GNN-Based Encoding (GraphToken style): This approach uses a Graph Neural Network (GNN) to encode the graph into "soft tokens." To isolate the GNN's impact, the authors replaced it with a simple Multi-Layer Perceptron (MLP) adapter that treats nodes as an unordered set.
Comparison of template-based node sequences and GNN-based soft token encoding strategies.

The integration of these graph representations into the LLM is typically handled via an adapter layer, which maps the graph features into the LLM's embedding space.

Architecture of the GraphToken framework, showing the adapter's role in integrating graph data into a frozen LLM.

Experimental Setup and Datasets

The study spanned a diverse range of Text-Attributed Graphs (TAGs), including homophilic datasets (Cora, Citeseer) and heterophilic datasets (School, Roman Empire). It also extended to molecular graphs (BACE, BBBP, HIV) and Geometric Deep Learning settings to test if structural importance varies when the topology is intrinsic to the data rather than just a citation link.

Key Findings: The "Structure Tax"

The results challenge the core tenets of graph representation learning:

  • The "Center Only" Surprise: On heterophilic datasets like School, the "Center Only" approach—which completely ignores neighbors—outperformed complex structural templates by a staggering 24.7% (91.13% vs 66.43%).
  • MLP vs. GNN Parity: In the GraphToken framework, replacing a GNN with a simple MLP adapter resulted in the highest average performance across all datasets (76.26% for node classification).
  • Molecular Parity: Even in molecular domains, a simple MLP head on node embeddings achieved 96.85% accuracy on the HIV dataset, matching the performance of sophisticated GNNs like GIN and GAT.
  • LLMs as Unordered Set Readers: The evidence suggests LLMs process graph inputs more like a "bag of nodes." When node semantics are rich, the model infers necessary context from text rather than topology.

Discussion and Future Directions

The authors suggest that current findings may be a byproduct of existing benchmarks that do not strictly require relational reasoning. Future work must focus on:

  • Structure-Essential Benchmarks: Developing tasks that cannot be solved by node text alone.
  • Effective Node Sequencing: Exploring how the ordering of nodes in a prompt (e.g., using Graph Diffusion Convolution) impacts reasoning.
  • Alignment: Improving the alignment between LLM attention mechanisms and actual graph connectivity, rather than just "shoving" graph data into the input.

Ultimately, this research serves as a call to move beyond the blind injection of structure into LLMs and instead focus on meaningful semantic-topological integration.

Summary updated

BibTeX
@inproceedings{xu2025when,
  author = {Haotian Xu and Yuning You and Tengfei Ma},
  title = {{When Structure Doesn't Help: LLMs Do Not Read Text-Attributed Graphs as Effectively as We Expected}},
  booktitle = {LOG},
  year = {2025},
  url = {https://openreview.net/forum?id=ijQTdlHJze},
}
Figure