Locality Alignment Improves Vision-Language Models

Ian Connick Covert, Tony Sun, James Zou, Tatsunori Hashimoto

The Spatial Reasoning Bottleneck in VLMs

Current Vision-Language Models (VLMs) excel at describing overall scenes but often fail at basic spatial tasks, such as counting objects or determining their precise locations. Most modern VLMs rely on vision backbones like CLIP or SigLIP, which are typically trained using image-level supervision—matching an entire image to a single caption. While this makes them excellent at understanding what is in an image, they lack the inductive bias to understand exactly where things are.

Because these models aren't forced to localize features during pre-training, their output embeddings often "smear" information across the entire image. Consequently, when a language model attempts to use these features for tasks like object localization or relational reasoning (e.g., "Is the cup to the left of the plate?"), it struggles due to a lack of spatial precision.

Introducing Locality Alignment and MaskEmbed

To address this, the authors propose a highly efficient post-training procedure called Locality Alignment, powered by a novel algorithm known as MaskEmbed. This stage teaches vision backbones to disentangle local semantics from global features without requiring any new human labels.

The core idea relies on a teacher-student architecture using the original pre-trained Vision Transformer (ViT):

  1. Masking: A large portion of the image patches is masked out.
  2. Encoding: The "student" encoder processes only the unmasked patches.
  3. Reconstruction: A small, shallow Transformer decoder is tasked with reconstructing the "teacher" model's embeddings for the masked patches.
  4. Self-Supervision: To minimize the reconstruction loss, the student encoder must learn to capture and represent the specific semantic contributions of every patch without leaking information from its neighbors.
MaskEmbed Architecture

This process leverages the latent knowledge already hidden inside the pre-trained model, forcing that knowledge into a more localized, accessible format.

Key Insights and Performance Gains

The researchers evaluated this approach across a massive suite of benchmarks, including RefCOCO/OCID-Ref (localization), TallyQA (counting), VSR (spatial relations), and AI2D (charts).

The Knowledge is Already There: The most striking insight is that models like CLIP already possess significant local semantic knowledge; it is simply buried. MaskEmbed acts as an extraction tool to bring that local information to the surface.

Scale Isn't a Silver Bullet: Even massive models like SigLIP SO400M—the current state-of-the-art for many VLMs—suffer from poor locality. Locality alignment provided a significant boost even to these strong backbones, proving that architectural scale alone doesn't automatically solve spatial reasoning.

Benchmark Improvements

VLM Benchmarks: Models using locality-aligned backbones saw consistent improvements across almost all spatial benchmarks. On tasks like RefCOCO, the aligned models significantly outperformed the baselines. Furthermore, when integrating the aligned backbone into a VLM, using the trained MaskEmbed decoder as the vision-language adapter worked much better than a standard MLP adapter, helping to "translate" the newly compressed local features.

Remarkable Efficiency: The entire alignment process is incredibly cheap. It requires less than 1% of the compute used for the original CLIP/SigLIP pre-training, making it a highly accessible method for improving VLM performance.

Limitations and Future Directions

While highly effective, locality alignment does have limitations. Because the new embeddings move into a different latent space, the model loses its out-of-the-box ability to perform zero-shot classification without further fine-tuning.

Future work could explore training on more diverse, web-scale datasets (like DataComp) to further enrich localized features. Additionally, researchers can investigate how locality alignment interacts with other popular techniques, such as feature fusion or higher-resolution input strategies, to continue pushing the boundaries of VLM spatial comprehension.

Summary updated

BibTeX
@inproceedings{covert2025locality,
  author = {Ian Connick Covert and Tony Sun and James Zou and Tatsunori Hashimoto},
  title = {{Locality Alignment Improves Vision-Language Models}},
  booktitle = {International Conference on Learning Representations},
  year = {2025},
  url = {https://openreview.net/forum?id=qssVptHTPN},
}
Figure