Adding simple structure at inference improves Vision-Language Compositionality

Imanol Miranda, Ander Salaberria, Eneko Agirre, Gorka Azkune
6/11/2025
cs.CVcs.CLcs.LG

No confident code implementation found for this paper.

Abstract

Dual encoder Vision-Language Models (VLM) such as CLIP are widely used for image-text retrieval tasks. However, those models struggle with compositionality, showing a bag-of-words-like behavior that limits their retrieval performance. Many different training approaches have been proposed to improve the vision-language compositionality capabilities of those models. In comparison, inference-time techniques have received little attention. In this paper, we propose to add simple structure at inference, where, given an image and a caption: i) we divide the image into different smaller crops, ii) we extract text segments, capturing objects, attributes and relations, iii) using a VLM, we find the image crops that better align with text segments obtaining matches, and iv) we compute the final image-text similarity aggregating the individual similarities of the matches. Based on various popular dual encoder VLMs, we evaluate our approach in controlled and natural datasets for VL compositionality. We find that our approach consistently improves the performance of evaluated VLMs without any training, which shows the potential of inference-time techniques. The results are especially good for attribute-object binding as shown in the controlled dataset. As a result of an extensive analysis: i) we show that processing image crops is actually essential for the observed gains in performance, and ii) we identify specific areas to further improve inference-time approaches.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{miranda2025adding,
  title  = {Adding simple structure at inference improves Vision-Language Compositionality},
  author = {Imanol Miranda and Ander Salaberria and Eneko Agirre and Gorka Azkune},
  year   = {2025},
  eprint = {2506.09691},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2506.09691v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2506.09691.svg)](https://codeofpaper.com/paper/2506.09691)

Discussion