Why We Recommend Referencing ReKep
Clear Boundaries
The main repository only concerns itself with the Driver interface; within the plugin, any SDK may be used freely.
Complete Structure
Manifest, Driver, runtime, deployment scripts, and tests β all included.
Directly Portable
Swap out ReKep's name, action mappings, and runtime implementation, and you've got your new plugin.
Minimal Plugin Structure
There is no need to implement all features at once. It is recommended to first build the basic skeleton, ensure Watchdog can load it properly, then gradually add complex capabilities.
βββ PhyAgentOS_plugin.toml β Manifest: tells the main repo who you are
βββ README.md / README_zh.md
βββ pyproject.toml
βββ my_plugin/
β βββ __init__.py
β βββ driver.py β BaseDriver implementation
β βββ profiles/
β βββ my_robot.md β Capability profile
βββ runtime/
β βββ your_runtime_entry.py β Real robot bridge, heavy logic
βββ tests/
βββ test_my_driver.py
| Path | Purpose |
|---|---|
PhyAgentOS_plugin.toml | Declares driver name, entry class, and profile location |
my_plugin/driver.py | The BaseDriver subclass that Watchdog actually loads |
my_plugin/profiles/*.md | Copied as EMBODIED.md at runtime |
runtime/ | Third-party SDKs, bridge scripts, long-running processes |
tests/ | Plugin-level smoke tests |
How to Write the Manifest
[plugin]
name = "my_robot"
version = "0.1.0"
description = "My robot plugin for PhyAgentOS"
[driver]
name = "my_robot"
module = "my_plugin.driver"
class = "MyRobotDriver"
profile_path = "my_plugin/profiles/my_robot.md"
[python]
sys_paths = ["."]
[[requirements]]
path = "runtime/requirements.txt"
optional = false
driver.name determines what name Watchdog uses with --driver to find you; driver.module + driver.class determines which Python class the main repo actually imports.
Driver and Runtime Responsibility Separation
Driver Layer
Responsible for implementing the BaseDriver interface: receiving actions, converting parameters, returning results, and exposing profiles. This layer should be kept as thin as possible.
Runtime Layer
Responsible for preflight checks, dry-runs, real robot execution, and long-running tasks. Heavy dependencies and complex bridging logic should be placed here, not in the Driver layer.
The direct advantage of this separation: when issues arise, you can quickly determine whether the fault lies in "main repo protocol adaptation" or "real robot execution".
Local Development Setup
The recommended local development approach: place the plugin repository alongside the main repository, and install it via local path.
git clone https://github.com/SYSU-HCP-EAI/PhyAgentOS.git
git clone https://github.com/baiyu858/PhyAgentOS-rekep-real-plugin.git
cd PhyAgentOS
pip install -e .
python scripts/deploy_rekep_real_plugin.py \
--repo-url ../PhyAgentOS-rekep-real-plugin
This way you can edit plugin code while running the full pipeline through the main repo's Watchdog and Agent for end-to-end verification.
Verification Order: Preflight β Dry-Run β Full Pipeline
# 1. Preflight β verify runtime environment is healthy
python runtime/dobot_bridge.py preflight --pretty
# 2. Dry-run β don't touch the real robot, verify action parsing
python runtime/dobot_bridge.py execute \
--instruction "pick up the red block and place it on the tray" \
--pretty
# 3. Real robot execution
python runtime/dobot_bridge.py execute \
--instruction "pick up the red block and place it on the tray" \
--execute_motion \
--pretty
# 4. Full closed loop with Watchdog + Agent
paos onboard
python hal/hal_watchdog.py --driver rekep_real --workspace ~/.PhyAgentOS/workspace
paos agent
ReKep Supports Two Action Protocols
Plugin Native Actions
real_preflight, real_execute, real_execute_background, real_scene_qa, real_longrun_start
Directly mapped to runtime subcommands β ideal for invoking plugin-specific capabilities.
Generic High-Level Actions
move_to, pick_up, put_down, push, point_to, open_gripper, close_gripper
Converted to natural language instructions and routed to the unified execution entry point.
When designing a new plugin, we recommend keeping both layers: one for the main repo's generic protocol, and one for the plugin's internal specialized interface.
Recommended Community Development Flow
Make the plugin discoverable first
Get Watchdog to load it successfully
Ensure EMBODIED.md installs correctly
Avoid stuffing all logic into the driver
Narrow down failure scope early
Run full end-to-end integration testing