AI Coding Agents Write Python Code To Teach Multi-Fingered Robot Hands Complex Bimanual Skills Without Human Demonstrations
Technology

AI Coding Agents Write Python Code To Teach Multi-Fingered Robot Hands Complex Bimanual Skills Without Human Demonstrations

A new framework bypasses teleoperation by letting parallel agents write and refine robot control programs, setting performance records on standard dexterity benchmarks.

By James Whitmore
Published:
Email this Article
AI Coding Agents Write Python Code To Teach Multi-Fingered Robot Hands Complex Bimanual Skills Without Human Demonstrations
Photo by Aideal Hwa on Unsplash

Autonomous robot hands can now learn complex bimanual tasks entirely through code-generating artificial intelligence agents operating in virtual environments, without needing costly human demonstrations or real-world trial and error. A research team at Peking University, the National University of Singapore, NVIDIA, Tongji University, and the University of Chicago developed a new framework called PyRUA-Dex, which allows software agents to independently write, test, and refine Python programs to control multi-fingered robotic hands. Tested across virtual benchmarks and physical hardware, the system achieves a record score of 72.9 on Bench2Dex, outperforming traditional neural network policies trained on thousands of teleoperated human episodes. The details of the framework are available on the arXiv preprint server.

How Do Parallel Coding Agents Solve Multi-Stage Robotic Tasks?

Teaching robots with human-like dexterity has long been bottlenecked by data collection limitations. Human video retargeting is often imprecise, teleoperation strips away vital force feedback, and mechanical exoskeletons are difficult to scale. PyRUA-Dex bypasses these hurdles by framing dexterous control as a software engineering problem rather than a pattern recognition task. During the initial exploration phase, eight parallel artificial intelligence agents write and test code on separate virtual layouts of a given task. Each agent uses state resets, letting it rewind the simulator up to eight times per layout to master individual steps without repeating earlier actions.

Once individual sub-skills are discovered, a distilling agent aggregates the successful attempts into a unified task library and a baseline program. In the second refinement phase, a single agent analyzes bottlenecks by running the program across hundreds of randomized layouts. By measuring failure rates at every consecutive stage of an action sequence, the agent iteratively repairs the least reliable parts of the code. The resulting policy functions as pure, frozen Python code that executes at the robot’s native control rate without calling any language models during operation.

Figure 1: PyRUA-Dex at a glance. Center: our real-world platform playing the piano (a video frame, cut out), with tactile sensing at the fingertips. (a) Coding agents learn a task’s program in simulation in two stages, exploration and refinement; the frozen program is deployed in the real world (sim-to-real), and real-world feedback updates the simulation (real-to-sim; Section 3). (b) DexJoCo success rate with the objects randomized (rand-obj) and with cameras, lighting and textures randomized as well (rand-full; Section 4.5). (c) Tasks learned for the real-world platform: validation layouts completed in simulation, of 32 (Section 5). (d) The nine best of the thirteen four-channel entries on the Bench2Dex leaderboard, where PyRUA-Dex holds the SOTA (Section 4.2). (e) The hands the programs drive, rendered from their models, with the joints driven per hand (DoF) and whether a program receives tactile sensing. (f) The tasks of the three settings in five classes, with the number of tasks per settin
PyRUA-Dex at a glance. Center: our real-world platform playing the piano (a video frame, cut out), with tactile sensing at the fingertips. (a) Coding agents learn a task’s program in simulation in two stages, exploration and refinement; the frozen program is deployed in the real world (sim-to-real), and real-world feedback updates the simulation (real-to-sim; Section 3). (b) DexJoCo success rate with the objects randomized (rand-obj) and with cameras, lighting and textures randomized as well (rand-full; Section 4.5). (c) Tasks learned for the real-world platform: validation layouts completed in simulation, of 32 (Section 5). (d) The nine best of the thirteen four-channel entries on the Bench2Dex leaderboard, where PyRUA-Dex holds the SOTA (Section 4.2). (e) The hands the programs drive, rendered from their models, with the joints driven per hand (DoF) and whether a program receives tactile sensing. (f) The tasks of the three settings in five classes, with the number of tasks per settin Credit: Feixiang Ruan et al. / arXiv

Why Is Programmatic Control More Robust Than Imitation Learning?

Traditional neural network policies often fail when object positions or camera lighting shift slightly from training conditions. In contrast, PyRUA-Dex programs actively measure the physical scene in every single episode using calibrated cameras, joint positions, and fingertip tactile maps. On the Bench2Dex benchmark, which evaluates bimanual tasks across twelve different robot hands with between six and twenty-two driven joints, PyRUA-Dex achieved a success rate of 60.6 percent and a stage completion rate of 82.3 percent. Furthermore, its performance dropped by only 4.1 percent when tested against severe environment perturbations, whereas conventional imitation learning models suffered steep declines.

The system excels particularly in tasks requiring strict mechanical precision and sequential ordering. On bimanual piano playing, sorting objects by category, and preparing baking trays, the programmatic approach significantly outperformed human-demonstration baselines. However, the authors note current limitations, observing that the coding agents struggle with tasks requiring continuous force and slip control, such as manipulating a frying pan or assembling a jigsaw puzzle, because simulated tactile sensors currently render contact coarsely.

Figure 2: Overview of PyRUA-Dex. All learning takes place in simulation. Stage 1 (exploration): eight agents (one is drawn) explore the task, each on a training layout of its own with state resets, and share a memory; their programs are evaluated without the agents and distilled into a task library and one program. Stage 2 (refinement): one agent finds the program’s bottleneck stage by a stage-wise failure analysis, refines it on randomized layouts and selects the version with the best held-out record. The resulting program runs frozen, without a language model. For the real world, the simulation is built from the real scene (real-to-sim), the frozen program is transferred (sim-to-real), and real-world feedback updates the simulation for the next round of refinement.
Overview of PyRUA-Dex. All learning takes place in simulation. Stage 1 (exploration): eight agents (one is drawn) explore the task, each on a training layout of its own with state resets, and share a memory; their programs are evaluated without the agents and distilled into a task library and one program. Stage 2 (refinement): one agent finds the program’s bottleneck stage by a stage-wise failure analysis, refines it on randomized layouts and selects the version with the best held-out record. The resulting program runs frozen, without a language model. For the real world, the simulation is built from the real scene (real-to-sim), the frozen program is transferred (sim-to-real), and real-world feedback updates the simulation for the next round of refinement. Credit: Feixiang Ruan et al. / arXiv

Can Virtual Programs Transfer Directly to Physical Robots?

To demonstrate real-world viability, the researchers deployed the framework on a bimanual platform equipped with two Franka FR3 arms and two Sharpa Wave SE hands featuring 22 joints each. Using a calibrated MuJoCo physics simulation built from precise hardware measurements, the team performed rigorous system identification on the hands, aligning simulated joint tracking errors down to about one-tenth of a degree. Exploration occurred entirely in simulation, while refinement alternated with the physical robot, feeding real-world discrepancies back into the virtual environment.

Physical experiments revealed that the frozen programs successfully directed the dual-armed robot to pick and place cubes, stack three-cube towers, open a box by its fabric loop, write the word “Dex” with a paintbrush, and play multi-phrase melodies on an electronic keyboard. Notably, learning a brand new musical piece from sheet music took the system between 30 and 60 minutes of iteration. The researchers suggest that future developments will focus on integrating learned continuous-force controllers and enabling automated skill transfer across related task families.

The study was posted to the arXiv preprint server on November 24, 2026.

Fact Checked

This article has been fact checked for accuracy, with information verified against reputable sources. Learn more about us and our editorial process.

Last reviewed on .

Article history

  • Latest version

Reference(s)

  1. Ruan, Feixiang. “PyRUA-Dex: Learning Programmatic Policies for Dexterous Bimanual Manipulation with Coding Agents.” arXiv.org <http://arxiv.org/abs/2611.33144v1>.

Cite this page:

Whitmore, James. “AI Coding Agents Write Python Code To Teach Multi-Fingered Robot Hands Complex Bimanual Skills Without Human Demonstrations.” BioScience. BioScience ISSN 2521-5760, 25 November 2026. <https://www.bioscience.com.pk/en/subject/technology/pyrua-dex-learning-programmatic-policies-for-dexterous-bimanual-manipulation-with-coding-agents>. Whitmore, J. (2026, November 25). “AI Coding Agents Write Python Code To Teach Multi-Fingered Robot Hands Complex Bimanual Skills Without Human Demonstrations.” BioScience. ISSN 2521-5760. Retrieved November 25, 2026 from https://www.bioscience.com.pk/en/subject/technology/pyrua-dex-learning-programmatic-policies-for-dexterous-bimanual-manipulation-with-coding-agents Whitmore, James. “AI Coding Agents Write Python Code To Teach Multi-Fingered Robot Hands Complex Bimanual Skills Without Human Demonstrations.” BioScience. ISSN 2521-5760. https://www.bioscience.com.pk/en/subject/technology/pyrua-dex-learning-programmatic-policies-for-dexterous-bimanual-manipulation-with-coding-agents (accessed November 25, 2026).
End of the article