acceptodds
Under review as a conference paper at ICLR 2027

BNFlow: Adaptive Flow Guidance for Graph-Level Anomaly Detection

Abstract

Graph-level anomaly detection (GLAD) identifies graphs that deviate from a normal population. With only normal graphs available for training, existing methods typically characterize normal patterns or generate pseudo anomalies for negative supervision. However, generated negatives can be too dissimilar to normal graphs or become too easy as the detector improves, limiting their usefulness for detecting subtle anomalies. To address this, we propose BNFlow, a guided flow matching framework that combines a normal graph reference with adaptive sample refinement. Flow matching learns transport toward normal graph representations, and detector feedback refines intermediate samples to make them more challenging as negatives. Refinement is bounded within each trajectory, and its strength adapts to the detector's ability to distinguish normal and generated graphs. Continued flow matching regularizes the generator toward the normal reference during joint learning. Our theoretical analysis characterizes the local effect of guidance and bounds deviation from normal references. Experiments on eight graph benchmarks demonstrate superior overall performance over state-of-the-art GLAD methods. Further analyses highlight the complementary roles of normal transport and detector guidance in providing effective negative supervision.

Primary area:
learning on graphs and other geometries & topologies
Keywords:
Graph-Level Anomaly Detection, Flow Matching

Reviews

Among:
Shape:
1234this paper, Top 4%
Figure 1. Mean review rating of the reviewed papers at ICLR 2027. This paper averages 3.33 over 3 reviews, above 96% of the others.
Reviewer_iCKCOpenReview ↗
Rating
3
Confidence
3
Informativeness
3
Presentation
3
Soundness
2
Read review
Paper summary

This paper proposes BNFlow, a guided flow matching framework for graph-level anomaly detection that generates informative pseudo-anomalies using only normal training graphs. The method combines flow matching toward normal graph representations with discriminator-guided refinement to produce challenging synthetic negatives. A relative velocity budget constrains refinement, while ranking-based feedback adaptively adjusts guidance strength throughout training. The paper also provides theoretical analyses that characterise the local effect of discriminator guidance and bound deviations from normal latent references. Experiments on eight graph benchmarks show competitive performance against existing graph anomaly detection methods, supported by ablation studies, parameter-sensitivity analyses, and computational-efficiency comparisons.

Critical strengths

-The paper addresses an important challenge in graph-level anomaly detection: generating synthetic negatives that remain informative as the detector improves. Combining normal-reference transport with discriminator-guided refinement offers a coherent way to balance resemblance to normal graphs with detection difficulty.

-The paper provides mathematical analyses showing that discriminator-guided refinement maximises the first-order increase in synthetic-negative classification loss under a relative velocity constraint. It also establishes a conditional bound on deviations from normal latent references, providing useful theoretical motivation for the proposed sampling strategy.

-BNFlow achieves the highest reported mean AUROC across all eight benchmarks and the highest mean F1-score on seven datasets. The ablation studies demonstrate substantial contributions from discriminator guidance and flow matching, while the reported computational comparisons indicate considerable training-time improvements over the generative baseline AGDiff.

Critical weaknesses

-The framework combines established techniques, including flow matching, discriminator-gradient guidance, constrained adversarial refinement, and adaptive feedback. Although the integration is reasonable, the paper does not sufficiently clarify how the proposed guidance mechanism fundamentally differs from existing classifier-guided generation or adversarial negative synthesis. The paper needs stronger comparisons with alternative guidance strategies to substantiate its methodological contribution.

-Proposition 1 characterises a local first-order optimisation property, while Proposition 2 bounds deviation from a normal latent reference in terms of velocity errors and accumulated guidance. However, these results do not guarantee that generated samples are sufficiently anomalous, semantically meaningful, or consistently informative for downstream detection. The theoretical connection between the proposed guidance and improved anomaly detection performance therefore remains limited.

-The method aims to generate informative synthetic negatives that capture subtle deviations from normal patterns, but the analysis primarily examines latent-space proximity and classification performance. Figure 6 indicates that approximately 98% of generated samples become normal-like at longer sampling horizons, with uneven coverage across normal prototypes. This raises concerns about insufficient diversity, potential concentration around specific normal modes, and whether the generated samples adequately represent different anomaly types.

-Although the reported results are generally strong, the improvements over AGDiff are relatively small on some datasets, and the paper does not provide paired statistical significance tests to establish their reliability. Additionally, the reported 230–800× training-time advantage over AGDiff is substantial but requires a clearer breakdown of preprocessing, autoencoder pretraining, generation, and joint optimisation costs to establish whether the comparison reflects equivalent computational workloads.

Questions for authors

-What are the key technical differences between the proposed bounded discriminator guidance and existing classifier-guided generation or constrained adversarial negative synthesis methods? Can the authors provide controlled comparisons using alternative guidance mechanisms within the same flow-matching framework to isolate the proposed strategy's contribution?

