NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Weisfeiler and Leman Go Neural: Higher-Order Graph Neural Networks

Christopher Morris, Martin Ritzert, Matthias Fey, William L. Hamilton, Jan Eric Lenssen, Gaurav Rattan, Martin Grohe

Abstract

Standard Graph Neural Networks (GNNs) are theoretically limited by the 1-dimensional Weisfeiler-Leman (1-WL) graph isomorphism test, preventing them from distinguishing certain simple graph structures. This paper introduces $k$-GNNs, a higher-order architecture that performs message passing between subgraphs rather than individual nodes. By breaking the 1-WL "glass ceiling," $k$-GNNs significantly improve performance on molecular and social network tasks, achieving over 90% error reduction on specific chemical property predictions.

Introduction: The 1-WL Limitation

In the late 2010s, GNNs became the standard for graph learning, yet their theoretical expressive power remained poorly understood. The authors identify a fundamental gap: standard GNNs rely on "neighborhood aggregation," a process mathematically equivalent to the 1-WL test.

Because 1-WL fails to distinguish certain structures—such as a graph containing a triangle versus one containing a 4-cycle—standard GNNs are effectively "blind" to higher-order structural properties. This limitation is particularly critical in chemistry, where specific ring structures (like benzene) determine a molecule's function.

Methods: $k$-Dimensional Graph Neural Networks

To overcome the limitations of 1-WL, the authors propose $k$-GNNs based on the $k$-WL algorithm. Instead of individual nodes, the basic units of computation are sets of $k$ nodes (subgraphs).

Architecture of the hierarchical k-GNN model, showing message passing across 1, 2, and 3-node subgraphs followed by pooling into an MLP.

Key Architectural Features:

  • Local Message Passing: To maintain computational feasibility ($O(n^k)$ is otherwise too expensive), the authors define "local" neighborhoods. Two $k$-sets are considered neighbors if they share $k-1$ nodes and the remaining two nodes are connected by an edge.
  • Hierarchical Integration: The model uses a "1-2-3-GNN" approach where features of a 3-node subgraph are initialized using the learned features of its 2-node components. This creates an inductive bias that captures how small structures build into larger ones.

Experimental Results

The authors evaluated $k$-GNNs on the QM9 dataset (~134,000 small organic molecules) and several classification benchmarks.

Massive Gains in Chemistry

On the QM9 regression task, the hierarchical $k$-GNN reduced the Mean Absolute Error (MAE) by an average of 54.45% compared to standard 1-GNNs.

Mean Absolute Error (MAE) results on the QM9 dataset. The 1-2-3-GNN shows dramatic improvements (Gain column) over standard GNN baselines across multiple chemical targets.

As shown in the table above, for properties like internal energy ($U_0$) or enthalpy ($H$), the improvement exceeded 98%. This demonstrates that capturing higher-order structural information is essential for accurate molecular modeling.

Classification and Kernels

On social network and bioinformatics classification tasks, $k$-GNNs outperformed standard GNNs and performed competitively with state-of-the-art graph kernels. Interestingly, the authors found that even with random (untrained) weights, $k$-GNNs performed well, suggesting the structural inductive bias of the architecture itself provides significant value.

Discussion and Future Work

The realization that GNNs are "neuralized" versions of classical graph algorithms provides a clear roadmap for future research: more expressive GNNs require higher-order WL foundations.

However, challenges remain regarding scalability. Storing features for all $k$-node sets is memory-intensive for large graphs. Future work may involve more sophisticated sampling strategies or the incorporation of domain-specific knowledge (e.g., functional groups in chemistry) to further refine the $k$-set initialization and selection process.

Summary updated

BibTeX
@inproceedings{morris2019weisfeiler,
  author = {Christopher Morris and Martin Ritzert and Matthias Fey and William L. Hamilton and Jan Eric Lenssen and Gaurav Rattan and Martin Grohe},
  title = {{Weisfeiler and Leman Go Neural: Higher-Order Graph Neural Networks}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2019},
  doi = {10.1609/aaai.v33i01.33014602},
}
Figure