Evaluating Link Prediction Explanations for Graph Neural Networks

Claudio Borile, Alan Perotti, André Panisson

Abstract

While Graph Neural Networks (GNNs) have become the standard for link prediction tasks, their "black box" nature poses significant challenges for interpretability. This paper addresses the gap in eXplainable AI (XAI) for link prediction by introducing a robust evaluation framework. By adapting insertion/deletion curve techniques from computer vision and utilizing synthetic ground truths, we quantify the effectiveness of various attribution methods. Our findings highlight that technical choices, such as the decoder's similarity measure, are critical to explainer performance, and we identify Integrated Gradients as a consistently superior method for generating reliable link explanations.

Introduction

Graph Neural Networks (GNNs) are widely deployed for predicting missing connections in complex networks, ranging from social media friend recommendations to identifying potential drug-drug interactions in pharmacology. Despite their predictive power, understanding why a model predicts a specific link remains difficult. Most research in graph XAI has focused on node or graph classification, leaving link prediction (LP) largely overlooked.

The core challenge in LP explanation is validation. In massive real-world datasets, there is rarely a documented "reason" for a link that can serve as ground truth. Without objective benchmarks, researchers have often relied on qualitative assessments, which are prone to bias and lack scalability. This work seeks to move beyond "look-and-see" evaluations by establishing quantitative metrics for link prediction explainability.

Evaluation Framework

To rigorously assess explainers, the authors propose a dual-strategy approach:

  1. Synthetic Ground Truth: The researchers utilize generative models, such as Stochastic Block Models (SBM) and Watts-Strogatz (WS) graphs, where the underlying reason for a link is mathematically defined (e.g., community membership or triangle completion). This allows for the calculation of traditional metrics like Sensitivity and Specificity.
  2. Insertion/Deletion Curves: For real-world datasets where ground truth is absent, the study adapts a technique from computer vision. Features or edges are ranked by their "importance" according to an explainer. These elements are then progressively removed (deletion) or added (insertion) to observe the impact on the model’s prediction confidence. A high-quality explainer should cause a sharp drop in confidence when highly-ranked edges are removed.
  3. The Area Score: To provide a single comparable value, the authors introduce the Area Score ($s_{ins}$ and $s_{del}$), which measures the explainer's performance gain over a random baseline.
Visualizing link prediction explanations: The task is to explain the predicted link between nodes 'a' and 'b' by identifying the most influential neighboring edges (e.g., x-a or y-a).

Experimental Insights

The study evaluated four prominent attribution methods: GNNExplainer (perturbation-based), Integrated Gradients (IG) (gradient-based), Deconvolution, and Layer-wise Relevance Propagation (LRP) across synthetic and empirical datasets (Cora, PubMed, and DDI).

The "Decoder Trap"

A significant finding is the impact of the GNN's decoder—the component that calculates the final link probability. The choice of similarity measure drastically affects explainability. Using cosine similarity often results in "degenerate" explanations where no features are deemed important. Conversely, the inner product allows explainers to function correctly, suggesting that certain architectural choices can inadvertently "break" interpretability.

Architecture and Strategy

Different GNN architectures exhibit distinct "reasoning" patterns. For instance, the Variational Graph Auto-Encoder (VGAE) was found to rely almost exclusively on node features, largely ignoring graph topology. In contrast, the Graph Isomorphism Network (GIN) utilized both features and the surrounding edge structure, demonstrating a more holistic use of graph data.

The Robustness of Integrated Gradients

Across nearly all benchmarks, Integrated Gradients (IG) emerged as the most reliable explainer. In the Cora dataset, for example, IG achieved an edge insertion area score of 0.72, vastly outperforming GNNExplainer’s 0.13. While GNNExplainer showed high specificity (avoiding wrong edges), it suffered from poor sensitivity, often missing relevant edges due to its tendency to produce overly sparse masks.

Conclusion

This research provides a necessary foundation for the rigorous evaluation of link prediction explanations. By demonstrating that gradient-based methods like IG are currently the most robust "plug-and-play" tools, and highlighting the pitfalls of specific decoder choices, the authors offer a roadmap for developing more interpretable GNNs. Future work will focus on unifying feature and edge importance into single narratives and developing model-agnostic explainers that match the reliability of gradient-based approaches without requiring internal model access.

Summary updated

BibTeX
@inproceedings{borile2023evaluating,
  author = {Claudio Borile and Alan Perotti and André Panisson},
  title = {{Evaluating Link Prediction Explanations for Graph Neural Networks}},
  booktitle = {xAI},
  year = {2023},
  doi = {10.1007/978-3-031-44067-0\_20},
}
Figure