Does Homophily Help in Robust Test-time Node Classification?
Yan Jiang, Ruihong Qiu, Zi Huang
TL;DR
This work tackles robust node classification when test-time graphs exhibit distribution shifts and data quality issues. It proposes GrapHoST, a data-centric, test-time framework that learns a homophily predictor to reweight and prune test edges, transforming the test graph without retraining the fixed GNN. Grounded in Contextual Stochastic Block Model analysis, the method shows that increasing homophily in homophilic test graphs or decreasing it in heterophilic ones improves misclassification rates, and it demonstrates state-of-the-art gains up to $10.92\%$ across nine benchmarks. The approach is plug-and-play, scalable to large graphs, and effective across various GNN backbones, making it practically impactful for real-world deployment under test-time data quality issues. Overall, GrapHoST provides a principled, efficient way to leverage homophily at test time to enhance the robustness of pre-trained GNNs.
Abstract
Homophily, the tendency of nodes from the same class to connect, is a fundamental property of real-world graphs, underpinning structural and semantic patterns in domains such as citation networks and social networks. Existing methods exploit homophily through designing homophily-aware GNN architectures or graph structure learning strategies, yet they primarily focus on GNN learning with training graphs. However, in real-world scenarios, test graphs often suffer from data quality issues and distribution shifts, such as domain shifts across users from different regions in social networks and temporal evolution shifts in citation network graphs collected over varying time periods. These factors significantly compromise the pre-trained model's robustness, resulting in degraded test-time performance. With empirical observations and theoretical analysis, we reveal that transforming the test graph structure by increasing homophily in homophilic graphs or decreasing it in heterophilic graphs can significantly improve the robustness and performance of pre-trained GNNs on node classifications, without requiring model training or update. Motivated by these insights, a novel test-time graph structural transformation method grounded in homophily, named GrapHoST, is proposed. Specifically, a homophily predictor is developed to discriminate test edges, facilitating adaptive test-time graph structural transformation by the confidence of predicted homophily scores. Extensive experiments on nine benchmark datasets under a range of test-time data quality issues demonstrate that GrapHoST consistently achieves state-of-the-art performance, with improvements of up to 10.92%. Our code has been released at https://github.com/YanJiangJerry/GrapHoST.