-How does the method ensure that generated samples remain informative pseudo-anomalies rather than becoming nearly indistinguishable from normal graphs? Given the uneven prototype coverage observed in Figure 6, can the authors provide quantitative analyses of synthetic-negative diversity, coverage across normal modes, and detection performance for different anomaly types?

-Can the authors provide paired statistical significance tests against AGDiff and clarify whether all methods use identical data splits and evaluation protocols? Additionally, does the reported 230–800× training-time improvement include autoencoder pretraining, flow pretraining, and joint optimisation for both methods, and how does performance compare under matched computational budgets?

4 comments
AuthorsOpenReview ↗

Response to Reviewer iCKC (1/4)

We thank the reviewer for the thoughtful and constructive comments. We address each point below.


1. Technical Distinction & Controlled Comparisons of Guidance Mechanisms. (W1, Q1)

1.1 Technical Distinction. (W1, Q1-part1)

Thank you for this important question. Below, we explain how BNFlow differs from existing pseudo-anomaly generation methods.

Gap in Existing Methods: Existing classifier-guided generation methods for GAD [1] use a shared classification objective to adjust generation through detector feedback. However, this objective can favor generating negatives that are easier to identify and does not guarantee that they remain challenging for an evolving detector. Such easy negatives may provide insufficient pressure to learn a decision boundary that closely follows the normal data distribution, limiting sensitivity to subtle anomalies. Adversarial approaches instead use a min–max objective to generate negatives that challenge the discriminator. However, SDM explicitly identifies min–max training instability as a limitation of its adversarial variants [2]. Neither a shared classification objective nor an adversarial objective alone provides fine-grained control over how much each node is refined at each intermediate generation state or how this local refinement budget adapts to the evolving detector.

Our Work Contribution: BNFlow addresses the need for fine-grained, detector-adaptive refinement by using the detector gradient to set each node's guidance direction and the learned transport velocity to bound its magnitude. Ranking feedback adjusts guidance strength as the detector evolves, while continued FM regression maintains a normal reference. This couples local difficulty control with transport-relative constraints, with Proposition 1 establishing the guidance's first-order optimality under the node-wise budget.

1.2 Controlled Guidance Comparisons. (W1, Q1-part2)

Controlled Comparison: We compared alternative generation and guidance strategies inside the same FM framework, keeping the data splits, VGAE settings, networks, and training budgets fixed. We replaced BNFlow's guided generation with joint training alone, corresponding to Without discriminator guidance (w/o DG) in Figure 5, and with SDM-style adversarial training [2]. We additionally adapted two guidance mechanisms from diffusion and flow-based generative models. DPS-style guidance [3] backpropagates through the predicted endpoint, whereas cov-A-style guidance [4] applies endpoint gradients directly with 1−t1-t scaling. Values are AUROC and F1-score (%), mean ± standard deviation.

Generation / guidance strategyCOX2 AUROC (%)COX2 F1-score (%)MOLT-4 AUROC (%)MOLT-4 F1-score (%)
SDM-style adversarial generation [2]57.37 ± 16.8356.62 ± 13.9870.70 ± 31.9780.72 ± 16.59
Joint training only (w/o DG)61.37 ± 15.4358.45 ± 15.1863.50 ± 25.2378.41 ± 14.12
DPS-style endpoint guidance [3]64.24 ± 25.6962.56 ± 19.7074.68 ± 17.3683.32 ± 5.74
cov-A-style endpoint guidance [4]61.67 ± 23.4659.82 ± 16.3062.34 ± 29.8576.66 ± 12.58
BNFlow guidance81.37 ± 2.8673.06 ± 2.3391.69 ± 4.5890.53 ± 4.13

Results: BNFlow achieves higher mean AUROC and F1-score with lower variability on both datasets, supporting the contribution of the proposed guidance strategy beyond FM alone.


References

[1] Cai, J., et al. (2025). Leveraging Diffusion Model as Pseudo-Anomalous Graph Generator for Graph-Level Anomaly Detection. ICML.

[2] Cai, J., et al. (2025). Self-Discriminative Modeling for Anomalous Graph Detection. ICML.

[3] Chung, H., et al. (2023). Diffusion Posterior Sampling for General Noisy Inverse Problems. ICLR.

[4] Feng, R., et al. (2025). On the Guidance of Flow Matching. ICML.

AuthorsOpenReview ↗

Response to Reviewer iCKC (2/4)

In the following, we clarify weakness 2 concerning the scope of the theoretical results and their connection to detection utility.


2. Scope of the Theoretical Results & Connection to Detection Utility. (W2)

Propositions 1–2 establish locally optimal negative-loss refinement under node-wise budgets and bound normal-reference deviation, without directly guaranteeing semantic anomalousness.

