feat(electrobun): add first-party Satellites and dynamic views#7779
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
… into codex/phase-11-event-bridge-wip
|
Phase 13 added trace host infrastructure on top of the dynamic view/event bridge:
Next planned follow-up: eliza.voice mock/text-only pipeline + trace integration. No static UI panel, no Swift. |
Why This Is Needed
Electrobun is already the right desktop shell for elizaOS, but the repo had several desktop/system capability paths growing in parallel: plugin-local filesystem access, command execution, local Git helpers, local-model control/status paths, Surface/dev tooling, runtime startup diagnostics, and emerging agent-created views. Leaving those paths duplicated creates permission drift, tracing gaps, inconsistent error handling, platform-specific bugs, and a package graph that becomes harder to review with every feature.
This PR creates the missing separation of responsibilities:
eliza.runtimebrokers capability calls without taking runtime ownership away from AgentManager.packages/uirenders shared components and generated UI, but does not execute capabilities.The practical reason this is needed now: without this convergence layer, every new plugin/app/desktop feature has to decide for itself how to read files, run commands, inspect Git, show tool state, trace behavior, expose voice/model status, and recover from startup failures. That makes the product harder to secure, harder to debug, and harder to keep portable across desktop, server, mobile, and web. This PR gives those features a shared host/broker/view/trace substrate while preserving the plugin system instead of flattening everything into Satellites.
Summary
This PR is the Electrobun platform convergence stack for first-party Satellites, dynamic views, trace/voice infrastructure, capability routing, Eliza GenUI, launch diagnostics, database boot policy, and the review-boundary build repairs needed after merging current
origin/develop.The core architecture remains:
packages/appowns the production app UI.packages/uiis the shared rendering kit and must not execute desktop/system capabilities.packages/app-core/platforms/electrobunis the desktop shell, typed RPC bridge, AgentManager host, dynamic-view host, trace/voice host layer, launch/database diagnostics layer, and first-party Satellite seeder.eliza.runtimebrokers to Satellites and delegates runtime lifecycle to AgentManager in Electrobun host mode.Major Changes
First-party Satellites and seeding
Adds bundled first-party Satellites under
packages/app-core/platforms/electrobun/satellites/:eliza.runtimeeliza.fseliza.ptyeliza.giteliza.local-modeleliza.surfaceas dev/admin onlyThe seeding path validates manifests, installs/updates idempotently, preserves disabled state, and marks
eliza.runtimeas required while keeping capability Satellites recommended.AgentManager-backed runtime broker
eliza.runtimedoes not own a second runtime process in Electrobun host mode. Runtime lifecycle/status/log calls delegate through the existing AgentManager path. Standalone runtime spawning remains only for Satellite-local smoke/dev mode.The runtime broker surface routes capability requests to:
eliza.fsfor filesystem implementationeliza.ptyfor terminal/session/command implementationeliza.gitfor local Git implementationeliza.local-modelfor desktop local-model control/statusTyped worker command and event bridge
Adds renderer-safe worker bridge surfaces:
carrotInvokeWorkercarrotTailWorkerEventsWorker events are captured in a bounded per-worker buffer with monotonic sequence cursors. This gives dynamic views and dev/admin views a typed path for command invocation and event tailing without direct Satellite calls.
Dynamic views
Adds host-side dynamic-view infrastructure under
src/dynamic-views/:agent.run.trace.demoDynamic views are contextual agent-created views. They are not a replacement for
packages/appand are not new fixed production dashboards.Trace and voice infrastructure
Adds trace as the observability spine and voice as a streaming/instrumented pipeline layer, including host services, trace integration, live adapter/latency primitives, and validation harness work. This PR does not add live voice/model-download test requirements.
Capability collapse and routing
Adds the convergence/collapse documentation and first routing slices for implementation-only paths. The rule is preserved:
eliza.computerremains only a documented future candidate for browser/computer-use/screen/camera/canvas overlap.Eliza GenUI and UI boundary work
Adds Eliza GenUI as an A2UI-compatible, Eliza-owned schema/rendering layer under
packages/ui, rendered through the shared UI kit with controlled action routing. It does not replacepackages/ui, does not execute arbitrary code, and does not call Satellites directly.Also repairs
packages/uiboundaries so UI no longer depends on@elizaos/app-core, which removes the Turbo circular package dependency involving UI, app-core, local inference, capacitor bridge, and agent packages.Launch and database diagnostics
Adds launch/startup/onboarding diagnostic groundwork and database boot policy diagnostics as Electrobun/AgentManager boot infrastructure, not Satellites.
Database startup is made explicit around:
POSTGRES_URLDATABASE_URLmappingPGLITE_DATA_DIRStartup/onboarding remains core boot infrastructure. No startup/onboarding/database Satellite is added.
Coding Satellite sandbox runner
Adds a Bun-based coding Satellite image under
packages/cloud-services/coding-satellitefor Eliza Cloud and home-machine sandbox execution. This is needed because mobile and cloud sessions need a real remote execution target for coding work: the phone/app can stay TypeScript/runtime-portable while file, process, Git, Codex, Claude Code, and opencode execution happens inside an authenticated Bun Satellite runner on Eliza Cloud or the user's home machine.This keeps the architecture simple:
The new image exposes guarded filesystem and process endpoints, ships with git/ripgrep/Python/SSH plus Codex, Claude Code, and opencode CLIs, and can be selected by setting
ELIZA_CLOUD_CODING_SATELLITE_IMAGE. The runner rejects paths outside the workspace and rejects writes through symlinks.Sandbox live smoke skips Eliza Cloud provisioning in non-strict mode until
ELIZA_CLOUD_CODING_SATELLITE_IMAGEor a direct runner URL is configured; strict/manual Cloud runs still fail when the provider is unavailable.CI follow-up for sandbox/mobile/server gates
After the first coding Satellite push, CI exposed three review-boundary issues that are now addressed in the branch:
init_elizasynchronous.runtime/eliza.tsimports local-inference embedding presets through the package's exported@elizaos/plugin-local-inference/runtimesubpath instead of a nested non-exported path.Build and review-boundary repairs
After merging current
origin/develop, this PR also includes build-boundary repairs:@elizaos/ui -> @elizaos/app-coredependency edge.@elizaos/plugin-capacitor-bridge -> @elizaos/agentpackage graph edge.cnhelper so the root build no longer fails on the metrics dashboard package.Static-analysis cleanup
The latest review pass reduces CodeFactor complexity in the high-churn sandbox and startup boundary files without changing behavior:
packages/agent/src/runtime/eliza.tspackages/agent/src/services/e2b-capability-router.test.tspackages/cloud-services/coding-satellite/src/index.tspackages/ui/src/onboarding/onboarding-config.tspackages/ui/src/components/settings/CloudInstancePanel.tsxThis keeps the PR easier to review and avoids letting the sandbox/mobile convergence work add another layer of hard-to-maintain branching logic.
What This PR Does Not Do
packages/app.eliza.surfaceproduction UI.eliza.computer; it remains a future candidate only.Validation
Local validation performed during this stack includes:
bun run --cwd packages/ui typecheckbun run --cwd packages/ui testbun run --cwd packages/app typecheckbun run --cwd packages/app-core/platforms/electrobun typecheckbun run --cwd packages/app-core/platforms/electrobun testbun run --cwd packages/app-core/platforms/electrobun buildbun run --cwd packages/electrobun-carrots typecheckbun run --cwd packages/electrobun-carrots testbun run --cwd plugins/plugin-capacitor-bridge typecheckbun run --cwd packages/benchmarks/skillsbench/experiments/metrics-dashboard buildbun run --cwd packages/cloud-services/coding-satellite typecheckbun run --cwd packages/cloud-services/coding-satellite testbun run --cwd packages/cloud-shared typecheckbun test packages/cloud-shared/src/lib/services/coding-containers.test.tsbun run --cwd packages/agent typecheckbun run --cwd packages/agent build:mobileinit_elizaremains synchronousbun run --cwd packages/agent test -- src/services/e2b-capability-router.test.ts --reporter verbosePASSED home: fs, pty, and git routes completed against live providergit diff --checkDocker image build was not run locally because this machine does not have the
dockerCLI installed; the runner package and local HTTP contract were validated directly with Bun and the live home Satellite smoke.The branch has been merged with current
origin/developand pushed. GitHub reports the PR as mergeable; CI is running on the latest pushed head.Review Focus
Please review this as a broad platform convergence PR. The most important review surfaces are:
eliza.runtimebehaviorpackages/uias rendering-only shared kitorigin/develop