Skip to content

feat(session): capture API planner trajectories - #312

Open
Hiforever-h wants to merge 33 commits into
RLinf:mainfrom
Hiforever-h:feat/env-state-records
Open

Hiforever-h wants to merge 33 commits into
RLinf:mainfrom
Hiforever-h:feat/env-state-records

Conversation

@Hiforever-h

@Hiforever-h Hiforever-h commented Oct 21, 2026 •

Copy link
Copy Markdown
Collaborator

Description

Add opt-in trajectory recording for API planner tasks through --record-trajectory in the CLI and Dashboard, and export executed VLA actions as LeRobot training data.

  • Record model requests and responses, tool calls, original results, and planner feedback, including partial responses and cancellation outcomes.
  • Capture executed actions and observations for LIBERO, RoboCasa365, RoboTwin, and RoboDojo, linking VLA actions to their instructions.
  • Save task, planner, action, and prediction records under trajectories/<task-id>/, with referenced attachments. Preserve existing tool steps and artifacts.
  • Replace the previous LIBERO collection and export commands. Export continuous VLA segments from successful tasks, and update the English and Chinese guides.

The optional flywheel dependencies now pin pyarrow<26 for compatibility with OpenPI's NumPy 1.x environment.

Validation

  • Unit tests on Python 3.11: 1849 passed, 7 skipped.
  • Ruff lint and formatting checks, and git diff --check: passed.
  • English and Chinese documentation builds: passed.
  • Actual simulator runs, trajectory recording, and dataset export have been verified on a machine with a single NVIDIA RTX 4090 GPU.

Checklist

  • My code follows the code style of this project.
  • I have updated related documentation when needed.
  • I have added tests to cover my changes when needed.
  • All new and existing tests passed.

Share environment action capture and VLA prediction grouping across LIBERO, RoboCasa, RoboDojo and RoboTwin. Remove the legacy Flywheel implementation and exports.

Restore docs/ to local main at 58844d5.
Preserve docs/ at the requested local main revision 58844d5 while retaining the remote planner check and dependency fixes.
Refresh camera frames only around captured RoboDojo actions, preserving ordinary observation reads.

Consolidate simulator capture tests with adapter contracts and share loopback fixtures across robot and core tests.

Validation: 184 tests passed across the seven changed test modules; git diff --check passed.
Comment thread .agents/skills/verify-change/SKILL.md Resolved
Comment thread .github/workflows/unittest.yml Resolved
Comment thread rpent/cli/task_capture.py Resolved
Move trajectory selection and export into rpent.flywheel with a dedicated
CLI and optional extra. Export per-step LIBERO, RoboCasa, RoboDojo, and
RoboTwin training data, preserving short segments and robot-native fields.

Move API task capture into the session layer and let toolkit callbacks
convert native environment results into trajectory recording payloads.
Group dual-Franka regressions with the env, toolkit, and runtime contracts.
Centralize tool-result conversion and schema tests, remove duplicate cases,
and reuse RPC fixtures with explicit server-thread cleanup.
@Hiforever-h
Hiforever-h marked this pull request as ready for review October 29, 2026 07:45
Replace four robot-specific Flywheel modules with RobotSpec declarations
and shared conversion, success selection, and metadata export.

Require trajectory schema v5 and use observation.state/action columns
for every robot, removing the historical schema compatibility paths.

Validation: 1887 unit tests passed, 7 skipped; pre-commit passed.
Verified a schema-v5 RoboTwin trajectory: 134 frames and 402 images
match the recorded source after export and reload.
Merge segment selection and image validation into flywheel.py and update the corresponding imports and tests without changing behavior.

Validation: 1889 unit tests passed, 7 skipped; pre-commit passed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants