Generalist Graph Anomaly Detection via Prototype-Based Distillation

Extracted source text · arXiv 2605.26857

%%%%%%%% ICML 2026 EXAMPLE LATEX SUBMISSION FILE %%%%%%%%%%%%%%%%%

\documentclass{article}

% Recommended, but optional, packages for figures and better typesetting:
\usepackage{microtype}
\usepackage{graphicx}
\usepackage{subcaption}
\usepackage{booktabs} % for professional tables

% hyperref makes hyperlinks in the resulting PDF.
% If your build breaks (sometimes temporarily if a hyperlink spans a page)
% please comment out the following usepackage line and replace
% \usepackage{icml2026} with \usepackage[nohyperref]{icml2026} above.
\usepackage{hyperref}

\usepackage{algorithmic}
% Attempt to make hyperref and algorithmic work together better:
\newcommand{\theHalgorithm}{\arabic{algorithm}}
% \usepackage{algorithmicx}

% Use the following line for the initial blind version submitted for review:
% \usepackage{icml2026}

% For preprint, use
% \usepackage[preprint]{icml2026}

% If accepted, instead use the following line for the camera-ready submission:
\usepackage[accepted]{icml2026}

\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{mathtools}
\usepackage{amsthm}

% \usepackage{hyperref}
\usepackage{url}

% \usepackage{algorithm}
% \usepackage{algorithmic}
% \usepackage{subfig}
% \usepackage{booktabs}
\usepackage{multirow}
% \usepackage{graphicx} 
\usepackage{pifont}
\usepackage{wrapfig}
% \usepackage[ruled,vlined,linesnumbered]{algorithm2e}

\usepackage{color, colortbl}
\definecolor{Gray}{gray}{0.9}

\definecolor{firstcolor}{RGB}{20,128,85}
\definecolor{secondcolor}{RGB}{20,104,168}
\definecolor{thirdcolor}{RGB}{236,84,20}

