mlsanityData to 7 Oct 2026

Theory of Code Space: Do Code Agents Understand Software Architecture?

arXiv 2603.00601 ↗First posted 28 Feb 2026cs.SE cs.AIcited by 0

On the map: LLM agents and tool use → Software engineering coding agents

Abstract (arXiv)

AI code agents excel at isolated tasks yet struggle with multi-file software engineering requiring architectural understanding. We introduce Theory of Code Space (ToCS), a benchmark that evaluates whether agents can construct, maintain, and update coherent architectural beliefs during codebase exploration. Agents explore procedurally generated codebases under partial observability -- opening files under a budget -- and periodically externalize their belief state as structured JSON, producing a time-series of architectural understanding. Three findings emerge from experiments with four baselines and six frontier LLMs. First, the Active-Passive Gap is model-dependent: one model builds better maps through active exploration than from seeing all files at once, while another shows the opposite -- revealing that active exploration is itself a non-trivial capability absent from some models. Second, retaining structured belief maps in context acts as self-scaffolding for some models but not others, showing that the mechanism is model-dependent. Third, belief state maintenance varies dramatically: a smaller model maintains perfectly stable beliefs across probes while its larger sibling suffers catastrophic belief collapse -- forgetting previously-discovered components between probes. We release ToCS as open-source software. Code: https://github.com/che-shr-cat/tocs

Key facts. No citing papers in the map yet (data through 7 Oct 2026). Placed in Software engineering coding agents, one of 16 directions in LLM agents and tool use. Builds on 13 of its 18 references that are in the map. First posted on arXiv 28 Feb 2026.

Builds on

13 of 18 references.

Closest ancestors · 3

Same direction, newest first

  1. 2026ContextBench: A Benchmark for Context Retrieval in Coding Agents5 Feb
  2. 2025LoCoBench-Agent: An Interactive Benchmark for LLM Agents in Long-Context Software Engineering17 Nov
  3. 2025TOM-SWE: User Mental Modeling For Software Engineering Agents24 Oct

Other references · 10

  1. 2021Evaluating Large Language Models Trained on Codecited by 8,053
  2. 2021Program Synthesis with Large Language Modelscited by 3,509
  3. 2023SWE-bench: Can Language Models Resolve Real-World GitHub Issues?cited by 3,193
  4. 2019Habitat: A Platform for Embodied AI Researchcited by 1,163
  5. 2024SpatialVLM: Endowing Vision-Language Models with Spatial Reasoning Capabilitiescited by 679
  6. 2023RepoBench: Benchmarking Repository-Level Code Auto-Completion Systemscited by 346
  7. 2023CodePlan: Repository-level Coding using LLMs and Planningcited by 139
  8. 2025CWM: An Open-Weights LLM for Research on Code Generation with World Modelscited by 87
  9. 2025RefactorBench: Evaluating Stateful Reasoning in Language Agents Through Codecited by 28
  10. 2026Theory of Space: Can Foundation Models Construct Spatial Beliefs through Active Exploration?cited by 18

Built on by

Not cited yet.

Similar, not cited

Close in wording, no citation either way

  1. 2026CodeCompass: Navigating the Navigation Paradox in Agentic Code Intelligence
  2. 2026The Devil Is in the Interface: Evaluating How Tool Architecture Shapes Coding Agent Behavior
  3. 2026Formal Architecture Descriptors as Navigation Primitives for AI Coding Agents
  4. 2026Projecting the Emerging Mindset of SWE Agent by Launching a Wild Code Understanding Journey
  5. 2026Inside the Scaffold: A Source-Code Taxonomy of Coding Agent Architectures
  6. 2026Understanding the Architecture of Coding Agents: An Exploratory Study Using a Research Prototype
  7. 2026Beyond the 'Diff': Addressing Agentic Entropy in Agentic Software Development
  8. 2026AI-Generated Smells: An Analysis of Code and Architecture in LLM and Agent-Driven Development