Beyond Message Passing: Neural Graph Pattern Machine

Zehong Wang, Zheyuan Zhang, Tianyi Ma, Nitesh V Chawla, Chuxu Zhang +1 more
1/30/2025
cs.LGcs.AIcs.SI

Official code: Zehong-Wang/GPM (15 stars, MIT, PyTorch, last commit 2025-05-28).

Abstract

Graph learning tasks often hinge on identifying key substructure patterns -- such as triadic closures in social networks or benzene rings in molecular graphs -- that underpin downstream performance. However, most existing graph neural networks (GNNs) rely on message passing, which aggregates local neighborhood information iteratively and struggles to explicitly capture such fundamental motifs, like triangles, k-cliques, and rings. This limitation hinders both expressiveness and long-range dependency modeling. In this paper, we introduce the Neural Graph Pattern Machine (GPM), a novel framework that bypasses message passing by learning directly from graph substructures. GPM efficiently extracts, encodes, and prioritizes task-relevant graph patterns, offering greater expressivity and improved ability to capture long-range dependencies. Empirical evaluations across four standard tasks -- node classification, link prediction, graph classification, and graph regression -- demonstrate that GPM outperforms state-of-the-art baselines. Further analysis reveals that GPM exhibits strong out-of-distribution generalization, desirable scalability, and enhanced interpretability. Code and datasets are available at: https://github.com/Zehong-Wang/GPM.

View on arXivView PDF

Code Implementations(1)

Zehong-Wang/GPMOfficial100%
PyTorchMIT

Beyond Message Passing: Neural Graph Pattern Machine, ICML 2025

155PythonFeb 11, 20251 years agoMIT
artificial-intelligencedeep-learninggraphgraph-convolutional-networksgraph-neural-networks+7 more

Similar Papers

Cite this paper

@article{wang2025beyond,
  title  = {Beyond Message Passing: Neural Graph Pattern Machine},
  author = {Zehong Wang and Zheyuan Zhang and Tianyi Ma and Nitesh V Chawla and Chuxu Zhang and Yanfang Ye},
  year   = {2025},
  eprint = {2501.18739},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2501.18739v2},
  journal = {ICML 2025 2025}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2501.18739.svg)](https://codeofpaper.com/paper/2501.18739)

Discussion