arXiv(opens in a new tab)cs.ROSep 2026Cited by 6 papers on PaperVantage

Manuscript Offprint

arXiv:2609.35432

Self-Evolving Coding Agents: From Digital Programs to Physical-World Intelligence

Hongcheng Gao, Jingjing Zhou, Zelin Zheng, Shijia Ge, Jay Zhu, Yazhe Wang, Jianshu Zeng, Xuan Shangguan, Di Wu, Lingyu He, Zhiqi Jia, Sihang Wu, Xiao He

Abstract

Vision-language-action (VLA) and world-action (WAM) models map observations and instructions directly to robot actions. This directness ties a policy to training: minor layout or viewpoint changes cause failure, and instructions generalize poorly. The root cause lies in representation: task requirements, conditions, progress, and failure recovery are implicitly encoded in action sequences, making them difficult to inspect or revise. Digital coding agents offer a precedent: LLMs call tools, verify results, and revise from feedback as executable code. The same working pattern of explicit state, manageable execution, and revisable procedures underlies generalization and long-horizon execution in the physical world, letting physical experience return as reusable programs, memory, or evidence. We propose Physical Coding, representing task state and execution as code. Code as World records objects, relations, constraints, and progress; Code as Policy organizes planning, verification, recovery, and execution. We build HexaAnything, which calls perception, planning, and control tools, including VLA/WAM policies, and makes in-the-loop decisions from external feedback. Verified traces become data and memory, enabling evolution from tools and Harness to model weights, architectures, and ultimately hardware and task design. On RoboCasa365, HexaAnything improves Composite-Unseen and overall success over XR-1 VLA, and its Harness-trained HexaModel beats the base on every split, indicating code traces internalize physical execution. On PhyBench and a dual-arm AgileX robot, the agent autonomously completes physics experiments and most tabletop tasks, often faster than published results. We observe data, model, and tool self-evolution; future work targets weight internalization, autonomous redesign of architectures, languages, representations, and tasks, and deployment in manufacturing and science.

1 Introduction

Vision–language–action (VLA) and world–action (WAM) systems connect foundation models to physical interaction [7, 8, 24, 40, 42, 106]. They map visual observations and language instructions to robot actions, providing a compact interface between perception and control. How much of this mapping depends on the instruction is less clear. A QwenGR00T policy trained on LIBERO with the instruction masked succeeds in 92.3% of trials, against 96.2% for its instruction-conditioned counterpart (Section 2.1): when the scene determines the task, the policy maps scenes to trajectories. Released VLAs are similarly insensitive to the instruction, and they lose more than half of their success under small changes in viewpoint or initial robot state and approach zero when object layout is perturbed [20, 44, 104]; increasing data or model capacity does not reliably remove this failure mode [43]. The limitation is structural rather than purely a matter of action capacity: a long-horizon task requires the system to track objects, constraints, unfinished subgoals, state changes, completion conditions, and recovery decisions, and none of these is represented in an action chunk and a stop signal. Closed-loop systems feed observations back to a planner [32, 98], and structured embodied

Figure

Figure

Figure 1. Physical Coding brings AI into the physical world through an explicit executable interface. Code as World represents task-relevant objects, relations, observations, constraints, and progress predicates, while Code as Policy organizes planning, tool calls, action execution, verification, and recovery. Together they form the core interface through which the agent interacts with physical environments and accumulates reusable artifacts for continual improvement.

agents maintain state records or spatial constraints [33, 34, 66, 99]; yet these representations, tool semantics, and recovery rules are usually designed outside the learning loop, so feedback may improve one episode without becoming a reusable, independently verifiable artifact.

This diagnosis shifts the problem from “can the model predict a better action?” to “does the system maintain a representation that can be inspected and revised throughout execution?” The missing capability is therefore not another action primitive, but an interface that exposes task state, execution, and feedback as objects that can be checked and changed. Digital coding agents provide a useful precedent: large language models use code to represent procedures, call external tools, inspect intermediate results, and revise programs from feedback [12, 85, 95]. Code is compositional, executable, verifiable, versionable, and revisable, making it a natural interface between representation, execution, and feedback. Physical execution makes this interface more demanding because actions may be delayed, partially observed, noisy, or irreversible. A physical coding agent therefore needs a world representation that can be updated from images, depth, proprioception, and tool outcomes; a policy representation that can branch, loop, interrupt, and recover; and a verifier independent of the model’s completion claim. The system must retain the observation that motivated an action, the state condition that authorized it, the tool outcome, and the evidence used to accept or reject it. The Harness connects these components and turns provenance into targeted revisions and reusable execution records.

Based on this observation, we study Coding Agents for the Physical World and introduce Physical Coding: a formulation that represents both the relevant world state and the execution procedure as executable programs. Code as World describes objects, relations, observations, states, constraints, and progress predicates. Code as Policy organizes planning, tool calls, outcome verification, recovery, and action execution. Because these programs can be independently validated, edited, versioned, and rolled back, the experience produced by one physical execution need not disappear at the end of an episode: it can return to the system as a reusable program artifact, memory entry, or structured evidence for later updates. The system can therefore revise not only a policy checkpoint but also the world representation, the workflow, the tools and verifiers, the data used for learning, and eventually the model and the representation standards themselves (Section 4). Code as World exposes task-relevant state, constraints, and progress, while Code as Policy exposes the workflow connecting planning, action, verification, and recovery, as illustrated in Figure 1.

Figure

HexaFuture

This representation allows execution experience to produce persistent updates rather than only additional demonstrations. Successful executions can be validated and admitted as reusable Physical Coding records, memory entries, or learning signals for later system updates, while failed executions provide localized evidence for revising tools, workflows, predicates, and recovery procedures. These two feedback paths form the recursive model–Harness–environment loop described in Section 4: interaction generates evidence, evidence updates the digital system, and the updated model and Harness determine the next round of physical interaction.

The resulting program has four coupled evolution targets—the Harness, the model, data and environments, and the embodiment and compute substrate (Section 4)—connected by the typed execution trace, which determines what evidence is collected and where it can be reused. The program proceeds in three stages: Stage 1 bootstraps the coding–action–state–feedback loop; Stage 2 closes the data–model–Harness loop; and Stage 3 transfers it to constrained physical workflows with real sensors, users, engineers, and safety gates (Section 5.3).

To instantiate this program, we develop HexaAnything, a physical coding agent that integrates state observation, task planning, action tools, verification, recovery, and feedback collection. Its action tools range from general-purpose robot tools to learned VLA/WAM policies, while the Harness maintains task state, coordinates execution, verifies intermediate outcomes, and adapts subsequent actions. We evaluate it on long-horizon robotic manipulation, simulated scientific experiments, and a real dual-arm robot. The experiments cover the Harness, tool revision, and a first data-to-model update: on manipulation, they test explicit workflow, verification, and recovery while holding the underlying action model fixed, and then train a new model on the traces the Harness returns.

We provide preliminary evidence for physical self-evolution at the Harness, tool, and data-to-model levels. The experiments demonstrate controlled, partial improvements through verified execution traces, while full autonomous co-evolution of models, representations, environments, and embodiments remains future work.

Our contributions are summarized as follows:

  1. We formulate Coding Agents for the Physical World and introduce Physical Coding, an executable interface between physical state, action, evidence, and revision, instantiated through the coupled representations Code as World and Code as Policy that unify physical-world modeling and action execution.

  2. We develop HexaAnything, a physical coding agent that integrates language models, state observation, verifiers, and action tools into a unified physical execution loop.

  3. We provide evidence for Harness, data, model, and tool improvement on long-horizon manipulation, and show on the proposed PhyBench simulated laboratory benchmark that the same Harness autonomously completes scientific experiments, thereby motivating a staged path toward broader self-evolution.

References (100)