i4h-workflow · diff

v0.6.0 to v0.8.0

66 added, 80 removed. Audit A to A.

---
name: i4h-workflow
- version: "0.6.0"
- description: Overview of `workflows/agentic/` (IsaacLab-Arena + GR00T/openpi). Use when the user asks what i4h workflow is, what's supported, or where to start.
+ description: Orient users to the i4h workflow runtime and route them to the correct stage skill. Use for architecture, support, or where-to-start questions; do not execute a known stage.
license: Apache-2.0
metadata:
author: "Isaac for Healthcare Team <isaac-for-healthcare-support@nvidia.com>"
+ version: "0.8.0"
tags:
- isaac-for-healthcare
- i4h
- - agentic-workflow
- robotics
- - overview
+ - onboarding
---
- # i4h Agentic Workflow
+ # i4h Workflows
## Purpose
- Orient on the agentic workflow before touching a specific stage: which envs/robots/policies are supported, how the `workflows/agentic/` subprojects fit together, and which per-stage skill to invoke next. This skill routes — it runs no pipeline stage itself.
+ Orient the user from live repository facts, then hand execution to the narrowest stage skill.
- ## Base Code
+ ## Instructions
- These steps drive the i4h-workflows base code (the `workflows/agentic/` tree). To reuse an existing checkout, set `I4H_WORKFLOWS` to its path (no clone happens). Otherwise this resolves the current repo, or clones to `~/i4h-workflows` — pick that default without prompting. Run every command below from the resolved root:
+ 1. Run the base-checkout resolver.
+ 2. Read live support and `DESIGN.md`.
+ 3. Use only current architecture facts in the answer.
+ 4. Use the narrowest stage skill for execution.
+ ## Resolve the checkout
+
```bash
- # Resolve the i4h-workflows base code (provides workflows/agentic/).
+ export I4H_WORKFLOWS_REPO_URL="${I4H_WORKFLOWS_REPO_URL:-https://github.com/isaac-for-healthcare/i4h-workflows}"
+ I4H_REPO_DIR_NAME="${I4H_WORKFLOWS_REPO_URL%/}"
+ I4H_REPO_DIR_NAME="${I4H_REPO_DIR_NAME##*/}"
+ I4H_REPO_DIR_NAME="${I4H_REPO_DIR_NAME##*:}"
+ I4H_REPO_DIR_NAME="${I4H_REPO_DIR_NAME%.git}"
+ [ -n "$I4H_REPO_DIR_NAME" ] || { echo "Cannot derive a checkout name from I4H_WORKFLOWS_REPO_URL" >&2; exit 2; }
ROOT="${I4H_WORKFLOWS:-$(git rev-parse --show-toplevel 2>/dev/null)}"
- if [ ! -d "$ROOT/workflows/agentic" ]; then
- ROOT="${I4H_WORKFLOWS:-$HOME/i4h-workflows}"
- [ -d "$ROOT/workflows/agentic" ] || git clone https://github.com/isaac-for-healthcare/i4h-workflows "$ROOT"
+ if [ ! -d "$ROOT/workflows/i4h_workflows" ]; then
+ ROOT="${I4H_WORKFLOWS:-$HOME/$I4H_REPO_DIR_NAME}"
+ [ -d "$ROOT/workflows/i4h_workflows" ] || git clone "$I4H_WORKFLOWS_REPO_URL" "$ROOT"
fi
- export I4H_WORKFLOWS="$ROOT"; cd "$ROOT"
+ export I4H_WORKFLOWS="$ROOT"
+ cd "$ROOT"
```
- ## Basics
-
- - Env YAMLs at `workflows/agentic/config/environments/<env>.yaml` are the source of truth.
- - Each pipeline stage has its own skill. Compose them or use [[i4h-workflow-e2e]] for full runs.
- - For env authoring or scene-edit source changes, load `skills/i4h-workflow/references/repo-map.md` before generating code.
+ Treat this resolver as part of the skill contract: a hosted copy may run outside the base repository, so never assume the current checkout contains `workflows/i4h_workflows`. `I4H_WORKFLOWS_REPO_URL` selects the clone source. When `I4H_WORKFLOWS` is unset, derive the fallback directory from that URL; set `I4H_WORKFLOWS` only to reuse or choose a specific destination. Never replace an existing checkout.
- ## Supported Envs
+ ## Inspect before answering
- Fallback when `--list-envs` fails (setup incomplete):
+ Read `./DESIGN.md` for architecture and `skills/i4h-workflow/references/repo-map.md` for ownership. Discover current support instead of copying a static table:
- | Env | Robot | Policy |
- |---|---|---|
- | `scissor_pick_and_place` | SO-ARM 101 | GR00T N1.5 (N1.7 alternative) |
- | `locomanip_tray_pick_and_place` | Unitree G1 | GR00T N1.6 (shared `policy.locomanip.*`) |
- | `locomanip_push_cart` | Unitree G1 | GR00T N1.6 (shared `policy.locomanip.*`) |
- | `assemble_trocar` | Unitree G1 + Dex hands | GR00T N1.5 (inference-only) |
- | `ultrasound_liver_scan` | Franka-style arm | openpi PI0 |
- | `surgical_reach_psm` | dVRK PSM | GR00T N1.5 or scripted state machine |
- | `surgical_reach_dual_psm` | dVRK dual PSM | GR00T N1.5 or scripted state machine |
- | `surgical_reach_star` | STAR | GR00T N1.5 or scripted state machine |
- | `surgical_lift_block` | dVRK PSM | GR00T N1.5 or scripted state machine |
- | `surgical_lift_needle` | dVRK PSM | GR00T N1.5 or scripted state machine |
- | `surgical_lift_needle_organs` | dVRK PSM | GR00T N1.5 or scripted state machine |
+ ```bash
+ ./run.sh list
+ ```
- ## Run
+ If discovery fails because setup is incomplete, report that limitation and route to `i4h-workflow-setup`.
- Run the step below before answering. Each step is a separate bash call; variables persist in the local agent's tmux session.
+ ## Explain the design
- ### Step 1 — list supported envs
+ Keep the summary precise:
- ```bash
- REPO_ROOT="${I4H_WORKFLOWS:-$(git rev-parse --show-toplevel 2>/dev/null)}"; [ -d "$REPO_ROOT/workflows/agentic" ] || REPO_ROOT="$HOME/i4h-workflows"
- "${REPO_ROOT}/workflows/agentic/policy/run.sh" --list-envs
- ```
+ - A Scene owns the simulated world, assets, embodiment, cameras, randomization, adapters, and reset hooks.
+ - A Task owns one reusable capability. It reads `ctx.scene`, writes `ctx.act`, and never advances the simulator.
+ - A Workflow selects one Scene, exposes run-mode-specific `TaskGraph` builders, and owns goal semantics. A run mode answers how that workflow should run; code and CLI use the shorter term `mode`.
+ - The Engine schedules graph nodes; the shared `SimulationRunner` alone resets, steps, renders, records, retries whole episodes, and prints run summaries.
+ - Online RL is a separate training lifecycle: its trainer owns vectorized stepping and returns a checkpoint to the normal policy Task and `SimulationRunner` validation path.
+ - Simulator-compatible exported RSL-RL actors may run as in-process Tasks; incompatible foundation-model policy stacks remain remote.
+ - Remote policy stacks run out of process and communicate over Zenoh; offline dataset tools remain independent of the simulator.
+ - Python owns behavior. Manifests carry facts across dependency boundaries.
- If the command fails, use the **Supported Envs** fallback table above.
+ Do not describe retired environment YAMLs, per-mode runners, or separate policy/Arena launchers.
- ## Subprojects
+ ## Route the next action
- | Directory | Purpose |
+ | Goal | Skill |
|---|---|
- | `workflows/agentic/arena/` | IsaacLab-Arena envs, scenes, tasks, teleop, record, replay |
- | `workflows/agentic/policy/` | Policy daemons and train dispatchers |
- | `workflows/agentic/dataset/` | HDF5 → LeRobot conversion and visualization |
- | `workflows/agentic/mimic/` | HDF5 trajectory expansion |
- | `workflows/agentic/annotator/` | VLM success labels and filtering |
- | `workflows/agentic/cosmos/` | Optional Cosmos Transfer video augmentation |
- | `workflows/agentic/common/` | Shared config, messaging, robot constants |
+ | Install, sync, or repair dependencies | `i4h-workflow-setup` |
+ | Create a new workflow/environment | `i4h-workflow-create` |
+ | Edit an existing scene, camera, task, or success rule | `i4h-workflow-scene-edit` |
+ | Record demonstrations | `i4h-workflow-dataset-teleop` |
+ | Replay HDF5 | `i4h-workflow-dataset-replay` |
+ | Augment HDF5 | `i4h-workflow-dataset-mimic` |
+ | Grade/filter HDF5 with a VLM | `i4h-workflow-dataset-annotate` |
+ | Convert HDF5 to LeRobot | `i4h-workflow-dataset-convert` |
+ | Inspect LeRobot in a browser | `i4h-lerobot-viz` |
+ | Fine-tune a manifest-backed policy task | `i4h-workflow-finetune` |
+ | RL post-train a supported policy in simulation | `i4h-workflow-train-rl` |
+ | Run policy or rule-based rollouts | `i4h-workflow-validate` |
+ | Run the maintained complete pipeline | `i4h-workflow-e2e` |
- ## Skill Index
+ For `Stop all`, do not load a stage skill. Run `./stop.sh all` from the repository root and report the stopped process count.
- | Skill | Purpose |
- |---|---|
- | `i4h-workflow-setup` | Install / sync / check third-party deps |
- | `i4h-workflow-create` | Add a new env |
- | `i4h-workflow-scene-edit` | Edit an existing scene / task / camera |
- | `i4h-workflow-dataset-teleop` | Record human demos |
- | `i4h-workflow-dataset-replay` | Replay HDF5 episodes |
- | `i4h-workflow-dataset-mimic` | Expand HDF5 demos with noise |
- | `i4h-workflow-dataset-annotate` | VLM label / filter episodes |
- | `i4h-workflow-dataset-convert` | Convert HDF5 to LeRobot |
- | `i4h-workflow-finetune` | Train supported envs |
- | `i4h-workflow-validate` | Roll out / evaluate policy checkpoints |
- | `i4h-workflow-e2e` | Run the full pipeline |
- | `i4h-lerobot-viz` | Open the LeRobot HTML viewer |
+ ## Troubleshooting
+ If discovery fails, verify the resolved checkout and run setup. If a mode is absent, report it as unsupported.
+
## Prerequisites
- - For any hands-on stage, set up the workflow first — see [[i4h-workflow-setup]] (component venvs and third-party checkouts present).
- - Env YAMLs at `workflows/agentic/config/environments/<env>.yaml` are the source of truth.
+ Require a readable base checkout or network access to clone it.
## Limitations
- - Overview/routing only — each pipeline stage has its own skill; this one performs no recording, training, or rollout.
-
- ## Troubleshooting
-
- - **Error:** env not found / unsupported — Cause: typo, unregistered env, or setup incomplete. Fix: run `workflows/agentic/policy/run.sh --list-envs`; if that fails, run [[i4h-workflow-setup]] first; otherwise check the **Supported Envs** table.
-
- ## Final Response
-
- The response is incomplete unless it includes all three parts below, each separated by a blank line. Do not reply with prose only or run sections together without spacing.
+ This router does not install, author, simulate, process data, train, or evaluate.
- 1. **Orientation** — one short paragraph: env YAMLs, subprojects, sim-to-policy pipeline.
+ ## Examples
- 2. **Supported envs** — heading plus markdown table from Step 1 (`--list-envs` output: env, stack, description) or the **Supported Envs** fallback table.
+ - `What does the i4h workflow include, and where should I start?` → inspect live support, summarize `DESIGN.md`, and recommend one stage skill.
- 3. **Available skills** — heading plus the full **Skill Index** table copied into the response.
+ ## Completion gate
- Then (after another blank line) recommend [[i4h-workflow-setup]] if setup is not done, and name one next stage skill matched to the user's goal.
+ Answer with the live workflow/mode list, a short architecture summary, and one concrete next skill. If the requested workflow or mode is absent from `run.sh list`, say it is unsupported instead of inventing a command.