Code as Policies, a code generation tool
Google researchers present Code as Policies (CaP): a robot-centric formalization of programs generated by language models (LMPs) running on real systems. CaP uses a language model for writing code that allows it to generate code for new tasks from a few prompts. This approach relies on hierarchical code generation, which encourages language models to recursively define new functions, accumulate their own libraries over time, and self-design a dynamic code base. Code-writing language models can express a variety of language-based arithmetic operations and feedback loops. Pythonic LMPs can express complex policies using :- Classical logic structures, e.g., sequences, selection (if/if), and loops (for/while) to assemble new behaviors at runtime;
- Third-party libraries to interpolate points (NumPy), analyze and generate generate shapes (Shapely) for spatial-geometric reasoning...
The experiments allowed Google researchers to demonstrate that code output led to improved generalization and task performance compared to direct learning of robotic tasks and natural language action generation. CaP allows a single system to perform a variety of different robotic tasks without task-specific training but struggles to grasp complex or abstract prompts.
The researchers have published the code needed to reproduce their experiments and an interactive simulated robot demonstration on the project's Website, which also contains additional real-world demos with videos and generated code.
Article sources:
"Robots that write their own code"
Blog by Jacky Liang, research intern, and Andy Zeng, research scientist, robotics at Google, November 2, 2022
"Code as Policies: Language Model Programs for Embodied Control" arXiv:2209.07753v2 19 Sep 2022
Authors:
Jacky Liang, Wenlong Huang, Fei Xia, Peng Xu, Karol Hausman, Brian Ichter, Pete Florence, Andy Zeng of Google Robotics
Translated from Google Research présente Code as Policies (CaP), un nouvel outil de génération de code
Our articles will then appear first in Google Top Stories.
