Skip to main content

CLI

View Markdown

lertha is the orchestrator's command line. It speaks the same words as the port and the UI.

Install

Download the binary for your platform from the orchestrator's releases and put it on your PATH, or build it from the orchestrator repository:

make lertha # in lertha-flow; produces bin/lertha

On first use it fetches its core into ~/.lertha/bin (about 30 MB, once). Nothing else to install.

Connect

export LERTHA_ADDRESS=engine.lertha.com:7233
export LERTHA_NAMESPACE=lertha # default: "default"

Any command also accepts --address and --namespace directly.

Tasks

# run a task and wait
lertha task run --type ComposeGreeting --id greet-1 --queue lab --timeout 10s \
--input '{"greeting":"Hello","name":"CLI"}'

# start without waiting, then look
lertha task start --type ComposeGreeting --id greet-2 --queue lab --timeout 10s --input '{"greeting":"Hi","name":"Ada"}'
lertha task describe --id greet-2
lertha task list --query 'ActivityType = "ComposeGreeting"'
lertha task cancel --id greet-2 --reason "operator"

--timeout is the attempt budget and --overall the whole-run budget, the same two budgets as RunOptions. --heartbeat sets the heartbeat timeout.

Flows

lertha flow describe --id agent-42
lertha flow history --id agent-42 # the recorded event history
lertha flow signal --id agent-42 --name approval --input '{"approved":true,"by":"cli"}'
lertha flow result --id agent-42
lertha flow list --query 'WorkflowType = "AgentRun"'
lertha flow cancel --id agent-42

Queues and workers

lertha queue describe --name lab # who is polling, and with which build

If this lists more workers than you expect, you have version skew. See Determinism.

Namespaces and the cluster

lertha namespace list
lertha namespace describe lertha
lertha cluster # core version and capabilities

Local dev orchestrator

lertha dev # in-memory; UI on :8233, gRPC on :7233
lertha dev --db lab.db # persists across restarts

Everything else

lertha renames what has a Lertha word and passes every other flag through unchanged, so the full core command set is reachable. lertha help lists the vocabulary; lertha raw -- ... hands the arguments to the core untouched:

lertha raw -- workflow list --limit 5

The Vocabulary page maps the words in both directions, which is also how to read the core's own --help output.