AG-VAS: Anchor-Guided Zero-Shot Visual Anomaly Segmentation with Large Multimodal Models
Organizations: Institute of Automation, Chinese Academy of Sciences · School of Artificial Intelligence, University of Chinese Academy of Sciences · Casivision · Weiqiao-UCAS Science and Technology Park
Abstract
Large multimodal models (LMMs) exhibit strong task generalization capabilities, offering new opportunities for zero-shot visual anomaly segmentation (ZSAS). However, existing LMM-based segmentation approaches still face fundamental limitations: anomaly concepts are inherently abstract and context-dependent, lacking stable visual prototypes, and the weak alignment between high-level semantic embeddings and pixel-level spatial features hinders precise anomaly localization. To address these challenges, we present AG-VAS (Anchor-Guided Visual Anomaly Segmentation), a new framework that expands the LMM vocabulary with three learnable semantic anchor tokens-[SEG], [NOR], and [ANO], establishing a unified anchor-guided segmentation paradigm. Specifically, [SEG] serves as an absolute semantic anchor that translates abstract anomaly semantics into explicit, spatially grounded visual entities (e.g., holes or scratches), while [NOR] and [ANO] act as relative anchors that model the contextual contrast between normal and abnormal patterns across categories. To further enhance cross-modal alignment, we introduce a Semantic-Pixel Alignment Module (SPAM) that aligns language-level semantic embeddings with high-resolution visual features, along with an Anchor-Guided Mask Decoder (AGMD) that performs anchor-conditioned mask prediction for precise anomaly localization. In addition, we curate Anomaly-Instruct20K, a large-scale instruction dataset that organizes anomaly knowledge into structured descriptions of appearance, shape, and spatial attributes, facilitating effective learning and integration of the proposed semantic anchors. Extensive experiments on six industrial and medical benchmarks demonstrate that AG-VAS achieves consistent state-of-the-art performance in the zero-shot setting.
Figures & tables
| Method | Base Model | Industrial Datasets | Medical Datasets | |||||
| MVTec-AD | KSDD2 | RSDD | ISIC | ColonDB | ClinicDB | |||
| CLIP-Based (AP, F1-Max, ) | WinCLIP [ 25 ] | CLIP(ViT-B-16-240) | (18.0, 24.3, 0.0) | (17.1, 24.6, 0.0) | (2.1, 6.6, 0.1) | (62.4, 64.1, 0.24) | (14.3, 21.0, 0.0) | (19.4, 27.3, 0.0) |
| APRIL-GAN [ 15 ] | CLIP(ViT-L-14-336) | (40.8, 43.3, 25.1) | (61.6, 62.6, 41.8) | (30.6, 40.2, 24.3) | (69.8, 69.3, 12.8) | (23.2, 32.5, 14.4) | (38.8, 44.4, 25.3) | |
| AnomalyCLIP [ 72 ] | CLIP(ViT-L-14-336) | (34.5, 39.1, 22.6) | (41.8, 50.3, 27.6) | (19.1, 30.6, 8.8) | (74.4, 70.8, 51.0) | (31.3, 39.8, 25.2) | (42.2, 45.9, 30.0) | |
| AnomalyCLIP* [ 72 ] | CLIP(ViT-L-14-336) | (35.2, 39.0, 22.4) | (48.8, 53.6, 28.6) | (25.5, 34.4, 8.5) | (76.5, 71.4, 54.1) | (34.2, 39.8, 22.7) | (44.1, 47.3, 29.4) | |
| Bayes-PFL [ 45 ] | CLIP(ViT-L-14-336) | (48.3, 49.1, 22.2) | (73.7, 63.5, 25.4) | (39.1, 45.2, 3.7) | (84.6, 76.8, 60.0) | (31.9, 39.2, 16.8) | (53.2, 51.7, 21.0) | |
| Method | Base Model | Average | ||
| PixelLM [ 52 ] | LLaVA-13B | 11.9 | 2.4 | 7.2 |
| PaDT [ 55 ] | Qwen2.5-VL-7B | 16.4 | 0.0 | 8.2 |
| LISA [ 29 ] | LLaVA-7B | 10.2 | 1.9 | 6.1 |
| LISA [ 29 ] | LLaVA-13B | 13.7 | 6.3 | 10.0 |
| LISA* [ 29 ] | LLaVA-13B | 31.8 | 43.5 | 37.7 |
| LISA [ 29 ] | LLaVA-OneVision-7B | 32.2 | 4.0 | 18.1 |
| AP | F1-Max | ||||
| Module Ablation | w/o [SEG] | 49.1 | 50.9 | 85.6 | 42.1 |
| w/o [NOR][ANO] | 47.2 | 49.7 | 52.1 | 39.5 | |
| w/o SPAM | 46.5 | 48.0 | 70.6 | 41.4 | |
| Training Dataset Ablation | w/o Anomaly-Instruct20K | 48.4 | 50.0 | 85.2 | 39.9 |
| w/o Anomaly-Seg20K | 49.3 | 51.5 | 53.5 | 42.4 | |
| w/o General Segmentation | 36.1 | 36.5 | 70.2 | 34.9 |
| Segmentation Mode | AP | F1-Max | ||
| Describe-then-segment | 49.3 | 51.3 | 58.8 | 43.6 |
| Describe-then-segment-plus | 51.9 | 53.0 | 90.2 | 45.1 |
| Segment-then-explain | 48.6 | 51.4 | 91.1 | 43.4 |
| Direct Segmentation | 51.0 | 52.7 | 87.7 | 44.8 |
Appendix figures & tables32 assets
Supplementary material from the paper’s appendix.
Appendix
| Dataset | Name | Type | Task | Number | Sampling Rate |
| General Segmentation Datasets | ADE20K [ 71 ] | Semantic Segmentation | Direct Segmentation | 200k | 0.4 |
| COCO-Stuff [ 12 ] | Direct Segmentation | ||||
| PACO-LVIS [ 50 ] | Part Semantic Segmentation | Direct Segmentation | |||
| PartImageNet [ 23 ] | Direct Segmentation | ||||
| PASCAL-Part [ 14 ] | Direct Segmentation | ||||
| refCLEF [ 27 ] | Referring Segmentation | Direct Segmentation |
| object | AnomalyCLIP | Bayes-PFL | PaDT | PixelLM | LISA-7B | LISA-13B | LISA-13B* | LISA-OV | LISA-OV* | AG-VAS |
| bottle | 55.3 | 64.7 | 10.1 | 22.9 | 14.2 | 15.6 | 34.3 | 35.0 | 47.5 | 45.8 |
| cable | 12.3 | 15.1 | 6.1 | 9.7 | 8.8 | 22.6 | 10.8 | 25.3 | 27.8 | 27.1 |
| capsule | 27.7 | 34.4 | 4.0 | 7.0 | 15.1 | 15.7 | 14.4 | 14.9 | 17.1 | 38.4 |
| carpet | 56.6 | 82.2 | 1.4 | 40.8 | 1.1 | 11.3 | 59.4 | 30.4 | 54.5 | 72.8 |
| grid | 24.1 | 41.1 | 0.7 | 0.7 | 0.4 | 0.5 | 60.4 | 23.4 | 57.5 | 64.1 |
| hazelnut | 43.4 | 70.9 | 5.8 | 7.6 | 11.5 | 11.7 | 36.0 | 34.8 | 55.9 | 70.2 |
| object | AnomalyCLIP | Bayes-PFL | PaDT | PixelLM | LISA-7B | LISA-13B | LISA-13B* | LISA-OV | LISA-OV* | AG-VAS |
| bottle | 51.6 | 61.3 | 18.9 | 34.6 | 27.4 | 30.5 | 38.3 | 38.3 | 46.4 | 47.0 |
| cable | 18.9 | 23.5 | 14.8 | 16.4 | 13.8 | 27.3 | 17.1 | 36.9 | 38.0 | 34.5 |
| capsule | 31.0 | 40.5 | 7.9 | 13.2 | 27.2 | 26.3 | 27.8 | 26.7 | 27.8 | 46.5 |
| carpet | 57.1 | 74.9 | 3.7 | 43.7 | 3.2 | 18.6 | 57.2 | 37.7 | 52.4 | 66.3 |
| grid | 32.0 | 41.6 | 1.6 | 1.5 | 1.4 | 1.4 | 61.7 | 29.1 | 59.2 | 64.2 |
| hazelnut | 47.6 | 66.2 | 11.3 | 15.5 | 23.0 | 23.2 | 44.3 | 36.3 | 56.9 | 65.0 |
| object | AnomalyCLIP | Bayes-PFL | PaDT | PixelLM | LISA-7B | LISA-13B | LISA-13B* | LISA-OV | LISA-OV* | AG-VAS |
| bottle | 27.3 | 25.2 | 20.0 | 26.7 | 20.0 | 25.4 | 30.7 | 36.7 | 23.8 | 41.4 |
| cable | 10.3 | 7.5 | 11.5 | 5.0 | 3.4 | 8.9 | 4.0 | 23.4 | 16.0 | 29.2 |
| capsule | 16.8 | 7.6 | 4.7 | 4.9 | 5.4 | 8.3 | 16.0 | 14.1 | 12.1 | 36.3 |
| carpet | 32.5 | 48.9 | 16.4 | 29.6 | 3.3 | 13.6 | 46.5 | 39.0 | 43.6 | 52.1 |
| grid | 20.5 | 24.4 | 12.9 | 2.0 | 0.8 | 0.5 | 43.7 | 32.8 | 47.9 | 41.7 |
| hazelnut | 28.0 | 9.4 | 14.5 | 13.2 | 17.6 | 23.0 | 45.8 | 44.7 | 45.7 | 64.4 |
| object | AnomalyCLIP | Bayes-PFL | PaDT | PixelLM | LISA-7B | LISA-13B | LISA-13B* | LISA-OV | LISA-OV* | AG-VAS |
| bottle | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 10.0 | 0.0 | 75.0 | 85.0 |
| cable | 17.2 | 0.0 | 0.0 | 34.5 | 25.9 | 17.2 | 0.0 | 0.0 | 56.9 | 55.2 |
| capsule | 73.9 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 91.3 | 95.7 |
| carpet | 78.6 | 96.4 | 0.0 | 0.0 | 0.0 | 3.6 | 100.0 | 57.1 | 89.3 | 100.0 |
| grid | 76.2 | 95.2 | 0.0 | 0.0 | 0.0 | 0.0 | 95.2 | 0.0 | 95.2 | 95.2 |
| hazelnut | 7.5 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 65.0 | 97.5 |
Zero-Shot Anomaly Detection
Zero-shot anomaly detection finds unusual patterns in unseen domains without task-specific labeled examples.
See all 85 papers