# Make Code as Policy Great Again: Frontier Agents Write, Call, and Evolve Robot Tools

Robotics.world

> Frontier models can already drive robots by choosing an end-effector pose and gripper command from a camera image, but doing this for every reach, grasp, and retreat makes manipulation slow and…

**arXiv**: 2609.39018 · Preprint · not peer-reviewed

**Published**: 2026-09-30

**Authors**: Shijia Ge, Alex Zhou, Jianshu Zeng, Yexing Wan, Di Wu, Zelin Zheng, Yazhe Wang, Zhiqi Jia, Xuan Shangguan, Jay Zhu, Yijun Liu, Lingyu He, Sihang Wu, Xiao He, Hongcheng Gao

## In plain words

Frontier models can already drive robots by choosing an end-effector pose and gripper command from a camera image, but doing this for every reach, grasp, and retreat makes manipulation slow and token-hungry.

## AI summary

## Overview

**Research area:** Robot learning and embodied AI — specifically, LLM/VLM agents as robot controllers (code-as-policy, tool use, agentic manipulation).

**Technical level:** Intermediate. Readers should know roughly how robot manipulation stacks work (end-effector poses, inverse kinematics, gripper commands) and what an LLM agent loop looks like, but no specialized math is required.

**Scope:** The paper proposes URAI, an interface and division-of-labor scheme in which a coding agent writes validated, timed robot tools and a frozen frontier model selects and parameterizes one complete tool per decision, evaluated on five RoboDojo simulation tasks with four execution agents and seven real dual-arm tasks.

## What This Paper Is About

Frontier models can already drive robots by choosing an end-effector pose and gripper command from a camera image, but doing this for every reach, grasp, and retreat makes manipulation slow and token-hungry. The paper asks whether the policy can instead be *code* — a library of executable, reusable robot tools that a coding agent writes and revises — so that the model only decides *which complete motion to run next*, rather than every step of it. The goal is to cut end-to-end time and output tokens while keeping (or improving) task success.

## Key Contributions

1. **A code-as-policy architecture with frontier agents in every role.** A programming agent writes reusable and task-specific robot tools from natural-language intent plus execution feedback; each tool call expands into a timed end-effector path (metric path, orientation, speed profile, ordered gripper events, execution constraints) that a shared backend grounds, validates, and runs locally.
2. **URAI, a universal robot–agent interface.** One tool contract is exposed through both a GUI and a structured API over the same backend, so a human and a frozen execution agent operate identical tools. Humans can also steer the programming agent in natural language.
3. **A distinct handoff boundary, evaluated directly.** The execution agent decides again after every complete tool execution, and tool revisions persist across episodes without updating foundation-model weights. The paper contrasts this against (a) direct fingertip control and (b) a single program written in advance over the *same* tools that then runs without the model.
4. **Simulation and real-robot evidence.** Five RoboDojo tasks with four frozen execution agents, plus seven real-world AgileX PiPER-X dual-arm tasks spanning object manipulation, cloth folding, and human-interactive tic-tac-toe, including comparisons to published runs on other hardware.

## Main Findings

- **Aggregate success improves substantially over direct control.** Across five RoboDojo tasks and four frozen execution agents, URAI raises aggregate success from 18.0% to 53.0% relative to direct fingertip control. Per agent: Claude Fable 5.1 52% vs 16%, Claude Opus 5.5 60% vs 32%, GPT-6 Astra 52% vs 16%, DeepSeek-V4-Flash 48% vs 8%.
- **The largest single gap is Swap Blocks.** URAI solved it in 19 of 20 episodes versus none of 20 native episodes. Excluding it, URAI still leads for every agent, 42.5% against 22.5% (21 against 5 discordant pairs, p = 0.0025), and the pooled gain remains significant (McNemar p = 7.9 × 10⁻⁸).
- **Deciding between calls matters, not just the tool library.** With the same tools, a program written in advance reaches 24% against 56% for two agents deciding after each call (12 of 50 episodes vs 28 of 50; 17 against 1 discordant pairs, p = 1.4 × 10⁻⁴), and 11 against 19 of 40 without swap blocks (8 against 0, p = 0.0078).
- **Three of four agents get faster and cheaper.** They finish episodes 1.3–1.5× faster with 1.5–1.7× fewer execution-agent output tokens; DeepSeek-V4-Flash saves only about 5% of its time and 9% of its tokens. Time outside robot and observation/probe commands falls by about 45%, 38%, and 32% for Claude Fable 5.1, Claude Opus 5.5, and GPT-6 Astra, but *rises* for DeepSeek-V4-Flash (441 s to 509 s) even as its motion calls drop from 25.6 to 10.0 — coarser calls do not guarantee lower total cost.
- **Motion calls become fewer and longer.** URAI episodes use 3.5–10.0 calls per episode lasting 29–72 s each, versus 21.0–25.6 calls of 19–20 s under native control.
- **Competitive with learned policies without robot training data.** Claude Opus 5.5 through URAI reaches a 60.0% five-task mean over 25 episodes, close to the best learned policy on the public leaderboard (58.1% under its own protocol). GPT-6 Astra averages 34.4% through the RoboProbe harness versus 52.0% through URAI.
- **Real-robot speedups against published references.** Tic-tac-toe: 3/3 wins, 5.0 minutes, 37.0 calls, 3.26k tokens, versus GPT-Policy's 13.6 minutes and 69.7 decisions with the same model (2.7× faster at the same 3/3 success). Unscrew bottle cap: 5.1 minutes and 24.7 calls versus 17.9 minutes and 54.7 decisions (3.5× faster, 3/3). Block into bowl: 61.3 s, 6.3 calls, 443 tokens versus Robocurve's 2.5 minutes, at most 20 calls, and 2.1k tokens at 19/20 success (2.4× faster, 4.7× fewer tokens).
- **Tasks with no published reference.** Over ten trials each: hot-dog serving 10/10 (100%), pour blocks 10/10 (100%), toss blocks into bowl 7/10 (91.7%), fold clothes 8/10 (90.0% mean progress).
- **Tool evolution works but is agent-sensitive.** For fold clothes, the existing two-point pick-and-place tool was revised seven times (eight versions) under natural-language author steering — adding sheet pinching with local thickness checks, synchronized dual-arm transport, outward wrist tilt, vertical release, and depth-derived drop height and clearance. The frozen final version then succeeded in 3 of 20 episodes on seeds 0–4 and 2 of 20 on seeds 5–9, versus 4 of 5 for a human choosing pixels through the GUI. Most agent failures came from pinching at the sleeve tip, where the fingers close on nothing.
- **Humans and agents share the interface.** A human operator driving the same tools through the GUI succeeded in 23 of 25 simulated episodes.

## Methodology in Plain English

The authors split robot control into two jobs. Offline, a **programming agent** (Claude Fable 5.1 in Claude Code, with Claude Opus 5.5 writing a task-specific pouring tool) is given a task description and the current toolset. It writes or edits tools as code — either general ones like pick-and-place, PushButton, or Home, or task-specific procedures. Every candidate version is run and must pass validation before being accepted; accepted versions are versioned, shipped with unit tests, and frozen before evaluation. Weights of the foundation models never change.

Each tool call describes a whole motion: a metric path, a desired end-effector orientation, a speed profile, an ordered list of gripper events, and execution constraints such as pose tolerances. A shared backend back-projects clicked points from calibrated depth, checks the full trajectory from the current pose against kinematic and geometric limits, and streams references locally at a nominal 50 Hz on the AgileX backend. Progress along the path is a path parameter, not wall-clock time, so gripper events can be tied to motion progress.

Online, a **frozen execution agent** receives the instruction, camera and depth observations, robot state, and execution feedback. It picks one tool and fills in its arguments, and the motion runs to completion or interruption before control returns to the model. A GUI exposes the same tools with continuous drawing, arm selection, orientation handles, and a speed-profile editor, so a human can operate them identically; the API exposes the same control points and profiles through a bounded arithmetic interpreter.

Evaluation used RoboDojo with five tasks (Pour Liquid Into Cup, Pour Balls Into Vase, Fold Clothes, Swap Blocks, Stack Blocks), one episode per seed 0–4, thirteen reusable tools frozen before evaluation, and per-task simulator-step budgets of 400, 600, 500, 700, and 550 with a 100-command limit. Each episode started a fresh agent session in a clean working directory; only RoboDojo's official terminal state counted. Wall-clock limits were 45 minutes for URAI and 60 for native control. The real-robot platform was an AgileX PiPER-X dual-arm system with four RealSense RGB-D cameras, run at 1× speed with three trials per referenced task.

## Why This Matters

**Impact on research.** The paper isolates a specific design variable that prior code-as-policy and agentic-manipulation work left tangled: *where the model hands off to code*. By holding the tool library fixed and comparing "model decides after every call" against "a program written in advance over the same tools," it shows that keeping the model in the loop between complete motions — not the tools alone — accounts for a measurable part of the gain. It also reframes efficiency as reducing the *number* of decisions per episode rather than the cost of each decision, and it reports wall-clock and token decompositions, which is rarer than success-rate reporting in this literature.

**Real-world applications.**

- Tabletop pick-and-place, packing, and kitting in warehouses, where multi-phase motions like approach–grasp–transfer–place–retreat can be one validated call.
- Cloth and deformable-object handling (folding, laundry), where the paper's case study shows a rigid-object tool being extended rather than replaced.
- Human-interactive tasks such as game playing or turn-taking assembly alongside a person, given the shared GUI/API contract.
- Rapid deployment of new lab or factory cells: the paper argues a new task called for writing or revising tools rather than collecting demonstrations and retraining.

**Industry relevance.** The approach requires no robot training data and no weight updates — tools, not models, are the artifact that improves. That makes it attractive for teams that want to swap in whichever frontier model is current, keep a persistent, auditable, unit-tested library of robot skills, and let human operators and agents share one control surface.

## Future Directions

- **Meter the cost of authoring.** Tool programming and author steering consumed unmetered time and tokens that may offset execution-phase savings; the authors state they will meter tool-authoring cost alongside execution cost.
- **Establish causal speedup estimates on real hardware.** The real-robot comparisons are against published runs on other hardware with no same-robot step-by-step baseline, so the reported ratios are not causal estimates.
- **Broaden portability.** The interface is validated on one simulator and one position-controlled dual-arm platform without force regulation, so generality across embodiments is unestablished.
- **Scale tasks and episodes, and add missing controls.** Five episodes per cell cannot establish per-task differences; the program control covers only two agents on seeds 0–4; and no prompt- or memory-only revision control was run. The stated plan is to extend the tool collection to more tasks and platforms.

## Target Audience

Robotics researchers working on LLM/VLM-based manipulation and code-as-policy; engineers building agentic robot stacks who care about latency and token cost as much as success rate; and practitioners who want a persistent, human-shared skill library rather than retrained policies. It is also useful for evaluation-minded readers, since it models how to report time and token decompositions honestly alongside success, including its own limitations.

## Authors’ abstract

Frontier models can control robots, but reasoning through every reach, grasp, and retreat makes manipulation slow and token-intensive. We revisit code as policy with a different division of labor: models build executable tools, code handles multi-phase motions, and models decide what to do next. We introduce URAI (Universal Robot-Agent Interface), which couples a programming agent that constructs robot tools with an execution agent that uses them in a feedback loop. The…

[The full abstract on arXiv](https://arxiv.org/abs/2609.39018)

[Read the original paper](https://arxiv.org/abs/2609.39018)

## Related papers

- [HexaShell: A Thin Harness for Exploring the Limits of VLM Agents as Robot Coding Agents](https://robotics.world/paper/hexashell-a-thin-harness-for-exploring-the-limits-of-vlm-agents-as-2610.23479) 2026-10-16 · cs.RO · Also by Alex Zhou, Di Wu +9
- [EmbodiedLab: Benchmarking Embodied Agents That Act to Know](https://robotics.world/paper/embodiedlab-benchmarking-embodied-agents-that-act-to-know-2610.35385) 2026-10-26 · cs.RO · Also by Alex Zhou, Di Wu +9
- [RACaP: Agentic Reasoning, Acting, and Coding as Policies for Evolvable Robot Learning](https://robotics.world/paper/racap-agentic-reasoning-acting-and-coding-as-policies-for-evolvable-2609.29394) 2026-09-24 · cs.RO · Key terms of the title in common
- [When the Simulator Fails, Not the Policy: Auditing Contact Artifacts in Simulated Robot Benchmarks](https://robotics.world/paper/when-the-simulator-fails-not-the-policy-auditing-contact-artifacts-in-2610.41857) 2026-10-30 · cs.RO · Also by Alex Zhou
- [Ego Guidance: Enhancing Robot Policy Learning with Action-Free Human Egocentric Videos](https://robotics.world/paper/ego-guidance-enhancing-robot-policy-learning-with-action-free-human-2611.13685) 2026-11-10 · cs.RO · Also by Di Wu

---

Canonical: https://robotics.world/paper/make-code-as-policy-great-again-frontier-agents-write-call-and-evolve-2609.39018
