arXiv:2611.07706cs.AINov 2026

Manuscript Offprint

arXiv:2611.07706

Towards Generalist Graph-Level Anomaly Detection

Junjun Pan, Yixin Liu, Yu Zheng, Fuyi Li, Alan Wee-Chung Liew, Shirui Pan

Abstract

Graph-level anomaly detection (GLAD) aims to identify graphs that deviate significantly from the majority and plays a crucial role in applications such as molecular analysis and fraud detection. While recent advances have achieved competitive performance, existing approaches mainly follow a dataset-specific paradigm, requiring substantial in-domain data and training cost when applied to new application scenarios. This limits their scalability and practicality in real-world applications where labeled data is scarce and diverse domains are continuously emerging. In this paper, we investigate the problem of generalist GLAD, which seeks to learn a single unified model capable of detecting anomalous graphs across multiple domains with minimal supervision on the target data. This problem introduces key challenges, including learning transferable patterns from heterogeneous graph datasets and effective adaptation under limited supervision. To address these challenges, we propose GenGLAD, a generalist GLAD approach that leverages discriminative subgraph extraction as the core mechanism to learn transferable anomaly knowledge and enable efficient adaptation to new domains. Specifically, GenGLAD employs a graph neural network-based discriminative subgraph extraction model to learn the anomaly-discriminative substructures that distinguish anomalous and normal graphs across diverse domains. During the test-time adaptation phase, multi-dimensional discrepancies between the extracted subgraph and multi-level contextual information are calculated to characterize anomalies from multiple perspectives. For efficient adaptation, a lightweight scoring module is introduced to automatically decide the most informative signals, improving robustness against misleading patterns. Extensive experiments on diverse benchmark datasets demonstrate that the proposed approach achieves strong performance, superior generalization ability, and improved data efficiency compared to existing methods.

1 Introduction

Graphs are a ubiquitous data structure for modeling discrete objects and their relationships, which makes them widely used in fields such as chemistry, biology, and social network analysis [46, 56]. Building on this foundation, graph-level anomaly detection (GLAD) aims to identify graph instances that are significantly different from the majority of graphs [18]. Due to its strong capability for solving various real-world challenges, such as identifying toxic chemicals [2], spotting fraudster networks [25] and safeguarding multi-agent systems [28], GLAD has attracted sustained research attention. Recently, graph neural network (GNN)-based methods have become the dominant approach for the GLAD problem, showcasing strong performance compared to traditional kernel-based methods [18, 25, 43].

∗^{*}Corresponding Author.

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

Figure

(a) Generalist GLAD paradigm.

(b) AUROC comparison.

Figure 1: (a) Sketch map the generalist GLAD paradigm, where one model fits multiple new datasets. (b) Performance of unsupervised GLAD methods reduces with the reduction of training set size.

Despite the competitive detection performance they achieved, existing GLAD approaches follow the traditional “one model per dataset” paradigm, requiring large amounts of in-domain data to train a dedicated detection model for each dataset. This learning paradigm brings significant limitations for GLAD applications. On the one hand, deploying a dataset-specific model requires sufficient in-domain data for model training, which limits its practical applicability in domains where data are scarce or difficult to collect. On the other hand, training a dataset-specific model is usually computationally expensive, involving high time and hardware costs, making it inefficient for large-scale databases.

Given the aforementioned limitations, a natural question arises: Can we train a “one-for-all” GLAD model that can generalize to detecting anomalous graphs across diverse application scenarios, without heavy adaptation cost? Following the previous success of generalist anomaly detection methods [19, 58], developing a generalist GLAD approach is a promising solution to the question. As shown in Figure 1a, a generalist GLAD model can be trained on a large collection of diverse datasets, acquiring strong generalization capabilities for various GLAD tasks. When applied to an arbitrary unseen target dataset, it only requires a few-shot normal samples for minimal-cost adaptation to detect anomalous graphs. As the knowledge learned from large-scale pre-training can be transferred to target datasets, the generalist GLAD paradigm eliminates the need for heavy dataset-specific training, reducing both data requirements and training costs.

Despite the promising potential of the generalist paradigm, it is non-trivial to develop a generalist GLAD approach. While recent efforts such as ARC [19] and AnomalyGFM [34] have promising generalist capabilities for node-level graph anomaly detection, extending such paradigms to GLAD comes with unique challenges. Firstly, (C1) How to learn generalizable patterns from diverse training datasets? Different graph-level applications lie in different semantic spaces and different structural priors. As a result, the characteristics of normal and abnormal graphs can vary widely across domains, which makes obtaining generalizable knowledge difficult. For example, in a social network, a fraudster community is usually characterized by dense local structures due to spamming behavior, while in molecular graphs, a small motif that exhibits specific functional groups can determine biotoxicity. In this case, how to develop a generalizable model that can capture transferable patterns across diverse domains remains a fundamental challenge. Moreover, (C2) How can models effectively adapt to a new test domain under limited supervision? Even if a generalist model can learn transferable patterns across domains, making reliable prediction on a target dataset still requires leveraging a few-shot set of normal samples, which characterize the specific distributional properties of the dataset. Nevertheless, unsupervised GLAD models typically rely heavily on sufficient data to capture the normal distribution: as shown in Figure 1b, their performance degrades sharply as the amount of training data decreases. In this context, how to effectively exploit the limited few-shot normal samples for efficient adaptation of pre-trained generalist GLAD models to unseen domains still remains an open problem.

To address the aforementioned challenges, we propose GenGLAD, a Generalist GLAD approach based on discriminative subgraph extraction. Our core idea is to learn transferable anomaly-discriminative subgraphs (e.g., the substructures in red in Figure 1a) through cross-domain pre-training, and adapt them to unseen domains via discrepancy-based evidence modeling under few-shot supervision. Specifically, to tackle (C1), GenGLAD incorporates a memory-guided discriminative subgraph extraction model as its backbone network, learning to capture shared fundamental knowledge for identifying the most anomaly-discriminative substructures that distinguish normal and anomalous graphs from arbitrary graph samples. To enhance transferable knowledge learning, GenGLAD empowers cross-domain pre-training by storing learned knowledge in a memory bank, and also facilitating task-relevant knowledge retrieval with the help of contextual priors. Moreover, to address (C2), we construct multi-dimensional discrepancy scores between the discriminative sub-graph of each graph sample and the contextual information, using them as prediction evidence. In this way, GenGLAD not only leverages few-shot contextual samples for domain-specific adaptation, but also captures anomaly evidence from fine-grained instance-level cues to coarse-grained cross-domain knowledge. With the discrepancy-based evidence, we can perform efficient adaptation by learning a lightweight scoring module with a linear layer to support anomaly prediction on new datasets. To summarize, this paper makes the following contributions:

  • Problem. To the best of our knowledge, we are the first to formalize and investigate the generalist GLAD problem, aiming to detect anomalous graphs from various domains with a single pre-trained GLAD model with limited in-domain supervision when adapting to arbitrary unseen datasets.

  • Method. We propose a novel generalist GLAD method, GenGLAD, which learns transferable anomaly-discriminative substructures through memory-guided cross-domain pre-training and performs efficient few-shot adaptation via discrepancy-based evidence modeling.

  • Experiments. We conduct extensive experiments to demonstrate the strong performance of GenGLAD, and illustrate its generalizability and efficiency across 10 benchmark datasets from various application domains.

References (56)