Control the GNN: Utilizing Neural Controller with Lyapunov Stability for Test-Time Feature Reconstruction
Jielong Yang, Rui Ding, Feng Ji, Hongbin Wang, Linbo Xie
TL;DR
This paper tackles robustness of graph neural networks under train-test distribution shift by reconstructing node features at test time without retraining. It proposes a control-theoretic framework that treats node features as inputs and predictions as states, using a neural controller $f_{\theta}$ guided by a neural Lyapunov function $V_{\phi}$ to ensure stable convergence to ground-truth labels. The method enforces Lyapunov stability through a joint training objective and counterexample generation via an SMT solver, enabling a single, stable test-time adjustment that yields class-representative embeddings for labeled nodes. Empirical evaluation on five datasets demonstrates improved accuracy and clearer separation between classes, with visualizations and Lyapunov analyses corroborating stability. This approach provides a theoretically grounded, parameter-free post-hoc boost to GNN robustness under distribution shifts, highlighting a practical control-theoretic direction for model-agnostic robustness.
Abstract
The performance of graph neural networks (GNNs) is susceptible to discrepancies between training and testing sample distributions. Prior studies have attempted to mitigating the impact of distribution shift by reconstructing node features during the testing phase without modifying the model parameters. However, these approaches lack theoretical analysis of the proximity between predictions and ground truth at test time. In this paper, we propose a novel node feature reconstruction method grounded in Lyapunov stability theory. Specifically, we model the GNN as a control system during the testing phase, considering node features as control variables. A neural controller that adheres to the Lyapunov stability criterion is then employed to reconstruct these node features, ensuring that the predictions progressively approach the ground truth at test time. We validate the effectiveness of our approach through extensive experiments across multiple datasets, demonstrating significant performance improvements.
