Bayesian Prompt Flow Learning for Zero-Shot Anomaly Detection
Zhen Qu, Xian Tao, Xinyi Gong, Shichen Qu, Qiyu Chen, Zhengtao Zhang, Xingang Wang, Guiguang Ding
Abstract
Recently, vision-language models (e.g. CLIP) have demonstrated remarkable performance in zero-shot anomaly detection (ZSAD). By leveraging auxiliary data during training, these models can directly perform cross-category anomaly detection on target datasets, such as detecting defects on industrial product surfaces or identifying tumors in organ tissues. Existing approaches typically construct text prompts through either manual design or the optimization of learnable prompt vectors. However, these methods face several challenges: 1) handcrafted prompts require extensive expert knowledge and trial-and-error; 2) single-form learnable prompts struggle to capture complex anomaly semantics; and 3) an unconstrained prompt space limits generalization to unseen categories. To address these issues, we propose Bayesian Prompt Flow Learning (Bayes-PFL), which models the prompt space as a learnable probability distribution from a Bayesian perspective. Specifically, a prompt flow module is designed to learn both imagespecific and image-agnostic distributions, which are jointly utilized to regularize the text prompt space and improve the model's generalization on unseen categories. These learned distributions are then sampled to generate diverse text prompts, effectively covering the prompt space. Additionally, a residual cross-model attention (RCA) module is introduced to better align dynamic text embeddings with fine-grained image features. Extensive experiments on 15 industrial and medical datasets demonstrate our method's superior performance. The code is available at https: //github.com/xiaozhen228/Bayes-PFL .
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
13 top-tier papers have cited it since. Know what they found before your reviewers do.
Lune can draw on
the full paper · the top-tier papers that cite it · related work
Free to start. No credit card required.
Lineage
- Language-driven Semantic Segmentation cites Learning Transferable Visual Models From Natural Language Supervision
- IAD-R1: Reinforcing Consistent Reasoning in Industrial Anomaly Detection cites Learning Transferable Visual Models From Natural Language Supervision
- Segment Anything cites Scaling Up Visual and Vision-Language Representation Learning With Noisy Text Supervision
- Segment Anything cites Learning Transferable Visual Models From Natural Language Supervision
- AnomalyVFM - Transforming Vision Foundation Models into Zero-Shot Anomaly Detectors cites Segment Anything
- AnomalyVFM - Transforming Vision Foundation Models into Zero-Shot Anomaly Detectors cites Learning Transferable Visual Models From Natural Language Supervision
- Conditional Prompt Learning for Vision-Language Models cites Scaling Up Visual and Vision-Language Representation Learning With Noisy Text Supervision
- Conditional Prompt Learning for Vision-Language Models cites Learning Transferable Visual Models From Natural Language Supervision
- MRAD: Zero-Shot Anomaly Detection with Memory-Driven Retrieval cites Language-driven Semantic Segmentation
- MRAD: Zero-Shot Anomaly Detection with Memory-Driven Retrieval cites Conditional Prompt Learning for Vision-Language Models
- MRAD: Zero-Shot Anomaly Detection with Memory-Driven Retrieval cites Learning Transferable Visual Models From Natural Language Supervision
- Scaling Up Visual and Vision-Language Representation Learning With Noisy Text Supervision cites Learning Transferable Visual Models From Natural Language Supervision
- GS-CLIP: Zero-shot 3D Anomaly Detection by Geometry-Aware Prompt and Synergistic View Representation Learning cites Learning Transferable Visual Models From Natural Language Supervision
- VisualAD: Language-Free Zero-Shot Anomaly Detection via Vision Transformer cites Learning Transferable Visual Models From Natural Language Supervision
Cited by top-tier papers13
- VisualAD: Language-Free Zero-Shot Anomaly Detection via Vision TransformerYanning Hou, Peiyuan Li, Zirui Liu, Yitong Wang et al.CVPR 2026 · 14 citations
- IAD-R1: Reinforcing Consistent Reasoning in Industrial Anomaly DetectionYanhui Li, Yunkang Cao, Chengliang Liu, Yuan Xiong et al.AAAI 2026 · 12 citations
- MRAD: Zero-Shot Anomaly Detection with Memory-Driven RetrievalChaoran Xu, Chengkan Lv, Qiyu Chen, Feng Zhang et al.ICLR 2026 · 9 citations
- GS-CLIP: Zero-shot 3D Anomaly Detection by Geometry-Aware Prompt and Synergistic View Representation LearningZehao Deng, An Liu, Yan WangCVPR 2026 · 6 citations
- AnomalyVFM - Transforming Vision Foundation Models into Zero-Shot Anomaly DetectorsMatic Fucka, Vitjan Zavrtanik, Danijel SkocajCVPR 2026 · 4 citations
Builds on14
- Learning Transferable Visual Models From Natural Language SupervisionAlec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh et al.ICML 2021 · 47,906 citations
- Segment AnythingAlexander Kirillov, Eric Mintun, Nikhila Ravi, Hanzi Mao et al.ICCV 2023 · 13,211 citations
- Scaling Up Visual and Vision-Language Representation Learning With Noisy Text SupervisionChao Jia, Yinfei Yang, Ye Xia, Yi-Ting Chen et al.ICML 2021 · 5,401 citations
- Conditional Prompt Learning for Vision-Language ModelsKaiyang Zhou, Jingkang Yang, Chen Change Loy, Ziwei LiuCVPR 2022 · 1,438 citations
- Language-driven Semantic SegmentationBoyi Li, Kilian Q. Weinberger, Serge J. Belongie, Vladlen Koltun et al.ICLR 2022 · 885 citations
Related papers
- AnomalyCLIP: Object-agnostic Prompt Learning for Zero-shot Anomaly DetectionQihang Zhou, Guansong Pang, Yu Tian, Shibo He et al.ICLR 2024 · 380 citations
- CoPS: Conditional Prompt Synthesis for Zero-Shot Anomaly DetectionQiyu Chen, Zhen Qu, Wei Luo, Haiming Yao, Yunkang Cao, Yuxin Jiang, Yinan Duan, Huiyuan Luo, Chengkan Lv, Zhengtao ZhangCVPR Findings 2026
- PromptMoE: Generalizable Zero-Shot Anomaly Detection via Visually-Guided Prompt MixturesYuheng Shao, Lizhang Wang, Changhao Li, Peixian Chen et al.AAAI 2026
- Aligning and Prompting Anything for Zero-Shot Generalized Anomaly DetectionJitao Ma, Weiying Xie, Hangyu Ye, Daixun Li et al.AAAI 2025 · 3 citations
- DLVP-CLIP: Enhancing Fine-Grained Zero-Shot Anomaly Detection via Dynamic Local Visual PromptingGaowei Zhang, Lihe ZhangCVPR 2026
