Saved in:
Bibliographic Details
Main Authors: Liu, Junze, Qian, Kun, Dubost, Florian, Zhong, Kai, Srinivasan, Arvind, Chen, Nan, Wang, Anping, Zhang, Sam, Mottini, Alejandro, Cui, Qingjun, Wang, Tian
Format: Preprint
Published: 2026
Subjects:
Online Access:https://arxiv.org/abs/2605.12586
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866917488228302848
author Liu, Junze
Qian, Kun
Dubost, Florian
Zhong, Kai
Srinivasan, Arvind
Chen, Nan
Wang, Anping
Zhang, Sam
Mottini, Alejandro
Cui, Qingjun
Wang, Tian
author_facet Liu, Junze
Qian, Kun
Dubost, Florian
Zhong, Kai
Srinivasan, Arvind
Chen, Nan
Wang, Anping
Zhang, Sam
Mottini, Alejandro
Cui, Qingjun
Wang, Tian
contents Vision-language models (VLMs) exhibit a striking paradox: they can generate executable code that reconstructs a 3D scene from geometric primitives with correct object counts, classes, and approximate positions, yet the same models fail at simpler spatial questions on the same image. We show that 3D geometric primitives (cubes, spheres, cylinders, expressed in executable code) serve as a powerful intermediate representation for spatial understanding, and exploit this through three contributions. First, we introduce \textbf{\textsc{SpatialBabel}}, a benchmark evaluating fourteen VLMs on primitive-based 3D scene reconstruction across six \emph{scene-code languages} (programming languages and declarative formats for 3D primitive scenes), revealing that a single model's object-detection F1 can vary by up to $5.7\times$ across languages. Second, we propose \textbf{Code-CoT} (Code Chain-of-Thought), a training-free inference strategy that routes spatial reasoning through primitive-based code generation. Code-CoT lifts the SpatialBabel-QA-Score by up to $+6.4$\% on primitive scenes and real-photo CV-Bench-3D accuracy by $+5.0$\% for VLMs with strong coding capabilities. Third, we propose \textbf{S$^{3}$-FT} (Self-Supervised Spatial Fine-Tuning), which self-supervisedly distills primitive spatial knowledge into general visual reasoning by parsing the model's own Three.js primitive-reconstructions into structured annotations and fine-tuning on the result, with \emph{no human labels and no teacher model}. Training on primitive images alone, S$^3$-FT improves Qwen3-VL-8B by $+4.6$ to $+8.6$\% on SpatialBabel-Primitive-QA, $+9.7$\% on CV-Bench-2D, and $+17$\% on HallusionBench; the recipe transfers across model families. These results establish geometric primitives in code as both a diagnostic and a transferable spatial vocabulary for VLMs. We will release all artifacts upon publication.
format Preprint
id arxiv_https___arxiv_org_abs_2605_12586
institution arXiv
publishDate 2026
record_format arxiv
spellingShingle 3D Primitives are a Spatial Language for VLMs
Liu, Junze
Qian, Kun
Dubost, Florian
Zhong, Kai
Srinivasan, Arvind
Chen, Nan
Wang, Anping
Zhang, Sam
Mottini, Alejandro
Cui, Qingjun
Wang, Tian
Computer Vision and Pattern Recognition
Artificial Intelligence
Databases
Vision-language models (VLMs) exhibit a striking paradox: they can generate executable code that reconstructs a 3D scene from geometric primitives with correct object counts, classes, and approximate positions, yet the same models fail at simpler spatial questions on the same image. We show that 3D geometric primitives (cubes, spheres, cylinders, expressed in executable code) serve as a powerful intermediate representation for spatial understanding, and exploit this through three contributions. First, we introduce \textbf{\textsc{SpatialBabel}}, a benchmark evaluating fourteen VLMs on primitive-based 3D scene reconstruction across six \emph{scene-code languages} (programming languages and declarative formats for 3D primitive scenes), revealing that a single model's object-detection F1 can vary by up to $5.7\times$ across languages. Second, we propose \textbf{Code-CoT} (Code Chain-of-Thought), a training-free inference strategy that routes spatial reasoning through primitive-based code generation. Code-CoT lifts the SpatialBabel-QA-Score by up to $+6.4$\% on primitive scenes and real-photo CV-Bench-3D accuracy by $+5.0$\% for VLMs with strong coding capabilities. Third, we propose \textbf{S$^{3}$-FT} (Self-Supervised Spatial Fine-Tuning), which self-supervisedly distills primitive spatial knowledge into general visual reasoning by parsing the model's own Three.js primitive-reconstructions into structured annotations and fine-tuning on the result, with \emph{no human labels and no teacher model}. Training on primitive images alone, S$^3$-FT improves Qwen3-VL-8B by $+4.6$ to $+8.6$\% on SpatialBabel-Primitive-QA, $+9.7$\% on CV-Bench-2D, and $+17$\% on HallusionBench; the recipe transfers across model families. These results establish geometric primitives in code as both a diagnostic and a transferable spatial vocabulary for VLMs. We will release all artifacts upon publication.
title 3D Primitives are a Spatial Language for VLMs
topic Computer Vision and Pattern Recognition
Artificial Intelligence
Databases
url https://arxiv.org/abs/2605.12586