arXiv:2610.34610cs.CVOct 2026

Manuscript Offprint

arXiv:2610.34610

Do Words Matter? What Text Contributes to Few and Full-Shot Vision-Language Anomaly Detection

Arda Baris Basaran, Mesut Ceylan, Elgar Fleisch, Filipe Barata

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

ABSTRACT

Vision-language anomaly detectors describe normal and abnormal appearance with text, and their gains are commonly credited to the semantic content of these descriptions. This attribution is plausible in the zero-shot setting, but few and full-shot detectors interpose a trained visual adapter, and in that setting it has not been isolated. Changing a description changes both its meaning and its numerical geometry, so accuracy comparisons cannot separate the two. We ask what a fixed pair of text embeddings, or anchors, contributes to such a detector: semantic content, effective scale, or joint anchor geometry. For a single anchor pair, the answer is effective scale alone. The score reads the anchors only through their difference, and a trained adapter can rotate to follow any replacement direction, leaving that direction, and with it the linguistic content, unidentifiable. We prove that replacement anchors with the same difference-vector length permit exactly the same probability maps and attainable losses. Across seven medical datasets, three vision backbones, both supervision regimes, and three adapter families, scale-matched random and orthogonal anchors track correct prompts; breaking the scale match opens a clear gap that restoring the scale closes without text. The same pattern holds empirically in MVFA's residual, multi-level detector and when MadCLIP's learned prompts are replaced by a text-free learned scale. When one adapter serves many categories, the answer expands to their joint arrangement. Rotating all category axes together does not change anything, as predicted. For the tested CLIP prompt banks, these axes are nearly collinear, and meaning-free rotations that spread them apart improve performance on both industrial benchmarks. Even under frozen zero-shot transfer, a random anchor frame transfers as well as the prompt frame: coordinate consistency, not meaning. What these detectors read from their prompts is scale and arrangement, not semantic content.

1 INTRODUCTION

Anomaly detection asks a model to identify appearances it has rarely or never seen. Because anomalies are rare, visually diverse, and seldom labeled, the field has largely trained detectors on normal data alone, scoring a test image by how far it departs from the resulting model of normality (Roth et al., 2022; Deng & Li, 2022; Gudovskiy et al., 2022; Salehi et al., 2021); supervising anomalies directly only shifts the scarcity, since labeled anomalous examples are rarer still (Ding et al., 2022; Yao et al., 2023). Such detectors carry no explicit representation of what constitutes abnormality, and must define it negatively, as departure from a reference distribution that has to be estimated exhaustively from images. The cost is a per-category fit: every new object or organ needs its own corpus of normal data, and accuracy degrades when only a handful of examples are available (Huang et al., 2022). Vision-language models supply the missing half. Contrastive pretraining on web-scale image-text pairs places visual and textual concepts in a shared space (Radford et al., 2021), so the reference for abnormal can be written in language instead of estimated from target-domain images. This both enables low-sample operation and lets a single category-agnostic detector be re-targeted by changing the noun in a prompt.

Figure

Figure 1: What the text anchors contribute to a trained fixed-anchor detector. The score reads the two anchors only through their difference, the scoring axis. Left: a separately trained adapter rotates to follow any replacement axis of the same effective scale, so its direction, and with it the semantic content, is unidentifiable. Middle: with one adapter serving many categories, a shared rotation preserves the arrangement of their axes; independent rotations keep each scale but change the arrangement. Right: a frozen adapter cannot rotate, so it must keep the anchor frame it was trained with, which need not be linguistic. Embeddings are schematic.

These detectors perform well in practice. Handcrafted prompts give competitive zero-shot results on industrial benchmarks (Jeong et al., 2023); trained visual projections or learned prompts improve zero- and few-shot performance (Chen et al., 2023; Zhou et al., 2024); and the approach extends to medical imaging, where labeled anomalies are scarcest (Huang et al., 2024; Shiri et al., 2025). Language-conditioned detection is thus common in the low-label regime. The trained fixed-anchor subclass studied here uses two prescribed embeddings, or anchors, for its normal-abnormal readout.

The field typically attributes these gains to semantic factors, including anomaly semantics, language-compatible features, or vision-language alignment (Li et al., 2024; Zuo et al., 2024; Huang et al., 2024; Zhang et al., 2024; Shiri et al., 2025). In a training-free detector, the anchors directly define the scoring rule: no learned visual map can compensate when their coordinates change. The fixed-anchor few- and full-shot setting differs: real or synthetic anomaly targets train a visual adapter against the anchors, letting it absorb changes in their direction. Because changing a description alters both its meaning and its numerical geometry, ordinary prompt comparisons cannot determine which anchor properties remain observable after adaptation. Curated prompt banks cost clinical expertise for each new dataset and finding; if anchors contribute only geometry, pursuing better descriptions and text encoders targets the wrong variable. This motivates our central question: For trained fixed-anchor vision-language anomaly detectors, what information from the text anchors actually affects representational capacity and observed performance: semantic content, effective scale, or joint anchor geometry? We answer this by identifying what the score can read, then testing whether training respects it. The binary score depends on the anchors only through their difference: a direction, which a trained adapter can rotate its output to follow (Figure 1, left), and a magnitude, which it cannot. We prove the direction is therefore unidentifiable, and probe the claim with five anchor conditions (correct medical prompts, a mismatched-dataset bank, and three text-free pairs that preserve or break the surviving magnitude) across seven medical datasets, two supervision regimes, three vision backbones and three adapter families. We then find the same scale-controlled pattern in MVFA's residual multi-level detector and in MadCLIP after replacing its learned prompt path with a text-free learned scale. Two further settings test the boundaries: one adapter serving many categories, where the invariant becomes the joint geometry of their difference vectors (Figure 1, middle), and frozen zero-shot transfer, where the adapter can no longer rotate.

Our contributions are:

Single-pair identification. Only the effective scale is identifiable. Scale-matched random and orthogonal anchors track correct medical prompts with mean gaps of 0.16%–0.26% image AUROC; breaking the scale opens a clear gap that restoring it closes with no text.

Shared multi-category geometry. The invariant expands to the Gram matrix of the category difference vectors. The tested CLIP prompt axes are nearly collinear, and spreading them apart, while preserving every category's scale and adding no meaning, improves both industrial benchmarks, by 5.6% image and 4.4% pixel AUROC on VisA and up to 8.8% and 8.3% across vision backbones.

Frozen zero-shot transfer boundary. With the adapter frozen, its anchor frame is load-bearing but need not be linguistic: a retained random frame averages within 0.5% AUROC of prompts.

References (66)