Objective
Promote RuntimeBridge from an isolated/tested transport into the production effect path of the Simplicio Loop runner whenever the Runtime-backed profile is selected.
Today the main runner invokes Mapper and Dev CLI operators directly, while RuntimeBridge is exercised primarily by transport tests. This leaves two parallel effect paths and prevents Runtime from being the authoritative executor/evidence boundary for Runtime-backed runs.
Non-negotiable architecture
- Loop remains usable standalone without Runtime.
- When Runtime-backed execution is selected, every mutating/process effect must go through Runtime MCP or an explicitly supported native binding.
- Mapper may remain a read-only context producer.
- Dev CLI may compile plans/verification proposals, but writes/process effects in integrated mode are applied by Runtime.
- No silent direct-subprocess or direct-file fallback after Runtime selection.
- Any compatible coordinator can drive Loop; Simplicio Agent is optional.
Implementation steps
- Add an explicit execution profile: standalone and runtime-backed.
- Resolve profile from CLI/config/contract, never from accidental binary presence alone.
- Instantiate one lazy RuntimeBridge per Loop Hub/session and workspace registry.
- Add a production runner effect adapter with map/read/edit/exec/validate/checkpoint/evidence methods.
- Translate Loop work-item identity, attempt, lease, fencing token, deadline, cancellation and write set into EffectTransaction/v1.
- Route Dev CLI planned mutation through the Runtime adapter instead of applying it directly.
- Route tests/build/process execution through simplicio_exec with bounded env, cwd, output and timeout.
- Persist Runtime receipt references in operator, watcher, delivery and loop-execution receipts.
- Prevent direct filesystem/subprocess mutation from runtime-backed runner stages with a policy guard and tests.
- Handle Runtime unavailable, incompatible, disconnected and uncertain-effect states explicitly.
- Keep standalone path behavior and contracts intact.
- Expose active profile, executor identity, Runtime generation and fallback status in CLI/status/progress.
- Add migration notes and minimum Runtime version.
- Make the installed-package E2E release-blocking.
State and recovery
- Before effect: safe retry with the same idempotency key.
- During/after uncertain effect: reconcile; never blindly replay.
- Runtime disconnect: pause the affected lane, preserve unrelated lanes.
- Capability drift: stop before mutation and provide exact repair.
- Cancellation: honor only at Runtime safe boundaries.
- Shutdown: drain, close and verify zero owned processes.
Tests
- Standalone run without Runtime.
- Runtime-backed mechanical task with all effects through MCP.
- Semantic task coordinated by two different hosts.
- Direct mutation bypass attempt is rejected.
- Runtime missing before effect.
- Runtime crash before, during and after effect.
- Duplicate idempotency key and reconnect.
- Mapper stale context and Dev CLI rejected plan.
- Watcher validation through Runtime.
- Multi-item drain with mixed success/failure.
- Installed minimum/latest versions.
Acceptance criteria
Relations
Objective
Promote RuntimeBridge from an isolated/tested transport into the production effect path of the Simplicio Loop runner whenever the Runtime-backed profile is selected.
Today the main runner invokes Mapper and Dev CLI operators directly, while RuntimeBridge is exercised primarily by transport tests. This leaves two parallel effect paths and prevents Runtime from being the authoritative executor/evidence boundary for Runtime-backed runs.
Non-negotiable architecture
Implementation steps
State and recovery
Tests
Acceptance criteria
Relations