ProG: A Graph Prompt Learning Benchmark

Chenyi Zi, Haihong Zhao, Xiangguo Sun, Yiqing Lin, Hong Cheng, Jia Li

Introduction

In the domain of Graph Neural Networks (GNNs), the "Pre-train & Fine-tune" paradigm has long been the standard approach. This strategy involves training a model on large-scale unlabeled data using a pretext task—such as predicting missing edges—and subsequently fine-tuning it for specific downstream applications like protein classification or social network analysis. However, this paradigm faces two significant challenges: the Task Gap and Efficiency Constraints.

The task gap refers to the fundamental mismatch between pre-training pretexts and downstream objectives, which often leads to "negative transfer," where pre-trained knowledge inadvertently degrades performance on the target task. Furthermore, as GNN architectures grow in complexity, fine-tuning becomes computationally prohibitive, particularly in few-shot scenarios where labeled data is scarce.

To address these issues, the ProG benchmark introduces a comprehensive framework for graph prompt learning. This approach keeps the pre-trained model frozen and utilizes lightweight, learnable "prompts" to reformulate downstream tasks to match the pre-training pretext, effectively bridging the task gap.

The ProG Framework and Methodology

ProG is the first open-source library designed to standardize the evaluation of graph prompt learning. It categorizes existing methods into two primary branches:

  1. Prompts as Graphs: These methods treat the prompt as an additional subgraph or structural component inserted into the original data (e.g., the All-in-one method).
  2. Prompts as Tokens: These methods utilize learnable vectors (tokens) added to node features to align the task spaces (e.g., GPF, GPPT).
Overview of the ProG framework comparing traditional supervised and fine-tuning paradigms with the new pre-train and prompt paradigm.

Built on PyTorch, the ProG library integrates six classic pre-training methods (such as DGI and GraphMAE) and five state-of-the-art prompting techniques. Its modular architecture—comprising Backbone, Pre-training, Prompting, and Evaluation modules—enables researchers to conduct fair, standardized comparisons across different components of the pipeline.

Experimental Setup and Datasets

The benchmark evaluates performance across 15 diverse datasets to ensure robust findings. These include:

  • Node-level tasks: Seven datasets covering both homophilic (e.g., Cora, PubMed) and heterophilic graphs (e.g., Wisconsin, Texas).
  • Graph-level tasks: Eight datasets spanning social networks (IMDB-B), biological proteins (PROTEINS, ENZYMES), and small molecules (MUTAG, BZR).

Key Insights and Results

Mitigating Negative Transfer

A primary finding of the ProG benchmark is that prompting acts as a "task bridge." Instead of modifying the model to fit the task, prompting modifies the task to fit the model's pre-trained state. This reversal is critical: while traditional fine-tuning often results in performance worse than simple supervised baselines (negative transfer), prompting methods like GPF-plus and All-in-one consistently achieve positive transfer across nearly all tested scenarios.

Heat maps demonstrating how prompting methods (GPF-plus for node tasks and All-in-one for graph tasks) alleviate negative transfer compared to traditional fine-tuning.

Performance and Efficiency

In few-shot settings (1-shot, 3-shot, and 5-shot), prompting methods consistently outperformed both supervised baselines and traditional fine-tuning. Furthermore, prompting is remarkably efficient; for instance, the Gprompt method requires only a single learnable vector to achieve high accuracy, significantly reducing the number of tunable parameters and accelerating convergence times compared to full model retraining.

Task Specialization

The study reveals that "prompts as tokens" are generally superior for node-level tasks due to their ability to refine feature representations. Conversely, "prompts as graphs" are more effective for graph-level tasks, as they can better manipulate the structural information necessary for global graph classification.

Conclusion and Future Directions

The ProG benchmark standardizes a fragmented field, providing the tools and theoretical framework necessary to advance graph prompt learning. While current methods show immense promise, challenges remain in scaling complex subgraph operations to massive graphs (e.g., ogbn-arxiv) and handling datasets that lack node features. Future work will focus on expanding ProG to include link prediction tasks and developing automated prompt selection techniques to further minimize manual tuning requirements.

Summary updated

BibTeX
@inproceedings{zi2024prog,
  author = {Chenyi Zi and Haihong Zhao and Xiangguo Sun and Yiqing Lin and Hong Cheng and Jia Li},
  title = {{ProG: A Graph Prompt Learning Benchmark}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2024},
}
Figure