Maintaining Distinguishable Pseudo-anomalies: Although guidance locally increases the normality logit ℓψ(Z)\ell_{\psi}(Z), four mechanisms are designed to reduce the risk of generated samples becoming indistinguishable from normal graphs: (i) Eq. (4) constrains each node's guidance velocity by ∥Uv∥2≤r∥Vθ,v∥2\lVert U_{v}\rVert_{2}\leq r\lVert V_{\theta,v}\rVert_{2}, limiting the magnitude of the local normality-increasing refinement. (ii) In Eq. (9), the synthetic-negative loss B(ℓ−,0)\mathcal{B}(\ell^-,0) updates both the flow field and detector. Its derivative ∂B(ℓ−,0)/∂ℓ−=σ(ℓ−)>0\partial\mathcal{B}(\ell^-,0)/\partial\ell^-=\sigma(\ell^-)>0 encourages lower synthetic normality logits, counterbalancing sampling-time refinement toward higher logits. (iii) Eqs. (7)–(8) increase rr when negatives become too easy to distinguish and reduce it toward its allowed lower bound when the smoothed normal–synthetic separability score falls below dlo=0.60d_{\mathrm{lo}}=0.60. (iv) Where τ<1\tau<1 is configured, Eq. (6) stops sampling at an intermediate transport state, providing an additional means to control resemblance to normal references.

Connection to Detection Utility: Appendix B.4 shows that identical normal and generated distributions yield an optimal BCE prediction of 1/21/2 under equal class weights, motivating distinguishable negatives. Item 3 shows that guided pseudo graphs remain distinguishable but are harder to separate than unguided samples under the evaluated scores. Items 1.2 and 3 further support detection gains through controlled guidance and anomaly-type comparisons.

AuthorsOpenReview ↗

Response to Reviewer iCKC (3/4)

In the following, we address weakness 3 and question 2 regarding pseudo-anomaly distinguishability, diversity, and anomaly-type coverage.


3. Generated Pseudo-anomaly Distinguishability, Diversity & Anomaly-type Coverage. (W3, Q2)

Thank you for the insightful question. In Figure 6, "normal-like" denotes proximity under the specified distance threshold in the mean-pooled frozen VGAE space. As reported in Appendix C.2, 71 of the 73 real test anomalies also fall within this region. Thus, the approximately 98% normal-like proportion of generated samples does not mean that they are indistinguishable from normal graphs. To assess their distinguishability and diversity more directly, we added the following analyses on COX2.

Generated Pseudo-anomaly Distinguishability: On COX2, we compared reconstructed normal test graphs with pseudo graphs generated by trained BNFlow models with and without guidance. All graphs used the same frozen VGAE decoder and discretization. For each feature set—atom composition, edge endpoint atom-type pairs, WL patterns, and Laplacian spectra—we scored graphs by their mean distance to five nearest reconstructed normal training graphs, excluding self-matches. AUC compares each group against reconstructed training normals, with 0.5 indicating chance-level discrimination and 1.0 perfect separation.

FeatureNormal test referenceBNFlow pseudo graphsUnguided pseudo graphs
Atom composition0.4590.8750.966
Edge endpoint atom-type pairs0.4690.8150.955
WL structural patterns0.5050.7320.938
Laplacian spectrum0.5260.7160.961

Results: Across all four feature sets, BNFlow pseudo graphs yield higher AUC than the normal test reference, showing that they remain distinguishable from normal graphs. Their AUC is consistently lower than that of unguided pseudo graphs, indicating that guidance brings generated samples closer to normal graphs and makes them harder to distinguish under these feature-based scores.

Normal-mode Coverage: We likewise used trained BNFlow models to generate pseudo graphs and grouped normal training graphs into three or five clusters according to the similarity of their representations. We assigned each generated pseudo graph to its nearest cluster center and compared sampling with and without guidance for each model. Normalized entropy measures dispersion across clusters, taking zero when all generated samples occupy one cluster and one when they are evenly distributed. JSD measures the difference between normal and generated cluster proportions, with lower values indicating closer agreement. The occupied-cluster percentage measures the fraction of normal clusters receiving at least one generated sample. Results are averaged over three repeated runs with different random seeds.

ClustersGuidanceNormalized entropy ↑JSD ↓Occupied clusters (%) ↑
3Off0.4740.15966.67
3On0.5990.07777.78
5Off0.2050.29446.67
5On0.3420.23766.67

Results: We see that the guidance increases normalized entropy and occupied-cluster coverage and reduces JSD for both cluster counts. These results indicate that although the generated samples do not cover all normal modes represented by these clusters, they cover a majority of the normal clusters on average.

