Thinking with Spatial Code for Physical-World Video Reasoning
On the map: LLM reasoning → Spatial and embodied reasoning
Abstract (arXiv)
We introduce Thinking with Spatial Code, a framework that transforms RGB video into explicit, temporally coherent 3D representations for physical-world visual question answering. We highlight the empirical finding that our proposed spatial encoder can parse videos into structured spatial code with explicit 3D oriented bounding boxes and semantic labels, enabling large language models (LLMs) to reason directly over explicit spatial variables. Specifically, we propose the spatial encoder that encodes image and geometric features by unifying 6D object parsing and tracking backbones with geometric prediction, and we further finetuning LLMs with reinforcement learning using a spatial rubric reward that encourages perspective-aware, geometrically grounded inference. As a result, our model outperforms proprietary vision-language models on VSI-Bench, setting a new state-of-the-art. Code is available at https://github.com/Beckschen/spatialcode.
Key facts. Cited by 7 papers in the map (data through 7 Oct 2026). Placed in Spatial and embodied reasoning, one of 17 directions in LLM reasoning. Builds on 44 of its 48 references that are in the map. First posted on arXiv 5 Mar 2026.
Builds on
44 of 48 references.
Closest ancestors · 5
Same direction, newest first
- 2025SpatialLadder: Progressive Training for Spatial Reasoning in Vision-Language Models9 Oct
- 2025SpaceR: Reinforcing MLLMs in Video Spatial Reasoning2 Apr
- 2025Spatial457: A Diagnostic Benchmark for 6D Spatial Reasoning of Large Multimodal Models12 Feb
- 2024Thinking in Space: How Multimodal Large Language Models See, Remember, and Recall Spaces18 Dec
- 2024SpatialVLM: Endowing Vision-Language Models with Spatial Reasoning Capabilities22 Jan
Other references · 39
- 2021Learning Transferable Visual Models From Natural Language Supervisioncited by 33,456
- 2024DeepSeekMath: Pushing the Limits of Mathematical Reasoning in Open Language Modelscited by 8,851
- 2025Qwen3 Technical Reportcited by 8,195
- 2023Segment Anythingcited by 8,158
- 2023Visual Instruction Tuningcited by 7,792
- 2023BLIP-2: Bootstrapping Language-Image Pre-training with Frozen Image Encoders and Large Language Modelscited by 6,069
- 2025Qwen2.5-VL Technical Reportcited by 5,418
- 2024GPT-4o System Cardcited by 4,467
- 2022Flamingo: a Visual Language Model for Few-Shot Learningcited by 4,337
- 2025Gemini 2.5: Pushing the Frontier with Advanced Reasoning, Multimodality, Long Context, and Next Generation Agentic Capabilitiescited by 3,655
- 2023Let's Verify Step by Stepcited by 3,598
- 2017ScanNet: Richly-annotated 3D Reconstructions of Indoor Scenescited by 3,088
27 more
- 2024SAM 2: Segment Anything in Images and Videoscited by 2,784
- 2024LLaVA-OneVision: Easy Visual Task Transfercited by 2,669
- 2017What Uncertainties Do We Need in Bayesian Deep Learning for Computer Vision?cited by 2,335
- 2023DUSt3R: Geometric 3D Vision Made Easycited by 1,526
- 2025VGGT: Visual Geometry Grounded Transformercited by 1,475
- 2016CLEVR: A Diagnostic Dataset for Compositional Language and Elementary Visual Reasoningcited by 1,445
- 2023Video-LLaVA: Learning United Visual Representation by Alignment Before Projectioncited by 1,385
- 2019Generalized Intersection over Union: A Metric and A Loss for Bounding Box Regressioncited by 1,361
- 2024Depth Anything: Unleashing the Power of Large-Scale Unlabeled Datacited by 1,346
- 2024Tulu 3: Pushing Frontiers in Open Language Model Post-Trainingcited by 988
- 2022Solving math word problems with process- and outcome-based feedbackcited by 871
- 2025Depth Anything 3: Recovering the Visual Space from Any Viewscited by 626
- 2020Hypersim: A Photorealistic Synthetic Dataset for Holistic Indoor Scene Understandingcited by 593
- 2021ARKitScenes: A Diverse Real-World Dataset For 3D Indoor Scene Understanding Using Mobile RGB-D Datacited by 442
- 2025Spatial-MLLM: Boosting MLLM Capabilities in Visual-based Spatial Intelligencecited by 206
- 2023Aria Digital Twin: A New Benchmark Dataset for Egocentric 3D Machine Perceptioncited by 166
- 2022Omni3D: A Large Benchmark and Model for 3D Object Detection in the Wildcited by 159
- 2024RoboSpatial: Teaching Spatial Understanding to 2D and 3D Vision-Language Models for Roboticscited by 133
- 2017MarrNet: 3D Shape Reconstruction via 2.5D Sketchescited by 108
- 2024SceneScript: Reconstructing Scenes With An Autoregressive Structured Language Modelcited by 95
- 2025SpatialLM: Training Large Language Models for Structured Indoor Modelingcited by 63
- 2024Efficient Large Multi-modal Models via Visual Context Compressioncited by 46
- 2024ViTamin: Designing Scalable Vision Models in the Vision-Language Eracited by 39
- 2024Cubify Anything: Scaling Indoor 3D Object Detectioncited by 39
- 2025Detect Anything 3D in the Wildcited by 32
- 20183D-Aware Scene Manipulation via Inverse Graphicscited by 24
- 20253D-MOOD: Lifting 2D to 3D for Monocular Open-Set Object Detectioncited by 10
Built on by
Citing papers per year: 2026: 7.
7 papers.
- 2026LLaVA-OneVision-2: Towards Next-Generation Perceptual Intelligencecited by 31
- 2026Ouroboros-Spatial: Closing the Data-Model Loop for Spatial Reasoningcited by 1
- 2026Annotations as Rollouts: Efficient and Scalable Reinforcement Learning for Video MLLMscited by 1
- 2026BVB: Benchmarking Agentic Video Understanding via Programmatic Reconstruction in Blendercited by 1
- 2026OneCanvas: 3D Scene Understanding via Panoramic Reprojectioncited by 0
- 2026Chain of Spatial Thoughts: Modality-Agnostic Spatial Grounding for Vision Language Modelscited by 0
- 2026Geometric Encoding for Spatial Reasoning in Vision-Language Modelscited by 0
- 2026Geometric Encoding for Spatial Reasoning in Vision-Language Models28 Sep 2026
- 2026BVB: Benchmarking Agentic Video Understanding via Programmatic Reconstruction in Blender14 Sep 2026
- 2026Annotations as Rollouts: Efficient and Scalable Reinforcement Learning for Video MLLMs20 Aug 2026
- 2026Chain of Spatial Thoughts: Modality-Agnostic Spatial Grounding for Vision Language Models10 Aug 2026
- 2026OneCanvas: 3D Scene Understanding via Panoramic Reprojection17 Jun 2026
- 2026Ouroboros-Spatial: Closing the Data-Model Loop for Spatial Reasoning10 Jun 2026
- 2026LLaVA-OneVision-2: Towards Next-Generation Perceptual Intelligence25 May 2026
Similar, not cited
Close in wording, no citation either way
- 2026SpatioLM: Towards General Physical Spatial Intelligence in Vision-Language Models
- 2025Learning to Reason in 4D: Dynamic Spatial Understanding for Vision Language Models
- 2026Q-GeoMem: Question-Guided Geometric Memory for Video Spatial Reasoning
- 2025Scene-R1: Video-Grounded Large Language Models for 3D Scene Reasoning without 3D Annotations
- 2026SpatialBlock: Enhancing Spatial Intelligence in LVLMs via Synthetic Block-Stacking Problem
- 2026SpatialSpeak: QA-Native Reconstruction with Local and Global Context for Spatial Chain-of-Thought Reasoning
- 2024SpatialRGPT: Grounded Spatial Reasoning in Vision Language Models
- 2025SpatialThinker: Reinforcing Scene Graph-Grounded Spatial Reasoning via Dense Rewards