Inductive Subgraph Embedding for Link Prediction

Jiajun Zhou, Qi Xuan, Zhou, Jiajun, Yu, Shanqing, Chen, Lina, Xuan, Qi · DOI

Abstract

Graph representation learning (GRL) has emerged as a powerful technique for solving graph analytics tasks. It can effectively convert discrete graph data into a low-dimensional space where the graph structural information and graph properties are maximumly preserved. While there is rich literature on node and whole-graph representation learning, GRL for link is relatively less studied and less understood. One common practice in previous works is to generate link representations by directly aggregating the representations of their incident nodes, which is not capable of capturing effective link features. Moreover, common GRL methods usually rely on full-graph training, suffering from poor scalability and high resource consumption on large-scale graphs. In this paper, we design Subgraph Contrastive Link Representation Learning (SCLRL) -- a self-supervised link embedding framework, which utilizes the strong correlation between central links and their neighborhood subgraphs to characterize links. We extract the "link-centric induced subgraphs" as input, with a subgraph-level contrastive discrimination as pretext task, to learn the intrinsic and structural link features via subgraph mini-batch training. Extensive experiments conducted on five datasets demonstrate that SCLRL has significant performance advantages in link representation learning on benchmark datasets and prominent efficiency advantages in terms of training speed and memory consumption on large-scale graphs, when compared with existing link representation learning methods.

Introduction

Link prediction is a fundamental task in graph analytics, essential for applications ranging from social network recommendations to knowledge graph completion. Despite the success of Graph Representation Learning (GRL), existing methods face two primary challenges: limited expressiveness and poor scalability. Most models rely on a "node2link" approach, where link representations are derived from simple aggregations of incident node embeddings. This often fails to capture the intricate structural context between nodes. Furthermore, full-graph training methods frequently encounter "neighborhood explosion" and Out-of-Memory (OOM) errors on large-scale graphs.

The SE4LP Framework

To address these issues, the Inductive Subgraph Embedding for Link Prediction (SE4LP) framework (referred to as SCLRL in the abstract) adopts a "subgraph2link" paradigm. By focusing on the local neighborhood surrounding a potential link, SE4LP captures vital structural information while maintaining scalability through mini-batch training.

The SE4LP architecture illustrating subgraph extraction, augmentation, and contrastive learning.

The framework incorporates five main components:

  • Subgraph Extraction & Sampling: Extracts a "link-centric induced subgraph" (lsg) and uses recursive sampling (top-K neighbors by degree) to manage complexity.
  • Subgraph Augmentation: Generates multiple views of each subgraph using edge removal, attribute masking, and novel techniques like attribute similarity and KNN graph construction.
  • GNN-based Encoder: Utilizes a Graph Isomorphism Network (GIN) to produce graph-level embeddings from augmented views.
  • Subgraph-level Contrast: Employs a contrastive loss to maximize consistency between views of the same subgraph while differentiating them from others.
  • Joint Training: Optimizes the model end-to-end using both self-supervised contrastive loss and supervised classification loss.

Experimental Evaluation

SE4LP was benchmarked against five real-world datasets: citation networks (Cora, Citeseer, Pubmed) and large-scale social/collaboration networks (Facebook, Github).

Performance comparison of SE4LP against heuristic, unsupervised, and supervised baselines.

The experimental results highlight several key advantages:

  • State-of-the-Art Performance: SE4LP consistently outperforms traditional heuristics, random walk methods (Node2Vec), and unsupervised GRL methods (GAE, VGAE, DGI). It shows significant relative improvements in AUC over the best GAE models on citation benchmarks.
  • Scalability and Efficiency: Unlike GAE variants that hit OOM limits on Facebook and Github, SE4LP handles large-scale graphs efficiently due to its mini-batch approach.
  • Robustness to Sparse Labels: The self-supervised contrastive task significantly reduces dependence on labeled data. Performance remains stable even when training sets are reduced significantly, demonstrating the power of the pretext task.

Conclusion

SE4LP provides a scalable and expressive solution for link prediction by leveraging local subgraph structures and self-supervised learning. Its inductive nature and mini-batch compatibility make it a robust choice for large-scale graph analytics. Future work may explore more advanced sampling strategies and alternative GNN architectures to further enhance performance.

Summary updated

BibTeX
@article{zhou2025inductive,
  author = {Jiajun Zhou and Qi Xuan and Zhou, Jiajun and Yu, Shanqing and Chen, Lina and Xuan, Qi},
  title = {{Inductive Subgraph Embedding for Link Prediction}},
  journal = {Mob. Networks Appl.},
  year = {2025},
  doi = {10.1007/s11036-024-02339-3},
}
Figure