Anomaly-type Detection: We used 73 normal graphs from the COX2 test set to construct three types of anomalies: structural anomalies by selecting a subset of edges and reconnecting one endpoint to another node, attribute anomalies by selecting nodes and randomly replacing each node's category with one of the other 34 categories, and mixed anomalies by combining edge rewiring and node-category replacement. Both variants were evaluated on identical sets of 73 normal and 73 perturbed graphs at each edge/node perturbation rate (5%, 10%, and 15%), with AUROC averaged across rates.

Perturbation typeWithout guidance AUROC (%)BNFlow AUROC (%)
Structural67.8885.87
Attribute70.4877.29
Mixed69.7884.55

Results: The proposed guidance improves mean detection AUROC over the unguided variant for structural, attribute, and mixed anomalies.

AuthorsOpenReview ↗

Response to Reviewer iCKC (4/4)

In the following, we clarify weakness 4 and question 3 concerning statistical reliability, evaluation protocols, and computational budgets.


4. Statistical Reliability, Evaluation Protocol & Computational Budgets. (W4, Q3)

4.1 Paired Significance Tests. (W4-part1, Q3-part1)

We added 10 MUTAG runs paired by identical splits and corresponding random seeds, under the same evaluation protocol. Given the limited time, we selected MUTAG because AGDiff has a short runtime on this dataset and its reported performance gap with BNFlow is relatively small.

StatisticResult
BNFlow mean AUROC (%)95.63
AGDiff mean AUROC (%)94.31
Mean paired improvement+1.32 percentage points
Pairs favoring BNFlow8 / 10
Paired t-test, two-sided pp0.0216
Exact sign-flip test, two-sided pp0.0234
Exact Wilcoxon signed-rank test, two-sided pp0.0273

Results: All tests support the MUTAG improvement at the 0.05 level.

Evaluation Protocol: All methods use the same data splits and evaluation protocol. Training uses 80% of normal graphs; testing combines the remainder with at most an equal number of anomalies on moderate-scale datasets, or all anomalies on large datasets. The paired runs share actual graph indices.

4.2 Complete Cost Accounting. (W4-part2, Q3-part2)

We use the same outer timing protocol for all baselines, covering the complete experiment subprocess, including data preparation, training, evaluation, and result saving. However, we found that the original BNFlow runs loaded cached VGAE checkpoints, whereas AGDiff's timed runs included VGAE pretraining. We apologize for overlooking this difference, which inadvertently excluded BNFlow's VGAE-pretraining cost from the original 230–800× comparison. We have now included this cost, remeasured BNFlow's total runtime, and listed the time spent in each stage below:

DatasetBNFlow VGAE (s)FM pretraining + generation (s)Joint optimization + other (s)BNFlow total (s)AGDiff total (s)Ratio
MOLT-41,379.05110.55200.721,690.3255,900.2533.07×
MCF-7633.70189.66154.58977.9434,238.7835.01×
PC-3830.3863.0155.98949.3735,592.0837.49×
SW-6201,502.55105.90199.961,808.4147,677.8626.36×

Results: With VGAE pretraining included, BNFlow achieves a 26.36–37.49× speedup over AGDiff across the four evaluated datasets. The remaining runtime gap is not due to omitted VGAE pretraining, as both methods pretrain the VGAE for 100 epochs with comparable runtimes. The difference arises during joint training. During joint training, AGDiff takes roughly one hundred to over two hundred seconds per epoch across these four large-scale datasets, whereas BNFlow takes less than or approximately 10 seconds per epoch on each. A major reason is that AGDiff performs 1,000 diffusion sampling steps while BNFlow uses only 8 Euler updates, and this generation process must be executed for every batch.

Performance under an Equal 30-minute Training Budget: We additionally compared BNFlow and AGDiff under the same 30-minute (1,800-second) training budget, including VGAE pretraining for both methods, with final testing timed separately. AGDiff stopped at the budget limit before completing its planned joint training, completing fewer than 10 joint-training epochs on each of the four datasets. Within the same 30-minute budget, BNFlow pretrained the VGAE from scratch and completed its prescribed FM pretraining and joint training. AUROC and F1-score (%) are reported below.

DatasetBNFlow AUROC (%)BNFlow F1-score (%)AGDiff AUROC (%)AGDiff F1-score (%)
MCF-791.6390.5284.9184.32
MOLT-488.7887.7879.4482.76
PC-392.5593.4112.4770.66
SW-62094.5494.4316.8569.73

Results: Under the same 30-minute training budget, BNFlow achieves higher AUROC and F1-score than AGDiff on all four datasets.


Finally, thank you again for your time and constructive comments. We hope these responses address your concerns. We would be happy to discuss any remaining questions and provide further clarification.

Reviewer_oRoXOpenReview ↗
Rating
3(+1)
Confidence
3
Informativeness
2
Presentation
3
Soundness
2
Read review
Paper summary

