SpaceVLM: Sub-Space Modeling of Negation in Vision-Language Models
Sepehr Kazemi Ranjbar, Kumail Alhamoud, Marzyeh Ghassemi
TL;DR
SpaceVLM tackles the challenge of negation in vision–language models by modeling negation as a subspace in the joint embedding space rather than a single embedding. Grounded in the empirical divisibility of CLIP-like embeddings into semantically coherent regions, it computes a center direction from affirmative and negated embeddings using spherical caps and a cosine-threshold, enabling a training-free, model-agnostic negation score. The method yields around a 30% average improvement on negation tasks across retrieval, MCQ, and text-to-image generation, while preserving zero-shot performance on affirmative prompts. Evaluations across 40+ settings and multiple backbones demonstrate robustness to threshold choices and LLM pre-processors, with practical gains in negation-aware generation, suggesting a promising geometric perspective for broader logical reasoning in VLMs.
Abstract
Vision-Language Models (VLMs) struggle with negation. Given a prompt like "retrieve (or generate) a street scene without pedestrians," they often fail to respect the "not." Existing methods address this limitation by fine-tuning on large negation datasets, but such retraining often compromises the model's zero-shot performance on affirmative prompts. We show that the embedding space of VLMs, such as CLIP, can be divided into semantically consistent subspaces. Based on this property, we propose a training-free framework that models negation as a subspace in the joint embedding space rather than a single point (Figure 1). To find the matching image for a caption such as "A but not N," we construct two spherical caps around the embeddings of A and N, and we score images by the central direction of the region that is close to A and far from N. Across retrieval, MCQ, and text-to-image tasks, our method improves negation understanding by about 30% on average over prior methods. It closes the gap between affirmative and negated prompts while preserving the zero-shot performance that fine-tuned models fail to maintain. Code will be released upon publication.