\newcommand{\first}[1]{\textcolor{firstcolor}{\underline{\mathbf{#1}}}}
\newcommand{\second}[1]{\textcolor{secondcolor}{\underline{#1}}}
\newcommand{\third}[1]{\textcolor{thirdcolor}{\underline{#1}}}

% 定义 theorem 环境
% \newtheorem{theorem}{Theorem}



% if you use cleveref..
\usepackage[capitalize,noabbrev]{cleveref}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% THEOREMS
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\theoremstyle{plain}
\newtheorem{theorem}{Theorem}[section]
\newtheorem{proposition}[theorem]{Proposition}
\newtheorem{lemma}[theorem]{Lemma}
\newtheorem{corollary}[theorem]{Corollary}
\theoremstyle{definition}
\newtheorem{definition}[theorem]{Definition}
\newtheorem{assumption}[theorem]{Assumption}
\theoremstyle{remark}
\newtheorem{remark}[theorem]{Remark}

% Todonotes is useful during development; simply uncomment the next line
%    and comment out the line below the next line to turn off comments
%\usepackage[disable,textsize=tiny]{todonotes}
\usepackage[textsize=tiny]{todonotes}

% The \icmltitle you define below is probably too long as a header.
% Therefore, a short form for the running title is supplied here:
\icmltitlerunning{Generalist Graph Anomaly Detection via Prototype-Based Distillation}

\begin{document}

\twocolumn[
  \icmltitle{Generalist Graph Anomaly Detection via Prototype-Based Distillation}

  % It is OKAY to include author information, even for blind submissions: the
  % style file will automatically remove it for you unless you've provided
  % the [accepted] option to the icml2026 package.

  % List of affiliations: The first argument should be a (short) identifier you
  % will use later to specify author affiliations Academic affiliations
  % should list Department, University, City, Region, Country Industry
  % affiliations should list Company, City, Region, Country

  % You can specify symbols, otherwise they are numbered in order. Ideally, you
  % should not use this facility. Affiliations will be numbered in order of
  % appearance and this is the preferred way.
  \icmlsetsymbol{equal}{*}

%   \begin{icmlauthorlist}
%     \icmlauthor{Firstname1 Lastname1}{equal,yyy}
%     \icmlauthor{Firstname2 Lastname2}{equal,yyy,comp}
%     \icmlauthor{Firstname3 Lastname3}{comp}
%     \icmlauthor{Firstname4 Lastname4}{sch}
%     \icmlauthor{Firstname5 Lastname5}{yyy}
%     \icmlauthor{Firstname6 Lastname6}{sch,yyy,comp}
%     \icmlauthor{Firstname7 Lastname7}{comp}
%     %\icmlauthor{}{sch}
%     \icmlauthor{Firstname8 Lastname8}{sch}
%     \icmlauthor{Firstname8 Lastname8}{yyy,comp}
%     %\icmlauthor{}{sch}
%     %\icmlauthor{}{sch}
%   \end{icmlauthorlist}

%   \icmlaffiliation{yyy}{Department of XXX, University of YYY, Location, Country}
%   \icmlaffiliation{comp}{Company Name, Location, Country}
%   \icmlaffiliation{sch}{School of ZZZ, Institute of WWW, Location, Country}

%   \icmlcorrespondingauthor{Firstname1 Lastname1}{first1.last1@xxx.edu}
%   \icmlcorrespondingauthor{Firstname2 Lastname2}{first2.last2@www.uk}

%   % You may provide any keywords that you find helpful for describing your
%   % paper; these are used to populate the "keywords" metadata in the PDF but
%   % will not be shown in the document
%   \icmlkeywords{Machine Learning, ICML}

%   \vskip 0.3in
% ]


  \begin{icmlauthorlist}
    \icmlauthor{Yiming Xu}{xjtu,lab}
    \icmlauthor{Zihan Chen}{uva}
    \icmlauthor{Zhen Peng}{xjtu,lab}
    \icmlauthor{Song Wang}{ucf}
    \icmlauthor{Bin Shi}{xjtu,lab}
    \icmlauthor{Bo Dong}{lab,xjtu_de}
    \icmlauthor{Chao Shen}{xjtu_shen}
  \end{icmlauthorlist}

  \icmlaffiliation{xjtu}{School of Computer Science and Technology, Xi'an Jiaotong University, Xi'an, China}
  \icmlaffiliation{lab}{National Engineering Research Center for Visual Information and Applications, Xi'an, China}
  % \icmlaffiliation{xjtu}{Xi'an Jiaotong University, Xi'an, China}
  \icmlaffiliation{uva}{University of Virginia, Charlottesville, USA}
  \icmlaffiliation{ucf}{University of Central Florida, Orlando, USA}
  \icmlaffiliation{xjtu_de}{School of Distance Education, Xi’an Jiaotong University, Xi'an, China}
  \icmlaffiliation{xjtu_shen}{School of Cyber Science and Engineering, Xi'an Jiaotong University, Xi'an, China}

  \icmlcorrespondingauthor{Bin Shi}{shibin@xjtu.edu.cn}
  \icmlcorrespondingauthor{Zhen Peng}{zhenpeng@xjtu.edu.cn}

  % You may provide any keywords that you find helpful for describing your
  % paper; these are used to populate the "keywords" metadata in the PDF but
  % will not be shown in the document
  \icmlkeywords{Machine Learning, ICML}

  \vskip 0.1in
]

% this must go after the closing bracket ] following \twocolumn[ ...

% This command actually creates the footnote in the first column listing the
% affiliations and the copyright notice. The command takes one argument, which
% is text to display at the start of the footnote. The \icmlEqualContribution
% command is standard text for equal contribution. Remove it (just {}) if you
% do not need this facility.

% Use ONE of the following lines. DO NOT remove the command.
% If you have no special notice, KEEP empty braces:
\printAffiliationsAndNotice{}  % no special notice (required even if empty)
% Or, if applicable, use the standard equal contribution text:
% \printAffiliationsAndNotice{\icmlEqualContribution}

\begin{abstract}
Driven by the pressing demand for graph anomaly detection (GAD) in high-stakes domains, the generalist GAD paradigm, which trains a single detector transferable across new graphs, has recently gained growing attention. However, existing methods often rely on scarce and costly annotations for training and sometimes even require few-shot support at inference, which limits their robustness to diverse and unseen anomaly patterns. To address this limitation, we introduce ProMoS, the first unsupervised generalist GAD framework, which detects anomalies by modeling the abundant normality in unlabeled data.
ProMoS adopts a knowledge-distillation paradigm to distill normality priors from a frozen self-supervised graph neural network (GNN) teacher to a mixture-of-students model with shared global and lightweight personalized branches, enabling efficient and expressive normality modeling without learning from scratch. 
We further propose prototype-guided soft-label distillation to align teacher and student in a shared prototype space, enhancing cross-graph generalizability. 
During inference, ProMoS performs zero-shot anomaly detection on unseen graphs via distillation bias and prototype geometric deviation.
Extensive experiments show the effectiveness and efficiency of ProMoS, charting a practical path toward label-free, zero-shot generalist GAD. \footnote{The source code and datasets are available at: https://github.com/yimingxu24/ProMoS.}

\end{abstract}


\section{Introduction}
Graph anomaly detection (GAD) has attracted attention in high-stakes domains modeled with graphs~\citep{ma2021comprehensive, zheng2024survey, xu2025court}, such as finance~\citep{xu2025ted}, social networks~\citep{xu2022evidence}, and cybersecurity~\citep {wang2022wrongdoing}, by identifying deviations from normal patterns automatically~\citep{wang2025open,li2025diffgad}.
Despite recent progress, conventional GAD methods~\citep{liu2021anomaly,bwgnn_tang2022rethinking,tam_qiao2024truncated,xu2025revisiting} require retraining and extensive hyperparameter tuning to handle each new coming graph, incurring prohibitive computational and operational costs that are untenable for large-scale or latency-sensitive applications~\citep{niu2024zero}.
To overcome these limitations, recent studies explore generalist GAD models that are trained once and generalize across graphs without any retraining on the target graph~\citep{liu2024arc}. 


\definecolor{myred}{RGB}{215,48,39}
\definecolor{mygreen}{RGB}{26,152,80}
\newcommand{\cmark}{\textcolor{mygreen}{\ding{51}}}
\newcommand{\xmark}{\textcolor{myred}{\ding{55}}}
\begin{table*}[t]
\centering
\small
\renewcommand{\baselinestretch}{1.151}
% \setlength\tabcolsep{8.2pt}
% \vspace{-.1in}
\caption{A brief comparison of representative GAD methods. 
“Zero-shot” refers to inference on unseen graphs without using any labeled data for fine-tuning or adaptation; SSL refers to graph self-supervised learning (pre-trained) models.}
\begin{tabular}{lccccc}
\toprule
\textbf{Method}                             & \textbf{Unsupervised}     & \textbf{Zero-shot}     & \textbf{Generalist}  & \textbf{Training Paradigm}\\\midrule
DOMINANT~\citep{ding2019deep}    & \cmark    &  \cmark    &  \xmark   & Train from scratch \\
CoLA~\citep{liu2021anomaly}    & \cmark    &  \cmark    &  \xmark   &  Train from scratch \\
TAM~\citep{tam_qiao2024truncated}    & \cmark    &  \cmark    &  \xmark   &  Train from scratch \\
ARC~\citep{liu2024arc} & \xmark    &  \xmark    &  \cmark   &  Train from scratch \\
UNPrompt~\citep{niu2024zero}    & \xmark    &  \cmark    &  \cmark   &  Train from scratch \\
AnomalyGFM~\citep{qiao2025anomalygfm}  & \xmark    &  \cmark    &  \cmark   &  Train from scratch \\\midrule
\textbf{ProMoS (Ours)}  & \cmark    &  \cmark    &  \cmark   &  \textbf{Transferred from SSL} \\
\bottomrule
\end{tabular}
\label{tab:comparison}
% \vspace{-.2in}
\end{table*}

Although effective in some scenarios, existing generalist GAD methods still heavily rely on labeled supervision~\citep{liu2024arc,niu2024zero,qiao2025anomalygfm}. In practice, anomaly labels are scarce, costly~\citep{ma2024graph}, and intrinsically unable to cover the constantly evolving space of abnormal behavior in the open world, since no fixed annotation set can fully enumerate this variability~\citep{sricharan2014localizing,wang2019detecting}. In contrast, large graphs naturally provide abundant unlabeled signals~\citep{liu2022graph,xie2022self,xu2023cldg}: normal nodes dominate the graph and collectively harbor rich and robust normal patterns of behavior and connectivity that reflect the underlying regularities of the graph~\citep{cao2025use}, with anomalies emerging as significant deviations from these patterns. Motivated by these insights, we ask whether a \emph{generalist} GAD model can be trained once in an \emph{unsupervised} manner and then transferred across graphs.

Realizing this vision is non-trivial and poses two key challenges.
\ding{182}~\textit{Comprehensive normality modeling}.
A fundamental challenge is to learn comprehensive and representative normal patterns without labeled data~\citep{ma2021comprehensive,qiao2025deep}. 
An ill-designed unsupervised objective may recover a narrow and unrepresentative manifold of normal patterns from the data. Leveraging such a biased characterization of normality for anomaly detection inevitably leads to degraded performance~\citep{cao2025use}.
\ding{183}~\textit{Cross-graph heterogeneity gap}. Significant discrepancies exist across graphs in both node-attribute semantics and topological characteristics, posing a critical challenge to cross-graph transfer. For instance, financial transaction graphs contain scalar fields like monetary amounts and exhibit hub-centric structures, whereas social networks contain unstructured text such as posts and bios, while exhibiting community-centric connectivity~\citep{ruff2021unifying}. The prevailing unsupervised GAD methods primarily rely on objectives like within-graph instance discrimination~\citep{liu2021anomaly,xu2025revisiting} or feature reconstruction~\citep{ding2019deep,zou2024structural}, tend to overfit to dataset-specific fine-grained patterns. This overfitting severely hinders the generalization of learned normal patterns to graphs with different data distributions.  \looseness=-1


To tackle the above challenges, we propose \textbf{ProMoS}, a \textbf{Pro}totype-guided \textbf{M}ixture-\textbf{o}f-\textbf{S}tudents framework for unsupervised generalist GAD, as shown in Table~\ref{tab:comparison}. 
Specifically, to address Challenge \ding{182}, we propose a knowledge distillation (KD) framework that distills normality priors from a well-trained self-supervised GNN into the student module, departing from the conventional practice of learning normal patterns from scratch. To balance expressiveness and efficiency, the student module devises a mixture-of-students (MoS) architecture, with a shared branch capturing global regularities and a sparsely activated personalized branch modeling diverse local normal patterns.
To address Challenge \ding{183}, we propose prototype-guided soft-label distillation, which aligns teacher and student predictions with a set of learnable semantic prototypes initialized by clustering features, thereby avoiding reliance on instance-level or feature-level fine-grained modeling. To further enhance transferability, we introduce a discrepancy-aware commitment and refinement objective that uses sample reliability-weighted to enforce stability in the teacher’s semantic space across graphs while continually updating prototypes to encode higher-quality transferable semantics.
Theoretically, we prove that the expected prediction error of the MoS framework is no greater than that of any individual student, ensuring its effectiveness. During inference, ProMoS requires \textit{no} retraining or fine-tuning. Anomaly scores are derived by combining two complementary signals: prototype-level distillation bias and geometric deviation, enabling robust zero-shot detection on unseen graphs. Our contributions are summarized as follows:

$\bullet$ We propose the \textit{first} unsupervised generalist GAD framework, ProMoS, which eliminates the reliance on labeled data for cross-graph generalization. Our work establishes a new pathway to take full advantage of large-scale unlabeled graph data for efficient and scalable anomaly detection.

$\bullet$ We propose a novel unsupervised KD framework for generalist GAD that transfers priors from a pre-trained graph SSL teacher and introduces a MoS module to balance expressiveness and efficiency. A tailored loss suite, comprising prototype distillation and discrepancy-aware commitment and refinement, further improves cross-graph generalizability. \looseness=-1

$\bullet$ Extensive experiments on 11 real-world graphs demonstrate that ProMoS shows superior generalization to state-of-the-art supervised, unsupervised, and generalist GAD baselines, while incurring lower computational overhead.

\section{Related Work}
\textbf{Anomaly Detection on Graphs.} 
The rapid progress of GNNs~\citep{xu2025out} has substantially advanced research on GAD~\citep{shi2023edge,xu2025text}. Existing GNN-based GAD approaches can be broadly categorized into supervised and unsupervised methods. Supervised methods~\citep{bwgnn_tang2022rethinking,ghrn_gao2023addressing,dong2025spacegnn} rely on limited anomaly labels to learn explicit decision boundaries, but often suffer from overfitting to seen anomalies and tend to misclassify unseen anomalies as normal~\citep{wang2025open}. In contrast, unsupervised methods have gained increasing attention for their label-agnostic nature~\citep{qiao2025deep}, typically leveraging reconstruction errors~\citep{ding2019deep,roy2024gad,zou2024structural} or contrastive~\citep{liu2021anomaly,zhang2024graph,xu2024learning} proxy tasks to model normal patterns and detect anomalies. While both paradigms achieve promising results under the conventional setting where training and inference are performed on the same graph, they typically break down under cross-graph settings, revealing a critical generalization gap~\citep{liu2024arc}. 

\noindent\textbf{Generalist Anomaly Detection.}
Generalist anomaly detection has recently gained traction as a promising direction for addressing the challenges of label scarcity and poor model generalization in anomaly detection~\citep{yao2024resad}. Inspired by advances in image anomaly detection~\citep{zhu2024toward}, several early studies have explored supervised generalist GAD models and demonstrated initial effectiveness~\citep{liu2024arc,niu2024zero,qiao2025anomalygfm}. However, these approaches typically rely on extensive labeled data to learn transferable representations and domain knowledge. For example, ARC~\citep{liu2024arc} requires substantial annotations to train not only the encoder but also its context module, and still depends on a few target-domain samples during inference. UNPrompt~\citep{niu2024zero} utilizes label-driven soft prompts, while AnomalyGFM~\citep{qiao2025anomalygfm} explicitly constructs class-specific priors for normal and anomalous categories. In contrast to these label-intensive methods, we take the first step toward unsupervised generalist GAD, aiming to learn cross-graph transferable normality patterns without any annotations. Our framework provides a new perspective for achieving zero-shot anomaly detection across diverse graphs.

\noindent\textbf{Knowledge Distillation on Graphs.} 
Knowledge distillation (KD)~\citep{hinton2014distilling} was first introduced to facilitate model compression and the creation of resource-efficient architectures. Later, it was extended to various domains, including image and video anomaly detection~\citep{georgescu2021anomaly,zhang2023destseg}. 
Graph KD has gained traction in recent years~\citep{tian2025knowledge}, yet its adoption in GAD remains limited~\citep{qiao2025deep}. Most existing efforts target graph-level GAD tasks~\citep{ma2022deep,lin2023discriminative,cai2024fgad}, while node-level GAD has received comparatively little attention. Moreover, prevailing methods adopt a \emph{one-teacher–one-student} paradigm that aligns hidden states or logits, neglecting the design of student architectures and failing to address cross-graph generalization. In this work, we advance KD for GAD by (i) establishing its feasibility at the node-level GAD and (ii) introducing a mixture-of-students that aligns student outputs to teacher-derived prototype soft labels, improving cross-graph transferability and generalization.

\begin{figure*}
  \centering
  \includegraphics[width=0.96\linewidth]{figures/overview.pdf}
  \caption{The architecture of the ProMoS. During training, a frozen self-supervised GNN teacher guides a Mixture-of-Students via prototype-guided soft-label distillation, while discrepancy-aware commitment and refinement objectives stabilize teacher outputs and refine the prototype for cross-graph consistency. During inference, anomalies are identified by fusing distillation bias with geometric deviation, enabling zero-shot detection on unseen graphs.}
  \label{fig:overview}
\end{figure*}


\section{Methodology}
\subsection{Preliminaries}
\noindent\textbf{Notation.}
An attributed graph is denoted as \(\mathcal{G}=(\mathcal V,\mathcal E,\mathbf X)\) with a node set \(\mathcal V=\{v_i\}_{i=1}^n\), en edge set  \( \mathcal{E} \subseteq \mathcal{V} \times \mathcal{V} \), and the node feature matrix \(\mathbf X\in\mathbb R^{n\times d}\). Its topological structure is recorded in the adjacency matrix \(\mathbf A\in\{0,1\}^{n\times n}\) where \(A_{ij}=1\) iff \((v_i,v_j)\in\mathcal E\).
In GAD, binary labels \(y_i\in Y \subset \{0,1\}^n\) split the nodes into a normal set \(\mathcal{V}_n=\{v_i\,|\,y_i=0\}\) and an anomalous set \(\mathcal{V}_a=\{v_i\,|\,y_i=1\}\) where \(\mathcal{V}_n\cap\mathcal{V}_a=\varnothing\), \(\mathcal{V}_n\cup\mathcal{V}_a=\mathcal{V}\), and \(|\mathcal{V}_n|\gg|\mathcal{V}_a|\).

\noindent\textbf{Conventional GAD Setting.}
Most existing GAD studies follow the \emph{one-graph-one-model} protocol: a detector is trained and deployed on the same graph \(\mathcal{G}\). Learning proceeds in either a supervised or unsupervised fashion to obtain a scoring function \(f:\mathcal V\!\to\!\mathbb R\) that ranks abnormal nodes higher than normal ones in reverse order, i.e., \(f(v_i)\!>\!f(v_j)\) for \(\forall\,v_i\in\mathcal V_a,\;v_j\in\mathcal V_n\). Once trained, \(f\) is applied at the inference phase to identify anomalous nodes within the same graph \(\mathcal{G}\).

\noindent\textbf{Generalist GAD Setting.}  
Generalist GAD aims to build a universal anomaly scoring model \( f \) from an collection of training graphs \(\mathcal{T}_{\text{train}}=\{(\mathcal{G}_{\text{train}}^{(1)},Y^{(1)}),\dots,(\mathcal{G}_{\text{train}}^{(N)}, Y^{(N)})\}\). The trained \( f \) is directly applicable, without fine-tuning or re-training, to unseen test graphs \(\mathcal{T}_{\text{test}}=\{\mathcal{G}_{\text{test}}^{(1)},\dots, \mathcal{G}_{\text{test}}^{(n)}\}\) drawn from diverse domains and distributions, satisfying \(\mathcal{T}_{\text{train}}\cap \mathcal{T}_{\text{test}}=\varnothing\) and even allowing for distribution differences between them. 
Previous generalist GAD approaches rely on labels $Y$ from training graphs \(\mathcal{T}_{\text{train}}\) and even require few-shot samples at inference~\citep{liu2024arc}. In contrast, our study specifically emphasizes the unsupervised development of \( f \), relying solely on patterns learned from $\{\mathcal{G}_{\text{train}}^{(1)},\dots,\mathcal{G}_{\text{train}}^{(N)}\}$ to detect anomalies in novel target graphs. \looseness=-1

\subsection{Mixture-of-Students Guided by Teacher Knowledge}
\noindent\textbf{Pre-trained Teacher.} 
Self-supervised GNN pretraining captures patterns of neighbor matching in unlabeled graphs, yielding robust representations that encode strong normality priors due to the dominance of normal nodes in real-world graphs~\citep{hou2024graphalign,zhao2025survey}. Rather than relearning these regularities from scratch, we adopt a knowledge distillation framework that reuses a well-trained self-supervised GNN encoder as the teacher and transfers its normality priors to the student. Formally, given a graph $\mathcal{G}$, the teacher representations are computed as:
\begin{equation}
\label{eq:adapter}
\mathbf{U}_T=f_T(\mathbf{X}, \mathbf{A}), \quad \mathbf{Z}_T=g_\phi\left(\mathbf{U}_T\right),
\end{equation}
where the parameters of the teacher encoder $f_T$ are frozen. The lightweight adapter $g_\phi$ (e.g., a single-layer perceptron) is the only trainable component on the teacher side. Its parameters $\phi$ are jointly optimized with the student branches, ensuring the teacher’s knowledge remains calibrated and consistent across diverse graph domains (details elaborated in Section~\ref{sec:objective}).


\noindent\textbf{Mixture-of-Students.} 
To balance expressiveness and efficiency, we employ a mixture-of-students (MoS) with one \emph{shared} and one \emph{personalized} branch, enabling the student to capture the diverse normality patterns encoded by a frozen teacher. First, each branch operates on an enhanced node representation that augments raw features $\mathbf{x}_i$ with a residual representation $\mathbf{e}_i$, which is widely recognized to improve generalization~\citep{qiao2025anomalygfm}. The resulting enhanced representation is defined as: \looseness=-1
\begin{equation}
\mathbf{e}_i = \mathbf{x}_i - \frac{1}{|\mathcal{N}(v_i)|}\sum_{v_j \in \mathcal{N}(v_i)} \mathbf{x}_j,
\quad
\tilde{\mathbf{x}}_i = \mathbf{x}_i + \mathbf{e}_i,
\end{equation}
where $\tilde{\mathbf{x}}_i$ is enhanced node representation. $\mathcal{N}(v_i)$ is the neighbor set of node $i$.

Given $\tilde{\mathbf{x}}_i$, the shared student $S^{g}$ remains always \emph{active}, learning global normality signals from the teacher, with the shared branch formally expressed as:
\begin{equation}
\mathbf{h}_i^{g} = S^{g}\left(\tilde{\mathbf{x}}_i ; \theta_g\right) = f_g\left(\tilde{\mathbf{x}}_i \odot \mathbf{m}_i\right) + \tilde{\mathbf{x}}_i,
\end{equation}
where $\mathbf{h}_i^{g}\!\in\!\mathbb{R}^{d}$ is the shared student output, $f_g$ is a lightweight MLP with parameters $\theta_g$, $\odot$ denotes the Hadamard product, and $\mathbf{m}_i$ is a random binary mask for robustness~\citep{he2022masked}. The identity skip stabilizes training and encourages $f_g$ to model teacher-induced aggregation deltas.

In contrast, the personalized branch hosts a pool of $N$ lightweight student models $\{S_p^{\ell}\}_{p=1}^{N}$. The personalized branch first employs a routing network to compute sparse activation weights, dynamically selecting a small subset of students based on masked node features to capture specialised local normality patterns. Formally, the routing network computes student selection scores as follows:
\begin{equation}
\begin{alignedat}{2}
\mathbf{r}_i 
&= \operatorname{softmax}\!\left(\mathbf{W}_r \tilde{\mathbf{x}}_i\right), \\[2pt]
g_{i,p}
&=
\begin{cases}
\mathbf{r}_i[p], 
& \mathbf{r}_i[p] \in \operatorname{Top}\text{-}K(\mathbf{r}_i), \\
0, 
& \text{otherwise},
\end{cases}
\end{alignedat}
\label{eq:route}
\end{equation}
where $\mathbf{r}_i \in \mathbb{R}^{N}$ is the routing probability vector, and $g_{i,p}$ denotes the sparse gating weight for student $p$. $\mathbf{W}_r \in \mathbb{R}^{N \times d}$ are trainable router parameters. Only the top-$K$ students receive non-zero weights, enforcing sparse activation. Given the routing weights, the personalized representation of node $v_i$ is computed as:
\begin{equation}
\label{eq:stu_rep}
\mathbf{h}_i^{\ell} = S^{\ell}\left(\tilde{\mathbf{x}}_i ; \theta_\ell\right) = \sum_{p=1}^{N} \left( g_{i,p} \cdot f_p(\tilde{\mathbf{x}}_i \odot \mathbf{m}_i) \right) + \tilde{\mathbf{x}}_i,
\end{equation}
where $\mathbf{h}_i^{\ell} \in \mathbb{R}^{d}$ is the output of the personalized branch, 
$f_p(\cdot)$ denotes the $p$-th student parameter.



\subsection{Training Objective}\label{sec:objective}

\noindent\textbf{Prototype-Driven Soft-Label Distillation.}
To transfer generalizable normality priors from the frozen teacher to lightweight student branches, we introduce a prototype-driven soft-label distillation strategy. Instead of enforcing instance-level feature matching, we rely on learnable prototype codebooks that serve as semantic anchors, initialized from the node features in the training graph via k-means clustering~\citep{douze2024faiss} and loaded as trainable parameters. 
For each branch $b \in \mathcal{B}=\{g,\ell\}$ (shared $g$, personalized $\ell$), we maintain a prototype codebook $\mathbf{P}^{b} = [\mathbf{p}_1^{b}, \dots, \mathbf{p}_{M_b}^{b}] \in \mathbb{R}^{M_b \times d}$.
Here $M_b$ denotes the number of prototypes assigned to branch $b$. For a given branch $b$, with teacher representation $\mathbf{z}_i^t$ and the corresponding student output $\mathbf{h}_i^{b}$ of node $i$, we compute their distributions over the prototypes $\mathbf{P}^{b}$ as follows:
\begin{equation}
\begin{aligned}
\mathbf{q}_{i}^{b}[m] 
&= 
\frac{\exp\!\left( \mathrm{sim}(\mathbf{z}_i^t, \mathbf{p}_{m}^{b}) / \tau \right)}
{\sum_{m'=1}^{M_b} \exp\!\left( \mathrm{sim}(\mathbf{z}_i^t, \mathbf{p}_{m'}^{b}) / \tau \right)}, \\
\mathbf{s}_{i}^{b}[m] 
&= 
\frac{\exp\!\left( \mathrm{sim}(\mathbf{h}_i^b, \mathbf{p}_{m}^{b}) / \tau \right)}
{\sum_{m'=1}^{M_b} \exp\!\left( \mathrm{sim}(\mathbf{h}_i^b, \mathbf{p}_{m'}^{b}) / \tau \right)},
\end{aligned}
\end{equation}
where $\mathbf q_{i}^{b}[m]$ and $\mathbf s_{i}^{b}[m]$ denote the probabilities of assigning node $i$ to the $m$-th prototype, produced by the teacher and the student under branch $b$, respectively. The similarity function is the negative squared Euclidean distance, i.e., $\mathrm{sim}(\mathbf{z}_i^{t}, \mathbf{p}_m^b) = - \left\| \mathbf{z}_i^{t} - \mathbf{p}_m^b \right\|_2^2$, and $\tau$ is the temperature coefficient.

Finally, the prototype-driven distillation loss minimizes the Kullback–Leibler (KL) divergence between teacher- and student-induced distributions across all branches:
\begin{equation}
\mathcal{L}_{\text{PSD}}
= \frac{1}{ \left | \mathcal V\right |}\sum_{i=1}^{ \left | \mathcal V\right |}\;\sum_{b \in \mathcal{B}} \mathrm{KL}(\mathbf q_i^{b}\,\Vert\, \mathbf s_i^{b}),
\end{equation}
where $ \left | \mathcal V\right |$ is the number of nodes in the graph and $\mathbf q_i^{b}$ are the teacher-provided soft labels.

This objective guides the students to capture prototype-level semantics distilled from the teacher, where prototypes act as high-level and abstract concepts that are easier to transfer across graphs, rather than overfitting to instance-specific details. We theoretically guarantee the effectiveness of MoS, with detailed proofs provided in Appendix~\ref{sec:proof}.

\noindent\textbf{Discrepancy-aware Commitment and Refinement} 
Graphs from different domains often exhibit substantial semantic and structural heterogeneity~\citep{liu2024arc}, leading to unordered or unstable feature spaces encoded by the frozen teacher, which in turn hampers generalization across graphs.
Moreover, without proper constraints, prototypes may remain largely underutilized, thereby limiting semantic coverage and diminishing representational diversity~\citep{li2021prototypical}.
To mitigate these issues, we introduce two complementary objectives with distinct roles. The commitment loss regularizes the adapter outputs in Eq.~\ref{eq:adapter} by pulling teacher representations toward stable prototype anchors, thereby enforcing a consistent and well-structured feature space across graphs. In contrast, the refinement loss updates the prototype to capture high-level transferable semantics. Together, these objectives ensure that the teacher features become prototype-aligned and that the prototypes evolve into meaningful semantic centers.
Specifically, each teacher representation is first quantized to its nearest prototype:
\looseness=-1
\begin{equation}
\mathcal{Z}_b(\mathbf{z}_i^{t}) = \mathbf{p}_{m_i^\star}^b, 
\quad 
m_i^\star = \arg\min_{m \in [M_b]} \; \big\|\mathbf{z}_i^{t} - \mathbf{p}_m^b\big\|_2^{2},
\end{equation}
where $\mathcal{Z}_b(\mathbf{z}_i^{t})$ denotes the quantized representation of node $i$ under branch $b$, 
$\mathbf{p}_{m_i^\star}^b$ is the $m_i$-th prototype in branch $b$.

However, directly optimizing commitment and refinement on real-world graphs is challenging because anomalous nodes inject misleading gradients, which bias prototype updates and regularizes the adapter outputs toward suboptimal alignments.
To address this issue, we propose a \emph{discrepancy-aware weighting} mechanism that adaptively downweights unreliable nodes. Specifically, we first construct the prototype–prototype relation matrix $\mathbf Q^{b} = \operatorname{softmax}\!\left(\mathrm{sim}(\mathbf P^{b}, \mathbf P^{b})/{\tau}\right)$, which provides a global semantic structure among prototypes and serves as the ground-truth relational pattern. For each node $i$, we then measure the consistency between its teacher-induced prototype distribution $\mathbf q_i^{b}$ and the relational pattern of its nearest prototype, given by $\mathbf Q_{m_i^\star}^{b}$, which serves as a canonical reference. This consistency is quantified via the KL divergence. The core intuition is that normal nodes should yield prototype distributions well aligned with $\mathbf Q_{m_i^\star}^{b}$—since their semantics are expected to follow the same global prototype structure—resulting in low KL divergence and thus large reliability weights, whereas unreliable nodes deviate from this global prototype structure and therefore receive reduced weights. The reliability weight $w_i^{b}$ is computed as:
\begin{equation}
\begin{aligned}
\tilde{w}_i^{b} 
&= \sigma\!\Big(-\beta \cdot \big(\mathrm{KL}(\mathbf q_i^{b}\,\|\,\mathbf Q_{m_i^\star}^{b}) - \mu\big)\Big), \\
w_i^{b} 
&= \frac{\tilde{w}_i^{b}}{\sum_{j=1}^{N}\tilde{w}_j^{b} + \epsilon},
\end{aligned}
\end{equation}
where $\sigma(\cdot)$ is the sigmoid function, $\beta$ controls the sharpness of reweighting, $\mu$ sets the pivot of the reliability threshold. $\beta$ and $\mu$ control the sensitivity of the reliability weight. $\mathbf{Q}_{m_i^\star}^{b}$ denotes the $m_i^\star$-th row of $\mathbf{Q}^b$ corresponding to the nearest prototype.
Given these adaptive weights, we define the discrepancy-aware commitment and refinement loss as
\begin{equation}
\begin{aligned}
\mathcal{L}_{\mathrm{DCR}}
= \sum_{i=1}^{|\mathcal V|} \sum_{b \in \mathcal{B}} w_i^{b}
\Big(
&\big\| \mathbf{z}_i^{t} - \mathrm{sg}\!\left[\mathcal{Z}_{b}(\mathbf{z}_i^{t})\right] \big\|_2^2 \\
&+ \big\| \mathrm{sg}\!\left[\mathbf{z}_i^{t}\right] - \mathcal{Z}_{b}(\mathbf{z}_i^{t}) \big\|_2^2
\Big),
\end{aligned}
\end{equation}
where $\operatorname{sg}\left [ \cdot  \right ]$ denotes the stop-gradient operation. The first term corresponds to the \emph{commitment loss}, which pulls teacher features toward their assigned prototypes, and the second term corresponds to the \emph{refinement loss}, which updates the prototypes so they better capture transferable semantic structure.

\noindent\textbf{Overall Objective} 
The overall training objective integrates prototype distillation, discrepancy-aware commitment, and refinement loss:  
\begin{equation}
\mathcal{L}
= \mathcal{L}_{\text{PSD}}
+ \lambda\,\mathcal{L}_{\text{DCR}},
\end{equation}
where $\lambda$ are trade-off hyperparameters.


\subsection{Generalist Anomaly Score Inference}
During inference, anomaly scores are derived without retraining on the target graph. We integrate two complementary signals: (i) the distillation deviation, which reflects the semantic mismatch between teacher soft labels and student predictions, and (ii) the geometric deviation, which captures geometric inconsistency between embeddings and their quantized prototypes. The final anomaly score is a weighted combination of both terms:
\begin{equation}
s_i = \sum_{b \in \mathcal{B}}
\left[
\mathrm{KL}\!\left(\mathbf q_i^b \,\Vert\, \mathbf s_i^b\right)
+ \lambda \Big(
\|\Delta_h\|_2^2 + \|\Delta_z\|_2^2
\Big)
\right],
\end{equation}
where $\Delta_h := \mathbf{h}_i^{b} - \mathcal{Z}_{b}(\mathbf{h}_i^{b})$, $\Delta_z := \mathbf{z}_i^{t} - \mathcal{Z}_{b}(\mathbf{z}_i^{t})$, the $\lambda$ controls the relative contribution of geometric deviation. Nodes with higher $s_i$ values are considered more anomalous.


\begin{table*}[t]
\caption {Anomaly detection performance on 11 datasets under the zero-shot setting (AUROC). 
\textcolor{firstcolor}{\textbf{\underline{$\mathbf{1^{st}}$}}} marks the best result, 
\textcolor{secondcolor}{\underline{$\mathbf{2^{nd}}$}} the runner-up, and 
\textcolor{thirdcolor}{\underline{$\mathbf{3^{rd}}$}}. 
\textit{OOM} denotes out-of-memory. }
\centering
\label{tab:main_auroc}
\renewcommand{\baselinestretch}{2.4}
\setlength{\tabcolsep}{2.4pt}
\resizebox{1\textwidth}{!}{
\begin{tabular}{l|ccccccccccc}
\toprule
Method
& Cora & CiteSeer & ACM & BlogCatalog & Facebook & Weibo
& Reddit & CS & Photo & Tolokers & T\text{-}Finance \\
\midrule

\rowcolor[HTML]{E9E9E9}
\multicolumn{12}{c}{Supervised - Pre-Train Only} \\
GCN
& $59.64{\scriptstyle\pm8.30}$ & $60.27{\scriptstyle\pm8.11}$ & $60.49{\scriptstyle\pm9.65}$ & $56.19{\scriptstyle\pm6.39}$ & $29.51{\scriptstyle\pm4.86}$ & $\third{76.64{\scriptstyle\pm17.69}}$
& $50.43{\scriptstyle\pm4.41}$ & $47.90{\scriptstyle\pm2.12}$ & $52.65{\scriptstyle\pm3.38}$ & $50.79{\scriptstyle\pm0.32}$ & $64.37{\scriptstyle\pm0.51}$ \\
GAT
& $50.06{\scriptstyle\pm2.65}$ & $51.59{\scriptstyle\pm3.49}$ & $48.79{\scriptstyle\pm2.73}$ & $50.40{\scriptstyle\pm2.80}$ & $51.88{\scriptstyle\pm2.16}$ & $53.06{\scriptstyle\pm7.48}$
& $51.78{\scriptstyle\pm4.04}$ & $49.02{\scriptstyle\pm0.53}$ & $51.71{\scriptstyle\pm1.00}$ & $\first{54.86{\scriptstyle\pm2.24}}$ & $\second{65.56{\scriptstyle\pm0.07}}$ \\
BGNN
& $42.45{\scriptstyle\pm11.57}$ & $42.32{\scriptstyle\pm11.82}$ & $44.00{\scriptstyle\pm13.69}$ & $47.67{\scriptstyle\pm8.52}$ & $54.74{\scriptstyle\pm25.29}$ & $32.75{\scriptstyle\pm35.35}$
& $50.27{\scriptstyle\pm3.84}$ & $52.35{\scriptstyle\pm4.63}$ & $49.88{\scriptstyle\pm1.13}$ & $51.53{\scriptstyle\pm4.29}$ & $50.78{\scriptstyle\pm5.46}$ \\
BWGNN
& $54.06{\scriptstyle\pm3.27}$ & $52.61{\scriptstyle\pm2.88}$ & $67.59{\scriptstyle\pm0.70}$ & $56.34{\scriptstyle\pm1.21}$ & $45.84{\scriptstyle\pm4.97}$ & $53.38{\scriptstyle\pm1.61}$
& $48.97{\scriptstyle\pm5.74}$ & $57.09{\scriptstyle\pm5.85}$ & $51.29{\scriptstyle\pm3.88}$ & $\third{53.82{\scriptstyle\pm2.58}}$ & $52.88{\scriptstyle\pm4.56}$ \\
GHRN
& $59.89{\scriptstyle\pm6.57}$ & $56.04{\scriptstyle\pm9.19}$ & $55.65{\scriptstyle\pm6.37}$ & $57.64{\scriptstyle\pm3.48}$ & $44.81{\scriptstyle\pm8.06}$ & $51.87{\scriptstyle\pm14.18}$
& $46.22{\scriptstyle\pm2.33}$ & $59.49{\scriptstyle\pm9.06}$ & $\third{54.24{\scriptstyle\pm8.95}}$ & $48.29{\scriptstyle\pm9.02}$ & $52.12{\scriptstyle\pm16.68}$ \\
UNPrompt
& $53.19{\scriptstyle\pm4.12}$ & $53.70{\scriptstyle\pm4.08}$ & $68.74{\scriptstyle\pm0.88}$ & $\third{68.87{\scriptstyle\pm0.56}}$ & $\third{61.37{\scriptstyle\pm4.54}}$ & $44.94{\scriptstyle\pm4.73}$
& $\second{57.10{\scriptstyle\pm1.21}}$ & $\second{71.64{\scriptstyle\pm0.86}}$ & $52.88{\scriptstyle\pm3.67}$ & $38.60{\scriptstyle\pm2.85}$ & $22.14{\scriptstyle\pm2.75}$ \\
AnomalyGFM
& $47.83{\scriptstyle\pm0.54}$ & $49.10{\scriptstyle\pm1.36}$ & $53.40{\scriptstyle\pm1.09}$ & $49.31{\scriptstyle\pm1.63}$ & $56.55{\scriptstyle\pm1.98}$ & $51.24{\scriptstyle\pm0.41}$
& $52.78{\scriptstyle\pm0.88}$ & $48.24{\scriptstyle\pm0.98}$ & $49.65{\scriptstyle\pm0.79}$ & $48.16{\scriptstyle\pm0.87}$ & $\third{64.44{\scriptstyle\pm7.12}}$ \\

\midrule
\rowcolor[HTML]{E9E9E9}
\multicolumn{12}{c}{Unsupervised - Pre-Train Only} \\
DOMINANT
& $\second{66.53{\scriptstyle\pm1.15}}$ & $\third{69.47{\scriptstyle\pm2.02}}$ & $\third{70.08{\scriptstyle\pm2.34}}$ & $\second{74.25{\scriptstyle\pm0.65}}$ & $51.01{\scriptstyle\pm0.78}$ & $\first{92.88{\scriptstyle\pm0.32}}$
& $50.05{\scriptstyle\pm4.92}$ & $60.61{\scriptstyle\pm0.11}$ & $47.39{\scriptstyle\pm0.34}$ & $48.12{\scriptstyle\pm1.65}$ & \textit{OOM} \\
CoLA
& $\third{63.29{\scriptstyle\pm8.88}}$ & $62.84{\scriptstyle\pm9.52}$ & $66.85{\scriptstyle\pm4.43}$ & $50.04{\scriptstyle\pm3.25}$ & $12.99{\scriptstyle\pm11.68}$ & $16.27{\scriptstyle\pm5.64}$
& $52.81{\scriptstyle\pm6.69}$ & $52.72{\scriptstyle\pm1.02}$ & $52.84{\scriptstyle\pm1.95}$ & $51.02{\scriptstyle\pm2.81}$ & $52.61{\scriptstyle\pm3.51}$ \\
HCM-A
& $54.28{\scriptstyle\pm4.73}$ & $48.12{\scriptstyle\pm6.80}$ & $53.70{\scriptstyle\pm4.64}$ & $55.31{\scriptstyle\pm0.57}$ & $35.44{\scriptstyle\pm13.97}$ & $65.52{\scriptstyle\pm12.58}$
& $48.79{\scriptstyle\pm2.75}$ & $62.91{\scriptstyle\pm5.86}$ & $50.62{\scriptstyle\pm1.40}$ & $\second{54.46{\scriptstyle\pm0.92}}$ & \textit{OOM} \\
TAM
& $62.02{\scriptstyle\pm2.39}$ & $\second{72.27{\scriptstyle\pm0.83}}$ & $\second{74.43{\scriptstyle\pm1.59}}$ & $49.86{\scriptstyle\pm0.73}$ & $\second{65.88{\scriptstyle\pm6.66}}$ & $71.54{\scriptstyle\pm0.18}$
& $\third{55.43{\scriptstyle\pm0.33}}$ & $\third{69.95{\scriptstyle\pm0.12}}$ & $\second{58.35{\scriptstyle\pm0.21}}$ & $50.51{\scriptstyle\pm0.14}$ & $56.16{\scriptstyle\pm4.54}$ \\

\midrule
\rowcolor[HTML]{E9E9E9}
\multicolumn{12}{c}{Ours} \\
ProMoS
& $\first{84.56{\scriptstyle\pm0.16}}$ & $\first{90.77{\scriptstyle\pm0.12}}$ & $\first{89.47{\scriptstyle\pm0.79}}$ & $\first{76.17{\scriptstyle\pm0.37}}$ & $\first{69.31{\scriptstyle\pm0.50}}$ & $\second{91.74{\scriptstyle\pm0.03}}$
& $\first{60.83{\scriptstyle\pm0.35}}$ & $\first{88.85{\scriptstyle\pm0.60}}$ & $\first{72.67{\scriptstyle\pm1.07}}$ & $52.80{\scriptstyle\pm0.82}$ & $\first{71.62{\scriptstyle\pm1.06}}$ \\
\bottomrule
\end{tabular}
}
\end{table*}


\begin{table*}[t]
\caption{Anomaly detection performance on 11 datasets under the zero-shot setting (AUPRC).}
\centering
\label{tab:main_auprc}
\renewcommand{\baselinestretch}{2.4}
\setlength{\tabcolsep}{2.4pt}

\resizebox{1\textwidth}{!}{
\begin{tabular}{l|ccccccccccc}
\toprule
Method
& Cora & CiteSeer & ACM & BlogCatalog & Facebook & Weibo
& Reddit & CS & Photo & Tolokers & T\text{-}Finance \\
\midrule

\rowcolor[HTML]{E9E9E9}
\multicolumn{12}{c}{Supervised - Pre-Train Only} \\
GCN
& $7.41{\scriptstyle\pm1.55}$ & $6.40{\scriptstyle\pm1.40}$ & $5.27{\scriptstyle\pm1.12}$ & $7.44{\scriptstyle\pm1.07}$ & $1.59{\scriptstyle\pm0.11}$ & $\third{67.21{\scriptstyle\pm15.20}}$
& $3.39{\scriptstyle\pm0.39}$ & $2.78{\scriptstyle\pm0.02}$ & $5.27{\scriptstyle\pm0.08}$ & $20.81{\scriptstyle\pm0.16}$ & $\third{9.82{\scriptstyle\pm0.18}}$ \\
GAT
& $6.49{\scriptstyle\pm0.84}$ & $5.58{\scriptstyle\pm0.62}$ & $4.70{\scriptstyle\pm0.75}$ & $12.81{\scriptstyle\pm2.08}$ & $3.14{\scriptstyle\pm0.37}$ & $33.34{\scriptstyle\pm9.80}$
& $3.73{\scriptstyle\pm0.54}$ & $2.97{\scriptstyle\pm0.09}$ & $5.62{\scriptstyle\pm0.17}$ & $\third{22.87{\scriptstyle\pm0.98}}$ & $\second{9.93{\scriptstyle\pm0.11}}$ \\
BGNN
& $4.90{\scriptstyle\pm1.27}$ & $3.91{\scriptstyle\pm1.01}$ & $3.48{\scriptstyle\pm1.33}$ & $5.73{\scriptstyle\pm1.47}$ & $3.81{\scriptstyle\pm2.12}$ & $30.26{\scriptstyle\pm29.98}$
& $3.52{\scriptstyle\pm0.50}$ & $4.19{\scriptstyle\pm0.89}$ & $5.96{\scriptstyle\pm0.18}$ & $\second{24.46{\scriptstyle\pm2.43}}$ & $4.57{\scriptstyle\pm0.59}$ \\
BWGNN
& $7.25{\scriptstyle\pm0.80}$ & $6.35{\scriptstyle\pm0.73}$ & $7.14{\scriptstyle\pm0.20}$ & $8.99{\scriptstyle\pm1.12}$ & $2.54{\scriptstyle\pm0.63}$ & $12.13{\scriptstyle\pm0.71}$
& $3.69{\scriptstyle\pm0.81}$ & $8.09{\scriptstyle\pm0.62}$ & $6.55{\scriptstyle\pm0.60}$ & $22.60{\scriptstyle\pm1.41}$ & $5.02{\scriptstyle\pm0.64}$ \\
GHRN
& $9.56{\scriptstyle\pm2.40}$ & $7.79{\scriptstyle\pm2.01}$ & $5.61{\scriptstyle\pm0.71}$ & $10.94{\scriptstyle\pm2.56}$ & $2.41{\scriptstyle\pm0.62}$ & $28.53{\scriptstyle\pm7.38}$
& $3.24{\scriptstyle\pm0.33}$ & $5.79{\scriptstyle\pm1.16}$ & $7.67{\scriptstyle\pm1.91}$ & $23.79{\scriptstyle\pm5.74}$ & $8.13{\scriptstyle\pm7.57}$ \\
UNPrompt
& $5.94{\scriptstyle\pm0.77}$ & $5.00{\scriptstyle\pm0.85}$ & $9.05{\scriptstyle\pm1.32}$ & $\third{23.93{\scriptstyle\pm4.47}}$ & $3.17{\scriptstyle\pm0.44}$ & $16.04{\scriptstyle\pm5.91}$
& $\second{4.12{\scriptstyle\pm0.22}}$ & $9.88{\scriptstyle\pm1.02}$ & $5.99{\scriptstyle\pm0.57}$ & $16.86{\scriptstyle\pm1.11}$ & $2.79{\scriptstyle\pm0.27}$ \\
AnomalyGFM
& $5.11{\scriptstyle\pm0.07}$ & $4.09{\scriptstyle\pm0.11}$ & $4.01{\scriptstyle\pm0.22}$ & $5.57{\scriptstyle\pm0.30}$ & $\third{6.02{\scriptstyle\pm0.10}}$ & $6.79{\scriptstyle\pm0.04}$
& $\third{3.99{\scriptstyle\pm0.11}}$ & $2.84{\scriptstyle\pm0.06}$ & $5.32{\scriptstyle\pm0.12}$ & $21.39{\scriptstyle\pm0.75}$ & $7.65{\scriptstyle\pm2.31}$ \\

\midrule
\rowcolor[HTML]{E9E9E9}
\multicolumn{12}{c}{Unsupervised - Pre-Train Only} \\
DOMINANT
& $\second{12.75{\scriptstyle\pm0.71}}$ & $\second{13.85{\scriptstyle\pm2.34}}$ & $\third{15.59{\scriptstyle\pm2.69}}$ & $\second{35.22{\scriptstyle\pm0.87}}$ & $2.95{\scriptstyle\pm0.06}$ & $\first{81.47{\scriptstyle\pm0.22}}$
& $3.49{\scriptstyle\pm0.44}$ & $15.48{\scriptstyle\pm0.46}$ & $\third{7.88{\scriptstyle\pm0.04}}$ & $20.51{\scriptstyle\pm0.25}$ & \textit{OOM} \\
CoLA
& $\third{11.41{\scriptstyle\pm3.51}}$ & $8.33{\scriptstyle\pm3.73}$ & $7.31{\scriptstyle\pm1.45}$ & $6.04{\scriptstyle\pm0.56}$ & $1.90{\scriptstyle\pm0.68}$ & $7.59{\scriptstyle\pm3.26}$
& $3.71{\scriptstyle\pm0.67}$ & $3.66{\scriptstyle\pm0.14}$ & $6.40{\scriptstyle\pm0.45}$ & $22.93{\scriptstyle\pm1.47}$ & $4.61{\scriptstyle\pm0.36}$ \\
HCM-A
& $5.78{\scriptstyle\pm0.76}$ & $4.18{\scriptstyle\pm0.75}$ & $4.01{\scriptstyle\pm0.61}$ & $6.89{\scriptstyle\pm0.34}$ & $2.08{\scriptstyle\pm0.60}$ & $21.91{\scriptstyle\pm11.78}$
& $3.18{\scriptstyle\pm0.23}$ & $\third{26.56{\scriptstyle\pm12.10}}$ & $6.73{\scriptstyle\pm0.61}$ & $20.56{\scriptstyle\pm1.15}$ & \textit{OOM} \\
TAM
& $11.18{\scriptstyle\pm0.75}$ & $\third{11.55{\scriptstyle\pm0.44}}$ & $\second{23.20{\scriptstyle\pm2.36}}$ & $10.57{\scriptstyle\pm1.17}$ & $\first{8.40{\scriptstyle\pm0.97}}$ & $16.46{\scriptstyle\pm0.09}$
& $3.94{\scriptstyle\pm0.13}$ & $\second{29.51{\scriptstyle\pm1.46}}$ & $\second{15.46{\scriptstyle\pm1.29}}$ & $23.32{\scriptstyle\pm0.08}$ & $5.91{\scriptstyle\pm0.67}$ \\

\midrule
\rowcolor[HTML]{E9E9E9}
\multicolumn{12}{c}{Ours} \\
ProMoS
& $\first{46.48{\scriptstyle\pm0.30}}$ & $\first{46.91{\scriptstyle\pm0.30}}$ & $\first{41.47{\scriptstyle\pm0.20}}$ & $\first{36.20{\scriptstyle\pm0.10}}$ & $\second{6.42{\scriptstyle\pm0.34}}$ & $\second{72.05{\scriptstyle\pm0.11}}$
& $\first{4.85{\scriptstyle\pm0.02}}$ & $\first{33.04{\scriptstyle\pm0.07}}$ & $\first{18.33{\scriptstyle\pm0.83}}$ & $\first{27.37{\scriptstyle\pm0.63}}$ & $\first{10.16{\scriptstyle\pm0.96}}$ \\
\bottomrule
\end{tabular}
}
\end{table*}



\section{Experiments} \label{sec:sec5}
\subsection{Experimental Setup}
\noindent\textbf{Datasets.} 
To evaluate the generalization of GAD models, we follow established protocols~\citep{dong2024universal,liu2024arc} by training all methods on a set of graphs and testing on a separate set of unseen graphs. Our evaluation spans 15 real-world graphs from diverse domains and scales, each containing either real or injected anomalies. Specifically, we use PubMed~\citep{sen2008collective}, Flickr~\citep{tang2009relational}, Questions~\citep{platonov2023critical}, and YelpChi~\citep{rayana2015collective} as training datasets, and assess generalization on unseen in-domain graphs (Cora, CiteSeer, ACM~\citep{tang2008arnetminer}, BlogCatalog~\citep{ding2019deep}, Facebook~\citep{xu2022contrastive}, Weibo~\citep{kumar2019predicting}, Reddit~\citep{kumar2019predicting}) and unseen out-of-domain graphs (CoAuthor CS~\citep{shchur2018pitfalls}, Amazon Photo~\citep{shchur2018pitfalls}, Tolokers~\citep{Tolokers}, T-Finance~\citep{bwgnn_tang2022rethinking}). Further details are provided in Appendix~\ref{sec:appendix_datasets}.

    
\noindent\textbf{Baselines.} 
We compare against 12 representative baselines across supervised and unsupervised paradigms. The supervised group includes two conventional GNNs (GCN~\citep{gcn_kipf2017semi}, GAT~\citep{gat_velivckovic2018graph}), three GAD-specific models (BGNN~\citep{bgnn_ivanov2021boost}, BWGNN~\citep{bwgnn_tang2022rethinking}, GHRN~\citep{ghrn_gao2023addressing}), as well as three recently proposed generalist GAD methods (ARC~\citep{liu2024arc}, UNPrompt~\citep{niu2024zero}, AnomalyGFM~\citep{qiao2025anomalygfm}). 
The unsupervised group covers four representative paradigms: the reconstruction-based method DOMINANT~\citep{ding2019deep}, the contrastive method CoLA~\citep{liu2021anomaly}, the hop-prediction method HCM-A~\citep{huang2022hop}, and the affinity-based method TAM~\citep{tam_qiao2024truncated}. \looseness=-1


\noindent\textbf{Implementation.} 
Following prior GAD protocols~\citep{ding2019deep,liu2021anomaly,qiao2025anomalygfm}, we report AUROC and AUPRC (mean$\pm$std over five runs with different seeds). To enable a fair assessment of generalist GAD, we focus on zero-shot inference: train on training graphs \(\mathcal{T}_{\text{train}}\) and evaluate on unseen test graphs \(\mathcal{T}_{\text{test}}\) with no support set. Comparisons to few-shot methods (e.g., ARC~\citep{liu2024arc}) are deferred to Appendix~\ref{sec:few-shot}. For feature parity, we apply the projection mapping of \citep{liu2024arc} to obtain 64-dimensional node features. Our pre-trained teacher GNN uses GCA~\citep{zhu2021graph}, implemented via the PyG-SSL Toolkit~\citep{zheng2024pyg}. All baselines are implemented via official code and tuned following their reported strategies. More details are provided in Appendix~\ref{sec:appendix_implement}.

\subsection{Generalist GAD Performance} 
We evaluate the generalist GAD performance across eleven datasets from diverse domains. Table~\ref{tab:main_auroc} and Table~\ref{tab:main_auprc} report the AUROC and AUPRC results compared with existing baselines. Several observations emerge.

First, supervised pre-training methods struggle in this setting. This highlights the inherent diversity of anomalies, and models that emphasize learning specific abnormal patterns from training graphs have difficulty generalizing to unseen anomaly types. Second, unsupervised GAD methods, such as TAM, perform more robustly by modeling normality to identify outliers, confirming the promise of this direction. However, they still suffer from substantial degradation in the generalist setting. For instance, CoLA achieves AUROC scores (\%) of 87.79 and 89.68 on Cora and CiteSeer, respectively, when training and testing on the same graph, yet loses over 24\% when generalized across domains.


Finally, ours consistently outperforms both supervised and unsupervised baselines while requiring only unsupervised pre-training. 
Across eleven datasets, ProMoS achieves the best AUROC on nine and the second-best on one, with an average improvement of 14.12\% over the strongest baseline, DOMINANT. Table~\ref{tab:main_auprc} further reports AUPRC, which is more informative under severe class imbalance. Consistent with the AUROC results in Table~\ref{tab:main_auroc}, ProMoS achieves the best performance on 9 of the 11 datasets and ranks second on the remaining two. ProMoS delivers substantial gains, outperforming the best competitor by 33.73\% on Cora.
These gains stem from leveraging advances in graph self-supervised learning and our tailored design mixture-of-students, prototype distillation, and discrepancy-aware objectives, which enable more faithful modeling of generalizable normal patterns for anomaly detection. Additional experimental results, such as visualization analyses, sensitivity studies, and student activation analysis, are reported in Appendix~\ref{sec:se}.



\subsection{Ablation Study}
To comprehensively assess the contribution of the core ideas in ProMoS, we construct three variants: (1) w/o PSD removes the prototype-driven soft-label distillation objective; (2) w/o DCR discards the discrepancy-aware commitment and refinement loss; (3) w/o SSL replaces the pre-trained teacher GNN with a randomly initialized two-layer GCN.
Table~\ref{tab:ablation} reports the results. We observe that eliminating any single module consistently harms performance. In particular, removing the prototype-driven distillation mechanism (w/o PSD) leads to a dramatic drop, with performance on most datasets barely above random guessing, highlighting the necessity of prototype-guided distillation. Similarly, excluding the constraint on teacher outputs (w/o DCR) or discarding the pre-trained teacher in favor of learning from scratch (w/o SSL) results in more than 5\% AUROC reduction. Experiments validate the critical role of our core idea. Further ablation studies are provided in the Appendix~\ref{sec:abl}.


\begin{figure*}[!t]
\centering
% \setlength{\belowcaptionskip}{-0.24cm}
\subfloat[Efficiency]{\label{fig:eff}\includegraphics[width=0.5\linewidth]{figures/runtime_plot.pdf}}
\subfloat[Scalability]{\label{fig:sca}\includegraphics[width=0.5\linewidth]{figures/scalability.pdf}}
\caption{Efficiency and scalability. (a) Training and inference time (seconds, log-scale) across baselines; our method achieves the lowest overall cost. (b) Inference time as a function of edge count (log). The dashed curve shows a power-law fit $T\propto |\mathcal{E}|^{\alpha } $ with $ \alpha \approx 0.3$, indicating sub-linear growth ($ \alpha \approx 1$ would be near-linear).}
\label{fig:efficency}
% \setlength{\belowcaptionskip}{-0.24cm}
\end{figure*}


\begin{table*}[t]
\caption{Ablation results w.r.t. AUC for ProMoS and its variants.}
\label{tab:ablation}
\centering
% \renewcommand{\baselinestretch}{1.2}
% \small
\setlength{\tabcolsep}{5pt}
\resizebox{0.9\textwidth}{!}{
\begin{tabular}{l|cccccc|c}
\toprule
Method & ACM & Facebook & Reddit & CS & Photo & T\text{-}Finance & Avg. \\
\midrule
\rowcolor[HTML]{E9E9E9} 
ProMoS & $\mathbf{89.47{\scriptstyle\pm0.79}}$ & $\mathbf{69.31{\scriptstyle\pm0.50}}$ & $\mathbf{60.83{\scriptstyle\pm0.35}}$ & $\mathbf{88.85{\scriptstyle\pm0.60}}$ & $\mathbf{72.67{\scriptstyle\pm1.07}}$ & $\mathbf{71.62{\scriptstyle\pm1.06}}$ & $\mathbf{75.46}$ \\
\midrule
w/o PSD & $69.25{\scriptstyle\pm0.42}$ & $26.68{\scriptstyle\pm1.09}$ & $56.72{\scriptstyle\pm1.95}$ & $65.75{\scriptstyle\pm0.34}$ & $55.91{\scriptstyle\pm1.03}$ & $63.58{\scriptstyle\pm0.66}$ & $56.32$ \\
w/o DCR & $88.11{\scriptstyle\pm0.93}$ & $65.86{\scriptstyle\pm1.05}$ & $56.14{\scriptstyle\pm1.02}$ & $87.23{\scriptstyle\pm0.65}$ & $58.80{\scriptstyle\pm5.80}$ & $65.05{\scriptstyle\pm3.41}$ & $70.20$ \\
w/o SSL & $76.60{\scriptstyle\pm0.69}$ & $68.93{\scriptstyle\pm0.35}$ & $53.83{\scriptstyle\pm1.82}$ & $79.27{\scriptstyle\pm0.34}$ & $71.01{\scriptstyle\pm1.14}$ & \textit{OOM} & $69.93$ \\
\bottomrule
\end{tabular}}
\end{table*}

\begin{table*}[!t]
\caption{ProMoS with different teacher backbones (AUROC).}
\label{tab:pretrain}
\centering
% \renewcommand{\arraystretch}{1.2}
\setlength{\tabcolsep}{5pt}
\resizebox{0.9\textwidth}{!}{
\begin{tabular}{l|cccccc|c}
\toprule
Method & Cora & CiteSeer & ACM & BlogCatalog & Weibo & Tolokers & Avg. \\
\midrule
\rowcolor[HTML]{E9E9E9}
GCA 
& $84.56{\scriptstyle\pm0.16}$ 
& $90.77{\scriptstyle\pm0.12}$ 
& $\mathbf{89.47{\scriptstyle\pm0.79}}$ 
& $76.17{\scriptstyle\pm0.37}$ 
& $\mathbf{91.74{\scriptstyle\pm0.03}}$ 
& $52.80{\scriptstyle\pm0.82}$ 
& $\mathbf{80.92}$ \\
\midrule
GraphCL 
& $\mathbf{89.20{\scriptstyle\pm0.93}}$ 
& $\mathbf{93.42{\scriptstyle\pm0.27}}$ 
& $81.32{\scriptstyle\pm0.58}$ 
& $66.80{\scriptstyle\pm0.81}$ 
& $91.30{\scriptstyle\pm0.06}$ 
& $54.66{\scriptstyle\pm0.23}$ 
& $79.45$ \\
BGRL 
& $87.56{\scriptstyle\pm0.20}$ 
& $89.60{\scriptstyle\pm0.38}$ 
& $73.97{\scriptstyle\pm0.34}$ 
& $\mathbf{76.96{\scriptstyle\pm0.11}}$ 
& $91.55{\scriptstyle\pm0.03}$ 
& $\mathbf{56.69{\scriptstyle\pm0.25}}$ 
& $79.39$ \\
DGI 
& $84.62{\scriptstyle\pm0.02}$ 
& $90.90{\scriptstyle\pm0.02}$ 
& $84.97{\scriptstyle\pm0.77}$ 
& $76.63{\scriptstyle\pm0.21}$ 
& $91.66{\scriptstyle\pm0.02}$ 
& $51.30{\scriptstyle\pm1.44}$ 
& $80.01$ \\
GraphMAE
& $83.76{\scriptstyle\pm0.09}$
& $90.51{\scriptstyle\pm0.09}$ 
& $76.83{\scriptstyle\pm0.47}$
& $73.76{\scriptstyle\pm0.34}$ 
& $91.73{\scriptstyle\pm0.07}$
& $50.24{\scriptstyle\pm0.64}$
& $77.81$ \\
\bottomrule
\end{tabular}}
% \vspace{-.2in}
% \setlength{\belowcaptionskip}{-0.24cm}
\end{table*}



\subsection{Efficiency and Scalability Analysis} \label{sec:efficiency}
\textbf{Efficiency.} First, we measure total training time on the training graphs \(\mathcal{T}_{\text{train}}\) and inference time on unseen test graphs \(\mathcal{T}_{\text{test}}\), with each epoch training efficiency and theoretical time complexity analysis provided in Appendix~\ref{sec:complexity}. As shown in Fig.~\ref{fig:eff}, GCN and GAT are the fastest baselines due to their minimalist architectures, while CoLA is extremely slow because it performs many random walks during both training and inference (e.g., 256 walks per node at inference). 
ProMoS attains the best overall efficiency, running 4.8× faster than GCN during training and 1.4× faster during inference.

\textbf{Scalability.} Second, we measure inference time on ten graphs (4,732-519,000 edges), reporting mean$\pm$std over five runs (x-axis in log-scale).
As shown in Fig.~\ref{fig:sca}, the results follow a power-law trend $T\propto |\mathcal{E}|^{\alpha }$ with $ \alpha \approx 0.3$. Since the slope is well below 1, inference grows \emph{sub-linearly} with graph size: a tenfold increase in edge size leads to only about a twofold increase in inference time.
This result demonstrates that ProMoS scales efficiently to large graphs. 


\subsection{Robustness to Teacher Backbones}\label{sec:adapt}
To assess robustness to different teacher backbones, we evaluate the adaptability of ProMoS by comparing several well-established graph SSL methods spanning diverse paradigms. Specifically, we replace the teacher with GCA (default)~\citep{zhu2021graph}, GraphCL~\citep{you2020graph}, BGRL~\citep{thakoor2022large}, DGI~\citep{velivckovic2019deep}, and GraphMAE~\citep{hou2022graphmae}.
As reported in Table~\ref{tab:pretrain}, all variants of ProMoS achieve strong and stable performance across the six datasets. 
ProMoS with GCA, GraphCL, and BGRL each achieves the best performance on two datasets, while DGI consistently delivers the second-best results overall. 
The reconstruction-based GraphMAE also achieves competitive performance, indicating that the framework remains effective when paired with teachers from different learning paradigms.  These findings demonstrate the robustness of our framework to the choice of teacher and highlight its plug-and-play nature, allowing future substitution with more advanced graph SSL models as they emerge.

\begin{table*}[!t]
\caption{Comparison of optimization strategies for the commitment and refinement loss.}
\label{tab:cr_strategy_ablation}
\centering
\renewcommand{\baselinestretch}{1.2}
\setlength{\tabcolsep}{5pt}
\resizebox{0.9\textwidth}{!}{
\begin{tabular}{l|cccccc|c}
\toprule
Method & ACM & Facebook & Reddit & CS & Photo & T\text{-}Finance & Avg. \\
\midrule
\rowcolor[HTML]{E9E9E9}
ProMoS & $89.47{\scriptstyle\pm0.79}$ & $69.31{\scriptstyle\pm0.50}$ & $60.83{\scriptstyle\pm0.35}$ & $88.85{\scriptstyle\pm0.60}$ & $72.67{\scriptstyle\pm1.07}$ & $71.62{\scriptstyle\pm1.06}$ & $\mathbf{75.46}$ \\
\midrule
Alt-PT
& $89.67{\scriptstyle\pm1.00}$ & $69.19{\scriptstyle\pm0.57}$ & $60.73{\scriptstyle\pm0.66}$ & $88.95{\scriptstyle\pm1.08}$ & $72.80{\scriptstyle\pm1.36}$ & $70.58{\scriptstyle\pm0.65}$ & 75.32 \\
Alt-TP
& $89.86{\scriptstyle\pm0.65}$ & $68.95{\scriptstyle\pm0.50}$ & $60.62{\scriptstyle\pm0.98}$ & $89.16{\scriptstyle\pm0.82}$ & $71.19{\scriptstyle\pm1.69}$ & $70.39{\scriptstyle\pm1.15}$ & 75.03 \\
\bottomrule
\end{tabular}}
\end{table*}

\subsection{Optimization Strategy Analysis}
The commitment and refinement module serves two purposes: it regularizes the teacher’s feature space toward the prototype space and simultaneously refines the prototypes to capture transferable, high-level semantics. In this section, we evaluate the influence of optimizing these two components simultaneously on prototype distinctiveness by overly coupling their learning dynamics. To examine this, we compare the default \emph{joint} optimization strategy in ProMoS with two epoch-level \emph{alternating} strategies: (i) \textbf{Alt-PT}, which first updates the prototypes and then applies the commitment loss to regularize the teacher features; and (ii) \textbf{Alt-TP}, which first regularizes the teacher features and then updates the prototypes. 

Table~\ref{tab:cr_strategy_ablation} summarizes the results across six datasets. All three strategies yield highly consistent performance, and the joint optimization used in ProMoS achieves the best average AUC. These findings indicate that simultaneous optimization does not compromise prototype distinctiveness; instead, the joint strategy remains a stable and effective choice for aligning the teacher feature space with the evolving prototype semantics.

\section{Conclusion}
In this work, we introduced ProMoS, the first fully unsupervised generalist GAD framework that enables zero-shot detection on unseen graphs. ProMoS transfers rich normal patterns from a frozen self-supervised GNN teacher to a lightweight mixture-of-students via prototype-guided soft-label distillation in a learnable high-level semantic space. Our discrepancy-aware commitment and refinement mechanism further enhances generalization by stabilizing teacher outputs and refining semantic prototypes. 
Extensive experiments on eleven real-world graphs show that ProMoS achieves superior accuracy and sub-linearly scaling inference, with top AUROC on nine datasets and a 14.12\% average gain. Overall, this work lays the groundwork for scalable, label-free generalist graph anomaly detection.

\section*{Acknowledgements}
This research was partially supported by the Key Research and Development Project in Shaanxi Province No. 2024PT-ZCK-89, the National Natural Science Foundation of China Nos. 62406242, 62476215, 62302380, 62037001 and 62137002, and the Project of China Knowledge Centre for Engineering Science and Technology.

\section*{Impact Statement}
This paper presents a general, annotation-free graph anomaly detection method with zero-shot transferability, aiming to advance machine learning techniques for anomaly detection. The proposed approach may benefit high-risk applications such as financial risk control, social network analysis, and cybersecurity by reducing reliance on costly annotations and repeated training, thereby improving scalability and deployment efficiency. As with many learning-based methods, potential risks include biased predictions or false alarms due to data shift or distribution mismatch, which could lead to unfair decisions in sensitive settings. In practice, we recommend using the model’s outputs as auxiliary signals within human-in-the-loop and accountable decision-making processes to mitigate these risks.

% Authors are \textbf{required} to include a statement of the potential broader
% impact of their work, including its ethical aspects and future societal
% consequences. This statement should be in an unnumbered section at the end of
% the paper (co-located with Acknowledgements -- the two may appear in either
% order, but both must be before References), and does not count toward the paper
% page limit. In many cases, where the ethical impacts and expected societal
% implications are those that are well established when advancing the field of
% Machine Learning, substantial discussion is not required, and a simple
% statement such as the following will suffice:

% ``This paper presents work whose goal is to advance the field of Machine
% Learning. There are many potential societal consequences of our work, none
% which we feel must be specifically highlighted here.''

% The above statement can be used verbatim in such cases, but we encourage
% authors to think about whether there is content which does warrant further
% discussion, as this statement will be apparent if the paper is later flagged
% for ethics review.

% In the unusual situation where you want a paper to appear in the
% references without citing it in the main text, use \nocite
\nocite{langley00}

\bibliography{icml_paper}
\bibliographystyle{icml2026}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% APPENDIX
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\newpage
\appendix
\onecolumn

\section{Proof of Theorem 1}\label{sec:proof}
\begin{theorem}[Error reduction of MoS]
Consider a graph $\mathcal{G}=(\mathcal V,\mathcal E,\mathbf X)$. 
For any node $i \in \mathcal V$, let the Mixture-of-Students (MoS) architecture consist of $\{S_k\}_{k=1}^{N}$ student models with outputs $\widehat{f}(i)$.
Then, for any single student $k \in \{1,\ldots,N\}$, the MoS prediction achieves no larger expected prediction error than the single student:
\begin{equation}
\mathbb{E}\!\left[(y_i-\widehat{f}(i))^2 \,\middle|\, \mathcal{G}\right]
\;\le\;
\mathbb{E}\!\left[(y_i-f_k(i))^2 \,\middle|\, \mathcal{G}\right].
\end{equation}
\end{theorem}

where $y_i$ denotes the ground-truth label of node $i$, $f_k(i)$ is the output of the $k$-th student.

\begin{proof}
To formalize the predictive mechanism of the Mixture-of-Students (MoS), we describe how multiple student models are combined through router weights to produce the final output. Specifically, the MoS prediction for node $i\in\mathcal V$ is defined as the weighted sum:
\begin{equation}
\label{eq:mos}
\widehat f(i)\;=\;\sum_{k=1}^{N} g_{i,k}\, f_k(i)\;=\;\mathbf g_i^\top \mathbf f(i),
\end{equation}
where $f_k(i)$ denotes the output of the $k$-th student $S_k$, 
$\mathbf g_i=(g_{i,1},\ldots,g_{i,N})^\top\in\Delta^N$ are the router weights with 
$\sum_{k=1}^N g_{i,k}=1$ and $g_{i,k}\ge0$, and 
$\mathbf f(i)=(f_1(i),\ldots,f_N(i))^\top$ stacks all individual student outputs. 


To analyze the prediction error of MoS, we expand the expected squared loss and 
separate it into bias, variance, and noise. Each label is modeled as 
$y_i = f_i^\star + \epsilon$, where $f_i^\star$ represents the deterministic ground-truth component of node $i$, and $\epsilon$ is a stochastic residual 
typically modeled as Gaussian noise $\epsilon \sim \mathcal{N}(0,\sigma^2)$. 
Under this formulation, the decomposition proceeds as:
\begin{equation}
\begin{aligned}
\mathbb{E}\!\left[(y_i - \widehat f(i))^2 \right] 
&= \mathbb{E}\!\left[y_i^2 - 2y_i \widehat f(i) + \widehat f(i)^2 \mid \mathcal{G}\right] \\[4pt]
&= \mathbb{E}[y_i^2] - 2\mathbb{E}[y_i \widehat f(i)] + \mathbb{E}[\widehat f(i)^2] \\[4pt]
&= \mathbb{E}[(f_i^\star + \epsilon)^2] - 2\mathbb{E}[(f_i^\star+\epsilon)\widehat f(i)] + \mathbb{E}[\widehat f(i)^2] \\[4pt]
&= \mathbb{E}[(f_i^\star)^2] + 2\mathbb{E}[f_i^\star \epsilon] + \mathbb{E}[\epsilon^2] 
   - 2\mathbb{E}[f_i^\star \widehat f(i)] - 2\mathbb{E}[\epsilon \widehat f(i)] + \mathbb{E}[\widehat f(i)^2] \\[4pt]
&= (f_i^\star)^2 + \sigma^2 - 2f_i^\star\mathbb{E}[ \widehat f(i)] - 2\mathbb{E}[\epsilon]\mathbb{E}[\widehat f(i)] + \mathbb{E}[\widehat f(i)^2] \\[4pt]
&= (f_i^\star)^2 + \sigma^2 - 2 f_i^\star \,\mathbb{E}[\widehat f(i)] + \mathbb{E}[\widehat f(i)^2] \\[4pt]
&= (f_i^\star)^2 + \sigma^2 - 2 f_i^\star \,\mathbb{E}[\widehat f(i)] 
   + \mathrm{Var}(\widehat f(i)) + \big(\mathbb{E}[\widehat f(i)]\big)^2 \\[4pt]
&= \underbrace{\big(f_i^\star - \mathbb{E}[\widehat f(i)\mid\mathcal G]\big)^2}_{\text{Bias}} 
   + \underbrace{\mathrm{Var}(\widehat f(i)\mid\mathcal G)}_{\text{Variance}} 
   + \underbrace{\sigma^2(\mathcal G)}_{\text{Noise}} .
\end{aligned}
\end{equation}

In parallel, the expected squared loss of a single student $S_k$ can be decomposed in the same manner, yielding:
\begin{equation}
\mathbb{E}\!\left[(y_i - f_k(i))^2 \,\middle|\, \mathcal{G}\right]
= \underbrace{\big(f_i^\star - \mathbb{E}[f_k(i)\mid\mathcal G]\big)^2}_{\text{Bias}}
+ \underbrace{\mathrm{Var}(f_k(i)\mid\mathcal G)}_{\text{Variance}}
+ \underbrace{\sigma^2(\mathcal G)}_{\text{Noise}} .
\end{equation}


To establish a direct comparison between MoS and an individual student $S_k$, we consider the difference in their conditional prediction errors, $\mathbb{E}\!\left[(y_i-\widehat f(i))^2 \mid \mathcal{G}\right]
-\mathbb{E}\!\left[(y_i-f_k(i))^2 \mid \mathcal{G}\right]$. 
Substituting the bias–variance–noise decomposition into both terms gives:
\begin{equation}
\label{eq:gap-bvn}
\begin{aligned}
&\mathbb{E}\!\left[(y_i-\widehat f(i))^2 \,\middle|\, \mathcal{G}\right]
-\mathbb{E}\!\left[(y_i-f_k(i))^2 \,\middle|\, \mathcal{G}\right] \\
&\quad=\;
\underbrace{\Big(f_i^\star-\mathbb{E}[\widehat f(i)\mid\mathcal G]\Big)^2
-\Big(f_i^\star-\mathbb{E}[f_k(i)\mid\mathcal G]\Big)^2}_{\text{Bias difference}}
\;+\;
\underbrace{\mathrm{Var}(\widehat f(i)\mid\mathcal G)
-\mathrm{Var}(f_k(i)\mid\mathcal G)}_{\text{Variance difference}}.
\end{aligned}
\end{equation}


Then, we introduce a mild mean alignment hypothesis reflecting that all students are trained under the same target/teacher and differ only in stochasticity:
\begin{equation}\label{eq:mean-align}
\mathbb{E}\!\left[f_k(i)\mid \mathcal G\right] \;=\; \mu_i(\mathcal G)\qquad \text{for all } k\in\{1,\ldots,N\}.
\end{equation}
Combining Eq.~\ref{eq:mean-align} with the MoS predictor in Eq.~\ref{eq:mos} and the simplex constraint
$\mathbf 1^\top \mathbf g_i = 1$, we obtain
\begin{equation}\label{eq:mos-mean}
\mathbb{E}\!\left[\widehat f(i)\mid \mathcal G\right]
= \mathbb{E}\!\left[\mathbf g_i^\top \mathbf f(i)\mid \mathcal G\right]
= \mathbf g_i^\top \mathbb{E}\!\left[\mathbf f(i)\mid \mathcal G\right]
= \mathbf g_i^\top \big(\mu_i(\mathcal G)\mathbf 1\big)
= \mu_i(\mathcal G).
\end{equation}
Therefore the two bias terms in Eq.~\ref{eq:gap-bvn} coincide:
\[
\Big(f_i^\star-\mathbb{E}[\widehat f(i)\mid\mathcal G]\Big)^2
\;=\;
\Big(f_i^\star-\mathbb{E}[f_k(i)\mid\mathcal G]\Big)^2
\;=\;
\Big(f_i^\star-\mu_i(\mathcal G)\Big)^2,
\]
and the bias difference vanishes. Consequently, the expected prediction error simplifies to the:
\begin{equation}
\mathbb{E}\!\left[(y_i-\widehat f(i))^2 \mid \mathcal{G}\right]
-\mathbb{E}\!\left[(y_i-f_k(i))^2 \mid \mathcal{G}\right]
= \mathrm{Var}(\widehat f(i)\mid\mathcal G)-\mathrm{Var}(f_k(i)\mid\mathcal G).
\end{equation}

%%%%%%%%%%%%%%%%

Having reduced the comparison to the variance gap, we now compute both terms explicitly.
Let $\mathbf m:=\mathbb{E}[\mathbf f(i)\mid\mathcal G]$, and 
$\Sigma_{\mathcal G}:=\mathrm{Cov}(\mathbf f(i)\mid\mathcal G)
=\mathbb{E}\!\left[(\mathbf f-\mathbf m)(\mathbf f-\mathbf m)^\top\mid\mathcal G\right]$.
Since the router weights $\mathbf g_i$ are $\mathcal G$–measurable (given $\mathcal G$ and node $i$), the conditional variance of the MoS predictor satisfies:
\begin{equation}
\label{eq:var-mos-steps}
\begin{aligned}
\mathrm{Var}(\widehat f(i)\mid\mathcal G)
&= \mathbb{E}\!\left[\big(\widehat f(i)-\mathbb{E}[\widehat f(i)\mid\mathcal G]\big)^2 \,\middle|\, \mathcal G\right] \\[2pt]
&= \mathbb{E}\!\left[\big(\mathbf g_i^\top\mathbf f - \mathbf g_i^\top\mathbf m\big)^2 \,\middle|\, \mathcal G\right]\\[2pt]
&= \mathbb{E}\!\left[\big(\mathbf g_i^\top(\mathbf f-\mathbf m)\big)^2 \,\middle|\, \mathcal G\right] \\[2pt]
&= \mathbb{E}\!\left[(\mathbf f-\mathbf m)^\top(\mathbf g_i\mathbf g_i^\top)(\mathbf f-\mathbf m) \,\middle|\, \mathcal G\right] \\[2pt]
&= \mathrm{tr}\!\left(\mathbf g_i\mathbf g_i^\top\ \mathbb{E}\!\left[(\mathbf f-\mathbf m)(\mathbf f-\mathbf m)^\top \,\middle|\, \mathcal G\right]\right) \\[2pt]
&= \mathrm{tr}\!\left(\mathbf g_i\mathbf g_i^\top \Sigma_{\mathcal G}\right)
= \mathbf g_i^\top \Sigma_{\mathcal G}\,\mathbf g_i.
\end{aligned}
\end{equation}

%%%%%%%%%%%%%%%%%%%
To further simplify the variance expression, we impose a standard 
\emph{equicorrelation} structure on the student outputs. Specifically, we assume 
that each student has the same conditional variance $v(\mathcal G)$ and any pair 
shares a common conditional correlation $\rho(\mathcal G)\in[-1,1]$. Formally,
\begin{equation}
\mathrm{Var}(f_k(i)\mid\mathcal G)=v(\mathcal G), 
\quad 
\mathrm{Corr}(f_k(i),f_r(i)\mid\mathcal G)=\rho(\mathcal G),\ \ \forall k\neq r.
\end{equation}
Under this assumption, the covariance matrix admits the closed form:
\begin{equation}
\label{eq:sigma-equi}
\Sigma_{\mathcal G}
= v(\mathcal G)\Big((1-\rho(\mathcal G))I+\rho(\mathcal G)\,\mathbf 1\mathbf 1^\top\Big),
\end{equation}
where $\mathbf 1$ is the all-ones vector in $\mathbb{R}^N$.

We next compute $\mathrm{Var}(\widehat f(i)\mid\mathcal G)$ under the Eq.~\ref{eq:var-mos-steps} that $\mathrm{Var}(\widehat f(i)\mid\mathcal G)=\mathbf g_i^\top \Sigma_{\mathcal G}\,\mathbf g_i$, and from Eq.~\ref{eq:sigma-equi} that
$\Sigma_{\mathcal G}=v(\mathcal G)\big((1-\rho(\mathcal G))I+\rho(\mathcal G)\mathbf 1\mathbf 1^\top\big)$. Substituting and simplifying yields:
\begin{equation}
\label{eq:var-mos-equi-deriv}
\begin{aligned}
\mathrm{Var}(\widehat f(i)\mid\mathcal G)
&= \mathbf g_i^\top \Big[v(\mathcal G)\big((1-\rho(\mathcal G))I+\rho(\mathcal G)\mathbf 1\mathbf 1^\top\big)\Big]\mathbf g_i \\[2pt]
&= v(\mathcal G)\Big((1-\rho(\mathcal G))\,\mathbf g_i^\top \mathbf g_i
\;+\;\rho(\mathcal G)\,\mathbf g_i^\top \mathbf 1\mathbf 1^\top \mathbf g_i\Big) \\[2pt]
&= v(\mathcal G)\Big((1-\rho(\mathcal G))\,\|\mathbf g_i\|_2^2
\;+\;\rho(\mathcal G)\,(\mathbf 1^\top \mathbf g_i)^2\Big) \\[2pt]
&= v(\mathcal G)\Big(\rho(\mathcal G)+(1-\rho(\mathcal G))\|\mathbf g_i\|_2^2\Big).
\end{aligned}
\end{equation}


Therefore, combining the decompositions, we have:
\begin{equation}\label{eq:err-gap-final}
\begin{aligned}
\mathbb{E}\!\left[(y_i-\widehat f(i))^2 \mid \mathcal G\right]
-\mathbb{E}\!\left[(y_i-f_k(i))^2 \mid \mathcal G\right]
&= \mathrm{Var}(\widehat f(i)\mid\mathcal G)-\mathrm{Var}(f_k(i)\mid\mathcal G) \\[2pt]
&= v(\mathcal G)\Big(\rho(\mathcal G)+(1-\rho(\mathcal G))\|\mathbf g_i\|_2^2\Big)-v(\mathcal G) \\[2pt]
&= -\,v(\mathcal G)\big(1-\rho(\mathcal G)\big)\big(1-\|\mathbf g_i\|_2^2\big)\;\le\;0 .
\end{aligned}
\end{equation}
\textit{where} $v(\mathcal G)\!\ge\!0$, $\rho(\mathcal G)\!\le\!1$, and 
$\|\mathbf g_i\|_2^2\!\le\!1$ for any $\mathbf g_i\!\in\!\Delta^N$ (equality iff $\mathbf g_i$ is one–hot).

In particular, if the router activates at least two students, then $\|\mathbf g_i\|_2^2<1$ and the inequality is strict. 
This completes the proof. \hfill\qedhere

\end{proof}


\begin{algorithm}[!t]
\caption{ProMoS: Prototype-Guided Mixture-of-Students for Generalist GAD}
\label{alg:promos}
\begin{algorithmic}[1]
\REQUIRE Training graphs $\mathcal{T}_{\text{train}}$; frozen teacher $f_T$; adapter $g_\phi$; shared student $S_g$; personalized students $\{S_p^{\ell}\}_{p=1}^N$; prototype codebooks $\{\mathbf{P}_b\}_{b\in\{g,\ell\}}$; epochs $E$; temperature $\tau$; Top-$K$ router.
\ENSURE Zero-shot anomaly scoring function $s:V\!\to\!\mathbb{R}$.

\STATE \textbf{Stage A: Initialization}
\STATE Initialize learnable parameters $\theta_g$, $\{\theta_p^{\ell}\}_{p=1}^N$, router $\mathbf{W}_r$, adapter $\phi$
\STATE Initialize prototypes $\{\mathbf{P}_b\}$ by clustering node embeddings (e.g., k-means)

\STATE \textbf{Stage B: Training (teacher frozen)}
% \FOR{$e = 1$ \TO $E$}
\FOR{$e = 1,\dots,E$}
  \FOR{each $\mathcal{D}^{(i)}\in \mathcal{T}_{\text{train}}$}
    \STATE Extract node features and adjacency $(\mathbf{X}^{(i)},\mathbf{A}^{(i)})$
    \STATE \textit{// Teacher forward (stop-grad) and calibration}
    \STATE $\mathbf{U}_T \leftarrow f_T(\mathbf{X}^{(i)},\mathbf{A}^{(i)})$; $\mathbf{Z}_T \leftarrow g_\phi(\mathbf{U}_T)$

    \STATE \textit{// Shared branch}
    \STATE $\mathbf{h}^{g} \leftarrow S_g(\tilde{\mathbf{X}}_i^{(i)};\theta_g)$

    \STATE \textit{// Personalized branch with sparse Top-$K$ routing}
    \STATE $\mathbf{r} \leftarrow \mathrm{softmax}(\mathbf{W}_r\, \tilde{\mathbf{X}}_i^{(i)})$; $g_{i,p} \leftarrow \text{Top-}K(\mathbf{r}_i)$; $\mathbf{h}^{\ell} \leftarrow \sum_{p=1}^{N} g_{i,p}\, S_p^{\ell}(\tilde{\mathbf{X}}_i^{(i)};\theta_p^{\ell})$

    \STATE \textit{// Prototype-guided soft-label distillation (PSD)}
    \FOR{each $b\in\{g,\ell\}$}
      \STATE $\mathbf{q}_i^{\,b} \propto \exp(\mathrm{sim}(\mathbf{z}_i^{t},\mathbf{P}_b)/\tau)$; $\mathbf{s}_i^{\,b} \propto \exp(\mathrm{sim}(\mathbf{h}_i^{\,b},\mathbf{P}_b)/\tau)$
    \ENDFOR
    \STATE $\mathcal{L}_{\mathrm{PSD}} \leftarrow \frac{1}{|V|}\sum_i\sum_{b}\mathrm{KL}\!\big(\mathbf{q}_i^{\,b}\,\|\,\mathbf{s}_i^{\,b}\big)$

    \STATE \textit{// Discrepancy-aware commitment \& refinement (DCR)}
    \FOR{each $b\in\{g,\ell\}$}
      \STATE $\mathcal{Z}_b(\mathbf{z}_i^{t}) \leftarrow \arg\min_{\mathbf{p}_m\in \mathbf{P}^b}\|\mathbf{z}_i^{t}-\mathbf{p}_m^b\|_2^2$
      \STATE Compute reliability $w_i^b$ from prototype relations $\mathbf{Q}_b$
    \ENDFOR
    \STATE $\mathcal{L}_{\mathrm{DCR}} \leftarrow \sum_i\sum_b w_i^b\!\left(\|\mathbf{z}_i^{t}-\mathrm{sg}[\mathcal{Z}_b(\mathbf{z}_i^{t})]\|_2^2
      + \|\mathrm{sg}[\mathbf{z}_i^{t}]-\mathcal{Z}_b(\mathbf{z}_i^{t})\|_2^2\right)$

    \STATE \textit{// Overall objective and updates (teacher frozen)}
    \STATE $\mathcal{L} \leftarrow \mathcal{L}_{\mathrm{PSD}} + \lambda\,\mathcal{L}_{\mathrm{DCR}}$
    \STATE Update $S_g$, $\{S_p^{\ell}\}_{p=1}^N$, $\mathbf{W}_r$, $\phi$, and $\{\mathbf{P}_b\}$ by gradient descent on $\mathcal{L}$
  \ENDFOR
\ENDFOR

\STATE \textbf{Stage C: Zero-shot inference on unseen graph $\mathcal{G}=(\mathcal V,\mathcal E,\mathbf X)$ (no retraining)}
\STATE Compute $\mathbf{Z}_T$, $\mathbf{h}^{g}$, $\mathbf{h}^{\ell}$, soft labels $\{\mathbf{q}^b\}$, predictions $\{\mathbf{s}^b\}$, and quantizers $\mathcal{Z}_b(\cdot)$ as above
\FOR{each node $v_i\in V$}
  \STATE $s_i \leftarrow \sum_{b\in\{g,\ell\}}
  \Big[
    \mathrm{KL}\!\big(\mathbf{q}_i^{\,b}\,\|\,\mathbf{s}_i^{\,b}\big)
    + \lambda\big(\|\mathbf{h}_i^{\,b}-\mathcal{Z}_b(\mathbf{h}_i^{\,b})\|_2^2
    + \|\mathbf{z}_i^{t} - \mathcal{Z}_b(\mathbf{z}_i^{t})\|_2^2\big)
  \Big]$
\ENDFOR
% \RETURN $s(\cdot)$
\STATE \textbf{return} $s(\cdot)$
\end{algorithmic}
\end{algorithm}



\section{Algorithms}
\label{sec:algorithms}

Algorithm~\ref{alg:promos} outlines ProMoS, prototype-guided mixture-of-students framework for generalist GAD. 

\paragraph{Initialization.}
We freeze the pretrained teacher $f_T$, introduce an adapter $g_\phi$, and initialize a shared student $S_g$, personalized students ${S_p^{\ell}}_{p=1}^N$, router $\mathbf{W}_r$, and prototypes ${\mathbf{P}_b}$ from clustered node embeddings. \looseness=-1

\paragraph{Training.}
Given training graphs, the teacher produces calibrated features. The shared branch models global patterns, while the personalized branch employs sparse Top-$K$ routing for efficiency. Students are guided by prototype soft-label distillation, enforcing alignment with teacher semantics, and by discrepancy-aware commitment and refinement, which stabilize the teacher's output and update prototypes using sample reliability weighting. The total loss combines these two objectives.

\paragraph{Inference.}
On unseen graphs, no retraining is required. We compute teacher and student features, project them into prototype space, and score anomalies by combining distillation bias with geometric deviation. This enables zero-shot detection across diverse graphs.


\section{Time Complexity Analysis}\label{sec:complexity}
\textbf{Theoretical Analysis.} 
In this section, we analyze the time complexity of ProMoS by dividing it into the encoder and the loss functions. Since the teacher model is pre-computed offline, its cost is negligible and omitted from the analysis. For the encoder, the main components include the adapter, the router, and the student models. The adapter projects each node representation into the student space with complexity $\mathcal{O}(n d^2)$, where $n=|\mathcal{V}|$ is the number of nodes and $d$ is the embedding dimension. The router computes gating logits over $N$ students and performs a Top-$K$ selection, leading to $\mathcal{O}(n d N)$. For student forward propagation, one shared student and $K$ activated personalized students are applied to each node, giving $\mathcal{O}(n (K{+}1) d^2)$. 
For the loss functions, the prototype-driven soft-label distillation requires computing similarities between each node and $M$ prototypes, which takes $\mathcal{O}(n d M)$, where $M$ is the number of prototypes. The commitment loss and refinement loss introduce an additional residual computation with $\mathcal{O}(n d)$ and prototype–prototype similarity construction with $\mathcal{O}(dM^2)$. Finally, router regularization terms such as load-balancing and z-loss incur $\mathcal{O}(n N)$. Therefore, the overall training complexity of ProMoS is $\mathcal{O}\big(nKd^2 + ndN + ndM + dM^2\big)$.

Table~\ref{tab:complexity_comparison} summarizes the complexity comparison with representative generalist GAD methods. In practice, the number of edges is usually much larger than the number of nodes, i.e., $m \gg n \gg \{K,N,M,K'\}$. Hence, the edge- and node-related terms dominate the overall cost, while contributions from the number of activated students $K$ (typically fixed to $K=2$), the number of students $N$, and the number of prototypes $M$ can be regarded as negligible constants. Consequently, the complexity of ProMoS remains comparable to existing generalist GAD methods, while providing enhanced scalability and flexibility through its mixture-of-students design.

\textbf{Empirical Analysis.} As shown in Figure~\ref{fig:appendix_time}, in addition to reporting the overall training and inference time, we also provide the per-epoch training time and include comparisons with DOMINANT and TAM. Notably, DOMINANT runs out of memory on T-Finance, and thus its inference time excludes this dataset. Reconstruction-based methods, such as DOMINANT, require rebuilding the full adjacency matrix, making them infeasible for large graphs. TAM incurs even higher costs, as it relies on multi-round graph truncation and multi-network training, leading to substantial complexity in both training and inference. In contrast, ProMoS achieves remarkably low per-epoch training cost, second only to GCN and GAT, while delivering superior inference efficiency: it is 1.4× faster than GCN, the fastest baseline, and improves over existing GAD methods by orders of magnitude. These results further highlight ProMoS as an efficient and scalable solution for generalist GAD.

We further investigate the impact of different MoS architectures on both efficiency and performance. The \textit{All} variant activates all student branches simultaneously, while the \textit{Single} variant replaces the personalized branch with a single student of equivalent parameter count (achieved by widening its hidden layers). As shown in Figure~\ref{fig:appendix_mos}, the sparsely-activated MoS achieves the best AUROC while maintaining the lowest training and inference cost. This demonstrates that dynamic sparsification enables more efficient parameter utilization, striking a favorable balance between expressiveness and efficiency.



\begin{table}[t]
\caption{Comparison of the complexity of generalist GAD methods. 
Here, $n=|\mathcal{V}|$ is the number of nodes, $m=|\mathcal{E}|$ is the number of edges, $d$ is the feature dimension, $N$ is the number of students, $K$ is the number of activated students, $M$ is the number of prototypes, $n_q$ is the number of query nodes and $n_k$ is the number of context nodes in ARC, and $K'$ is size of each graph prompt in UNPrompt.}
\centering
\small
\begin{tabular}{lc}
\toprule
\textbf{Method} & \textbf{Complexity} \\\midrule
ARC~\citep{liu2024arc} & $\mathcal{O}\big(nd^2 + ed + n_qn_kd + d \log d\big)$ \\
UNPrompt~\citep{niu2024zero} & $\mathcal{O}\big(nd^2 + ed + K'nd\big)$ \\
AnomalyGFM~\citep{qiao2025anomalygfm} & $\mathcal{O}\big(md^2 + n^2d + nd + d^2\big)$ \\\midrule
\textbf{ProMoS (Ours)} & $\mathcal{O}\big(nKd^2 + ndN + ndM + dM^2\big)$  \\
\bottomrule
\end{tabular}
\label{tab:complexity_comparison}
\end{table}


\begin{figure*}[t]
  \centering
  \begin{minipage}{0.695\linewidth}
    \centering
    \includegraphics[width=\linewidth]{figures/runtime_with_per_epoch.pdf}
    \caption{Time comparison with baseline.}
    \label{fig:appendix_time}
  \end{minipage}
  \hfill
  \begin{minipage}{0.295\linewidth}
    \centering
    \includegraphics[width=\linewidth]{figures/mos_ablation.pdf}
    \caption{Performance comparison with MoS variants.}
    \label{fig:appendix_mos}
  \end{minipage}
\end{figure*}

    
\section{More Experimental Setup}
\subsection{Datasets details}\label{sec:appendix_datasets}
We evaluate on 15 benchmark datasets spanning diverse domains, as summarized in Table~\ref{tab:dsets_statis}. To ensure broad coverage, the datasets are grouped into 8 categories: citation networks with injected anomalies (Cora, CiteSeer, ACM, PubMed), social networks with injected anomalies (BlogCatalog, Flickr), social networks with real anomalies (Facebook, Weibo, Reddit, Questions), co-review networks with real anomalies (YelpChi), co-author with injected anomalies (CoAuthor CS) and co-purchase networks with injected anomalies (Amazon Photo), crowd-sourcing service network with real anomalies (Tolokers) and finance networks with real anomalies (T-Finance). 


Follow established protocols~\citep{dong2024universal,liu2024arc}, in the first four categories that contain two datasets each, we select the larger graph (PubMed, Flickr, Questions, and YelpChi) as the training dataset. The remaining 11 graphs, including the smaller counterparts (Cora, CiteSeer, ACM, BlogCatalog, Facebook, Weibo, Reddit) and the four single-domain datasets (CoAuthor CS, Amazon Photo, Tolokers, T-Finance), are used for evaluation. This design enables us to examine both in-domain generalization, where the model is tested on datasets from the same domains as the training graph, and out-of-domain generalization, where it is tested on datasets from other domains. This diversity provides a comprehensive testbed to evaluate the robustness and adaptability of to unseen graphs. Specifically, the detailed descriptions for the datasets are given as follows:

\begin{itemize}
    \item \textbf{Cora}, \textbf{CiteSeer}, \textbf{ACM}~\citep{tang2008arnetminer} and \textbf{PubMed}~\citep{sen2008collective} are four citation networks, where nodes denote scientific publications and edges capture citation relationships between them. Each publication is described by a bag-of-words feature vector, with the vocabulary size determining the attribute dimension.
    \item \textbf{BlogCatalog} and \textbf{Flickr}~\citep{ding2019deep,tang2009relational} are representative social blog directories, where nodes correspond to users with inter-node links symbolizing mutual following. The node features are constructed from personalized textual content generated by users, such as blog posts or tagged images, reflecting individual interests and activities.
    \item \textbf{YelpChi}~\citep{rayana2015collective,mcauley2013amateurs} is dataset about the relationship between users and reviews. YelpChi aims to identify anomalous reviews on Yelp.com that unfairly promote or demote products or businesses. Based on~\citep{mukherjee2013yelp,rayana2015collective}, three different graph datasets were derived from Yelp using different connections in user, product review text, and time. In this study, we focus on YelpChi-RUR (reviews posted by the same user).
    \item \textbf{Facebook}~\citep{xu2022contrastive}, \textbf{Weibo}~\citep{kumar2019predicting}, \textbf{Reddit}~\citep{kumar2019predicting} and \textbf{Questions}~\citep{platonov2023critical} are four social networks with real anomalies. Facebook is a social network in which users can build relationships with others and share with their friends. The Weibo dataset encompasses a graph of users and their associated hashtags from the Tencent Weibo platform. Suspicious behavior is defined by users posting multiple consecutive posts within a short temporal window (e.g., 60 seconds), with those exhibiting at least five such bursts labeled as anomalies. Node features combine geolocation information of the microblog post with bag-of-words features. Reddit serves as a forum for posts sourced from the social media platform Reddit, where users labeled as banned are identified as anomalies. Textual content from posts is encoded as vectors to serve as node attributes. Questions~\citep{platonov2023critical} is constructed from Yandex Q, an online question-answering platform. Nodes correspond to users, and edges indicate whether a question–answer interaction occurred within a one-year period. Each user is represented by the averaged FastText embedding of their profile description, augmented with a binary feature flagging missing descriptions.
    \item \textbf{CoAuthor CS}~\citep{shchur2018pitfalls} are co-authorship graphs derived from the Microsoft Academic Graph (KDD Cup 2016). Nodes represent authors, and edges connect pairs of authors who have co-authored a paper.  Node features represent paper keywords for each author’s papers, and class labels indicate the most active fields of study for each author.
    \item \textbf{Amazon Photo}~\citep{shchur2018pitfalls} is a subgraph of the Amazon co-purchase network~\citep{mcauley2015image}, where nodes correspond to products and edges indicate frequent co-purchases. Each product is described by bag-of-words features extracted from reviews, with labels derived from product categories.
    \item \textbf{Tolokers}~\citep{Tolokers} is constructed from the Toloka crowdsourcing platform. Nodes correspond to workers who participated in at least one of 13 selected projects, and edges link pairs of workers who completed the same task. Each node is described by profile attributes and task performance statistics, while labels indicate whether a worker was banned for anomalous behavior.
    \item \textbf{T-Finance}~\citep{bwgnn_tang2022rethinking} is a large-scale transaction network where nodes represent anonymized accounts characterized by ten features capturing registration days, logging activities, and interaction frequency. Edges connect pairs of accounts with transaction records. Human experts annotate nodes as anomalies if they fall into categories like fraud, money laundering, and online gambling. 
\end{itemize}


\noindent\textbf{Anomaly Injection.} To evaluate the effectiveness of our method in detecting diverse types of anomalies, we follow established practices~\citep{song2007conditional,ding2019deep,liu2021anomaly} by injecting an equal number of attributive and structural anomalies into each of the six datasets (ACM, PubMed, BlogCatalog, Flickr, CoAuthor CS, and Amazon Photo). Specifically, for structural anomalies, in a small clique, a small set of nodes are much more closely linked to each other than average, aligning with typical structural abnormalities observed in real-world networks~\citep{skillicorn2007detecting}. To simulate such anomalies, we commence by defining the clique size $p$ and the number of cliques $q$. When generating a clique,  $p$ nodes are randomly selected from the node set $\mathcal{V}$ and fully connected, thus marking all selected nodes $p$ as structural anomaly nodes. This process is iterated $q$ times to generate $q$ cliques, resulting in a total injection of  $p \times q$ structural anomalies. In particular, we fix $p=15$ and $q=5, 5, 20, 20, 10, 15, 20, 15$ on Cora, CiteSeer, ACM, PubMed, BlogCatalog, Flickr, CoAuthor CS, and Amazon Photo, respectively. For feature anomalies, inconsistencies between node features and their neighboring contexts represent another prevalent anomaly observed in real-world scenarios. Following the pattern introduced by~\citep{song2007conditional}, feature anomalies are created by perturbing node attributes. When generating a single feature anomaly, we first select a target node $v_i$ and then sample a set of $k$ nodes as candidates. Subsequently, from the candidate set, we choose the node $v_j$ with the maximum Euclidean distance from the feature of the target node $v_i$ , and replace $v_i$'s feature with that of $v_j$. Here, we set $k=50$ to ensure a sufficiently large perturbation magnitude. To ensure an equal balance in the quantity of both anomaly types, we set the number of feature anomalies to $p \times q$, implying that the above operation is repeated $p \times q$ times to generate all feature anomalies. 


\begin{table*}[t]
\caption{The statistics of datasets.} 
\centering
\label{tab:dsets_statis}
\resizebox{0.91\textwidth}{!}{
\begin{tabular}{l|cc|cccccc}
\toprule
Dataset & Train & Test & \#Nodes & \#Edges & \#Features & Avg. Degree &  \#Anomaly & \%Anomaly  \\
\midrule
\rowcolor[HTML]{E9E9E9} 
        \multicolumn{9}{c}{Citation network with injected anomalies} \\
Cora & - & $\checkmark$ & 2,708 & 5,429 & 1,433 & 3.90 &  150 & 5.53 \\
CiteSeer & - & $\checkmark$ & 3,327 & 4,732 & 3,703 & 2.77 &  150 & 4.50 \\
ACM & - & $\checkmark$ & 16,484 & 71,980 & 8,337 & 8.73 &  597 & 3.62 \\
PubMed & $\checkmark$ & - & 19,717 & 44,338 & 500 & 4.50 &  600 & 3.04 \\

\midrule
\rowcolor[HTML]{E9E9E9} 
        \multicolumn{9}{c}{Social network with injected anomalies} \\
BlogCatalog & - & $\checkmark$ & 5,196 & 171,743 & 8,189 & 66.11 &  300 & 5.77 \\
Flickr & $\checkmark$ & - & 7,575 & 239,738 & 12,047 & 63.30 &  450 & 5.94 \\
\midrule
\rowcolor[HTML]{E9E9E9} 
        \multicolumn{9}{c}{Social network with real anomalies} \\
Facebook & - & $\checkmark$ & 1,081 & 55,104 & 576 & 50.97 & 25 & 2.31 \\
Weibo & - & $\checkmark$ & 8,405 & 407,963 & 400 & 48.53 & 868 & 10.30 \\
Reddit & - & $\checkmark$ & 10,984 & 168,016 & 64 & 15.30 & 366 & 3.33 \\
Questions & $\checkmark$ & - & 48,921 & 153,540 & 301 & 3.13 & 1,460 & 2.98 \\

\midrule
\rowcolor[HTML]{E9E9E9} 
        \multicolumn{9}{c}{Co-review network with real anomalies} \\
YelpChi & $\checkmark$ & - & 23,831 & 49,315 & 32 & 2.07 & 1,217 & 5.10 \\
\midrule
\rowcolor[HTML]{E9E9E9} 
        \multicolumn{9}{c}{Co-author network with injected anomalies} \\
CoAuthor CS & - & $\checkmark$ & 18,333 & 163,788 & 6,805 & 8.93 & 600 & 3.27 \\
\midrule
\rowcolor[HTML]{E9E9E9} 
        \multicolumn{9}{c}{Co-purchase network with injected anomalies} \\
Amazon Photo & - & $\checkmark$ & 7,650 & 238,162 & 745 & 31.13 & 450 & 5.88 \\
\midrule
\rowcolor[HTML]{E9E9E9} 
        \multicolumn{9}{c}{Crowd-sourcing Service network with real anomalies} \\
Tolokers & - & $\checkmark$ & 11,758 & 519,000 & 10 & 44.14 & 2,566 & 21.82 \\
\midrule
\rowcolor[HTML]{E9E9E9} 
        \multicolumn{9}{c}{Finance network with real anomalies} \\
T-Finance & - & $\checkmark$ & 39,357 & 21,222,543 & 10 & 539.23 & 1,803 & 4.58 \\
\bottomrule
\end{tabular}
}
\end{table*}

\subsection{Implementation Details} \label{sec:appendix_implement}

\paragraph{Metrics.}
Following prior GAD protocols~\citep{ding2019deep,liu2021anomaly,liu2024arc,niu2024zero,qiao2025anomalygfm}, we report AUROC and AUPRC, two standard metrics for anomaly detection. AUROC is obtained by ranking nodes according to their anomaly scores and computing the area under the ROC curve, while AUPRC is measured as the area under the precision-recall curve. Higher AUROC and AUPRC values indicate better detection performance. All results are averaged over five independent runs with different random seeds, and reported as mean$\pm$std.


\textbf{Computing infrastructure.}
Experiments are carried out on a workstation running Ubuntu~22.04. 
The machine is equipped with an AMD EPYC~7542 processor (32 cores), a NVIDIA RTX~4090 GPU with CUDA~12.2 support, and 500\,GiB of system memory. 

\textbf{Software stack.}
We used Python~3.9.22, PyTorch~2.3.1+cu121, torchvision~0.18.1+cu121, torchaudio~2.3.1+cu121,
and DGL~0.9.0. For PyG we used torch-geometric~2.6.1 with
torch-scatter~2.1.2+pt23cu121, torch-sparse~0.6.18+pt23cu121,
torch-cluster~1.6.3+pt23cu121, and torch-spline-conv~1.2.2+pt23cu121.


\textbf{Implementation details.}
We adopt five representative pre-trained graph SSL teacher models, namely GCA~\citep{zhu2021graph} (default), GraphCL~\citep{you2020graph}, BGRL~\citep{thakoor2022large}, DGI~\citep{velivckovic2019deep} and GraphMAE~\citep{hou2022graphmae}. GraphMAE used its publicly available source code, while the other models used the official implementations and hyperparameter settings provided by the PyG-SSL toolkit~\citep{zheng2024pyg}. In addition, to prevent data leakage, the five representative graph SSL models are pre-trained exclusively on the training graphs $\mathcal{T}_{\text{train}}$. 
For each teacher model pre-training across multiple graphs, we follow established protocols~\citep{dong2024universal,liu2024arc}: in each pre-training epoch, the teacher model is trained \emph{sequentially} on the four graphs in $\mathcal{T}_{\text{train}}$. This ensures that the teacher model is trained across all training graphs following standard multi-graph SSL procedures. 
All baselines are configured to follow the same multi-graph pre-training paradigm for a fair comparison.
For prototype initialization, we collect the node features from all nodes in the training graphs $\mathcal{T}_{\text{train}}$, concatenate them into a single feature matrix, and apply FAISS k-means to derive the initial prototypes used by ProMoS.
For the rest of ProMoS, we conduct small grid sweeps around the default for all hyperparameters.
The learning rate spans
\(\{10^{-2},\,5\times10^{-2},\,10^{-3},\,2\times10^{-3},\,5\times10^{-3},\,10^{-4},\,5\times10^{-4},\,10^{-5}\}\);
the number of training epochs is
\(\{5,\,10,\,25,\,50,\,75,\,100,\,150,\,200\}\);
the trade-off parameter \(\lambda\) is
\(\{0.1,\,0.3,\,0.5,\,0.7,\,1.0,\,1.2,\,1.5,\,2.0\}\);
the number of students \(N\) is
\(\{2,\,5,\,10,\,15,\,20,\,25,\,30,\,50\}\);
the number of prototypes \(M_b\) is
\(\{2,\,5,\,10,\,15,\,20,\,25,\,30,\,50\}\);
the routed activate top-\(K\) students is
\(\{2,\,4,\,6,\,8,\,10,\,12,\,16,\,20\}\);
the sharpness \(\beta\) is
\(\{0.2,\,0.4,\,0.6,\,0.8,\,1.0,\,1.2,\,1.6,\,2.0\}\);
the margin \(\mu\) is
\(\{0.1,\,0.2,\,0.4,\,0.5,\,0.6,\,0.8,\,0.9,\,1.0\}\);
and the temperature \(\tau\) is
\(\{0.2,\,0.5,\,0.7,\,1.0,\,1.5,\,2.0,\,2.5,\,3.0\}\).
Hyperparameters are selected by choosing the configuration with the lowest proxy objective. After tuning, we adopt the configuration with learning rate $5\times10^{-3}$, epochs is 10, trade-off parameter $\lambda=0.5$, number of students \(N\) is 20, number of prototypes \(M_B\) is 20, top-\(K\) is 2, sharpness $\beta=1$, margin $\mu=0.6$, temperature $\tau=2$. Importantly, ProMoS is trained once and then directly transferred to unseen test graphs, without any dataset-specific hyperparameter search or tuning on the test datasets. \looseness=-1


\section{Supplemental Experiments}
\label{sec:se}
\subsection{Comparison with Few-Shot Generalist GAD}\label{sec:few-shot}
We further compare our method with two representative few-shot generalist methods, ARC and AnomalyGFM, under the 10-shot setting. Both ARC and AnomalyGFM rely on supervised pre-training on the training graphs and require access to 10 labeled nodes from the unseen test graph at inference, whereas ProMoS remains fully unsupervised throughout. As shown in Table~\ref{tab:few-shot}, AnomalyGFM benefits noticeably from few-shot inference compared to its zero-shot performance. Nevertheless, ProMoS achieves the best AUROC on 6 out of 11 datasets and ranks second on the remaining 5, yielding a higher overall average than all few-shot baselines. These results underscore that our method not only delivers state-of-the-art performance but also eliminates the reliance on scarce and costly labels, thereby greatly simplifying practical deployment.


\begin{table*}[!t]
\caption{AUROC (\%, mean$\pm$std over five runs) on eleven datasets, comparing with supervised pre-training methods using few-shot inference (ARC~\citep{liu2024arc} and AnomalyGFM~\citep{qiao2025anomalygfm}), while ours is fully unsupervised and pre-trained only. \textcolor{firstcolor}{\textbf{\underline{$\mathbf{1^{st}}$}}} marks the best result, \textcolor{secondcolor}{\underline{$\mathbf{2^{nd}}$}} the runner-up, and \textcolor{thirdcolor}{\underline{$\mathbf{3^{rd}}$}}.}
\centering
\label{tab:few-shot}

% ---------------- Part 1: first 6 datasets ----------------
\resizebox{0.9\textwidth}{!}{
\begin{tabular}{l|cccccc}
\toprule
Method & Cora & CiteSeer & ACM & BlogCatalog & Facebook & Weibo \\
\midrule
\rowcolor[HTML]{E9E9E9} 
\multicolumn{7}{c}{Supervised - Pre-Train \& Few-Shot Inference} \\
ARC & $\first{87.45{\scriptstyle\pm0.74}}$ & $\first{90.95{\scriptstyle\pm0.59}}$ & $\second{79.88{\scriptstyle\pm0.28}}$ & $\second{74.76{\scriptstyle\pm0.06}}$ & $\third{67.56{\scriptstyle\pm1.60}}$ & $\second{88.85{\scriptstyle\pm0.14}}$ \\
AnomalyGFM & $\third{56.31{\scriptstyle\pm1.11}}$ & $\third{51.27{\scriptstyle\pm1.48}}$ & $\third{64.03{\scriptstyle\pm0.93}}$ & $\third{67.68{\scriptstyle\pm0.99}}$ & $\first{75.66{\scriptstyle\pm2.46}}$ & $\third{56.91{\scriptstyle\pm2.55}}$ \\
\midrule
\rowcolor[HTML]{E9E9E9} 
\multicolumn{7}{c}{Unsupervised - Pre-Train Only} \\
ProMoS & $\second{84.56{\scriptstyle\pm0.16}}$ & $\second{90.77{\scriptstyle\pm0.12}}$ & $\first{89.47{\scriptstyle\pm0.79}}$ & $\first{76.17{\scriptstyle\pm0.37}}$ & $\second{69.31{\scriptstyle\pm0.50}}$ & $\first{91.74{\scriptstyle\pm0.03}}$ \\
\bottomrule
\end{tabular}
}

\resizebox{0.9\textwidth}{!}{
\begin{tabular}{l|cccccc}
\toprule
Method & Reddit & CS & Photo & Tolokers & T\text{-}Finance & Avg. \\
\midrule
\rowcolor[HTML]{E9E9E9} 
\multicolumn{7}{c}{Supervised - Pre-Train \& Few-Shot Inference} \\
ARC & $\second{60.04{\scriptstyle\pm0.69}}$ & $\second{82.73{\scriptstyle\pm0.48}}$ & $\first{75.55{\scriptstyle\pm0.72}}$ & $\first{53.42{\scriptstyle\pm2.70}}$ & $\second{64.10{\scriptstyle\pm3.10}}$ & $\second{75.03 {\scriptstyle\pm12.45}}$ \\
AnomalyGFM & $\third{50.18{\scriptstyle\pm3.52}}$ & $\third{50.99{\scriptstyle\pm1.15}}$ & $\third{61.19{\scriptstyle\pm0.84}}$ & $\third{59.36{\scriptstyle\pm5.44}}$ & $\third{56.97{\scriptstyle\pm4.04}}$ & $\third{59.14 {\scriptstyle\pm7.75 }}$ \\
\midrule
\rowcolor[HTML]{E9E9E9} 
\multicolumn{7}{c}{Unsupervised - Pre-Train Only} \\
ProMoS & $\first{60.83{\scriptstyle\pm0.35}}$ & $\first{88.85{\scriptstyle\pm0.60}}$ & $\second{72.67{\scriptstyle\pm1.07}}$ & $\second{52.80{\scriptstyle\pm0.82}}$ & $\first{71.62{\scriptstyle\pm1.06}}$ & $\first{77.16 {\scriptstyle\pm13.09 }}$ \\
\bottomrule
\end{tabular}
}

\end{table*}


\subsection{Comparison of Pretraining Dataset Configurations}
To ensure fairness, our main experiments follow the ARC protocol and pre-train the teacher models on PubMed, Flickr, Questions, and YelpChi—the configuration adopted in the first generalist GAD study. To assess the influence of the choice of pretraining datasets on downstream performance, we further evaluate an alternative configuration (Alt-DPD) in which the teacher is pre-trained on a different set of graphs: Cora, CiteSeer, ACM, and PubMed.

Table~\ref{tab:pretrain_dataset_ablation} reports the results across six target graphs. The alternative configuration achieves performance highly comparable to that of ProMoS, with average AUCs of 72.70 and 72.50, respectively. These results indicate that ProMoS is not sensitive to the specific selection of pretraining datasets and generalizes well across different pretraining regimes.


\begin{table}[!t]
\caption{Comparison of pretraining dataset configurations.}
\label{tab:pretrain_dataset_ablation}
\centering
\renewcommand{\baselinestretch}{1.2}
\setlength{\tabcolsep}{5pt}
\resizebox{0.9\textwidth}{!}{
\begin{tabular}{l|cccccc|c}
\toprule
Method & Facebook & Weibo & Reddit & CS & Photo & Tolokers & Avg. \\
\midrule
\rowcolor[HTML]{E9E9E9}
ProMoS 
& $69.31{\scriptstyle\pm0.50}$ 
& $91.74{\scriptstyle\pm0.03}$ 
& $60.83{\scriptstyle\pm0.35}$ 
& $88.85{\scriptstyle\pm0.60}$ 
& $72.67{\scriptstyle\pm1.07}$ 
& $52.80{\scriptstyle\pm0.82}$ 
& $\mathbf{72.70}$ \\
\midrule
Alt-DPD 
& $68.58{\scriptstyle\pm0.38}$ 
& $91.77{\scriptstyle\pm0.07}$ 
& $58.15{\scriptstyle\pm1.58}$ 
& $89.15{\scriptstyle\pm0.32}$ 
& $73.39{\scriptstyle\pm1.15}$ 
& $53.96{\scriptstyle\pm0.66}$ 
& $72.50$ \\
\bottomrule
\end{tabular}}
\end{table}


\subsection{More Ablation Study}\label{sec:abl}
We further evaluated five ProMoS variants: (1) w/o PB drops the personalized branch in the MoS design; (2) w/o SB drops the shared branch; (3) w/o DIS removes the quality control weights $w_i^b$ in the commitment and refinement stage; (4) w/o PB \& DIS drops the personalized branch and $w_i^b$; and (5) w/o SB \& DIS drops the shared branch and $w_i^b$.

Table~\ref{tab:app_ablation} reports the results. Comparing MoS branches, w/o SB performs better than w/o PB, suggesting the importance of the personalized branch for capturing complementary knowledge. Finally, disabling the data-quality weighting in the commitment and refinement stage (w/o DIS) also causes a measurable decline, further confirming its role in stabilizing training and improving detection robustness. 

Notably, these components do not operate independently. SB and PB jointly constitute the Mixture-of-Students architecture, modeling global and local normality from complementary perspectives, while DIS modulates prototype updates by emphasizing high-quality semantic structures. To explicitly examine their interaction, we further introduce joint ablations that remove DIS together with either PB or SB. As shown in Table~\ref{tab:app_ablation}, both joint variants suffer substantial degradation across all datasets. On ACM, performance drops by 9.80\% and 9.20\% for w/o PB \& DIS and w/o SB \& DIS, respectively, while on CS, both variants incur reductions exceeding 6\%.

These drops are significantly larger than those observed in the corresponding single ablations, demonstrating strong interdependence among PB, SB, and DIS. Overall, the results indicate that these components address complementary aspects of generalist GAD and that their joint design is crucial for the robustness and stability of ProMoS.

\begin{table*}[!t]
\caption{Ablation results w.r.t. AUC for ProMoS and its variants.}
\label{tab:app_ablation}
\centering
\setlength{\tabcolsep}{5pt}
\resizebox{0.7\textwidth}{!}{
\begin{tabular}{l|cccc|c}
\toprule
Method & T\text{-}Finance & Reddit & ACM & CS & Avg. \\
\midrule
\rowcolor[HTML]{E9E9E9}
ProMoS 
& $\mathbf{71.62{\scriptstyle\pm1.06}}$
& $\mathbf{60.83{\scriptstyle\pm0.35}}$
& $\mathbf{89.47{\scriptstyle\pm0.79}}$
& $\mathbf{88.85{\scriptstyle\pm0.60}}$
& $\mathbf{77.69}$ \\
\midrule
w/o PB  
& $69.88{\scriptstyle\pm1.33}$
& $59.78{\scriptstyle\pm1.80}$
& $89.39{\scriptstyle\pm1.01}$
& $88.33{\scriptstyle\pm0.25}$
& $76.85$ \\
w/o SB  
& $70.63{\scriptstyle\pm0.48}$
& $58.48{\scriptstyle\pm2.89}$
& $89.21{\scriptstyle\pm0.93}$
& $88.27{\scriptstyle\pm1.66}$
& $76.65$ \\
w/o DIS 
& $69.49{\scriptstyle\pm1.19}$
& $59.55{\scriptstyle\pm1.87}$
& $88.99{\scriptstyle\pm0.88}$
& $88.12{\scriptstyle\pm0.33}$
& $76.54$ \\
w/o PB \& DIS
& $65.11{\scriptstyle\pm1.43}$
& $55.98{\scriptstyle\pm2.11}$
& $79.67{\scriptstyle\pm0.64}$
& $82.02{\scriptstyle\pm0.26}$
& $70.70$ \\
w/o SB \& DIS
& $65.52{\scriptstyle\pm0.81}$
& $56.31{\scriptstyle\pm0.86}$
& $80.27{\scriptstyle\pm0.44}$
& $82.18{\scriptstyle\pm0.75}$
& $71.07$ \\
\bottomrule
\end{tabular}}
\end{table*}


\begin{figure*}
\centering
\subfloat[]{\label{fig:vis1}\includegraphics[width=0.25\linewidth]{
figures/cora_umap_wodcr.pdf}}
\subfloat[]{\label{fig:vis2}\includegraphics[width=0.25\linewidth]{
figures/cora_umap.pdf}}
\subfloat[]{\label{fig:vis3}\includegraphics[width=0.25\linewidth]{
figures/ts_citeseer_umap_pairs.pdf}}
\subfloat[]{\label{fig:vis4}\includegraphics[width=0.25\linewidth]{
figures/weibo_stu.pdf}}
\caption{Visualization analysis of ProMoS. 
The four subfigures respectively show: 
(a) the embedding distributions w/o $\mathcal{L}_{\text{DCR}}$ on Cora; 
(b) the embedding distributions w/ $\mathcal{L}_{\text{DCR}}$ on Cora; 
(c) the teacher–student feature alignment on CiteSeer; 
and (d) the student-specific embedding on Weibo.}
\label{fig:vis}
\end{figure*}


\subsection{Visualization Analysis}
To further examine the effectiveness of the proposed components, we provide three additional visualization studies in Figure~\ref{fig:vis}.


\textbf{Effectiveness of the commitment and refinement losses.}
Figure~\ref{fig:vis1} and Figure~\ref{fig:vis2} visualize the standardized teacher outputs on an unseen Cora graph using t-SNE. Normal nodes (blue circles) and anomalous nodes (red squares) are plotted together with the shared and personalized prototypes projected into the same embedding space. Comparing the model without the discrepancy-aware commitment and refinement loss (w/o $\mathcal{L}_{\text{DCR}}$) to the model with it (w/ $\mathcal{L}_{\text{DCR}}$) reveals a clear contrast: w/o $\mathcal{L}_{\text{DCR}}$ (Figure~\ref{fig:vis1}), the teacher features become scattered and unstructured under distribution shift, and the prototypes lose semantic anchoring. In contrast, w/ $\mathcal{L}_{\text{DCR}}$ (Figure~\ref{fig:vis2}), both shared and personalized prototypes remain discriminative and representative, and anomalous nodes are more likely to be pushed away from any prototype regions. These observations indicate that the proposed DCR mechanism optimizes the prototype space and regularizes the teacher representation space, thereby strengthening out-of-distribution robustness.

\textbf{Effectiveness of the Two-Branch MoS Architecture.}
Figure~\ref{fig:vis2} further illustrates the distinct yet complementary roles of the shared and personalized branches in our Mixture-of-Students architecture. The shared prototypes (triangles) consistently lie near the central, high-density semantic regions, capturing global normality patterns that are transferable across graphs. In contrast, the personalized prototypes (inverted triangles) capture local patterns, often spreading to peripheral or fine-grained regions that the shared branch cannot model. This division of labor aligns with the intended design of MoS: the shared branch provides a universal backbone of normality, while personalized students specialize in diverse patterns.
Moreover, the ablation results in Table~\ref{tab:app_ablation} reinforce this observation. Eliminating either branch leads to performance degradation, demonstrating that both components are indispensable for capturing the full spectrum of normality patterns required for robust generalist GAD.

\textbf{Teacher–Student Feature Distributions}
Figure~\ref{fig:vis3} illustrates the projections of the teacher (blue circles) and student (yellow triangles) representations on the unseen CiteSeer graph. Overall, the two distributions exhibit no substantial global gap, indicating that the student network is able to approximate the teacher’s representation space even under distribution shift. 
To obtain a more fine-grained view, we randomly sample 20 normal teacher–student pairs and 20 anomalous teacher–student pairs, where each pair consists of a node’s teacher embedding and the corresponding student embedding, and connect each pair with a line segment.


The visualization reveals a clear pattern. Normal pairs (green lines) show consistently shorter teacher–student distances: their embeddings align closely in the representation space, demonstrating that the MoS architecture can better reconstruct the teacher’s normality patterns. In contrast, anomalous pairs (red lines) exhibit significantly larger distortions. Due to their irregular semantics and weaker prototype affinity, anomalous nodes cannot be faithfully reconstructed by the students, resulting in pronounced divergence in their representations. This behavior aligns precisely with our anomaly scoring mechanism, where reconstruction deviation serves as a crucial indicator of abnormality. These results confirm that the student network closely matches the teacher distribution for normal nodes while naturally amplifying deviations on anomalous nodes—exactly the behavior desired for zero-shot anomaly detection.

\textbf{Visual Evidence of Student Diversity}
To directly examine whether personalized students capture different modes, we visualize student-specific embeddings on the Weibo dataset (Figure~\ref{fig:vis4}). For each of the 20 students, we extract the personalized-branch outputs and project them into a two-dimensional space, with points colored by student index. The resulting clusters are clearly separated across students, indicating that each student focuses on distinct semantic patterns in the feature space. This empirical pattern is consistent with the design of ProMoS. The diversity among student models is structurally encouraged by the sparse Top-K routing mechanism: instead of sending every sample to every student, Top-K routing assigns each student only a subset of nodes, so semantically similar nodes are routed to partially overlapping students while each student is trained on a different portion of the graph. This routing scheme naturally guides different students toward different subsets of data and fosters meaningful specialization without requiring an explicit diversity regularizer.


\begin{figure*}[!t]
  \centering
  \begin{minipage}{0.695\linewidth}
    \centering
    \includegraphics[width=\linewidth]{figures/stu_heatmap_log.pdf}
    \caption{Student-wise activation frequency during inference on Cora, CiteSeer, and Facebook.}
    \label{fig:freq1}
  \end{minipage}
  \hfill
  \begin{minipage}{0.295\linewidth}
    \centering
    \includegraphics[width=\linewidth]{figures/stu_citeseer_top5.pdf}
    \caption{Top-5 frequency in Citeseer.}
    \label{fig:freq2}
  \end{minipage}
\end{figure*}


\subsection{Student Activation Analysis}
This subsection provides an empirical analysis of student activation behavior in ProMoS. 
Rather than introducing an explicit diversity regularizer, ProMoS encourages specialization through the sparse Top-$K$ routing in Eq.\ref{eq:route}, which assigns each node to a small subset of students based on its representation. 
This input-dependent routing exposes different students to different portions of the data distribution, naturally leading to differentiated and specialized student behaviors.

\paragraph{Student-wise activation frequency.}
We analyze the activation frequency of student models during inference to better understand the routing behavior induced by sparse Top-$K$ selection. Specifically, for each node, we record the students selected by Top-$K$ routing and accumulate their (normalized) activation counts over all test nodes. Figure~\ref{fig:freq1} visualizes the resulting student-wise activation frequencies on Cora, CiteSeer, and Facebook.

Across datasets, the activation mass is distributed over multiple students, with no single student dominating the routing decisions. Moreover, the activation patterns vary across graphs, indicating dataset-dependent student utilization rather than uniform averaging. For example, on Cora and CiteSeer, a subset of students (e.g., 3, 7, and 16) is more frequently activated, while on Facebook, the distribution shifts to a different subset, reflecting differences in the underlying data characteristics.

To further illustrate the selectivity of the routing mechanism, Figure~\ref{fig:freq2} reports the Top-$5$ most frequently activated students on CiteSeer, showing that only a small subset of students is repeatedly selected under sparse routing. Complementary to these frequency-based statistics, we also visualize student-specific embeddings on Weibo in Figure~\ref{fig:vis4}, where embeddings produced by different students form clearly separated clusters in the feature space. Together, these observations suggest that ProMoS leverages the student ensemble in a selective and input-dependent manner, with different students focusing on different regions of the data distribution.

\paragraph{Ablation with an explicit diversity regularizer.}
While sparse Top-$K$ routing already induces non-trivial specialization among students, we further explore an explicit diversity regularizer as an exploratory extension. The regularizer encourages the most highly activated students for the same node to produce dissimilar outputs by penalizing their similarity in the representation space:
\[
\mathcal{L}_{\text{DIV}}= -\frac{1}{2|\mathcal{V}|}\sum_{i\in\mathcal{V}}\Big[\mathrm{KL}\!\left(\mathbf{h}_{i,1}^{\ell}\,\big\Vert\,\mathbf{h}_{i,2}^{\ell}\right)+\mathrm{KL}\!\left(\mathbf{h}_{i,2}^{\ell}\,\big\Vert\,\mathbf{h}_{i,1}^{\ell}\right)\Big],
\]
where $\mathbf{h}_{i,1}^{\ell}$ and $\mathbf{h}_{i,2}^{\ell}$ denote the outputs of the two most highly activated routed students for node $i$ (Eq.\ref{eq:stu_rep}). Intuitively, this term explicitly pushes different experts to focus on and encode different aspects of the input, thereby promoting diversity at the representation level.

As shown in Table~\ref{tab:app_div}, incorporating $\mathcal{L}_{\text{DIV}}$ leads to mixed results. With a small weight (e.g., $0.01$), the regularizer yields marginal improvements on certain datasets (e.g., T-Finance), but does not consistently improve performance across all settings. In contrast, a large weight (e.g., $1$) substantially degrades performance. One possible explanation is that the default sparse Top-$K$ routing already provides sufficient functional diversity, and overly strong separation constraints may restrict beneficial information sharing among students or interfere with the teacher--student prototype distillation objective. Overall, these results suggest that explicitly encouraging expert diversity is a promising direction, but that effective integration likely requires more principled, task-aware designs beyond a naive pairwise separation penalty.


\begin{table*}[!t]
\caption{Effect of Explicit Diversity Regularization on ProMoS (AUROC).}
\label{tab:app_div}
\centering
\setlength{\tabcolsep}{5pt}
\resizebox{0.9\textwidth}{!}{
\begin{tabular}{l|cccccc|c}
\toprule
Method & ACM & Facebook & Reddit & CS & Photo & T\text{-}Finance & Avg. \\
\midrule
\rowcolor[HTML]{E9E9E9}
ProMoS 
& $\mathbf{89.47{\scriptstyle\pm0.79}}$
& $\mathbf{69.31{\scriptstyle\pm0.50}}$
& $\mathbf{60.83{\scriptstyle\pm0.35}}$
& $\mathbf{88.85{\scriptstyle\pm0.60}}$
& $\mathbf{72.67{\scriptstyle\pm1.07}}$
& $\mathbf{71.62{\scriptstyle\pm1.06}}$
& $\mathbf{75.46}$ \\
\midrule
+ $\mathcal{L}_{\text{DIV}}\!\times\!0.01$
& $88.94{\scriptstyle\pm1.22}$
& $69.32{\scriptstyle\pm0.46}$
& $60.81{\scriptstyle\pm0.29}$
& $88.70{\scriptstyle\pm0.74}$
& $72.66{\scriptstyle\pm0.97}$
& $71.79{\scriptstyle\pm1.03}$
& $75.37$ \\
+ $\mathcal{L}_{\text{DIV}}\!\times\!1$
& $63.60{\scriptstyle\pm5.75}$
& $55.17{\scriptstyle\pm3.73}$
& $53.11{\scriptstyle\pm2.72}$
& $61.47{\scriptstyle\pm9.43}$
& $46.26{\scriptstyle\pm10.32}$
& $72.17{\scriptstyle\pm4.51}$
& $58.63$ \\
\bottomrule
\end{tabular}}
\end{table*}


\subsection{Hyperparameter Sensitivity Analysis}
\label{app:hyperparam}

We evaluate the sensitivity of key hyperparameters on ProMoS and report the average AUROC and AUPRC on all unseen test graphs.

\textbf{Effect of trade-off parameter $\lambda$.}
Trade-off parameter $\lambda$ balances prototype-guided soft-label distillation (PSD) and discrepancy-aware commitment \& refinement (DCR).
As shown in the figure~\ref{fig:param1}, small $\lambda$ leads to insufficient teacher constraints and prototype updates, while large $\lambda$ overconstrains the student and affects distillation performance. Therefore, we choose $\lambda=0.5$ by default.

\textbf{Effect of number of students \(N\).}
In the mixture-of-students (MoS) architecture, the number of students $N$ determines how many personalized branches are initialized. As shown in Figure~\ref{fig:param2}, increasing $N$ initially improves both AUROC and AUPRC. With too few students, the model lacks sufficient expressive capacity to capture all normal patterns encoded in the teacher, resulting in underfitting. As $N$ continues to grow, the performance gains saturate, and parameter efficiency diminishes, since additional students contribute marginally to representation diversity. In our experiments, we set the default number of students to $N=20$.


\textbf{Effect of number of prototypes $M_b$.}
As shown in Figure~\ref{fig:param3}, increasing $M_b$ from very small values to a mid-to-high range improves performance, after which the results become stable. Too few prototypes lead to underfitting of transferable semantics with overly coarse granularity, while too many prototypes fragment the space, slightly reducing robustness and increasing inference time. A mid-range $M_b$ offers the best trade-off.

\textbf{Effect of Top-$K$ activated students.}
As shown in Figure~\ref{fig:param4}, activating fewer students (e.g., $K=2,4,6$) achieves the best AUROC/AUPRC. Larger $K$ values dilute the distillation signals each student receives and prevent individual students from specializing in distinct patterns. This undermines the divide-and-conquer principle of MoS, causing different students to converge toward similar behaviors and ultimately degrading performance.

\textbf{Effect of Sharpness $\beta$ and margin $\mu$.}
Both parameters regulate the discrepancy-aware weighting by controlling how strongly unreliable samples are down-weighted. As shown in Figure~\ref{fig:param5} and ~\ref{fig:param6}, moderate values yield the best AUROC/AUPRC. With too small $\beta$, the weighting is overly soft, making reliable and unreliable samples indistinguishable. Increasing $\beta$ sharpens the reweighting and improves robustness, but excessive sharpness overemphasizes a few samples and amplifies noise, leading to performance drops. 
For $\mu$, a small margin down-weights many diverse yet reliable, informative nodes (with modest KL), while an excessively large $\mu$ inflates the weights of high-KL nodes—including unreliable or anomalous nodes—thereby degrading robustness. Hence, performance peaks at moderate $\beta$ and $\mu$.


\textbf{Effect of temperature $\tau$.}
In Prototype-guided Soft-label Distillation (PSD), the temperature coefficient $\tau$ controls the smoothness of the teacher’s soft labels. As shown in Figure~\ref{fig:param7}, a very low $\tau$ produces overly confident prototype posteriors, making the soft labels too sharp and limiting the transfer of richer semantic information. In contrast, a very high $\tau$ yields overly flat targets, which weakens the guidance signal and reduces the effectiveness of distillation. Moderate values of $\tau$ strike a balance, preserving informative relative probabilities while avoiding overconfidence, and thus achieve the best performance.

\textbf{Effect of training epochs.}
Interestingly, we observe a clear divergence between AUROC and AUPRC (Figure~\ref{fig:param8}). AUROC reaches its peak in the early stage of training and then gradually declines, whereas AUPRC continues to improve until it flattens out. This behavior arises because our method primarily models normal patterns: with prolonged training, the decision boundary becomes increasingly fitted to normal nodes, effectively shrinking the boundary. Such refinement benefits AUPRC, which is more sensitive to anomaly nodes, but slightly reduces AUROC by compressing the global ranking margins—some normal nodes near the boundary may be assigned higher anomaly scores, lowering the overall ranking quality. In practice, the choice of training epochs should be guided by the downstream evaluation priority: if overall ranking is crucial, early stopping is preferable, whereas if precision and recall of anomalies are emphasized, longer training may be beneficial. \looseness=-1


\begin{figure*}
\centering
% \setlength{\belowcaptionskip}{-0.51cm}
\subfloat[Trade-off parameter $\lambda$]{\label{fig:param1}\includegraphics[width=0.25\linewidth]{
figures/param_lam.pdf}}
\subfloat[Number of Students]{\label{fig:param2}\includegraphics[width=0.25\linewidth]{
figures/param_num_students.pdf}}
\subfloat[Number of Prototypes]{\label{fig:param3}\includegraphics[width=0.25\linewidth]{
figures/param_num_prototypes.pdf}}
\subfloat[Top-$K$ student]{\label{fig:param4}\includegraphics[width=0.25\linewidth]{
figures/param_topk.pdf}}\\
\subfloat[Sharpness parameter $\beta$]{\label{fig:param5}\includegraphics[width=0.25\linewidth]{
figures/param_beta.pdf}}
\subfloat[Margin parameter $\mu$]{\label{fig:param6}\includegraphics[width=0.25\linewidth]{
figures/param_mu.pdf}}
\subfloat[Temperature $\tau$]{\label{fig:param7}\includegraphics[width=0.25\linewidth]{
figures/param_temp.pdf}}
\subfloat[Training epochs]{\label{fig:param8}\includegraphics[width=0.25\linewidth]{
figures/param_epoch.pdf}}
\caption{The hyperparameter sensitivity analysis of ProMoS.}
\label{fig:param_appendix1}
\end{figure*}


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\end{document}

% This document was modified from the file originally made available by
% Pat Langley and Andrea Danyluk for ICML-2K. This version was created
% by Iain Murray in 2018, and modified by Alexandre Bouchard in
% 2019 and 2021 and by Csaba Szepesvari, Gang Niu and Sivan Sabato in 2022.
% Modified again in 2023 and 2024 by Sivan Sabato and Jonathan Scarlett.
% Previous contributors include Dan Roy, Lise Getoor and Tobias
% Scheffer, which was slightly modified from the 2010 version by
% Thorsten Joachims & Johannes Fuernkranz, slightly modified from the
% 2009 version by Kiri Wagstaff and Sam Roweis's 2008 version, which is
% slightly modified from Prasad Tadepalli's 2007 version which is a
% lightly changed version of the previous year's version by Andrew
% Moore, which was in turn edited from those of Kristian Kersting and
% Codrina Lauth. Alex Smola contributed to the algorithmic style files.