This paper proposes BNFlow, which generates pseudo anomalies through flow matching and adaptive discriminator guidance. The paper analyzes the local effect of guidance and deviation from normal references, and evaluates graph anomaly detection on eight benchmarks.

Critical strengths

S1. The paper combines bounded discriminator guidance, ranking feedback, and continued flow matching to adjust negative sample difficulty during training.

S2. The paper reports the highest mean AUROC on all eight datasets. The ablations support the contributions of discriminator guidance and continued flow matching.

Critical weaknesses

W1. The paper does not sufficiently establish the contribution beyond existing pseudo anomaly generation methods. SDM and MoEGAD are discussed but not compared experimentally. Under exact target conditioning, comparison with the analytic bridge would also clarify the benefit of learning the flow.

W2. The paper leaves model selection, the number of Euler steps, and joint training duration unspecified, making the reported performance and speedup difficult to verify. Tables 1 & 4 also report standard deviations differing by a factor of ten for the same MUTAG and DD mean AUROCs.

Questions for authors

Q1. How does BNFlow perform against SDM and MoEGAD under the same evaluation settings?

Q2. With exact target conditioning, does the learned flow outperform the analytic bridge using the same guidance and detector?

Q3. Why do the MUTAG and DD standard deviations differ tenfold between Tables 1 & 4?

Q4. How were pretraining costs and training budgets accounted for in the reported up to 800x speedup?

5 comments
AuthorsOpenReview ↗

Response to Reviewer oRoX (1/3)

We thank the reviewer for the insightful and valuable comments. We provide our point-by-point responses below.


1. Methodological Contribution & Comparison with SDM and MoEGAD. (W1-part1, Q1)

1.1 Methodological Contribution. (W1-part1)

Thank you for the valuable comment. An unresolved challenge in existing pseudo-anomaly generation methods is that generated negatives can become easy to identify as the detector evolves. This may lead to a learned decision boundary that does not closely follow the normal data distribution. BNFlow addresses this gap through a learned normal-reference flow and bounded detector guidance that modulates how challenging the generated negatives are for the current detector. We elaborate on this point below.

Gap in Existing Methods: Existing pseudo-anomaly generation methods use reconstruction or distributional objectives to produce samples close to normal graphs, often incorporating detector feedback through joint or adversarial optimization. However, merely constraining generated samples to stay close to normal graphs does not guarantee that they remain challenging for an evolving detector. In particular, a shared classification objective can reward generating negatives that are easier to identify. Such easy negatives may provide insufficient pressure to learn a decision boundary that closely follows the normal data distribution, limiting sensitivity to subtle anomalies. The challenge is therefore to adapt how difficult the negatives are to distinguish according to the current detector's ability, through fine-grained refinement at each intermediate state along the generation trajectory.

Our Work Contribution: To address this challenge, BNFlow combines flow learning with detector guidance to control the generation trajectory in response to the evolving detector. Specifically, it learns a velocity field that determines the direction and speed of transport at each intermediate state and adapts through joint training. On this basis, the current detector guides intermediate states toward higher normality scores, making them locally harder as negatives. Each node's guidance is bounded relative to its learned flow velocity, and ranking feedback strengthens guidance when negatives become too easy to identify and weakens it when they become too difficult to distinguish from normal graphs. Together with continued flow-matching regression, this generates negatives with bounded refinement while retaining a normal reference. Proposition 1 establishes the first-order optimality of the guidance under its node-wise budget.

1.2 Additional Baseline Experiments. (Q1)

Under our unified benchmark evaluation, we repeated each experiment three times and report AUROC and F1-score below as mean ± standard deviation (%). For SDM, we use SDM-NAT, which performs best in most comparisons reported in the original paper. Because complete training and repeated runs on the four large datasets are time-consuming, we evaluated SDM-NAT and MoEGAD only on the following four datasets.

DatasetMetric (%)SDM-NATMoEGADBNFlow
COX2AUROC61.45 ± 4.3765.35 ± 3.5681.37 ± 2.86
COX2F1-score58.11 ± 4.0760.71 ± 1.7173.06 ± 2.33
ER_MDAUROC88.85 ± 1.5073.70 ± 2.4692.56 ± 1.07
ER_MDF1-score81.18 ± 3.5670.41 ± 0.8983.97 ± 0.95
MUTAGAUROC93.39 ± 1.4493.83 ± 1.3595.68 ± 0.13
MUTAGF1-score89.20 ± 0.8588.33 ± 2.5790.67 ± 1.89
DDAUROC82.33 ± 1.78NA87.00 ± 0.49
DDF1-score77.43 ± 3.57NA80.43 ± 0.59

Results: BNFlow achieves higher mean AUROC and F1-score in all available comparisons. MoEGAD's three DD runs terminated with NaN logits, so both metrics are reported as NA.

AuthorsOpenReview ↗

