Table of Contents
Fetching ...

Logical Distillation of Graph Neural Networks

Alexander Pluska, Pascal Welke, Thomas Gärtner, Sagar Malhotra

TL;DR

This work introduces Iterated Decision Trees (IDTs) as a symbolic, interpretable distillation of Graph Neural Networks (GNNs) that captures the two-variable counting fragment $C^2$ and extends it to handle mean-like aggregations common in GNNs. By learning successive IDT layers from intermediate GNN representations, the authors show that the distilled models are concise, maintain competitive accuracy, and can surpass the GNN when the ground truth is expressible in $C^2$. The approach bridges logic and deep learning by making the reasoning of GNNs explicit through logical formulas and leaf-set constructions, enabling human-understandable explanations. The work demonstrates practical benefits on both synthetic and real datasets (e.g., AIDS), and outlines a path toward broader applicability, including extensions to more complex graph types and richer modal operators.

Abstract

We present a logic based interpretable model for learning on graphs and an algorithm to distill this model from a Graph Neural Network (GNN). Recent results have shown connections between the expressivity of GNNs and the two-variable fragment of first-order logic with counting quantifiers (C2). We introduce a decision-tree based model which leverages an extension of C2 to distill interpretable logical classifiers from GNNs. We test our approach on multiple GNN architectures. The distilled models are interpretable, succinct, and attain similar accuracy to the underlying GNN. Furthermore, when the ground truth is expressible in C2, our approach outperforms the GNN.

Logical Distillation of Graph Neural Networks

TL;DR

This work introduces Iterated Decision Trees (IDTs) as a symbolic, interpretable distillation of Graph Neural Networks (GNNs) that captures the two-variable counting fragment and extends it to handle mean-like aggregations common in GNNs. By learning successive IDT layers from intermediate GNN representations, the authors show that the distilled models are concise, maintain competitive accuracy, and can surpass the GNN when the ground truth is expressible in . The approach bridges logic and deep learning by making the reasoning of GNNs explicit through logical formulas and leaf-set constructions, enabling human-understandable explanations. The work demonstrates practical benefits on both synthetic and real datasets (e.g., AIDS), and outlines a path toward broader applicability, including extensions to more complex graph types and richer modal operators.

Abstract

We present a logic based interpretable model for learning on graphs and an algorithm to distill this model from a Graph Neural Network (GNN). Recent results have shown connections between the expressivity of GNNs and the two-variable fragment of first-order logic with counting quantifiers (C2). We introduce a decision-tree based model which leverages an extension of C2 to distill interpretable logical classifiers from GNNs. We test our approach on multiple GNN architectures. The distilled models are interpretable, succinct, and attain similar accuracy to the underlying GNN. Furthermore, when the ground truth is expressible in C2, our approach outperforms the GNN.
Paper Structure (16 sections, 6 theorems, 25 equations, 2 figures, 1 algorithm)

This paper contains 16 sections, 6 theorems, 25 equations, 2 figures, 1 algorithm.

Key Result

Theorem 1

Any classifier expressible in $\mathrm{C}^2$ can be computed by a GNN.

Figures (2)

  • Figure 1: A simple decision tree. Each set of leaves can be interpreted as a formula, e.g. set of red leaves can be interpreted as $(\neg U_1\wedge \neg U_0) \vee(\neg U_1\wedge U_0)\vee(U_1\wedge U_0).$
  • Figure 2: Schematic representation of the data table.

Theorems & Definitions (20)

  • Example 1
  • Example 2
  • Theorem 1: Barcel2019LogicalEO, Theorem 5.2
  • Definition 1
  • Example 3
  • Theorem 2: Barcel2019LogicalEO, Theorem D.3, Lemma D.4
  • Definition 2
  • Example 4
  • Definition 3
  • Example 5
  • ...and 10 more