Agentic AI Atlasby a5c.ai
OverviewWikiGraphFor AgentsEdgesSearchWorkspace
/
GitHubDocsDiscord
iiRecord
Agentic AI Atlas · Babysitter CLI Reference
page:docs-user-guide-reference-cli-referencea5c.ai
Search record views/
Record · tabs

Available views

II.Record viewspp. 1 - 1
overviewarticlejsongraph
II.
Page JSON

page:docs-user-guide-reference-cli-reference

Structured · live

Babysitter CLI Reference json

Inspect the normalized record payload exactly as the atlas UI reads it.

File · wiki/docs/user-guide/reference/cli-reference.mdCluster · wiki
Record JSON
{
  "id": "page:docs-user-guide-reference-cli-reference",
  "_kind": "Page",
  "_file": "wiki/docs/user-guide/reference/cli-reference.md",
  "_cluster": "wiki",
  "attributes": {
    "nodeKind": "Page",
    "sourcePath": "docs/user-guide/reference/cli-reference.md",
    "sourceKind": "repo-docs",
    "title": "Babysitter CLI Reference",
    "displayName": "Babysitter CLI Reference",
    "slug": "docs/user-guide/reference/cli-reference",
    "articlePath": "wiki/docs/user-guide/reference/cli-reference.md",
    "article": "\n# Babysitter CLI Reference\n\n**Version:** 1.1\n**CLI/SDK Version:** 5.0.0\n**Last Updated:** 2026-01-25\n\nComplete reference documentation for the core Babysitter command-line interface.\n\n> **Looking for slash commands?** See [Slash Commands Reference](./slash-commands.md) for `/babysitter:call`, `/babysitter:yolo`, and other Claude Code commands.\n\n---\n\n## Table of Contents\n\n- [Overview](#overview)\n- [Installation](#installation)\n- [Global Options](#global-options)\n- [Run Management Commands](#run-management-commands)\n  - [run:create](#runcreate)\n  - [run:assign-process](#runassign-process)\n  - [run:status](#runstatus)\n  - [run:events](#runevents)\n  - [run:iterate](#runiterate)\n  - [run:rebuild-state](#runrebuild-state)\n- [Task Commands](#task-commands)\n  - [task:list](#tasklist)\n  - [task:show](#taskshow)\n  - [task:post](#taskpost)\n- [Breakpoint Rule Commands](#breakpoint-rule-commands)\n  - [breakpoint:approve-rule](#breakpointapprove-rule)\n  - [breakpoint:remove-rule](#breakpointremove-rule)\n  - [breakpoint:list-rules](#breakpointlist-rules)\n  - [breakpoint:should-auto-approve](#breakpointshould-auto-approve)\n  - [breakpoint:history](#breakpointhistory)\n- [Exit Codes](#exit-codes)\n- [Output Formats](#output-formats)\n- [Examples](#examples)\n\n---\n\n## Overview\n\nThe Babysitter CLI provides deterministic orchestration for event-sourced workflows. It enables run lifecycle management, task introspection, plugin/profile management, and result posting.\n\n**Binary Names:**\n- `babysitter` (primary)\n- `babysitter-sdk` (alias)\n\n**Package split:**\n- Install `@a5c-ai/babysitter` for the recommended end-user `babysitter` command.\n- Install `@a5c-ai/babysitter-sdk` if you need the SDK/library directly or want the underlying CLI implementation package.\n- Install `@a5c-ai/babysitter-agent` for runtime commands such as `call`, `resume`, `plan`, `start-server`, and `tui`.\n\n**Design Principles:**\n- Deterministic operations (same inputs = same outputs)\n- JSON-first output for automation\n- POSIX path separators in all output (cross-platform)\n- No hidden state mutations\n\n---\n\n## Installation\n\n### Global Installation (Recommended)\n\n```bash\nnpm install -g @a5c-ai/babysitter@latest\n```\n\n### Optional Runtime CLI\n\n```bash\nnpm install -g @a5c-ai/babysitter-agent@latest\n```\n\n### Via npx (No Install)\n\n```bash\nnpx -y @a5c-ai/babysitter@latest <command>\n```\n\n### Verify Installation\n\n```bash\nbabysitter --version\n# Output: 5.0.0\n```\n\n### Alias Setup\n\n```bash\n# Recommended alias for scripts\nCLI=\"babysitter\"\n\n# Or for npx usage\nCLI=\"npx -y @a5c-ai/babysitter@latest\"\n```\n\n---\n\n## Global Options\n\nThese options are available on all commands:\n\n| Option | Description | Default |\n|--------|-------------|---------|\n| `--runs-dir <path>` | Override the runs directory | `~/.a5c/runs` |\n| `--json` | Output in JSON format | `false` |\n| `--verbose` | Enable verbose logging (paths, resolved options) | `false` |\n| `--dry-run` | Preview changes without applying (where supported) | `false` |\n| `--help`, `-h` | Show agent-facing help (default; covers commands intended for agent/automation use) | - |\n| `--help-human` | Show human-facing help for the core CLI surface (for example `session:*`, `plugin:*`, `harness:*`, `configure`) | - |\n| `--version`, `-v` | Show version number | - |\n\n> The default `--help` (and the usage text printed on a wrong-syntax invocation or a bare command name) lists **agent-facing** commands only — the surface a babysitter skill or hook would call. Run `babysitter --help-human` to see the commands intended for direct human use.\n\n> Runtime/orchestration commands such as `babysitter-agent call`, `resume`, `plan`, `doctor`, `start-server`, and `tui` are part of the optional `@a5c-ai/babysitter-agent` package and are not covered by this reference unless explicitly noted.\n\n### Path Handling\n\n- All paths in output use POSIX separators (`/`) regardless of platform\n- Input paths accept both POSIX (`/`) and Windows (`\\`) separators\n- Paths are relative to the run directory unless absolute\n\n---\n\n## Run Management Commands\n\n### run:create\n\nCreates a new orchestration run.\n\n#### Synopsis\n\n```bash\nbabysitter run:create \\\n  --process-id <id> \\\n  --entry <path>#<export> \\\n  [--inputs <file>] \\\n  [--run-id <id>] \\\n  [--process-revision <rev>] \\\n  [--request <description>] \\\n  [--prompt <text>] \\\n  [--json]\n```\n\n#### Options\n\n| Option | Required | Description |\n|--------|----------|-------------|\n| `--process-id <id>` | Yes | Process identifier (e.g., `dev/build`) |\n| `--entry <path>#<export>` | Yes | Entry point file and export name |\n| `--inputs <file>` | No | Path to inputs JSON file |\n| `--run-id <id>` | No | Custom run ID (auto-generated if omitted) |\n| `--process-revision <rev>` | No | Process revision/version |\n| `--request <description>` | No | Human-readable request description |\n| `--prompt <text>` | No | Initial user prompt to persist in run metadata and journal |\n\n#### Output (Human)\n\n```\n[run:create] runId=run-20260125-143012 runDir=.a5c/runs/run-20260125-143012\n```\n\n#### Output (JSON)\n\n```json\n{\n  \"runId\": \"run-20260125-143012\",\n  \"runDir\": \".a5c/runs/run-20260125-143012\",\n  \"process\": {\n    \"processId\": \"dev/build\",\n    \"entry\": \"processes/build/process.mjs#process\"\n  }\n}\n```\n\n#### Examples\n\n```bash\n# Basic run creation\nbabysitter run:create \\\n  --process-id dev/build \\\n  --entry .a5c/processes/build/main.js#buildProcess\n\n# With inputs and custom ID\nbabysitter run:create \\\n  --process-id tdd/feature \\\n  --entry .a5c/processes/tdd/main.js#tddProcess \\\n  --inputs ./inputs.json \\\n  --run-id \"run-$(date -u +%Y%m%d-%H%M%S)-auth-feature\" \\\n  --prompt \"Implement auth feature with TDD\" \\\n  --json\n\n# With request description\nbabysitter run:create \\\n  --process-id dev/api \\\n  --entry ./process.js#apiProcess \\\n  --request \"Build REST API with authentication\" \\\n  --prompt \"Build REST API with authentication\"\n```\n\n---\n\n### run:assign-process\n\nAssigns a process to an existing run.\n\n#### Synopsis\n\n```bash\nbabysitter run:assign-process <runDir> \\\n  --entry <path>#<export> \\\n  [--process-id <id>] \\\n  [--process-revision <rev>] \\\n  [--force] \\\n  [--json] \\\n  [--dry-run] \\\n  [--verbose]\n```\n\n#### Description\n\nAssigns a process entrypoint to an existing bare run (one created without `--entry`). Updates the run's `entrypoint`, `processPath`, and `processId` fields in `run.json` and appends a `PROCESS_ASSIGNED` journal event. If the run already has a process assigned, the command rejects unless `--force` is provided.\n\n#### Arguments\n\n| Argument | Required | Description |\n|----------|----------|-------------|\n| `<runDir>` | Yes | Run ID or path to run directory |\n\n#### Options\n\n| Option | Required | Description |\n|--------|----------|-------------|\n| `--entry <path>#<export>` | Yes | Entry point file and export name |\n| `--process-id <id>` | No | Process identifier (retains existing if omitted) |\n| `--process-revision <rev>` | No | Process revision/version |\n| `--force` | No | Override if a process is already assigned |\n| `--json` | No | Output in JSON format |\n| `--dry-run` | No | Preview changes without applying |\n| `--verbose` | No | Enable verbose logging |\n\n#### Output (Human)\n\n```\n[run:assign-process] runId=run-20260125-143012 runDir=.a5c/runs/run-20260125-143012 entry=.a5c/processes/build/main.js#buildProcess processId=dev/build\n```\n\n#### Output (JSON)\n\n```json\n{\n  \"runId\": \"run-20260125-143012\",\n  \"runDir\": \".a5c/runs/run-20260125-143012\",\n  \"entry\": \".a5c/processes/build/main.js#buildProcess\",\n  \"processId\": \"dev/build\",\n  \"previousEntrypoint\": {\n    \"importPath\": \"bare-run\"\n  },\n  \"assigned\": true\n}\n```\n\n#### Dry Run Output (JSON)\n\n```json\n{\n  \"dryRun\": true,\n  \"runDir\": \".a5c/runs/run-20260125-143012\",\n  \"runId\": \"run-20260125-143012\",\n  \"entry\": \".a5c/processes/build/main.js#buildProcess\",\n  \"processId\": \"dev/build\",\n  \"previousEntrypoint\": {\n    \"importPath\": \"bare-run\"\n  },\n  \"force\": false\n}\n```\n\n#### Error Responses (JSON)\n\n| Error Code | Condition |\n|------------|-----------|\n| `RUN_NOT_FOUND` | Run directory does not exist |\n| `PROCESS_ALREADY_ASSIGNED` | Run already has a process and `--force` was not provided |\n\n#### Examples\n\n```bash\n# Assign a process to a bare run\nbabysitter run:assign-process .a5c/runs/run-20260125-143012 \\\n  --entry .a5c/processes/build/main.js#buildProcess \\\n  --process-id dev/build\n\n# Assign with JSON output\nbabysitter run:assign-process run-20260125-143012 \\\n  --entry .a5c/processes/tdd/main.js#tddProcess \\\n  --process-id tdd/feature \\\n  --json\n\n# Preview without applying\nbabysitter run:assign-process run-20260125-143012 \\\n  --entry .a5c/processes/build/main.js#buildProcess \\\n  --process-id dev/build \\\n  --dry-run --json\n\n# Force reassign a process to a run that already has one\nbabysitter run:assign-process run-20260125-143012 \\\n  --entry .a5c/processes/build/main.js#buildProcess \\\n  --process-id dev/build \\\n  --force --json\n\n# With process revision\nbabysitter run:assign-process run-20260125-143012 \\\n  --entry .a5c/processes/build/main.js#buildProcess \\\n  --process-id dev/build \\\n  --process-revision 2.1.0\n```\n\n---\n\n### run:status\n\nReturns the current status of a run.\n\n#### Synopsis\n\n```bash\nbabysitter run:status <runId> [--json]\n```\n\n#### Arguments\n\n| Argument | Required | Description |\n|----------|----------|-------------|\n| `<runId>` | Yes | Run ID or path to run directory |\n\n#### Output (Human)\n\n```\n[run:status] state=waiting last=EFFECT_REQUESTED#0042 2026-01-25T14:30:12.123Z pending[node]=2 pending[total]=2 stateVersion=42\n```\n\n#### Output (JSON)\n\n```json\n{\n  \"runId\": \"run-20260125-143012\",\n  \"state\": \"waiting\",\n  \"lastEvent\": \"EFFECT_REQUESTED#0042 2026-01-25T14:30:12.123Z\",\n  \"pendingByKind\": {\n    \"node\": 2\n  },\n  \"metadata\": {\n    \"processId\": \"dev/build\",\n    \"stateVersion\": 42,\n    \"pendingEffectsByKind\": {\n      \"node\": 2\n    }\n  },\n  \"completionProof\": \"...\" // Only present when state=completed\n}\n```\n\n#### State Values\n\n| State | Description |\n|-------|-------------|\n| `created` | Run initialized, not yet started |\n| `running` | Run in progress |\n| `waiting` | Blocked on breakpoint or sleep |\n| `completed` | Run finished successfully |\n| `failed` | Run terminated with error |\n\n#### Examples\n\n```bash\n# Check status\nbabysitter run:status run-20260125-143012\n\n# JSON output\nbabysitter run:status run-20260125-143012 --json\n\n# Using run directory path\nbabysitter run:status .a5c/runs/run-20260125-143012 --json\n```\n\n---\n\n### run:events\n\nLists journal events for a run.\n\n#### Synopsis\n\n```bash\nbabysitter run:events <runId> \\\n  [--limit <n>] \\\n  [--reverse] \\\n  [--filter-type <type>] \\\n  [--json]\n```\n\n#### Options\n\n| Option | Description | Default |\n|--------|-------------|---------|\n| `--limit <n>` | Maximum events to return | All |\n| `--reverse` | Show newest events first | `false` |\n| `--filter-type <type>` | Filter by event type | All types |\n\n#### Output (Human)\n\n```\n[run:events] count=42\n#0001 2026-01-25T14:30:12.123Z RUN_CREATED processId=dev/build\n#0002 2026-01-25T14:30:12.234Z EFFECT_REQUESTED effectId=effect-abc123\n#0003 2026-01-25T14:30:15.456Z EFFECT_RESOLVED effectId=effect-abc123\n...\n```\n\n#### Output (JSON)\n\n```json\n{\n  \"count\": 42,\n  \"events\": [\n    {\n      \"type\": \"RUN_CREATED\",\n      \"recordedAt\": \"2026-01-25T14:30:12.123Z\",\n      \"data\": {\n        \"processId\": \"dev/build\"\n      },\n      \"checksum\": \"a1b2c3...\"\n    }\n  ]\n}\n```\n\n#### Examples\n\n```bash\n# Show all events\nbabysitter run:events run-20260125-143012\n\n# Last 20 events (newest first)\nbabysitter run:events run-20260125-143012 --limit 20 --reverse\n\n# Filter by type\nbabysitter run:events run-20260125-143012 --filter-type EFFECT_RESOLVED --json\n```\n\n---\n\n### run:iterate\n\nExecutes a single orchestration iteration. This is the core command for driving runs.\n\n#### Synopsis\n\n```bash\nbabysitter run:iterate <runId> \\\n  [--iteration <n>] \\\n  [--json]\n```\n\n#### Options\n\n| Option | Description | Default |\n|--------|-------------|---------|\n| `--iteration <n>` | Iteration number (for logging) | 1 |\n\n#### Output (Human)\n\n```\n[run:iterate] iteration=1 status=executed action=executed-tasks count=3\n```\n\n#### Output (JSON)\n\n```json\n{\n  \"iteration\": 1,\n  \"status\": \"executed\",\n  \"action\": \"executed-tasks\",\n  \"reason\": \"auto-runnable-tasks\",\n  \"count\": 3,\n  \"metadata\": {\n    \"runId\": \"run-20260125-143012\",\n    \"processId\": \"dev/build\",\n    \"hookStatus\": \"executed\",\n    \"stateVersion\": 45\n  },\n  \"completionProof\": \"...\" // Only present when status=completed\n}\n```\n\n#### Status Values\n\n| Status | Description | Action |\n|--------|-------------|--------|\n| `executed` | Tasks were executed | Continue looping |\n| `waiting` | Breakpoint or sleep active | Pause, check periodically |\n| `completed` | Run finished successfully | Exit loop |\n| `failed` | Run encountered error | Exit loop, investigate |\n| `none` | No pending effects | May indicate completion |\n\n#### Examples\n\n```bash\n# Single iteration\nbabysitter run:iterate run-20260125-143012 --json\n\n# With iteration number\nbabysitter run:iterate run-20260125-143012 --iteration 5 --json\n\n# Orchestration loop pattern\nITERATION=0\nwhile true; do\n  ((ITERATION++))\n  RESULT=$(babysitter run:iterate \"$RUN_ID\" --json --iteration $ITERATION)\n  STATUS=$(echo \"$RESULT\" | jq -r '.status')\n\n  case \"$STATUS\" in\n    completed|failed) break ;;\n    waiting) sleep 5 ;;\n    *) continue ;;\n  esac\ndone\n```\n\n---\n\n### run:rebuild-state\n\nRebuilds the state cache from the journal.\n\n#### Synopsis\n\n```bash\nbabysitter run:rebuild-state <runId> [--json]\n```\n\n#### Description\n\nReplays the journal to reconstruct `state/state.json`. Useful when the state cache is missing, corrupted, or stale.\n\n#### Output (JSON)\n\n```json\n{\n  \"status\": \"rebuilt\",\n  \"reason\": \"missing-state-file\",\n  \"eventCount\": 42,\n  \"stateVersion\": 42\n}\n```\n\n#### Examples\n\n```bash\n# Rebuild state\nbabysitter run:rebuild-state run-20260125-143012\n\n# Check result\nbabysitter run:status run-20260125-143012 --json\n```\n\n---\n\n## Task Commands\n\n### task:list\n\nLists tasks in a run with their status.\n\n#### Synopsis\n\n```bash\nbabysitter task:list <runId> \\\n  [--pending] \\\n  [--kind <kind>] \\\n  [--json]\n```\n\n#### Options\n\n| Option | Description | Default |\n|--------|-------------|---------|\n| `--pending` | Show only pending (unresolved) tasks | All tasks |\n| `--kind <kind>` | Filter by task kind | All kinds |\n\n#### Output (Human)\n\n```\n[task:list] pending=2\n- ef-build-001 [node requested] build workspace (taskId=build.workspaces)\n- ef-lint-001 [node requested] lint sources (taskId=lint.sources)\n```\n\n#### Output (JSON)\n\n```json\n{\n  \"tasks\": [\n    {\n      \"effectId\": \"ef-build-001\",\n      \"status\": \"requested\",\n      \"kind\": \"node\",\n      \"label\": \"build workspace\",\n      \"taskId\": \"build.workspaces\",\n      \"taskDefRef\": \"tasks/ef-build-001/task.json\",\n      \"resultRef\": null,\n      \"stdoutRef\": null,\n      \"stderrRef\": null\n    }\n  ]\n}\n```\n\n#### Examples\n\n```bash\n# List all tasks\nbabysitter task:list run-20260125-143012\n\n# List pending tasks only\nbabysitter task:list run-20260125-143012 --pending --json\n\n# Filter by kind\nbabysitter task:list run-20260125-143012 --kind breakpoint\n```\n\n---\n\n### task:show\n\nShows detailed information about a specific task.\n\n#### Synopsis\n\n```bash\nbabysitter task:show <runId> <effectId> [--json]\n```\n\n#### Arguments\n\n| Argument | Required | Description |\n|----------|----------|-------------|\n| `<runId>` | Yes | Run ID |\n| `<effectId>` | Yes | Effect ID of the task |\n\n#### Output (JSON)\n\n```json\n{\n  \"effect\": {\n    \"effectId\": \"ef-build-001\",\n    \"taskId\": \"build.workspaces\",\n    \"status\": \"requested\",\n    \"kind\": \"node\",\n    \"stdoutRef\": null\n  },\n  \"task\": {\n    \"kind\": \"node\",\n    \"node\": {\n      \"entry\": \"build/scripts/build-workspace.mjs\",\n      \"args\": [\"--workspace\", \"frontend\"]\n    }\n  },\n  \"result\": null,\n  \"largeResult\": null\n}\n```\n\n#### Examples\n\n```bash\n# Show task details\nbabysitter task:show run-20260125-143012 ef-build-001 --json\n\n# Human readable\nbabysitter task:show run-20260125-143012 ef-build-001\n```\n\n---\n\n### task:post\n\nPosts a result for an executed task. This is how you commit external execution results into the run.\n\n#### Synopsis\n\n```bash\nbabysitter task:post <runId> <effectId> \\\n  --status <ok|error> \\\n  [--value <file>] \\\n  [--value-inline <json>] \\\n  [--error <file>] \\\n  [--stdout-ref <ref>] \\\n  [--stderr-ref <ref>] \\\n  [--stdout-file <file>] \\\n  [--stderr-file <file>] \\\n  [--started-at <iso8601>] \\\n  [--finished-at <iso8601>] \\\n  [--metadata <file>] \\\n  [--invocation-key <key>] \\\n  [--dry-run] \\\n  [--json]\n```\n\n#### Options\n\n| Option | Required | Description |\n|--------|----------|-------------|\n| `--status <ok\\|error>` | Yes | Task completion status |\n| `--value <file>` | No | Path to result value JSON (for status=ok) |\n| `--value-inline <json>` | No | Inline JSON result value (for status=ok, cannot be combined with `--value`) |\n| `--error <file>` | No | Path to error payload JSON (for status=error) |\n| `--stdout-ref <ref>` | No | Reference to stdout file |\n| `--stderr-ref <ref>` | No | Reference to stderr file |\n| `--stdout-file <file>` | No | Path to stdout file to copy |\n| `--stderr-file <file>` | No | Path to stderr file to copy |\n| `--started-at <iso8601>` | No | Task start timestamp |\n| `--finished-at <iso8601>` | No | Task end timestamp |\n| `--metadata <file>` | No | Path to additional metadata JSON |\n| `--invocation-key <key>` | No | Invocation key for the task |\n| `--dry-run` | No | Preview without committing |\n\n#### Output (JSON)\n\n```json\n{\n  \"status\": \"ok\",\n  \"committed\": {\n    \"resultRef\": \"tasks/ef-build-001/result.json\",\n    \"stdoutRef\": \"tasks/ef-build-001/stdout.log\",\n    \"stderrRef\": \"tasks/ef-build-001/stderr.log\"\n  },\n  \"stdoutRef\": \"tasks/ef-build-001/stdout.log\",\n  \"stderrRef\": \"tasks/ef-build-001/stderr.log\",\n  \"resultRef\": \"tasks/ef-build-001/result.json\"\n}\n```\n\n#### Important Notes\n\n1. **Do NOT write `result.json` directly** - The SDK owns this file\n2. Provide your result value either as a separate file (for example `output.json`) or inline JSON\n3. Pass the value via `--value <file>` or `--value-inline '<json>'`\n4. The CLI will create the proper `result.json` with metadata\n\n#### Examples\n\n```bash\n# Post successful result\necho '{\"score\": 85}' > tasks/ef-build-001/output.json\nbabysitter task:post run-20260125-143012 ef-build-001 \\\n  --status ok \\\n  --value tasks/ef-build-001/output.json \\\n  --json\n\n# Post successful result inline\nbabysitter task:post run-20260125-143012 ef-build-001 \\\n  --status ok \\\n  --value-inline '{\"approved\": true}' \\\n  --json\n\n# Post with stdout/stderr\nbabysitter task:post run-20260125-143012 ef-build-001 \\\n  --status ok \\\n  --value tasks/ef-build-001/output.json \\\n  --stdout-file tasks/ef-build-001/stdout.log \\\n  --stderr-file tasks/ef-build-001/stderr.log \\\n  --json\n\n# Post error\necho '{\"error\": \"Build failed\", \"exitCode\": 1}' > tasks/ef-build-001/error.json\nbabysitter task:post run-20260125-143012 ef-build-001 \\\n  --status error \\\n  --error tasks/ef-build-001/error.json \\\n  --json\n\n# Dry run (preview)\nbabysitter task:post run-20260125-143012 ef-build-001 \\\n  --status ok \\\n  --dry-run\n```\n\n---\n\n## Exit Codes\n\n| Code | Meaning |\n|------|---------|\n| `0` | Success |\n| `1` | Expected user error (bad args, missing run, validation failure) |\n| `2+` | Unexpected internal error |\n\n### Error Handling\n\nErrors include:\n- Command prefix\n- Resolved run directory\n- Descriptive message\n- Stack trace (with `--verbose`)\n\nExample error:\n```\n[run:events] unable to read run metadata at .a5c/runs/invalid-run\n```\n\n---\n\n## Output Formats\n\n### Human Format (Default)\n\nTerse, single-line output optimized for CI logs and human readability.\n\n```\n[run:status] state=waiting last=EFFECT_REQUESTED#0042 pending[node]=2\n```\n\n### JSON Format (`--json`)\n\nStructured JSON for programmatic parsing.\n\n```json\n{\n  \"state\": \"waiting\",\n  \"pendingByKind\": { \"node\": 2 }\n}\n```\n\n**JSON Conventions:**\n- Single JSON document (not streaming)\n- All timestamps are ISO 8601 strings\n- Numbers remain numeric\n- Paths use POSIX separators\n\n### Secret Handling\n\nTask payloads are never echoed by default. To see full payloads:\n\n```bash\nBABYSITTER_ALLOW_SECRET_LOGS=true babysitter task:show <runId> <effectId> --json --verbose\n```\n\n---\n\n## Examples\n\n### Complete Orchestration Flow\n\n```bash\n#!/bin/bash\nset -euo pipefail\n\nCLI=\"babysitter\"\nPROCESS_ID=\"tdd/feature\"\nENTRY=\".a5c/processes/tdd/main.js#tddProcess\"\n\n# 1. Create run\nRESULT=$($CLI run:create \\\n  --process-id \"$PROCESS_ID\" \\\n  --entry \"$ENTRY\" \\\n  --inputs inputs.json \\\n  --prompt \"Build feature with TDD\" \\\n  --json)\n\nRUN_ID=$(echo \"$RESULT\" | jq -r '.runId')\necho \"Created run: $RUN_ID\"\n\n# 2. Orchestration loop\nITERATION=0\nMAX_ITERATIONS=100\n\nwhile [ $ITERATION -lt $MAX_ITERATIONS ]; do\n  ((ITERATION++))\n  echo \"Iteration $ITERATION...\"\n\n  # Run iteration\n  RESULT=$($CLI run:iterate \"$RUN_ID\" --json --iteration $ITERATION)\n  STATUS=$(echo \"$RESULT\" | jq -r '.status')\n\n  echo \"Status: $STATUS\"\n\n  case \"$STATUS\" in\n    completed)\n      echo \"Run completed successfully!\"\n      break\n      ;;\n    failed)\n      echo \"Run failed!\"\n      exit 1\n      ;;\n    waiting)\n      echo \"Waiting for breakpoint...\"\n      sleep 10\n      ;;\n    executed|none)\n      continue\n      ;;\n  esac\ndone\n\n# 3. Final status\n$CLI run:status \"$RUN_ID\" --json\n```\n\n### Task Execution Pattern\n\n```bash\n#!/bin/bash\nRUN_ID=\"$1\"\n\n# Get pending tasks\nTASKS=$($CLI task:list \"$RUN_ID\" --pending --json)\nCOUNT=$(echo \"$TASKS\" | jq '.tasks | length')\n\necho \"Found $COUNT pending tasks\"\n\n# Process each task\necho \"$TASKS\" | jq -c '.tasks[]' | while read -r task; do\n  EFFECT_ID=$(echo \"$task\" | jq -r '.effectId')\n  KIND=$(echo \"$task\" | jq -r '.kind')\n\n  echo \"Processing: $EFFECT_ID ($KIND)\"\n\n  # Execute based on kind\n  case \"$KIND\" in\n    node)\n      # Execute node task...\n      node \"$(echo \"$task\" | jq -r '.task.node.entry')\"\n      ;;\n  esac\n\n  # Post result\n  echo '{\"success\": true}' > \"tasks/$EFFECT_ID/output.json\"\n  $CLI task:post \"$RUN_ID\" \"$EFFECT_ID\" \\\n    --status ok \\\n    --value \"tasks/$EFFECT_ID/output.json\" \\\n    --json\ndone\n```\n\n---\n\n## Quick Reference Card\n\n### Run Commands\n\n```bash\n# Create\nbabysitter run:create --process-id <id> --entry <path>#<export> [--prompt <text>] --json\n\n# Assign process to bare run\nbabysitter run:assign-process <runDir> --entry <path>#<export> [--process-id <id>] --json\n\n# Status\nbabysitter run:status <runId> --json\n\n# Iterate\nbabysitter run:iterate <runId> --json --iteration <n>\n\n# Events\nbabysitter run:events <runId> --limit 20 --reverse\n\n# Rebuild state\nbabysitter run:rebuild-state <runId>\n```\n\n### Task Commands\n\n```bash\n# List pending\nbabysitter task:list <runId> --pending --json\n\n# Show details\nbabysitter task:show <runId> <effectId> --json\n\n# Post result\nbabysitter task:post <runId> <effectId> --status ok --value <file> --json\n```\n\n---\n\n---\n\n## Breakpoint Rule Commands\n\nCommands for managing breakpoint auto-approval rules. Rules are stored at `~/.a5c/breakpoint-approvals/rules.json`.\n\n### breakpoint:approve-rule\n\nAdd or update an auto-approval rule.\n\n```bash\nbabysitter breakpoint:approve-rule <pattern> [--action auto-approve|never-auto-approve] [--source <source>] [--note <note>] [--json]\n```\n\n| Argument/Flag | Required | Description |\n|---------------|----------|-------------|\n| `<pattern>` | Yes | Pattern to match breakpointIds. Supports glob (`confirm.*`) and attribute predicates (`*.review(tags contains 'design')`). |\n| `--action` | No | Rule action: `auto-approve` (default) or `never-auto-approve`. |\n| `--source` | No | Who created the rule (e.g., `cli`, `agent`, `analyze-history`). |\n| `--note` | No | Human-readable note about why this rule exists. |\n| `--json` | No | Emit JSON output. |\n\n### breakpoint:remove-rule\n\nRemove an auto-approval rule by ID.\n\n```bash\nbabysitter breakpoint:remove-rule <ruleId> [--json]\n```\n\n### breakpoint:list-rules\n\nList all configured auto-approval rules.\n\n```bash\nbabysitter breakpoint:list-rules [--json]\n```\n\n### breakpoint:should-auto-approve\n\nCheck whether a breakpoint should be auto-approved given current rules.\n\n```bash\nbabysitter breakpoint:should-auto-approve <breakpointId> [--tags <csv>] [--expert <expert>] [--json]\n```\n\n| Flag | Description |\n|------|-------------|\n| `--tags` | Comma-separated list of tags to evaluate against rules. |\n| `--expert` | Expert identifier to evaluate against rules. |\n\n### breakpoint:history\n\nView breakpoint approval history from run journals.\n\n```bash\nbabysitter breakpoint:history [--breakpoint-id <id>] [--runs-dir <dir>] [--limit <n>] [--json]\n```\n\n| Flag | Description |\n|------|-------------|\n| `--breakpoint-id` | Filter history to a specific breakpointId. |\n| `--runs-dir` | Override runs directory (default: `.a5c/runs`). |\n| `--limit` | Maximum number of entries to display (default: 50). |\n\n---\n\n## Related Documentation\n\n- [Breakpoints Feature Guide](../features/breakpoints.md) - Breakpoint usage, auto-approval rules, and patterns\n- [Glossary](./glossary.md) - Term definitions\n- [Configuration Reference](./configuration.md) - Environment variables and settings\n- [Troubleshooting](./troubleshooting.md) - Common issues and solutions\n",
    "documents": []
  },
  "outgoingEdges": [],
  "incomingEdges": []
}

Shortcuts

Back to overview
Open graph tab