mirror_neuron binary is the primary interface for interacting with MirrorNeuron — submitting jobs, inspecting runtime state, managing cluster membership, and monitoring live activity. You build it once from the Elixir project, then use it directly from the shell on any node in your deployment.
Build the CLI binary
Build the binary withmix escript.build. This compiles the project and writes a self-contained mirror_neuron executable to the project root.
Build the escript binary
Compile and package the CLI into a single executable.On success you will see a
mirror_neuron file in your project root.The binary embeds the Elixir application. You do not need to run
mix on the target machine — only Erlang/OTP must be installed there.Command categories
mirror_neuron commands fall into five categories:
| Category | Commands | Purpose |
|---|---|---|
| Server | standalone-start | Start a standalone runtime instance |
| Cluster | cluster start/join/discover/status/nodes/leave/rebalance/elect-leader/health/reload | Manage distributed cluster membership |
| Job lifecycle | validate, run, pause, resume, cancel | Submit and control workflows |
| Inspection | job list/inspect, agent list, node list, events | Read runtime state |
| Operations | monitor, bundle reload/check, node add/remove, send | Observe and intervene at runtime |
Top-level commands
standalone-start
standalone-start
Start an isolated, standalone runtime server instance. Use this for single-node deployments and local development.
cluster
cluster
Start, join, and manage the peer-to-peer cluster. Covers the full membership lifecycle — from bootstrapping a new cluster to gracefully leaving or rebalancing nodes.See the commands reference for all
cluster subcommands.validate
validate
Check a job bundle before running it. Verifies bundle structure, manifest syntax, and node and edge relationships.
run
run
Submit a job bundle for execution. Supports interactive, JSON-output, and detached modes, as well as a configurable timeout.
monitor
monitor
Open the terminal monitor — a live ops view of your cluster nodes, running jobs, sandbox counts, and recent events. Supports JSON output and multi-node cluster connections.
job
job
List all jobs, inspect a specific job, or list the agents belonging to a job.
agent
agent
List agents for a given job.
node
node
List cluster nodes or add and remove nodes from the runtime.
events
events
Stream the event log for a job. Useful for debugging message flow, lease events, and sandbox completion or failure.
bundle
bundle
Reload or check a registered bundle by its ID.
pause / resume / cancel
pause / resume / cancel
Control a running job’s lifecycle from the CLI.
send
send
Inject a message directly into a specific agent in a running job. Useful for manual testing, sensor-style workflows, and operator intervention.
Verbose output
Add-v or --verbose to any command to raise the log level from error to warning, which surfaces additional runtime activity in the terminal.
Next steps
CLI command reference
Full syntax and examples for every mirror_neuron command.
Running workflows
End-to-end guide to submitting and monitoring a job.
Clustering
Set up a multi-node cluster and manage membership.
Monitoring
Use the terminal monitor for live operational visibility.