Response to Reviewer oRoX (2/3)

In the following, we clarify the remaining point in weakness 1 and question 2, followed by the standard-deviation correction in weakness 2 and question 3.


2. Comparison between the Analytic Bridge and Exact-Conditioned Learned Flow. (W1-part2, Q2)

Controlled Comparison: BNFlow uses null, noisy-target, exact-target, or mixed-target settings to vary its dependence on a specific normal graph reference, balancing normal-pattern preservation and generation flexibility across datasets. In the table, BNFlow reports the original main results together with their corresponding conditioning settings. Exact-conditioned learned flow uses exact-target conditioning throughout BNFlow, reusing the original results where this conditioning was already used and rerunning the remaining datasets. Analytic bridge does not perform flow learning and directly sets the velocity to v(z,t,c)=(c−z)/(1−t)v(z,t,c)=(c-z)/(1-t) for t<1t<1, where cc is the supplied normal target, while retaining the same discriminator guidance, detector training, and sampling settings within each dataset. Values are AUROC (%), mean ± standard deviation.

DatasetBNFlow conditioningBNFlowExact-conditioned learned flowAnalytic bridge
COX2Null81.37 ± 2.8666.64 ± 3.8154.79 ± 4.49
ER_MDNoisy target92.56 ± 1.0786.34 ± 3.5085.97 ± 6.16
MUTAGNull95.68 ± 0.1390.44 ± 0.5357.71 ± 2.42
DDNull87.00 ± 0.4985.81 ± 1.2650.50 ± 29.41
MCF-7Mixed target92.73 ± 0.6892.47 ± 0.3191.19 ± 1.44
MOLT-4Exact target91.69 ± 4.5891.69 ± 4.5861.98 ± 18.53
PC-3Exact target93.12 ± 3.5993.12 ± 3.5985.90 ± 7.61
SW-620Mixed target95.74 ± 1.7595.81 ± 2.2994.83 ± 1.21

Results: Under exact target conditioning, the learned flow achieves higher mean AUROC than the analytic bridge on all eight datasets. The smaller gains on SW-620 and MCF-7 may be partly explained by their early sampling termination, which limits the interval over which differences between the learned and analytic velocity fields can accumulate.

Why Learn the Flow: Our goal is to generate pseudo anomalies that provide useful supervision for anomaly detection, rather than merely reproduce a supplied normal target. Under exact target conditioning, the analytic bridge is optimal for the normal interpolation regression objective, but this does not imply optimality for the detection task. Its reference trajectory reaches the supplied normal target, yet the intermediate states along this path may not stay close to the normal data manifold. BNFlow learns the velocity field under both classification and flow-matching objectives, allowing classification feedback to adapt the generation trajectory while continued FM regression regularizes departures from the normal reference.


3. Correction of the Reported Standard Deviations. (W2-part2, Q3)

Thank you for identifying the decimal-point error in the Full column of Appendix Table 4. We have corrected the appendix to MUTAG 95.68±0.13%95.68\pm0.13\% and DD 87.00±0.49%87.00\pm0.49\%, consistent with Table 1.

AuthorsOpenReview ↗

Response to Reviewer oRoX (3/3)

In the following, we address model selection and training budgets in weakness 2, and complete cost accounting in question 4.


4. Model Selection, Training Budgets & Complete Cost Accounting. (W2-part1, Q4)

4.1 Model Selection and Configuration. (W2-part1)

In the compared configurations, BNFlow uses 100 VGAE-pretraining epochs, 100 FM-pretraining epochs, and 20 joint-training epochs, with 8 Euler updates per generated batch. AGDiff uses 100 VGAE-pretraining epochs and 200 joint-training epochs, with 1,000 diffusion sampling steps. For the other methods, we follow the default settings reported in their respective papers.

4.2 Complete Cost Accounting. (Q4)

We use the same outer timing protocol for all baselines, covering the complete experiment subprocess, including data preparation, training, evaluation, and result saving. However, we found that the original BNFlow runs loaded cached VGAE checkpoints, whereas AGDiff's timed runs included VGAE pretraining. We apologize for overlooking this difference, which inadvertently excluded BNFlow's VGAE-pretraining cost from the original 230–800× comparison. We have now included this cost, remeasured BNFlow's total runtime, and listed the time spent in each stage below:

DatasetBNFlow VGAE (s)FM pretraining + generation (s)Joint optimization + other (s)BNFlow total (s)AGDiff total (s)Ratio
MOLT-41,379.05110.55200.721,690.3255,900.2533.07×
MCF-7633.70189.66154.58977.9434,238.7835.01×
PC-3830.3863.0155.98949.3735,592.0837.49×
SW-6201,502.55105.90199.961,808.4147,677.8626.36×

