Skip to main content
An agent that heads the wrong way costs time and tokens for as long as it keeps going. In this guide you start an agent run, pause it in the middle of a command, change its mode, give it a new instruction and resume it, so it finishes the task you meant. A run keeps its whole state while it is paused, so it continues from where it stopped instead of starting over. Every control is described in Workflow control.

Before you begin

  • The reliant CLI, v1.21 or later, signed in (Sign in and tokens).
  • A connected machine that holds the repository (Run a machine from the terminal).
  • The Reliant app open on the same account, for the steps that change a running agent. The CLI pauses, resumes and reads runs; messages and parameter changes are sent from the app.
1

Start a run

Any workflow run works, including one an automation started. This one asks the stock agent for a small change with a slow command in the middle:
terminal
The execution ID is the run’s chat ID. Every command below takes it. Runs started from the CLI are listed under Workflows → Runs in the app.
2

Pause it

terminal
Pausing stops work in flight first. The sleep 60 was 22 seconds in, and the agent’s shell call ended with Tool execution cancelled. In the app, the stop button in the composer and Esc do the same.
3

Steer it while it is paused

In the app, open the run and change what you need before it continues:
  • Mode or model. Switch the mode in the composer toolbar, for example from auto to plan, which leaves the agent read-only tools. Pick another model with the model button. A change applies at the agent’s next model call.
  • A new instruction. Type it in the composer. Sending a message to a paused run resumes it with your message added. To leave the run paused for now, resume from the terminal instead (next step) and send the message once it runs: a message sent to a running agent is queued, and the agent reads it at its next turn.
For this run, the mode went to plan and the message was: Change of plan: skip the sleep and don’t write tests. Tell me in one line what calc.py does.
4

Resume it

terminal
watch blocks and prints each boundary as it happens: nodes, questions, approvals, and the end of the run. reliant workflow follow streams the same events as JSON, for scripts.
5

Verify the run took the new direction

reliant workflow status shows Status: COMPLETED, and the run’s last replies in the app show the agent working from the new settings:
The agent noticed the switch to plan, did not rerun the cancelled sleep, and answered the queued message. git status shows only the docstring edit it made before the pause.

When a run pauses by itself

A step of the main agent that fails after its retries pauses the run instead of failing it. The chat says what failed, such as an expired provider login, and ends with “Workflow paused — send a message to retry”. Fix the cause, then send a message or run reliant workflow resume. Runs nobody is watching, such as automations, retry by themselves for about half an hour before they end as failed. Automatic pause on failure covers both cases, and sub-agents.

What this does not do

  • Pausing is not stopping. A paused run keeps its checkpoint and still counts against its workflow’s concurrency.max_running. To end a run for good, run reliant workflow terminate <execution-id> or Stop on the run’s page. A terminated run cannot be resumed.
  • A cancelled command is not rerun for you. Pausing cancels the command in flight. After you resume, the agent decides whether to run it again, so say so in your message if you want it rerun.
  • The CLI cannot message a run or change its parameters. Use the app’s composer for both, or a sub-agent’s own message box to steer just that sub-agent (Messaging a running workflow).

Next steps

Workflow control

Every pause, resume and steering control, in the app and the terminal.

Require human approval

Make a run stop and wait for you at a fixed point instead.

How workflows run

Why a paused run costs nothing and continues where it stopped.

First multi-agent workflow

Write a workflow of your own to run, pause and steer.