Mind the Gap Between Spatial Reasoning and Acting! Step-by-Step Evaluation of Agents With Spatial-Gym

2026-04-10Artificial Intelligence

Artificial IntelligenceComputation and Language
AI summary

The authors created Spatial-Gym, a testing setup to measure how well models solve 2D pathfinding puzzles step-by-step, like humans do. They tested different models and found even the best one performed far below human level. Models did better with simpler step-by-step tasks but struggled when global planning or backtracking was required. They also noticed that models using images performed worse, and that thinking through each step carefully helps models make fewer mistakes. Spatial-Gym helps understand where models fail and guides improving spatial reasoning in AI.

spatial reasoningpathfinding2D-grid puzzlesstep-by-step reasoningbacktrackingreinforcement learningA* algorithmchain-of-thoughtGymnasium environmentmodel benchmarking
Authors
Lars Benedikt Kaesberg, Tianyu Yang, Niklas Bauer, Terry Ruas, Jan Philip Wahle, Bela Gipp
Abstract
Spatial reasoning is central to navigation and robotics, yet measuring model capabilities on these tasks remains difficult. Existing benchmarks evaluate models in a one-shot setting, requiring full solution generation in a single response, unlike humans, who work in interactive environments step-by-step. We introduce Spatial-Gym, a Gymnasium environment that isolates spatial constraint reasoning by testing pathfinding in 2D-grid puzzles as a sequential decision task with optional backtracking. We evaluate eight models in three settings (one-shot, step-by-step, step-by-step with backtracking) against human, random, and A* baselines on 500 episodes. The best model, GPT-OSS 120B, achieves a solve rate of 16.0%, 82 points below the human baseline (98.0%). Step-by-step format helps weaker models (up to +5.4%) by removing formatting errors, but hurts stronger models (up to 5.6%) by constraining global planning. Backtracking improves episode completion, but increases solve rate only for weaker models; stronger models rarely backtrack and do not benefit from it. Our experiments have three key findings: (1) models fail to scale reasoning effort with difficulty, (2) vision models receiving images of the spatial environment reduce solve rate by 73%, and (3) extended chain-of-thought reasoning retains a 3-5x accuracy advantage over standard inference even in the step-by-step setting. Spatial-Gym enables diagnosis of model limitations and provides a framework for improving spatial reasoning through reinforcement learning.