Identity-aware Graph Neural Networks

Jiaxuan You, Jonathan Michael Gomes Selman, Rex Ying, Jure Leskovec

Introduction

Standard Graph Neural Networks (GNNs), such as GCN, GraphSAGE, and GAT, have become the de facto standard for learning on graphs. However, their expressive power is theoretically upper-bounded by the 1-Weisfeiler-Lehman (1-WL) graph isomorphism test. This limitation means that if two nodes have identical local neighborhood structures—a common occurrence in $d$-regular graphs—standard GNNs will produce identical embeddings. Consequently, these models struggle with tasks requiring structural awareness, such as counting cycles or predicting shortest path distances.

The Identity-aware Approach

To overcome the 1-WL bottleneck, the authors introduce Identity-aware GNNs (ID-GNNs). The core innovation is "Inductive Identity Coloring." By uniquely identifying the target node during the message-passing process, the model can distinguish the target from its neighbors, effectively breaking the symmetry that limits standard GNNs.

Comparison of computational graphs between existing GNNs and ID-GNNs across different tasks.

The authors propose two implementations:

  1. ID-GNN (Full): This version extracts the $K$-hop ego network for a target node and applies identity coloring to the root. It uses heterogeneous message passing to differentiate between the colored target and uncolored neighbors, allowing the network to track information flow relative to the specific node it is embedding.
  2. ID-GNN-Fast: A more efficient version that augments node features with cycle counts (lengths $1$ to $K$) passing through the node. This serves as a proxy for identity information without the computational overhead of full ego-network extraction.

Key Insights

ID-GNNs are inductive, meaning they do not rely on fixed node IDs (like one-hot encoding), allowing them to generalize to unseen graphs. Furthermore, ID-GNN is a general framework; it acts as a "wrapper" that can enhance any existing message-passing architecture, such as GCN or GIN. Theoretically, the authors prove that ID-GNNs can count cycles of length $K$, a fundamental topological feature that standard GNNs cannot capture.

Experimental Results

The performance gains are most striking in tasks requiring structural understanding. On synthetic datasets designed to test clustering coefficient and shortest path prediction, ID-GNNs outperformed standard GNNs by an average of 40% accuracy.

Performance comparison on structural property prediction tasks, showing significant improvements for ID-GNNs over standard GNN baselines.

Beyond synthetic tasks, ID-GNNs showed significant improvements in real-world scenarios:

  • Link Prediction: A 15% improvement in ROC AUC was observed on real-world datasets. This is because link prediction inherently depends on the distance between nodes, which ID-GNNs can effectively measure.
  • Node Classification: Even on standard benchmarks like Cora and CiteSeer, ID-GNNs provided a modest boost, suggesting that structural awareness complements rich node features even when they are already present.

Conclusion

Identity-aware GNNs represent a simple yet powerful extension to the GNN toolbox. By breaking the anonymity of standard neighborhood aggregation, ID-GNNs achieve superior expressiveness and performance across a wide range of graph-based tasks without sacrificing the inductive nature of message passing. While the full version introduces some computational cost, the fast version provides nearly identical gains with zero additional runtime overhead during training.

Summary updated

BibTeX
@inproceedings{you2021identity,
  author = {Jiaxuan You and Jonathan Michael Gomes Selman and Rex Ying and Jure Leskovec},
  title = {{Identity-aware Graph Neural Networks}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2021},
  doi = {10.1609/aaai.v35i12.17283},
}
Figure