Skip to content

feat: per-env reset routing in the bridge (fleet mode PR-A, BRG-5) - #172

Merged
heyong4725 merged 1 commit into
mainfrom
feat/fleet-mode
Aug 12, 2026
Merged

feat: per-env reset routing in the bridge (fleet mode PR-A, BRG-5)#172
heyong4725 merged 1 commit into
mainfrom
feat/fleet-mode

Conversation

@heyong4725

Copy link
Copy Markdown
Owner

First fleet-mode increment (§8.4.3). The probe measured that batched physics, per-env command routing, guard state, and state publishing already exist — the true gap was per-env RESET:

  • teleport_reset(seed, env_id): env-sliced injection via envs_idx; whole-scene path bit-identical.
  • Per-env ResetQuarantine + CommandQueue.drain(env_id): one agent's reset no longer freezes or flushes its neighbours.
  • BRG-5-validated env_id on reset requests; reset_done replies carry it; the shared publish grid anchors to the first whole-scene reset (documented fleet-mode deviation from ADR-25).
  • Cameras stay env-0-only (ADR-7) — the fleet MVP targets L0, where nothing needs rendering.

Measured: n_envs=4 steps at ~single-env wall cost (3.8× env-step throughput). PR-B (the multiplexing scheduler + fleet CLI) follows.

Gates: ruff clean · 1051 unit tests · live T0 episode green (single-env regression) · env_hash re-pinned.

🤖 Generated with Claude Code

The batched-env probe measured the surprise: n_envs=4 already steps at
~the single-env wall cost (3.6 ms vs 3.5 ms, 3.8x env-step throughput),
and per-env command routing (BRG-5), per-env guard state, and per-env
state publishing all pre-exist. The one true gap was RESET:

- teleport_reset(seed, env_id): env-sliced state injection (boxes and
  arm home via envs_idx) with per-env command drain and dropped-count
  clearing; env_id None keeps the whole-scene semantics bit for bit.
- ResetQuarantine is per-env (arm/held/tick): a reset of env k no
  longer freezes the other envs' episodes; the legacy hold() contract
  is preserved and re-tested.
- CommandQueue.drain(env_id): env-scoped drain for per-env resets.
- The reset handler validates metadata env_id per BRG-5 (int, in
  range), teleports the slice, and replies reset_done with that env_id.
  The shared publish grid is NOT re-anchored on per-env resets (fleet
  cadence anchors to the first whole-scene reset — a documented
  fleet-mode difference from ADR-25's per-episode anchoring).

Cameras remain env-0-only (ADR-7): the fleet MVP targets the L0 rung,
where neither policy nor the oracle verifier needs rendering.

Frozen-set edit (dora_genesis.py): env_hash re-pinned. Gates: ruff
clean; 1051 unit tests (per-env quarantine/drain suites); live T0
episode green (single-env regression).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@heyong4725
heyong4725 merged commit aacc417 into main Aug 12, 2026
4 checks 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.

1 participant