Results: With VGAE pretraining included, BNFlow achieves a 26.36–37.49× speedup over AGDiff across the four evaluated datasets. The remaining runtime gap is not due to omitted VGAE pretraining, as both methods pretrain the VGAE for 100 epochs with comparable runtimes. The difference arises during joint training. During joint training, AGDiff takes roughly one hundred to over two hundred seconds per epoch across these four large-scale datasets, whereas BNFlow takes less than or approximately 10 seconds per epoch on each. A major reason is that AGDiff performs 1,000 diffusion sampling steps while BNFlow uses only 8 Euler updates, and this generation process must be executed for every batch.


Finally, thank you again for your time and constructive comments. We hope these responses address your concerns. We would be happy to discuss any remaining questions and provide further clarification.

Reviewer_g8tyOpenReview ↗
Rating
4(+1)
Confidence
3
Informativeness
2
Presentation
3
Soundness
2
Read review
Paper summary

BNFlow addresses graph-level anomaly detection by generating adaptive pseudo anomalies from normal training graphs. A frozen graph autoencoder defines the latent space, where flow matching learns transport toward normal references. Detector gradients refine intermediate states under a relative velocity budget, while ranking feedback adjusts guidance strength. Joint training combines classification with continued flow-matching regression. Theoretical results characterize local guidance optimality and reference deviation. Experiments on eight benchmarks, including four large molecular datasets, demonstrate improved detection performance.

Critical strengths
  1. This paper offers an insightful approach to controlling pseudo-anomaly difficulty during generation, providing a useful perspective on maintaining informative negative supervision while preserving normal graph context.

  2. The theoretical analysis explains the local optimality of guidance and separates sources of reference deviation, providing useful justification for the sampling design.

  3. Extensive experiments cover eight benchmarks, including four large molecular datasets, with ablations, sensitivity studies, and efficiency comparisons providing substantial empirical support for the proposed framework.

Critical weaknesses
  1. For nonzero gradients, Eq. (4) discards relative gradient magnitudes across nodes, setting each node’s guidance strength to r∥Vθ,v∥2r\|V_{\theta,v}\|_2. I am not sure whether my understanding is correct, but if so, why normalize gradients per node rather than across the graph? The rationale needs to be elaborated.

  2. In Figure 6, I wonder how N1–N3 are defined and why N3 attracts samples while N1 receives almost none. Could the authors explain the underlying differences between clusters?

  3. There seem to be decimal-point typos between Table 1 and Table 4 in the appendix, where the standard deviations of AUROC on MUTAG and DD are inconsistent in two tables.

Questions for authors
  1. What motivates using each node’s flow velocity to set its guidance strength, rather than preserving relative gradient magnitudes through normalization across the graph?

  2. Appendix C.2 mentions k-means clustering for N1–N3. What are the sizes and characteristics of these clusters, and why do generated samples predominantly reach N3 while almost none reach N1?

  3. Are the differing AUROC standard deviations in Table 1 and Table 4 in the appendix typos? Please confirm the correct values for MUTAG and DD.

3 comments
AuthorsOpenReview ↗

Response to Reviewer g8ty

We thank the reviewer for carefully reading our manuscript. We respond to each comment below.


1. Node-wise Gradient Normalization & Velocity-based Guidance Budget. (W1, Q1)

Yes, for nonzero gradients, Eq. (4) normalizes each node's gradient direction and sets its guidance magnitude to r∥Vθ,v∥2r\|V_{\theta,v}\|_2, so the discriminator determines the direction while the learned normal transport determines the scale.

Comparison with Graph-wide Normalization: Graph-wide normalization would solve a different problem. For example, Ugraph=r∥Vθ∥Fg/∥g∥FU^{\mathrm{graph}}=r\|V_\theta\|_F g/\|g\|_F controls the total perturbation but can allocate a disproportionately large update to a slowly moving node. It does not enforce the node-wise relative bound. Raw gradient magnitudes also reflect the detector's local sensitivity; they need not be calibrated measures of how far different nodes should move. Our normalization deliberately prevents these magnitudes from overriding the transport-based budget.

Optimization Interpretation: Proposition 1 shows that Eq. (4) maximizes the first-order increase in the synthetic-negative classification loss under these node-wise constraints. It also preserves each gradient direction and is invariant to positive rescaling of the normality logit. Although normalization is node-wise, the gradients come from a graph-level discriminator through the decoder and message passing, so the refinement still incorporates graph context.


2. Definition, Sizes & Characteristics of N1–N3. (W2, Q2)

Definition: N1–N3 are the three normal prototypes obtained by applying k-means (K=3K=3) to mean-pooled, unstandardized latent representations of normal COX2 training graphs from the frozen VGAE, ordered by their first principal-component coordinates. In Figure 6, generated samples within the normal-like distance threshold are assigned to their nearest prototype.

Cluster Sizes and Characteristics: The 292 normal training graphs are distributed as follows:

ClusterNormal training graphsProportion (%)Mean nodesMean edges
N16120.940.542.5
N27325.040.943.1
N315854.141.844.2

N3 is dominated by hydrogen and carbon (H: 38.9%, C: 46.0%), with relatively little nitrogen and fluorine (N: 2.9%, F: 2.1%). N1 and N2 contain higher proportions of nitrogen (approximately 6–7%) and fluorine (approximately 8%). Their similar elemental compositions suggest that their separation is more closely related to topology than composition. Geometrically, N3 is more compact, with a reported within-cluster dispersion of 1.68 and a mean leave-one-out nearest-normal distance of 1.71, compared with approximately 3.03 and 2.95 for N1/N2.

Why More Samples Reach N3: N3 contains over half of the normal training graphs, and this greater representation in the normal reference distribution may be one contributing factor to its larger share of generated samples. Its compact geometry also makes concentration around this dominant normal pattern a plausible outcome of learned transport. BNFlow further guides intermediate states toward higher detector normality scores to obtain more challenging negatives. If states near N3 receive higher scores, this guidance can reinforce the preference for N3.


3. Standard-deviation Consistency between Tables 1 & 4. (W3, Q3)

Thank you for identifying the decimal-point errors in the Full column of Appendix Table 4. We have corrected the appendix to MUTAG 95.68±0.13%95.68\pm0.13\% and DD 87.00±0.49%87.00\pm0.49\%, consistent with Table 1.


Finally, thank you again for your time and constructive comments. We hope these responses address your concerns. We would be happy to discuss any remaining questions and provide further clarification.

Thanks for the authors' rebuttal. After carefully reviewing the rebuttal, I believe my major concerns have been adequately addressed, particularly the explanation of the node-wise velocity budget and the additional cluster statistics. Overall, the paper presents a well-motivated idea that is supported by solid empirical results. I also learned some insightful points from reading this paper. Therefore, I have decided to raise my rating.

AuthorsOpenReview ↗

Official Comment by Authors

Thank you so much for your recognition of our work and your careful consideration of our rebuttal. We are glad that our response has addressed your major concerns. Your thoughtful feedback has helped us improve the clarity and rigor of our paper. Thank you again for your valuable time.

Comments on the paper

1 comment
AuthorsOpenReview ↗

Global Response by Authors

We appreciate the time and effort the reviewers devoted to evaluating our work. Their thoughtful suggestions have guided revisions to both the methodological explanations and the experimental evaluation. We are grateful for the reviewers' recognition of the following strengths:

  • Addressing the important challenge of maintaining informative pseudo-anomalies as the detector improves while preserving normal graph context (Reviewers g8ty and iCKC);
  • Combining bounded discriminator guidance, ranking feedback, and continued flow matching to adapt negative-sample difficulty during training (Reviewers oRoX and iCKC);
  • Establishing the local first-order optimality of guidance and separating the sources of deviation from normal references (Reviewers g8ty and iCKC);
  • Achieving the highest reported mean AUROC across all eight benchmarks (Reviewers oRoX and iCKC) and the highest mean F1-score on seven datasets (Reviewer iCKC);
  • Providing substantial empirical support through ablations, sensitivity studies, and efficiency comparisons, including four large molecular datasets (Reviewers g8ty and iCKC).

We have carefully addressed the reviewers' concerns and provide detailed responses to the individual reviews below. Changes in the revised manuscript are highlighted in blue. Key revisions include:

  • Clarify the methodological distinction from joint and adversarial pseudo-anomaly generation (Section 1).
  • Compare exact-conditioned learned flow with the analytic bridge and explain the benefit of flow learning (Section 4.1 and Appendix C.5, Table 5).
  • Add controlled comparisons with alternative generation and guidance strategies within the same flow-matching framework (Appendix C.7, Table 7).
  • Clarify normal-like latent placement and the sizes and geometric characteristics of N1–N3 in Figure 6 (Section 5.7 and Appendix C.2).
  • Add analyses of pseudo-anomaly distinguishability, normal-mode coverage, and detection across anomaly types (Appendix C.8, Tables 8–10).
  • Specify pretraining budgets and Euler steps, and correct the reported standard deviations (Appendices C.1 and C.4, Table 4).
  • Include VGAE pretraining in the runtime breakdown and correct the reported speedup (Section 5.4, Figure 3 and Appendix C.6, Table 6).
  • Add paired significance tests against AGDiff and performance comparisons under an equal training-time budget (Appendix C.9, Tables 11–12).

We hope that these revisions and the responses below address the reviewers' concerns. We thank the reviewers again for their time and helpful comments, and welcome further questions and discussion.

From OpenReview, CC BY 4.0. Authors as signed there; shown unedited.

Related papers

Loading the map…

Discussion (0)

Sign in to comment.