---
title: "Run and monitor"
description: "How to run a workflow, watch it execute, pause and resume, stop a runaway, and recover from a crash."
slug: guides/building-workflows/run-and-monitor
section: guides
subsection: building-workflows
canonical_url: https://cerevisor.com/docs/guides/building-workflows/run-and-monitor
last_verified: 2026-05-18
last_verified_version: "1.2.0"
updated_at: 2026-05-18T15:08:18.053416+00:00
---

## Running a workflow

Three ways:

- **Click the Run button** in the top-right of the canvas.
- **Press Ctrl/Cmd+R**.
- **Click an individual agent's play icon** to run just that agent (sandbox mode: runs in isolation).

When you click Run, Cerevisor opens the **Execution Modal** showing a pre-run summary:

- Total agents.
- Wave count.
- Estimated cost (per provider).
- Permissions the run will need.
- Skill availability check (preflight).

If anything's wrong, missing provider, gated feature, incompatible skill: the modal blocks the run with an actionable error.

If everything checks out, click **Run** in the modal to start. Click **Cancel** to dismiss.

## The Execution Modal

Once a run starts, the modal shows live status. Top section: overall progress and run cost.

Below that: one card per agent, grouped by wave. Each card shows:

- Status badge: **Waiting / Running / Completed / Failed / Skipped**.
- Streaming output preview (the agent's response as it's generated).
- Tool calls in flight, with the tool name and arguments.
- Wall-clock time so far.
- The agent's resolved provider + model.

Click any agent card to expand it for full output and full tool-call history.

The modal also shows:

- **Current wave** indicator at the top.
- **Run cost so far** (per provider).
- **Permission prompts** as banner toasts when an agent needs your sign-off.

## Stop, pause, resume

Three buttons in the modal:

| Button | Behavior |
|---|---|
| **Stop** | Hard stop. All running agents are cancelled; the run ends. Use for true emergencies. |
| **Pause** | After each agent's current tool call finishes, the orchestrator pauses. Resume picks up where you left off. |
| **Resume** | Continue from a paused state. |

The Execution Modal can be closed with Escape: the run continues in the background. To reopen, click the status indicator in the status bar.

## Permission prompts

When an agent calls a destructive tool (typically `bash`, `write_file`, `edit_file`), the **Permission Modal** opens.

Options:

| Button | Scope |
|---|---|
| **Allow once** | This single call. |
| **Allow always for this run** | Every call of this tool for the rest of the run. |
| **Allow always for this tool** | Permanently — writes to `WorkflowPermissions`. |
| **Deny** | Returns an error to the agent. |

Permission prompts pause only the agent that asked, other agents in the same wave continue running.

## Approval gates

If a connection has flow type **Approval Gate**, the workflow pauses when it reaches the gate. The **Approval Gate Modal** shows:

- The upstream agent's output preview.
- The approval prompt you wrote on the connection.
- The downstream agent that's waiting.

Click **Approve** to proceed or **Reject** to halt the run.

## Ask-user prompts

If an agent calls the `ask_user` tool, the **User Question Modal** opens. It shows the question and either a list of choice buttons or a free-form text input.

The agent pauses until you respond. Other agents (in the same or other waves) continue running.

## Run cost

The status bar shows running cost. The Execution Modal breaks it down per provider, per agent. Costs come from the provider's reported usage:

- Anthropic: reported tokens × per-model pricing.
- OpenAI-compatible: reported tokens × pricing if your provider returns it (Ollama returns no cost; local = always $0).
- Codex CLI: always $0 (subscription billing).
- Cursor Agent: always $0 (subscription billing).

After a run, the full cost breakdown is saved to the audit log.

## Audit log

Every run writes an NDJSON file to `~/.cerevisor/audit-logs/<session-id>.ndjson`. The log contains:

- Every event the orchestrator emitted.
- Every tool call (name, arguments, result).
- Every permission decision.
- Every model call (provider, model, tokens, cost).
- Errors with stack traces.

You can open these files in any text editor. They're the truth of what happened.

## Replaying a workflow

A `.cerevisor` file is the workflow definition. Re-opening it and pressing Run re-runs from scratch.

If you want to re-run with a single agent's output replaced (e.g. "use last run's research, regenerate the writing"), there's no first-class "rerun from agent X" yet, workaround: copy the research output to a markdown file, attach it as an input to the writer, and run just the writer.

## Crash recovery

If Cerevisor crashes or is force-closed mid-run:

- On next launch, Cerevisor detects the unfinished session via its checkpoint.
- The **Incomplete Session Modal** opens.
- You can **Resume** (continues from the last checkpoint) or **Discard** (deletes the session).

Resume is opportunistic; it works for most workflow shapes, but very recently-started agents may need to redo work. The modal shows session metadata so you can decide.

## Background runs

You don't have to keep the Execution Modal open. Close it (Esc) and the run continues. The status bar shows a live indicator with the current wave. Reopen the modal any time to see live state.

## Cloud runs (Cursor only)

If you set the workflow's run mode to **cloud** and use the Cursor Agent provider, the run executes on Cursor's cloud VMs. Cloud runs survive Cerevisor restarts. Manage them via the **Cloud Sessions** modal (title bar icon). See [Cursor cloud runs](../advanced/cursor-cloud-runs.md).
