Table of Contents
Fetching ...

SpatialMath: Spatial Comprehension-Infused Symbolic Reasoning for Mathematical Problem-Solving

Ashutosh Bajpai, Akshat Bhandari, Akshay Nambi, Tanmoy Chakraborty

TL;DR

SpatialMath tackles the gap in visual geometric reasoning for multimodal LLMs by introducing SpatialMath-SX, a Spatial Comprehension Core that converts diagrams into structured spatial descriptions, and SpatialMath-RX, a Reasoning Infusion Core that grounds stepwise symbolic reasoning in those spatial representations. The authors augment MathVerse with MATHVERSE-PLUS, a geometry-centric dataset providing spatial comprehensions and reasoning chains, and validate the approach across LLaVA-NeXT-34B, Phi-4, and other MSLMs, reporting substantial accuracy gains (up to ~10 percentage points) in vision-rich problems and improved robustness across benchmarks. They also propose an evaluator module to filter spatial comprehensions and demonstrate improved generalization and computational efficiency relative to strong baselines. The work advances a practical, perception-to-reasoning pipeline for visual mathematics with broad implications for STEM problem solving, educational tools, and robust multimodal reasoning. Overall, SpatialMath represents a significant step toward reliable, interpretable visual-mathematical reasoning in mid-sized multimodal models, combining enhanced perception with structured symbolic inference.

Abstract

Multimodal Small-to-Medium sized Language Models (MSLMs) have demonstrated strong capabilities in integrating visual and textual information but still face significant limitations in visual comprehension and mathematical reasoning, particularly in geometric problems with diverse levels of visual infusion. Current models struggle to accurately decompose intricate visual inputs and connect perception with structured reasoning, leading to suboptimal performance. To address these challenges, we propose SpatialMath, a novel Spatial Comprehension-Infused Symbolic Reasoning Framework designed to integrate spatial representations into structured symbolic reasoning chains. SpatialMath employs a specialized perception module to extract spatially-grounded representations from visual diagrams, capturing critical geometric structures and spatial relationships. These representations are then methodically infused into symbolic reasoning chains, facilitating visual comprehension-aware structured reasoning. To this end, we introduce MATHVERSE-PLUS, a novel dataset containing structured visual interpretations and step-by-step reasoning paths for vision-intensive mathematical problems. SpatialMath significantly outperforms strong multimodal baselines, achieving up to 10 percentage points improvement over supervised fine-tuning with data augmentation in vision-intensive settings. Robustness analysis reveals that enhanced spatial representations directly improve reasoning accuracy, reinforcing the need for structured perception-to-reasoning pipelines in MSLMs.

SpatialMath: Spatial Comprehension-Infused Symbolic Reasoning for Mathematical Problem-Solving

TL;DR

SpatialMath tackles the gap in visual geometric reasoning for multimodal LLMs by introducing SpatialMath-SX, a Spatial Comprehension Core that converts diagrams into structured spatial descriptions, and SpatialMath-RX, a Reasoning Infusion Core that grounds stepwise symbolic reasoning in those spatial representations. The authors augment MathVerse with MATHVERSE-PLUS, a geometry-centric dataset providing spatial comprehensions and reasoning chains, and validate the approach across LLaVA-NeXT-34B, Phi-4, and other MSLMs, reporting substantial accuracy gains (up to ~10 percentage points) in vision-rich problems and improved robustness across benchmarks. They also propose an evaluator module to filter spatial comprehensions and demonstrate improved generalization and computational efficiency relative to strong baselines. The work advances a practical, perception-to-reasoning pipeline for visual mathematics with broad implications for STEM problem solving, educational tools, and robust multimodal reasoning. Overall, SpatialMath represents a significant step toward reliable, interpretable visual-mathematical reasoning in mid-sized multimodal models, combining enhanced perception with structured symbolic inference.

Abstract

Multimodal Small-to-Medium sized Language Models (MSLMs) have demonstrated strong capabilities in integrating visual and textual information but still face significant limitations in visual comprehension and mathematical reasoning, particularly in geometric problems with diverse levels of visual infusion. Current models struggle to accurately decompose intricate visual inputs and connect perception with structured reasoning, leading to suboptimal performance. To address these challenges, we propose SpatialMath, a novel Spatial Comprehension-Infused Symbolic Reasoning Framework designed to integrate spatial representations into structured symbolic reasoning chains. SpatialMath employs a specialized perception module to extract spatially-grounded representations from visual diagrams, capturing critical geometric structures and spatial relationships. These representations are then methodically infused into symbolic reasoning chains, facilitating visual comprehension-aware structured reasoning. To this end, we introduce MATHVERSE-PLUS, a novel dataset containing structured visual interpretations and step-by-step reasoning paths for vision-intensive mathematical problems. SpatialMath significantly outperforms strong multimodal baselines, achieving up to 10 percentage points improvement over supervised fine-tuning with data augmentation in vision-intensive settings. Robustness analysis reveals that enhanced spatial representations directly improve reasoning accuracy, reinforcing the need for structured perception-to-reasoning pipelines in MSLMs.
Paper Structure (48 sections, 5 equations, 19 figures, 12 tables, 1 algorithm)

This paper contains 48 sections, 5 equations, 19 figures, 12 tables, 1 algorithm.

Figures (19)

  • Figure 1: An example from our dataset showcasing six settings of a geometrical mathematical problem.
  • Figure 2: An instance of SC: the Spatial Comprehension generated by an MLLM, specifically GPT-4o that includes the text-only variant of the problem highlighted in with blue color, and $r$: the Reasoning Chain, which consists of a series of sequential steps culminating in the final solution, also generated by the aforesaid MLLM.
  • Figure 3: An overview of our framework: (1) Generating Spatial Comprehension (SC) for training set using an MLLM; (2) Fine-tuning SpatialMath-SX to enhance visual comprehension; (3) Using SpatialMath-SX at inference to generate SC for test set; (4) Generating Reasoning Chain data for train set; (5) Fine-tuning SpatialMath-RX using generated SC for training set by SpatialMath-SX and Reasoning Chain; (6) Deploying SpatialMath-RX at inference for problem-solving.
  • Figure 4: Performance of LLaVA-NeXT-34B-based SpatialMath-SX alogn with default LLaVA-NeXT-34B-based solver across three other public benchmarks- MathVision, MathVista, and Geometry3K.
  • Figure 5: Analysis on computational overhead in comparison to a single model baseline (SFT+Data Aug.) approach. Bubble Size: Average #tokens generated
  • ...and 14 more figures