Reaktor workspace CLI
The installed reaktor command reads the workspace kernel's graph-owned operation catalog. CLI, MCP and Hangar use the same operations, canonical build-node identities and retained runs. The implementation lives in hangar/cli; shared operation and transport contracts live in Reaktor.
Workspace operations#
The CLI is a terminal client of the workspace owner. The owner validates authority, prepares plans, supervises effects and retains evidence. An explicit invocation can join or start that supervised owner. Help, version and static completion do not start it.
| Surface | Responsibility |
|---|---|
| CLI | Parse typed operation arguments, render results, follow accepted work and generate completion |
| Workspace owner | Resolve graph-owned operations, validate arguments, apply policy and retain execution evidence |
| Tooling | Execute typed process and provider requests with their declared inputs, effects and output handling |
| MCP and Hangar | Present the same operation contracts through their own adapters |
Build nodes, agent tasks and runs have separate identities. A selected build node identifies declared work; a run identifies one observation of execution. Neither a cached model nor a previous successful run proves that current work has succeeded.
Implementation#
The Kotlin/JVM CLI generates domain commands from the operation catalog and argument schemas. There is one parser and one operation invocation path. It does not maintain a handwritten copy of the owner's command tree or discover build commands from target folders and script-name families.
Commands#
Run these from BestBuds, or pass --dir /absolute/workspace:
reaktor operation catalog
reaktor operation describe build.run
reaktor build list
reaktor build tree
reaktor build explain bestbuds:pr
reaktor build plan bestbuds:pr
reaktor build run bestbuds:pr --json
reaktor run list --json
reaktor run show RUN
reaktor run logs RUN
reaktor build affected --since HEAD
reaktor build affected --since HEAD --view omissions
Use IDs returned by the current workspace. build plan is an explicit Gradle configuration request; its returned plan records that cost. build affected is a read of declared inputs and Git changes: it selects graph consumers conservatively, returns paged reasons, revisions, unmatched paths and omissions, and marks coverage partial. It does not execute work or authorize receipt reuse.
Common options work before or after commands: --dir, --json, --args, --detach, --request-id and --seat. The migration alias --workspace maps to --dir. Operation options come from its live schema. Repeated options supply collection fields; --args JSON or --args - supplies a bounded JSON object. Duplicate scalars, overlapping named/JSON fields, unknown fields and incorrect types fail before invocation.
Model and catalog#
Dependeasy exports the canonical build model. Build membership, declarations, kernel sources, inputs, outputs and dependency edges come from that model. Missing or stale facts remain visible; execution requiring current declarations rejects a stale model.
Help uses the disposable cached catalog and schemas, labels their status and gives refresh instructions. operation catalog refreshes membership; operation describe OPERATION refreshes its schema. An explicit unknown command refreshes membership once.
Execution and authority#
--seat records caller attribution. It does not grant authority. Approval-required returns exit 3 and a reference to review through the existing owner. The CLI does not approve or replay the operation.
Execution normally follows accepted durable work through run.logs and run.wait. --detach returns the accepted handle. Ctrl-C detaches the client while the owner continues the run. A timeout or lost reply retains the operation, request, workspace and accepted run references when known.
Output#
Human output renders tables, relationship trees, scope, pagination and an owning next command. --json emits one typed outcome on stdout; progress goes to stderr.
| Result | Exit |
|---|---|
| Completed | 0 |
| Failed operation | 1 |
| Rejected request or unavailable transport | 2 |
| Approval required | 3 |
| Client wait expired; work may continue | 124 |
| Client interrupted; work may continue | 130 |
A followed process preserves its nonzero exit status. An uncertain reply reports delivery_unknown or follow_unavailable; neither triggers automatic cancellation or retry. Request references identify calls. Exact owner reconciliation and deduplication remain open work.
Installation#
From the BestBuds checkout:
../hangar/cli/tools/install --build
The helper uses the configured Gradle build router, validates the distribution, installs the launcher under ~/.reaktor/bin, and retains the previous installation at its printed .cli-previous.* path. Java 25 is required, and the installed CLI selects it even when the shell has a stale JAVA_HOME. An optional destination supports isolated qualification. The helper does not edit shell configuration or restart owners.
Devices#
reaktor devices lists reachable computers and currently connected Android and
Apple devices, as seen by the local computer and configured worker. Use --json
to read device IDs, transport states and probe failures from scripts.
reaktor connect ios and reaktor connect android check trust, unlock and live UI
automation on a physical phone attached to either host. Use --device ID to
select a phone. Enter passcodes and approve UI Automation on the phone when prompted.
Completion#
reaktor completion bash|zsh|fish generates shell completion from cached metadata. Refresh catalog/schema metadata explicitly before regenerating it.
Live completion reads an existing owner for canonical build-node IDs, run IDs, operation IDs and declared environments. It returns at most 50 prefix matches, waits up to one second, and returns no matches when the owner is unavailable. Tab does not start an owner, build or provider, or refresh caches.
BestBuds and other workspaces#
--dir selects the workspace. The same client operates BestBuds, Reaktor and Manna through their independent owners and declared composite builds. It does not hardcode product service names.
Commands come only from the operation catalog: a target folder or package-script name is never a command. Use operation catalog to see them.
Other faces#
MCP uses the same owner invocation path:
reaktor --dir /absolute/workspace mcp --stdio --seat codex
Hangar projects the same graph and operations visually. Context, authority and evidence belong to the owner rather than a particular client.
Not built yet#
Typed build options per target, removal of the remaining generated aliases, exact reconciliation with the owner and an interactive terminal view are not built. Affected selection is conservative and read-only.
Source references#
hangar/cli/README.md: current examples and transport behavior.hangar/cli/src/main: generated command face and output.hangar/host: graph-owned operation catalog and workspace owner.dependeasy/model: canonical build model and shared readers.reaktor/reaktor-gate,reaktor/reaktor-mcpandreaktor/reaktor-conductor: operation contracts and owner transport.