Manuscript Offprint

arXiv:2610.24685

Contrastive Adversarial Training for Robust Graph Neural Networks under Label Poisoning

Manshika Charvi Bissessur, Melis Ilayda Bal, Michael Muehlebach

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

Graph Neural Networks (GNNs) are effective for modeling relational data but are vulnerable to label poisoning, where a small number of corrupted training labels can propagate errors across the graph via message passing. Despite this risk, defenses against label poisoning remain underexplored: existing methods are primarily designed for label noise and often rely on robust losses or heuristic data cleaning that fail to distinguish adversarial poisoning from naturally hard examples. In this paper, we propose CoLAT (Contrastive Label-flipping for Adversarial Training), a novel contrastive adversarial training framework tailored for robust node classification on graphs. The core of our approach is a structure-aware detection model that uses contrastive learning to identify label–structure inconsistencies. Unlike prior contrastive methods that focus on representation learning, CoLAT leverages contrastive embeddings to select high-risk nodes that guide adversarial label-flipping during training. This alternating optimization not only performs structure-aware adversarial training but also implicitly sanitizes some corrupted labels, improving robustness against diverse attacks from the literature. Extensive experiments on multiple benchmarks show that CoLAT consistently outperforms existing defenses under various poisoning intensities while scaling efficiently to large graphs.

1 Introduction

Graph Neural Networks (GNNs) have become the dominant paradigm for learning on graph-structured data, with strong results across social network analysis, molecular property prediction, and knowledge graph reasoning (Wu et al., 2020). However, GNNs are notoriously susceptible to adversarial perturbations (Kipf and Welling, 2016; Sun et al., 2022). While extensive research has focused on structural attacks, in which the graph topology is subtly altered (Zügner et al., 2018), the vulnerability of GNNs to label poisoning attacks (Biggio et al., 2012) remains a critical yet relatively underexplored threat. This vulnerability is particularly pronounced in semi-supervised settings. Since GNNs propagate information through message passing, a small number of corrupted labels can influence large portions of the graph, amplifying the effect of the attack (Lingam et al., 2024). As a result, even limited label poisoning can significantly degrade model performance.

Defenses against label poisoning in GNNs remain scarce. Aside from a regularization-based method (Zhang et al., 2020), most prior work addresses label noise rather than adversarial cor-

∗^{*}Equal Contribution

40th Conference on Neural Information Processing Systems (NeurIPS 2026).

ruption (Qian et al., 2023), and thus often fails to distinguish adversarial outliers from hard clean examples, particularly in complex graph structures. Adversarial training has been explored as a defense in graph learning, but prior work primarily focuses on structural perturbations (Gosch et al., 2023), rather than label poisoning. In parallel, contrastive learning has been shown to improve robustness by producing representations that are less sensitive to label noise (You et al., 2020; Yuan et al., 2023), but recent defenses against label noise (Du et al., 2023; Li et al., 2024b) use contrastive objectives mainly as auxiliary regularization. Consequently, existing approaches fail to address label poisoning and leave a critical gap in exploiting graph structure to identify or defend against adversarial label perturbations.

In this paper, we propose CoLAT (Contrastive Label-flipping for Adversarial Training), a contrastive-adversarial training framework for robust node classification under label poisoning attacks. We model the problem through a bilevel formulation and derive a tractable alternating optimization scheme. Our key idea is to exploit graph structure to guide adversarial perturbations. In particular, we leverage the unique property of graphs that local neighborhood provides a natural prior for label consistency. Building on this, CoLAT introduces a contrastive detection model that learns representations aligned with this structural signal, to identify nodes whose labels are incongruent with their local context and thus susceptible to adversarial manipulation. Conditioned on these high-risk nodes, CoLAT constructs targeted label perturbations by assigning labels that maximize the classifier's loss. The model is then trained on these adversarial labels, yielding an iterative procedure that focuses on structurally inconsistent regions of the graph as a guide for adversarial learning. By tightly coupling contrastive detection with adversarial optimization, CoLAT effectively regularizes the classifier against label corruption, improving robustness while preserving performance on clean data.

Contributions. Our main contributions are the following.

• We propose CoLAT, a contrastive-adversarial training framework that explicitly models label poisoning as an adversarial process to improve robustness on graph settings and approximates the minimax formulation via a tractable, structure-aware bilevel procedure.

• Structurally-guided inconsistency scoring: We introduce a contrastive detection model that leverages graph structure to identify nodes whose labels are inconsistent with their local neighborhoods. Unlike prior work that focuses on representation improvement, we employ contrastive learning for node selection to generate adversarial examples in our proposed adversarial training defense.

• We develop an alternating optimization scheme that decomposes an intractable inner maximization into node selection and loss-maximizing label assignment, enabling scalable adversarial training without combinatorial search.

• We empirically demonstrate that CoLAT significantly improves robustness to label poisoning across multiple benchmarks and attack types from the literature, including varying attack budgets and large-scale graphs, while maintaining competitive performance on clean data.

References (81)

  • GOttack: Universal adversarial attacks on graph neural networks via graph orbits learning
  • Adversarial training for defense against label poisoning attacks
  • Poisoning attacks against support vector machines
  • NRGNN: Learning a label noise resistant graph neural network on sparsely and noisily labeled graphs
  • Adversarial attack on graph structured data
  • Noise-robust graph learning by estimating and leveraging pairwise interactions
  • All you need is low (rank): Defending against adversarial attacks on graphs
  • Data determines distributional robustness in contrastive language image pre-training (CLIP)
  • Explaining and Harnessing Adversarial Examples
  • Adversarial training for graph neural networks: Pitfalls, solutions, and new directions
  • Inductive representation learning on large graphs
  • Graph structure learning for robust graph neural networks
  • Supervised contrastive learning
  • Semi-Supervised Classification with Graph Convolutional Networks
  • Boosting the adversarial robustness of graph neural networks: An OOD perspective
  • Contrastive learning of graphs under label noise
  • Rethinking label poisoning for GNNs: Pitfalls and attacks
  • Adversarial label poisoning attack on graph neural networks via label propagation
  • Towards Deep Learning Models Resistant to Adversarial Attacks
  • Image-based recommendations on styles and substitutes
  • Birds of a feather: Homophily in social networks
  • Are defenses for graph neural networks robust? Advances in Neural Information Processing Systems, 35:8954–8968
  • Query-driven active surveying for collective classification
  • Representation Learning with Contrastive Predictive Coding
  • Transferability in machine learning: from phenomena to black-box attacks using adversarial samples (opens arXiv in a new tab)
  • A critical look at the evaluation of gnns under heterophily: Are we really making progress? ArXiv
  • Robust training of graph neural networks via noise governance
  • Adversarial training should be cast as a non-zero-sum game
  • Exact certification of (graph) neural networks against label poisoning
  • Collective classification in network data
  • Pitfalls of graph neural network evaluation
  • Adversarial attack and defense on graph data: A survey
  • Social influence analysis in large-scale networks
  • Contrastive multiview coding
  • Graph attention networks
  • Microsoft academic graph: When experts are not enough
  • NoisyGL: A comprehensive benchmark for graph neural networks under label noise
  • A comprehensive survey on graph neural networks
  • Investigating why contrastive learning benefits robustness against label noise
  • OMG: Towards effective graph classification against label noise
  • Graph contrastive learning with augmentations
  • Learning on graphs under label noise
  • Mitigating emergent robustness degradation while scaling graph learning
  • Graph universal adversarial attacks: A few bad actors ruin graph learning models (opens arXiv in a new tab)
  • Adversarial label-flipping attack and defense for graph neural networks
  • GNNGuard: Defending graph neural networks against adversarial attacks
  • Adversarial attacks on neural networks for graph data
  • Adversarial attacks on graph neural networks via meta learning
  • Certifiable robustness and robust training for graph convolutional networks
  • Their work highlights key pitfalls in existing adversarial attack evaluations, particularly the common assumption of a clean validation set, which is unrealistic in label poisoning attacks
  • >Dataset</td><td rowspan=
  • To mitigate such attacks, the authors propose a defense framework that leverages community-level labels as auxiliary supervision for node classification
  • The key idea is that pairwise relationships are more reliable than individual node labels
  • It constructs a refined graph based on feature similarity to enhance supervision and employs a small-loss criterion to identify trustworthy nodes, leveraging the observation that clean samples tend to incur lower training loss
  • It generates augmented graph views through feature masking and edge perturbations while preserving node semantics
  • For the baselines, we follow the implementations and hyperparameter search spaces using the official codebase$^{3}$, provided by Wang et al. (2024), which offers a unified benchmark and standardized experimental settings for fair comparison
  • >RTGNN</td><td>$\tau$</td><td>0, 0.05, 0.1, 0.2</td></tr><tr><td>$\lambda$</td><td>0.05, 0.1, 0.2</td></tr><tr><td>$\alpha$</td><td>0.03, 0.1, 0.3, 1</td></tr><tr><td>PIGNN</td><td>N/A</td><td>N/A</td></tr><tr><td rowspan=
  • For the larger OGBN-Arxiv dataset, we adopt a deeper and wider architecture to account for its scale and complexity
  • (i) implicit sanitization of corrupted labels and (ii) the introduction of adversarial labels that reduce the model's sensitivity to attacks
  • Despite the absence of label correction, the model still benefits from proactively introduced adversarial labels under the NTK 10% poisoning setting, yielding a 10% improvement in test accuracy
  • C.1 and on the Co-author datasets (Shchur et al., 2018) in Sec
  • Both are co-authorship graphs derived from the Microsoft Academic Graph
  • CoLAT consistently achieves the strongest performance at higher poisoning levels
  • >Training</td><td rowspan=
  • Results are reported for NTK and SMulti across various attack budgets
  • To assess robustness under more extreme conditions, we evaluate CoLAT at $40\%$ and $50\%$ poisoning rates on Cora-ML, Citeseer, and PubMed
  • C.4.1) and ablation studies on Cora ML (Sec
  • All methods use a GCN architecture
  • >Architecture</td><td rowspan=
  • This comparison highlights that the contrastive loss is a key component of our structurally guided scoring mechanism
  • These results should be interpreted in light of the heterophilic structure which reduces the usefulness of graph structure as a prior
  • However, this would largely remove the role of graph structure, making a simple MLP more appropriate
  • This makes CoLAT a flexible framework
  • Nevertheless, even with the limited graph signal available in Actor, CoLAT's adversarial label flips still provide robustness gains under strong multiclass attacks such as SMulti
  • All classification models are trained for 200 epochs
  • CoLAT requires only 7.67 seconds and 2.77 GB of memory, close to clean GCN training (4.23 seconds and 2.76 GB), while incurring substantially lower computational overhead than the defense baselines
  • CoLAT achieves the best trade-off, requiring among the least training time while attaining the highest test accuracy across both CPU and GPU configurations
  • Lower is better
  • As a result, designing strong adaptive attacks for this setting remains an open problem
  • By improving robustness to such label perturbations, our method can enhance the reliability of graph-based systems in domains such as social network analysis, recommendation systems, and biological networks
  • While our goal is defensive, the formulation of structured label perturbations could potentially inform the design of stronger poisoning attacks or adaptive attacks