> ## Documentation Index
> Fetch the complete documentation index at: https://opensre.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Shell commands

> Slash commands in the OpenSRE interactive shell — usage detail for each command.

Start the shell with `opensre` (needs a real terminal). Type a `/command`, or describe what you want in plain language.

```bash theme={null}
opensre
/help
```

Type `/` to open the command tray attached to the input. Browse with the arrow
keys and press Enter to run the highlighted suggestion, or Tab to complete it
and edit before running. Esc closes the tray
without clearing your draft or stopping running work. On narrow terminals, the
highlighted command's description appears below the list.

<Info>
  Confirmation prompts come from **`/auto`** (tool-approval autonomy) and from
  elevated slash commands. Default `/auto` is **high** (alpha: no tool prompts).
  `/trust on` skips approval prompts for the rest of the session. Outside a TTY,
  actions that would ask are blocked.
</Info>

## How the REPL works

| Input type                           | What happens                                                                      |
| ------------------------------------ | --------------------------------------------------------------------------------- |
| Slash command (`/status`)            | Routed through the action agent and executed via `slash_invoke`                   |
| Plain language (`verify datadog`)    | Routed by the action agent to slash commands, tool calls, or doc-grounded answers |
| Pasted alert JSON/text               | The agent triages it in chat, calling integration tools as needed                 |
| Shell one-liner (`kubectl get pods`) | Executed through shell policy when the action agent selects a shell action        |

**TTY vs non-TTY:** Interactive menus, confirmations, and onboarding wizards need a real terminal. Piping input or running in CI is non-interactive — prefer explicit CLI commands outside the REPL for automation.

**Unknown commands:** Typos suggest the closest registered command (`Did you mean /integrations?`). Run `/help` for the authoritative list — it always matches your installed OpenSRE version.

**Keyboard shortcuts:**

| Key                        | Effect                                                                                                       |
| -------------------------- | ------------------------------------------------------------------------------------------------------------ |
| **Up/Down**                | Browse suggestions while the command tray is open; otherwise recall persisted command history (when enabled) |
| **Tab**                    | Complete the highlighted suggestion                                                                          |
| **Enter**                  | Run the highlighted suggestion, or submit the draft when the tray is closed                                  |
| **Esc**                    | Close the command tray first; otherwise stop running work or clear the draft                                 |
| **Ctrl+C** once            | Cancel in-flight streaming work or interrupt the current prompt                                              |
| **Ctrl+C** twice within 2s | Exit the REPL (prints `/resume` hint)                                                                        |
| **Ctrl+D**                 | Exit when the prompt is empty (same resume hint as `/exit`)                                                  |

Every launch asks which demo to run: **A** repository CI/CD analysis
(recommended), **B** a recurring CI/CD reliability agent, **C** remote CI/CD
repairs, **D** Slack setup, **E** skip the demo and open the shell.
Escape also skips it. Run `opensre --skip-onboarding` to open the shell without
the picker. Type `/demo` to start it later. See
[CI/CD analytics demo](/docs/cicd/cicd-analytics-demo).

The banner and prompt show **CI/CD fixes**: distinct GitHub repairs whose pushed
checks passed, including merge-conflict repairs. A repair can count before it is
merged; check the target branch before assuming it is green. Fixes in this shell
update the prompt immediately. Use `/clear` to pick up fixes saved by another
OpenSRE process in the same deployment. Zero also covers an unavailable count;
the total is best-effort and can decrease after restarting if a save failed.

## Quick reference

### Help and exit

| Command | What it does                                                                            |
| ------- | --------------------------------------------------------------------------------------- |
| `/help` | List commands or show help for one command or category                                  |
| `/?`    | Shortcut for `/help`                                                                    |
| `/exit` | Leave the interactive shell                                                             |
| `/quit` | Alias for `/exit`                                                                       |
| `/demo` | Open the guided demo picker (CI/CD analysis, reliability agent, managed service, Slack) |

### Session

| Command                | What it does                                                                                    |
| ---------------------- | ----------------------------------------------------------------------------------------------- |
| `/status`              | Session summary — interactions, alerts, provider, effort, trust mode                            |
| `/cost`                | Token usage and LLM call count for the current session                                          |
| `/context`             | Infra metadata accumulated during the session                                                   |
| `/effort`              | Set or show reasoning effort (`low` … `max`)                                                    |
| `/auto`                | Tool-approval autonomy (`off` / `low` / `med` / `high`; default `high`)                         |
| `/trust`               | Enable or disable trust mode (skip confirmation prompts)                                        |
| `/verbose`             | Toggle verbose logging                                                                          |
| `/clear`               | Clear the screen and re-render the banner                                                       |
| `/compact`             | Summarize older context into a replayable compaction entry                                      |
| `/sessions`            | List recent REPL sessions on disk                                                               |
| `/resume <id>`         | Restore a past session's conversation context                                                   |
| `/resume <id>:<entry>` | Restore a specific session branch point                                                         |
| `/new`                 | Start a new session file while keeping LLM context                                              |
| `/goal`                | Set a finish line and keep working toward it across turns — see [Goals](/docs/getting-started/goals) |

### Integrations, models, and tools

| Command         | What it does                                         |
| --------------- | ---------------------------------------------------- |
| `/health`       | Integration and agent health check                   |
| `/verify`       | Verify integration connectivity (all or one service) |
| `/integrations` | List, verify, show, setup, or remove integrations    |
| `/mcp`          | List, connect, or disconnect MCP servers             |
| `/model`        | Show the account-managed hosted model                |
| `/tools`        | List registered chat and action tools                |

### Privacy and history

| Command    | What it does                                            |
| ---------- | ------------------------------------------------------- |
| `/history` | Show or manage persisted command history                |
| `/privacy` | History persistence, redaction status, and threat model |
| `/memory`  | List and manage the agent's long-term memory            |

### Tasks and background work

| Command        | What it does                                             |
| -------------- | -------------------------------------------------------- |
| `/loops`       | List, create, run once, and debug recurring prompt loops |
| `/tasks`       | List recent and in-flight background tasks               |
| `/work`        | List, add, complete, and prioritize human work items     |
| `/cancel <id>` | Cancel a running task by id **elevated**                 |
| `/stop`        | Guidance for stopping background work                    |
| `/gateway`     | Start, stop, or inspect the background gateway daemon    |

### Agents and alerts

| Command   | What it does                                      |
| --------- | ------------------------------------------------- |
| `/fleet`  | View and manage the local AI agent fleet          |
| `/alerts` | Alert listener inbox status                       |
| `/choose` | Reopen the selection menu the agent is waiting on |

### CLI parity

These commands delegate to the same Click CLI you would run outside the REPL.

| Command        | What it does                                                                                                                                |
| -------------- | ------------------------------------------------------------------------------------------------------------------------------------------- |
| `/account`     | Sign in to OpenSRE, inspect the local account, or sign out                                                                                  |
| `/credits`     | Remaining hosted credits for the signed-in account (same as `opensre credits`)                                                              |
| `/setup`       | First-run setup: account sign-in, hosted model, then the shell (same as `opensre setup`)                                                    |
| `/auth`        | Log in to LLM providers, show provider auth status, or clear credentials                                                                    |
| `/login`       | Shortcut for `/auth login` (`/login openai`, `/login anthropic`, `/login deepseek`)                                                         |
| `/onboard`     | Interactive onboarding wizard                                                                                                               |
| `/remote`      | Connect to and operate remote deployed agents                                                                                               |
| `/remote-sync` | Manage remote sync to your object store. Subcommands: `status`, `sync`, `setup`. See [Sync to your own object store](/docs/install/remote-sync). |
| `/config`      | Show or edit `~/.opensre/config.yml`                                                                                                        |
| `/cron`        | Manage scheduled delivery jobs                                                                                                              |
| `/sentry`      | Schedule automated Sentry morning digests or uptime watches (Telegram or Slack required)                                                    |
| `/messaging`   | Telegram pairing and allowlist                                                                                                              |
| `/guardrails`  | Sensitive-information guardrail rules                                                                                                       |
| `/update`      | Check for updates and upgrade OpenSRE                                                                                                       |
| `/posthog`     | Run or schedule PostHog per-metric summary reports                                                                                          |
| `/runbooks`    | Manage trusted runbook sources for guided investigations                                                                                    |
| `/debug`       | Targeted runtime diagnostics                                                                                                                |
| `/uninstall`   | Remove OpenSRE and local data **elevated**                                                                                                  |

### System

| Command    | What it does                              |
| ---------- | ----------------------------------------- |
| `/doctor`  | Full local environment diagnostic         |
| `/version` | OpenSRE, Python, and OS versions          |
| `/theme`   | Choose and persist the shell colour theme |

### Commands with interactive menus (TTY)

Bare invocation opens a picker or submenu:

| Command              | Menu behavior                                      |
| -------------------- | -------------------------------------------------- |
| `/help`              | Browse categories; Enter runs the selected command |
| `/integrations`      | list / verify / show / setup / remove              |
| `/mcp`               | list / connect / disconnect                        |
| `/model`             | show / set / restore / toolcall                    |
| `/theme`             | Pick a colour theme from the installed list        |
| `/choose`            | Reopen the selection menu the agent queued         |
| `/trust`, `/verbose` | on / off                                           |
| `/history`           | show / clear / off / on / retention                |
| `/resume`            | Numbered list of recent sessions                   |

`/model` keeps its menu running: picking `show` prints the current models and
hands you back to the menu, so leave it with **done** or Esc.

## Commands

### Help

<AccordionGroup>
  <Accordion title="/help">
    ```text theme={null}
    /help
    /help /model
    /help tasks
    /help all
    ```

    | Form                     | Result                                                |
    | ------------------------ | ----------------------------------------------------- |
    | `/help`                  | Interactive picker in a TTY; category index otherwise |
    | `/help &lt;command&gt;`  | Detailed usage for one command (e.g. `/help /model`)  |
    | `/help &lt;category&gt;` | All commands in a section (`session`, `tasks`, …)     |
    | `/help all`              | Full command index                                    |

    Help categories mirror the REPL grouping: Quick Access, Session, Integrations/Models/Tools, Privacy, Tasks, Agents, Alerts, CLI parity, and System.

    **Quick Access** duplicates frequently used commands (`/integrations`, `/model`, `/health`, `/status`, `/help`) for faster discovery in the picker.
  </Accordion>

  <Accordion title="/?">
    Shortcut for `/help`. Same forms and picker behavior.
  </Accordion>
</AccordionGroup>

### Session

<AccordionGroup>
  <Accordion title="/status">
    Shows a snapshot of the **current** REPL session:

    ```text theme={null}
    /status
    ```

    Typical fields:

    | Field                 | Meaning                                                                    |
    | --------------------- | -------------------------------------------------------------------------- |
    | `interactions`        | Count of recorded turns (chat, slash, alerts)                              |
    | `incoming alerts`     | Alerts received by the local listener this session, plus age of the latest |
    | `trust mode`          | `on` / `off`                                                               |
    | `reasoning effort`    | Current `/effort` level (OpenAI/Codex only)                                |
    | `provider`            | Active `LLM_PROVIDER`                                                      |
    | `grounding … cache`   | Doc/source cache stats used for help answers                               |
    | `accumulated context` | Comma-separated keys from prior turns (e.g. `service`, `cluster`)          |

    Use `/status` for **session** state. Use `/health` for **integration connectivity**.
  </Accordion>

  <Accordion title="/cost">
    Shows LLM usage tracked **locally** for the current REPL session. This is not cloud-provider billing and does not read your vendor invoice.

    ```text theme={null}
    /cost
    ```

    Example output (measured + estimated mix):

    ```text theme={null}
      Session cost (includes estimates)

      history entries     12
      llm calls           8
      input tokens        4,210 (measured: 1,200 · estimated: 3,010)
      output tokens       890 (estimated: 890)
    ```

    | Field                            | Meaning                                               |
    | -------------------------------- | ----------------------------------------------------- |
    | `history entries`                | Lines recorded in this session's in-memory history    |
    | `llm calls`                      | LLM turns counted (planner + chat + help + follow-up) |
    | `input tokens` / `output tokens` | Running totals for prompt and completion usage        |

    **Measured vs estimated:**

    | Code path                             | Token source                                               |
    | ------------------------------------- | ---------------------------------------------------------- |
    | Planner `invoke()` (action selection) | Provider usage metadata when the API returns it            |
    | Streaming chat, help, follow-up       | Estimated from character length (\~4 characters per token) |

    When any estimate is included, the table title notes `(includes estimates)` and rows show measured vs estimated splits.

    **What increments the counter:** Normal LLM chat turns and planner calls. **What does not:** Non-LLM command handling such as history recall or prompt rendering.

    Token totals reset on `/new` or when session identity is rotated. They do **not** carry across `/resume`. See [Session History](/docs/platform/sessions).
  </Accordion>

  <Accordion title="/context">
    Displays key/value infra metadata collected during chat — typically `service`, `cluster`, `region`, or similar fields extracted from alert text and tool results.

    ```text theme={null}
    /context
    ```

    Context is **inherited** across turns in the same session (and restored by `/resume`), so the agent does not re-ask for environment details you already established.
  </Accordion>

  <Accordion title="/effort">
    Set reasoning depth for **OpenAI and Codex** providers in this REPL session only.

    ```text theme={null}
    /effort high
    /effort
    ```

    | Level          | When to use                                                                                     |
    | -------------- | ----------------------------------------------------------------------------------------------- |
    | `low`          | Fast triage, simple lookups, lower token cost                                                   |
    | `medium`       | Default balance for most incident work                                                          |
    | `high`         | Deeper analysis when latency is acceptable                                                      |
    | `xhigh`, `max` | Maximum reasoning; best with newer GPT-5 or Codex models — older models may reject these levels |

    Bare `/effort` prints the current level, the config default for your provider/model, and supported choices. `/status` includes the same field.

    Other providers (Anthropic, Ollama, etc.) ignore `/effort`; the shell prints a hint suggesting `/model set openai` or `/model set codex`. Set `OPENSRE_REASONING_EFFORT` in the environment for non-interactive defaults. See [LLM providers](/docs/platform/llm-providers).
  </Accordion>

  <Accordion title="/auto">
    Set how often the REPL asks before running agent tools. Shown on the status line as `Auto (Med) · …`.

    ```text theme={null}
    /auto
    /auto med
    /auto high
    ```

    | Level            | Prompts before                                                                                                |
    | ---------------- | ------------------------------------------------------------------------------------------------------------- |
    | `high` (default) | Nothing — alpha default; every tool runs immediately                                                          |
    | `med`            | Mutating agent tools: shell, code agent, slash/CLI, synthetic tests, LLM provider switch, Sentry issue fix, … |
    | `low`            | Everything `med` asks about, plus additional tool starts                                                      |
    | `off`            | Every tool type                                                                                               |

    `/auto` is **not** a shell-command allowlist: under alpha, shell strings still run when approved (or when High skips the prompt). Lower levels only promote the existing `ask` confirmation hook by `tool_type`.

    **With `/trust`:** `/trust on` skips approval prompts even when `/auto` would ask. Turn trust off to restore `/auto` prompts.

    Session preference only — not restored by `/resume`. Bare `/auto` prints the current level, the default, and each caption.
  </Accordion>

  <Accordion title="/trust">
    Trust mode skips execution confirmation prompts for **elevated** commands (`/cancel`, `/uninstall`, integration remove, etc.).

    ```text theme={null}
    /trust on
    /trust off
    /trust
    ```

    In a TTY, bare `/trust` opens an interactive on/off menu. Trust mode is a **session preference** — it is not restored by `/resume`.
  </Accordion>

  <Accordion title="/verbose">
    Toggle `TRACER_VERBOSE` logging for the REPL process (deeper internal logs to stderr). Also shows the per-turn tool-call log above each reply; by default it is hidden and only reachable with `Ctrl+O`.

    ```text theme={null}
    /verbose on
    /verbose off
    /verbose
    ```
  </Accordion>

  <Accordion title="/clear">
    Clears the terminal and re-renders the OpenSRE banner. Does **not** reset session state, token usage, LLM conversation context, or accumulated infra context.

    ```text theme={null}
    /clear
    ```
  </Accordion>

  <Accordion title="/compact">
    Summarizes older conversation context, keeps recent messages, and persists a `compaction` entry in the session file. Future `/resume` calls replay the summary before the kept messages.

    ```text theme={null}
    /compact
    ```

    If there are not enough messages to compact, the command reports nothing to compact. OpenSRE also compacts automatically before a shell turn when the replayed branch context exceeds the runtime threshold.
  </Accordion>

  <Accordion title="/sessions">
    List up to **20** recent sessions stored on disk, newest first:

    ```text theme={null}
    /sessions
    ```

    ```text theme={null}
      Recent sessions

       #  Session ID  Name                           Started            Duration  Turns
       ───────────────────────────────────────────────────────────────────────────────
       1  3f8a1c2d    (current)                      Jun 17 10:00       42m       8
       2  9b2e4f7a    why is CPU spiking on prod-api Jun 16 14:30       1h 5m    15
    ```

    | Column       | Meaning                                                      |
    | ------------ | ------------------------------------------------------------ |
    | `Session ID` | First 8 characters of the UUID (enough for `/resume`)        |
    | `Name`       | Derived from the first user message or resumed session label |
    | `Turns`      | Total chat + slash + alert turns recorded                    |

    The current row updates **duration** live. Sessions with no name show `(current)` or `↩ &lt;resumed-from&gt;` when applicable.
  </Accordion>

  <Accordion title="/resume">
    Restore LLM conversation context and accumulated infra context from a previous session.

    ```text theme={null}
    /resume 9b2e4f7a
    /resume 9b2e4f7a:abc123
    /resume redis
    /resume
    ```

    | Form              | Behavior                                                                        |
    | ----------------- | ------------------------------------------------------------------------------- |
    | ID prefix         | Match session UUID by prefix (must be unique)                                   |
    | ID + entry prefix | Replay the branch ending at the matching entry ID prefix                        |
    | Name substring    | Match when ≥3 characters and exactly one session matches (e.g. `/resume redis`) |
    | Bare `/resume`    | Interactive numbered picker of recent sessions (TTY)                            |

    **Current session:** If the ID prefix matches the session you are already in, `/resume` is a no-op — OpenSRE prints a hint to pick a previous session from `/sessions`.

    When you resume a **different** session, OpenSRE:

    1. Switches the active session file to the target session
    2. Restores `cli_agent_messages` so the assistant remembers prior turns
    3. Restores `accumulated_context` keys
    4. Reprints conversation history (user prompts, assistant replies, slash commands)

    Compaction entries are replayed as summary messages before the kept branch messages.

    **Restored vs not restored:**

    |                                | `/resume`                                            |
    | ------------------------------ | ---------------------------------------------------- |
    | Conversation context           | Yes                                                  |
    | Infra context keys             | Yes                                                  |
    | Trust mode, reasoning effort   | No — per-session preferences                         |
    | Token usage / `/cost` counters | No — fresh counters for the resumed session identity |
    | In-memory history count        | Yes — turn stubs from the saved session              |

    **Warning:** Resuming a different session replaces the current session's LLM context if messages already exist.

    Session replay reads the current version-2 session tree format. Older session files are ignored by `/sessions` and `/resume`. See [Session History](/docs/platform/sessions).
  </Accordion>

  <Accordion title="/new">
    Rotate to a **new session file** while keeping the current LLM conversation thread and accumulated context.

    ```text theme={null}
    /new
    ```

    ```text theme={null}
    new session started — conversation context carried forward.
      14 messages in context · type to continue
    ```

    | Command   | Session file   | LLM context          | Token counters         |
    | --------- | -------------- | -------------------- | ---------------------- |
    | `/clear`  | Same           | Kept                 | Kept                   |
    | `/new`    | New UUID       | Kept                 | Reset                  |
    | `/resume` | Target session | Replaced with target | Reset for that session |

    Use `/new` after a long `/resume` so `/sessions` stays tidy without losing your place in the conversation.
  </Accordion>

  <Accordion title="/goal">
    Set a finish line and keep working toward it across turns:

    ```text theme={null}
    /goal
    /goal set How many Windows users signed up last week?
    /goal set --max-turns 4 Prefer live PostHog if connected
    /goal pause
    /goal resume
    /goal edit <updated condition>
    /goal clear
    ```

    Bare `/goal` shows the current goal. `/goal set` starts work immediately.
    See [Goals](/docs/getting-started/goals) for the full workflow.
  </Accordion>
</AccordionGroup>

### Integrations, models, and tools

<AccordionGroup>
  <Accordion title="Choosing the right diagnostic command">
    | Question                                      | Command                                                        |
    | --------------------------------------------- | -------------------------------------------------------------- |
    | Are my integrations configured and reachable? | `/verify`, `/health`, or `/integrations verify`                |
    | Verify one integration by name?               | `/verify datadog` or `/integrations verify datadog`            |
    | Show one integration's credentials/endpoints? | `/integrations show datadog`                                   |
    | Is Python/Docker/venv OK on this machine?     | `/doctor`                                                      |
    | What integrations exist in OpenSRE generally? | Ask in plain language (docs answer) — not `/integrations list` |
  </Accordion>

  <Accordion title="/health">
    Read-only pass/fail report for the local OpenSRE agent, LLM connectivity, and each configured integration.

    ```text theme={null}
    /health
    ```

    Runs live verification against the integration store. Use before incidents to confirm Datadog/Grafana/K8s credentials still work. For integration-only checks without the full agent/LLM report, prefer `/verify`.
  </Accordion>

  <Accordion title="/verify">
    Shortcut for integration connectivity checks (same as `opensre integrations verify` / `make verify-integrations`).

    ```text theme={null}
    /verify
    /verify datadog
    /verify telegram
    ```

    | Form                      | Behavior                                                                                                     |
    | ------------------------- | ------------------------------------------------------------------------------------------------------------ |
    | Bare `/verify`            | Verify all integrations; prints status table plus `all integrations ok` or `N integration(s) need attention` |
    | `/verify &lt;service&gt;` | Verify one named integration                                                                                 |
  </Accordion>

  <Accordion title="/integrations">
    ```text theme={null}
    /integrations
    /integrations list
    /integrations verify
    /integrations verify datadog
    /integrations show datadog
    /integrations setup datadog
    /integrations remove datadog
    ```

    | Subcommand               | Behavior                                                       |
    | ------------------------ | -------------------------------------------------------------- |
    | `list` (default)         | Verify all configured integrations and render status table     |
    | `verify`                 | Verify all integrations; prints summary line                   |
    | `verify &lt;service&gt;` | Verify one integration (same as `/verify &lt;service&gt;`)     |
    | `show &lt;service&gt;`   | Verify one service and print key/value config (masked secrets) |
    | `setup &lt;service&gt;`  | Launch setup wizard via CLI subprocess                         |
    | `remove &lt;service&gt;` | Remove from local store **elevated**                           |

    Bare `/integrations` opens an interactive menu in a TTY with service pickers for show/remove.
  </Accordion>

  <Accordion title="/mcp">
    MCP-capable integrations only (subset of the full integration catalog).

    ```text theme={null}
    /mcp list
    /mcp connect github
    /mcp disconnect github
    ```

    | Subcommand                  | Maps to                                         |
    | --------------------------- | ----------------------------------------------- |
    | `list`                      | Table of MCP servers from verified integrations |
    | `connect &lt;server&gt;`    | `opensre integrations setup &lt;server&gt;`     |
    | `disconnect &lt;server&gt;` | `opensre integrations remove &lt;server&gt;`    |
  </Accordion>

  <Accordion title="/model">
    Show the active hosted model. An authenticated interactive shell is account-managed, so local provider/model changes are locked until sign-out; signing out closes the shell.

    ```text theme={null}
    /model show
    /model set openai gpt-4.1
    /model set anthropic claude-sonnet-4-20250514 --toolcall-model claude-sonnet-4-20250514
    /model set claude-sonnet-4-20250514
    /model restore
    /model restore anthropic
    /model toolcall set gpt-4.1-mini
    /model
    ```

    | Subcommand                                                  | Behavior                                                  |
    | ----------------------------------------------------------- | --------------------------------------------------------- |
    | `show` (default)                                            | Show provider and reasoning/toolcall model slots          |
    | `set &lt;provider&gt; [model] [--toolcall-model &lt;m&gt;]` | Refuse the local change while the account route is active |
    | `set &lt;model&gt;` (no provider)                           | Refuse the local change while the account route is active |
    | `restore [provider]`                                        | Refuse the local change while the account route is active |
    | `toolcall set &lt;model&gt;`                                | Refuse the local change while the account route is active |

    **Account lock:** `set`, `restore`, and `toolcall set` explain that the model is managed by the OpenSRE account and make no change. The account route overrides local provider variables for every model role while the session is signed in.

    **Bare `/model`:** in a terminal this opens a menu rather than printing the table. The menu stays open: `show` prints the current models and hands you back to it, so leave with **done** or Esc. `set`, `restore` and `toolcall` close it once the change succeeds. Use `/model show` when you only want the table.

    **Reasoning vs toolcall model:** Reasoning model drives chat and planning; toolcall model drives tool invocation when the provider exposes a separate slot (common on Anthropic/OpenAI).

    See [LLM providers](/docs/platform/llm-providers).
  </Accordion>

  <Accordion title="/tools">
    List tools available to the chat and action surfaces in this build (name, source, surfaces).

    ```text theme={null}
    /tools
    /tools list
    ```

    There is no global `/list` command — use domain-specific list commands (see [Natural language actions](#natural-language-actions)).

    ***
  </Accordion>
</AccordionGroup>

### Privacy and history

Command **history** (up-arrow recall) is separate from **session** history (`/sessions`). Full redaction patterns and env vars: [Interactive Shell Privacy](/docs/platform/interactive-shell-privacy).

<AccordionGroup>
  <Accordion title="/history">
    ```text theme={null}
    /history
    /history clear
    /history off
    /history on
    /history retention 1000
    ```

    | Subcommand            | Behavior                                                                      |
    | --------------------- | ----------------------------------------------------------------------------- |
    | (none)                | Numbered list of persisted prompt lines                                       |
    | `clear`               | Delete `~/.opensre/interactive_history`; up-arrow recall empty on next launch |
    | `off`                 | Pause disk writes for this session (in-memory recall still works)             |
    | `on`                  | Resume persistence                                                            |
    | `retention &lt;N&gt;` | Cap file entries; prunes immediately (requires redacting backend)             |

    Bare `/history` opens an interactive menu in a TTY (presets: 100, 500, 1000, 5000 for retention).

    <Warning>
      Redaction applies to the **history file**, not necessarily to what is sent to the LLM. Treat shared machines accordingly — run `/history clear` after sensitive sessions.
    </Warning>
  </Accordion>

  <Accordion title="/privacy">
    ```text theme={null}
    /privacy
    ```

    Shows persistence on/off, redaction on/off, retention cap, history file path, built-in pattern count, and a short threat-model reminder (unencrypted local disk).

    ***
  </Accordion>
</AccordionGroup>

### Tasks and background

Long-running work is tracked in a per-session task registry surfaced by `/tasks`.
Human todos and reminders are tracked separately by `/work`.

<AccordionGroup>
  <Accordion title="Task kinds">
    | Kind          | Source                              |
    | ------------- | ----------------------------------- |
    | `cli_command` | Delegated CLI subprocesses          |
    | `code_agent`  | Code-agent integrations (when used) |
  </Accordion>

  <Accordion title="Task statuses">
    | Status      | Meaning                         |
    | ----------- | ------------------------------- |
    | `running`   | In progress; `/cancel` eligible |
    | `completed` | Finished successfully           |
    | `cancelled` | User or `/cancel` stopped it    |
    | `failed`    | Non-zero exit or pipeline error |
    | `pending`   | Created but not yet started     |
  </Accordion>

  <Accordion title="/gateway">
    Control the background OpenSRE gateway daemon, which runs the web health app, Telegram chat, and the task scheduler. Scheduled work needs a scheduler running: this daemon, or `opensre cron start` in the foreground.

    ```text theme={null}
    /gateway
    /gateway start
    /gateway stop
    /gateway status
    /gateway logs
    /gateway logs 100
    ```

    | Subcommand         | Behavior                                         |
    | ------------------ | ------------------------------------------------ |
    | `status` (default) | Running state and pid, plus a line per component |
    | `start`            | Start the daemon in the background               |
    | `stop`             | Stop the running daemon                          |
    | `logs [lines]`     | Tail the log, 30 lines by default                |

    Logs are written to `~/.opensre/gateway/gateway.log`. Same daemon as `opensre gateway`.
  </Accordion>

  <Accordion title="/tasks">
    ```text theme={null}
    /tasks
    ```

    Example:

    ```text theme={null}
      Tasks

      id      kind           status     started (UTC)     duration  detail
      def34   cli_command    completed  2026-06-17 09:55  120.0s    opensre health
    ```

    Shows up to **50** recent tasks, newest first. Use the **id** column (short prefix) with `/cancel`.
  </Accordion>

  <Accordion title="/work">
    ```text theme={null}
    /work
    /work add &lt;title&gt;
    /work done &lt;id-or-title&gt;
    /work next
    /work path
    ```

    `/work add` creates durable human todos; it does not schedule reminder delivery.
    For reminders, use the destination-aware `opensre work add` command with
    `--remind-at` and `--target provider:chat-id`, or ask from a connected chat whose
    destination OpenSRE can reuse. These work items are separate from `/tasks`
    (runtime jobs). See [Work Management](/docs/platform/work-management).

    You can also ask naturally:

    ```text theme={null}
    Add task "finish Slack reminder smoke test" for the hackathon, priority high.
    What should I focus on next?
    ```
  </Accordion>

  <Accordion title="/cancel">
    ```text theme={null}
    /cancel abc12
    ```

    * Matches task id by **prefix** (must be unique among active/recent tasks)
    * Only **running** tasks accept cancellation
  </Accordion>

  <Accordion title="/stop">
    Prints guidance only — does not kill processes:

    ```text theme={null}
    /stop
    ```

    | Situation           | Action                          |
    | ------------------- | ------------------------------- |
    | Streaming turn      | **Ctrl+C**                      |
    | Background CLI task | `/tasks` → `/cancel &lt;id&gt;` |
  </Accordion>
</AccordionGroup>

### Agents and alerts

Fleet coordination is documented further on [Agents](/docs/platform/fleet). Register discovered agents with `opensre fleet scan --register` before `/fleet trace` targets them.

<AccordionGroup>
  <Accordion title="/fleet">
    ```text theme={null}
    /fleet
    /fleet budget
    /fleet budget cursor-agent 5.00
    /fleet bus
    /fleet claim feature-x my-agent
    /fleet release feature-x
    /fleet conflicts
    /fleet kill 12345
    /fleet kill 12345 --force
    /fleet trace 12345
    /fleet wait 12345 --on 67890
    /fleet graph
    ```

    | Subcommand                                | Behavior                                                                                                                          |
    | ----------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
    | (none)                                    | Dashboard: registered + discovered agents (Cursor, Claude Code, Codex, Aider, …) with pid, uptime, CPU, tokens/min, \$/hr, status |
    | `budget`                                  | View hourly budgets from `~/.opensre/agents.yaml`                                                                                 |
    | `budget &lt;agent&gt; &lt;usd&gt;`        | Set `hourly_budget_usd` for one agent                                                                                             |
    | `bus`                                     | Live-tail cross-agent context bus until Ctrl+C                                                                                    |
    | `claim &lt;branch&gt; &lt;agent&gt;`      | Exclusive branch claim (agent must be in registry)                                                                                |
    | `release &lt;branch&gt;`                  | Release a claim                                                                                                                   |
    | `conflicts`                               | File-write conflict report between agents                                                                                         |
    | `kill &lt;pid&gt; [--force]`              | SIGTERM → wait → SIGKILL **elevated**; refuses self-PID                                                                           |
    | `trace &lt;pid&gt;`                       | Live stdout tail of agent process                                                                                                 |
    | `wait &lt;pid&gt; --on &lt;other-pid&gt;` | Record wait dependency for graph                                                                                                  |
    | `graph`                                   | Tree of wait-on relationships                                                                                                     |

    **Kill confirmation:** Without `--force`, prompts `[y/N]`. `--force` skips prompt (still elevated tier unless trust mode).
  </Accordion>

  <Accordion title="/choose">
    Reopen the selection menu the agent is waiting on. Useful when the menu scrolled away, or you dismissed it with Esc and want it back.

    ```text theme={null}
    /choose
    ```

    Prints `No selection menu is pending.` when the agent has not asked anything. Outside a TTY it lists the options as text for you to answer in a reply instead of opening a picker — except for a pending onboarding demo choice, which it drops with "Guided demo selection is unavailable here", leaving you to ask for what you want directly.
  </Accordion>

  <Accordion title="/alerts">
    ```text theme={null}
    /alerts
    ```

    When the alert listener is active:

    | Field         | Meaning                             |
    | ------------- | ----------------------------------- |
    | `status`      | `listening`                         |
    | `queue depth` | Alerts waiting for REPL consumption |
    | `dropped`     | Alerts dropped when queue was full  |
    | `recent`      | Up to 5 latest alert names/snippets |

    If the listener is inactive, prints a warning. Incoming alerts also appear in `/status` as `incoming alerts`. Post alerts to your configured webhook/listener URL during setup; the REPL triages them in chat.

    ***
  </Accordion>
</AccordionGroup>

### Setup and ops (CLI parity)

These spawn `opensre …` subprocesses. Output is captured into the REPL buffer for non-interactive subcommands; wizards attach to the real TTY.

<AccordionGroup>
  <Accordion title="/account">
    ```text theme={null}
    /account
    /account login
    /account status
    /account credits
    /account usage
    /account logout
    ```

    Sign in to a personal OpenSRE account, inspect the local login, show remaining hosted credits (`/account credits` or `/credits`, same as `opensre credits`), open the credits and top-up page (`/account usage`, opens your browser; from a chat it replies with the link), or sign out. Same as `opensre account`. The browser opens the OpenSRE sign-up page, where you can use email or any enabled sign-in provider. The shell starts only for an `active` account state. `/account logout` revokes the saved session, invalidates the hosted-model route, and closes the shell before another turn. If `OPENSRE_ACCOUNT_TOKEN` is set in the environment, it overrides the token saved by login until you unset it.
  </Accordion>

  <Accordion title="/credits">
    ```text theme={null}
    /credits
    /credits --dev
    ```

    Show remaining OpenSRE hosted credits for the signed-in account. Same as `opensre credits` and `/account credits`. Requires an active login. A fetch or auth failure is reported as unavailable — it is never shown as a zero balance.
  </Accordion>

  <Accordion title="/setup">
    ```text theme={null}
    /setup
    /setup --dev
    ```

    Run the first-use webapp account flow. It creates or signs in to an OpenSRE account using email or another enabled provider and activates the account-hosted model. Use `--dev` for a webapp running at `http://localhost:3000`. Setup requires exclusive stdin because browser authorization prompts on the real TTY.
  </Accordion>

  <Accordion title="/auth">
    ```text theme={null}
    /auth
    /auth status
    /auth login deepseek
    /auth logout deepseek
    /auth verify anthropic
    ```

    Log in to LLM providers, show local auth status, or clear stored credentials. Same as `opensre auth`. Interactive login prompts on the real TTY.
  </Accordion>

  <Accordion title="/login">
    ```text theme={null}
    /login
    /login openai
    /login anthropic
    /login deepseek
    ```

    Shortcut for `/auth login`. Same provider flows as `opensre auth login`.
  </Accordion>

  <Accordion title="/onboard">
    ```text theme={null}
    /onboard
    /onboard local_llm
    ```

    Optional local LLM-provider onboarding. The account-hosted route remains authoritative while signed in, so this does not switch the model used by the interactive shell.
  </Accordion>

  <Accordion title="/remote">
    ```text theme={null}
    /remote health
    /remote ops
    /remote pull
    /remote trigger
    ```

    Operate remote deployed OpenSRE agents (EC2, Nitro, hosted runtime).
  </Accordion>

  <Accordion title="/remote-sync">
    ```text theme={null}
    /remote-sync
    /remote-sync status
    /remote-sync sync
    /remote-sync sync --dry-run
    /remote-sync setup --provider aws --bucket my-opensre-bucket
    ```

    Copy sessions and memory to an object store you own (S3, GCS, Azure, Vercel Blob, or S3-compatible). Credentials and API keys stay local. See [Sync to your own object store](/docs/install/remote-sync).
  </Accordion>

  <Accordion title="/config">
    ```text theme={null}
    /config show
    /config set interactive.history.max_entries 1000
    ```

    Read/write `~/.opensre/config.yml`. Prefer env vars for secrets; use config for structured interactive-shell settings.
  </Accordion>

  <Accordion title="/cron">
    ```text theme={null}
    /cron list
    /cron add
    /cron remove &lt;id&gt;
    /cron run &lt;id&gt;
    /cron logs &lt;id&gt;
    ```

    Scheduled report delivery. See [Cron](/docs/platform/cron).
  </Accordion>

  <Accordion title="/loops">
    ```text theme={null}
    /loops
    /loops active
    /loops all
    /loops show
    /loops show &lt;name-or-id&gt;
    /loops show &lt;name-or-id&gt; --run &lt;run-id&gt;
    /loops add --name "Morning ops" --time 08:30 --prompt "Check open incidents and summarize production risk" --run-now
    /loops add --name "CI fix agent" --cron "*/30 * * * * *" --mode agent --prompt "Repair failing PR checks with fix_github_pr_ci"
    /loops run &lt;loop_id&gt;
    /loops stop &lt;loop_id&gt;
    /loops start &lt;loop_id&gt;
    /loops delete &lt;loop_id&gt;
    /loops next &lt;loop_id&gt;
    /loops messages
    ```

    List recurring loops from the scheduler store, create manual prompt loops, run a loop once immediately, stop or restart a loop, delete a loop, and debug the next fire time. By default a loop tick only produces a report; add `--mode agent` when the tick should act with tools (for example edit and push CI fixes). Onboarding creates draft examples such as a weekday morning report; active loops run through the cron scheduler when the gateway or `opensre cron start` is running.

    Agent-mode prompts must contain the complete task and name the tools to use; each tick starts a fresh session without loading workflow skills. For the CLI equivalent, use `opensre cron add --kind manual_loop --mode agent` with your prompt and schedule. Existing loops retain their stored mode; check `/loops show <id>` before reusing one.

    The list shows each loop's latest finding and run status, plus its next scheduled time in your local timezone. Failed and quiet runs replace the previous result in the table.

    Use `/loops show` to pick a loop, or pass its name or ID directly. Details contain the full report, recent runs, and configuration. Open an earlier report with the run ID shown in its history. New reports are retained even when delivery fails; older reports may be unavailable.

    You can also ask naturally:

    ```text theme={null}
    Set up a manual loop called Morning ops at 08:30 UTC to check open incidents and summarize production risk, and run it once now.
    ```

    By default, new loops send to every configured default handle OpenSRE can reach: Telegram, Slack, and the local interactive-shell inbox.
  </Accordion>

  <Accordion title="/sentry">
    ```text theme={null}
    /sentry digest run
    /sentry digest schedule list
    /sentry digest schedule add --cron "0 8 * * *" --provider telegram --chat-id &lt;id&gt;
    /sentry digest schedule run &lt;id&gt;
    /sentry digest schedule remove &lt;id&gt;
    /sentry uptime check
    /sentry uptime watch list
    /sentry uptime watch add --cron "*/5 * * * *" --provider telegram --chat-id &lt;id&gt;
    /sentry uptime watch run &lt;id&gt;
    /sentry uptime watch remove &lt;id&gt;
    ```

    Automated Sentry morning digest delivery (#10) and uptime watch notifications (#4032).
    Requires Sentry plus Telegram or Slack configured for the chosen provider. See [Sentry](/docs/integrations/incidents/sentry).
  </Accordion>

  <Accordion title="/messaging">
    ```text theme={null}
    /messaging pair
    /messaging allow
    /messaging revoke
    /messaging status
    ```

    Telegram bot pairing and sender allowlist for two-way chat and delivery features.
  </Accordion>

  <Accordion title="/guardrails">
    ```text theme={null}
    /guardrails audit
    /guardrails init
    /guardrails rules
    /guardrails test
    ```

    | Subcommand | Purpose                                    |
    | ---------- | ------------------------------------------ |
    | `init`     | Scaffold local guardrail config            |
    | `rules`    | List active masking rules                  |
    | `test`     | Run sample text through rules              |
    | `audit`    | Scan recent content for sensitive patterns |

    Related: [Masking](/docs/platform/masking).
  </Accordion>

  <Accordion title="/update">
    ```text theme={null}
    /update
    ```

    Checks PyPI and upgrades OpenSRE in-place (5-minute network timeout). Non-zero exit prints CLI error code.
  </Accordion>

  <Accordion title="/posthog">
    Run or schedule automated PostHog per-metric summary reports. Requires the PostHog integration; see [PostHog](/docs/integrations/monitoring/posthog).

    ```text theme={null}
    /posthog report run
    /posthog report schedule list
    /posthog report schedule add
    /posthog report schedule run <id>
    /posthog report schedule remove <id>
    ```

    A scheduled report only fires while a scheduler is running, so pair it with `/gateway start` or `opensre cron start`. Same as `opensre posthog`.
  </Accordion>

  <Accordion title="/runbooks">
    Manage the trusted runbook sources the agent may read during guided investigations. See [Runbook-guided investigations](/docs/integrations/incidents/runbook-guided-investigations).

    ```text theme={null}
    /runbooks list
    /runbooks add github --name <name> --repo <owner/repo>
    /runbooks verify <name>
    /runbooks remove <name>
    ```

    The agent reads runbooks only from sources listed here; an untrusted repository, an unsafe path, or a non-Markdown document is rejected. Same as `opensre runbooks`.
  </Accordion>

  <Accordion title="/debug">
    ```text theme={null}
    /debug sentry
    ```

    Targeted smoke tests (Sentry, etc.) — subcommands match `opensre debug --help`.
  </Accordion>

  <Accordion title="/uninstall">
    ```text theme={null}
    /uninstall
    ```

    Removes OpenSRE and local data. **Destructive** — confirmation required unless trust mode. Delegates to interactive CLI uninstall flow.

    ***
  </Accordion>
</AccordionGroup>

### System

<AccordionGroup>
  <Accordion title="/doctor">
    Environment diagnostic distinct from `/health`:

    ```text theme={null}
    /doctor
    ```

    Checks Python version, venv, config paths, Docker availability, credential presence, and related local prerequisites. Each row: `ok`, `warn`, or `error` with detail text.

    Use **`/doctor`** before first install debugging; use **`/health`** before an incident to verify integrations.
  </Accordion>

  <Accordion title="/theme">
    Choose the shell colour theme. The choice persists to `interactive.theme` in `~/.opensre/config.yml`, so it survives restarts.

    ```text theme={null}
    /theme
    /theme nord
    ```

    Bare `/theme` opens a picker with the current theme preselected, and needs a TTY. Passing a name sets it directly and reports an unknown name with the full list.

    Installed themes: `green`, `blue`, `amber`, `mono`, `red`, `pink`, `purple`, `orange`, `teal`, `lime`, `nord`, `dracula`, `solarized`, `gruvbox`, `webflux`, `sunset`. The default is `purple`.
  </Accordion>

  <Accordion title="/version">
    ```text theme={null}
    /version
    ```

    | Field     | Example                      |
    | --------- | ---------------------------- |
    | `opensre` | Package version from install |
    | `python`  | `3.12.x`                     |
    | `os`      | `darwin (arm64)`             |
  </Accordion>

  <Accordion title="/exit and /quit">
    ```text theme={null}
    /exit
    /quit
    ```

    Clean shutdown with a `/resume` hint. Prefer this over killing the terminal so session files flush cleanly.

    `/exit`, `/quit`, double **Ctrl+C**, or **Ctrl+D** (empty prompt) all print something like:

    ```text theme={null}
    Resume this session with:
    /resume 3f8a1c2d
    opensre --resume 3f8a1c2d
    goodbye.
    ```
  </Accordion>
</AccordionGroup>

## Trust mode, `/auto`, and confirmations

Two controls decide whether the REPL prompts before an action:

| Control  | Role                                                                                                   |
| -------- | ------------------------------------------------------------------------------------------------------ |
| `/auto`  | Which **agent tool types** need approval (default **high** = none)                                     |
| `/trust` | Session override that **skips** approval prompts when `/auto` (or an elevated slash command) would ask |

| Tier     | Examples                                                       | Confirmation               |
| -------- | -------------------------------------------------------------- | -------------------------- |
| Exempt   | `/help`, `/exit`, `/trust`, `/auto`                            | Never prompts              |
| Safe     | `/status`, `/health`, `/integrations list`                     | Read-only or standard risk |
| Elevated | `/cancel`, `/integrations remove`, `/fleet kill`, `/uninstall` | Prompt unless trust on     |

Non-TTY: actions that would ask **fail closed** (error message, no side effect).

```text theme={null}
/auto med   # ask before mutating agent tools
/auto high  # alpha default — no tool prompts
/trust on   # skip prompts for this session
/trust off  # restore /auto (and elevated) prompts
```

***

## Natural language actions

You do not need to memorize every slash command. Examples:

| You type                              | Typical action                            |
| ------------------------------------- | ----------------------------------------- |
| "what's my token usage?"              | `/cost`                                   |
| "verify datadog"                      | `/verify datadog`                         |
| "show datadog config"                 | `/integrations show datadog`              |
| "show the active model"               | `/model show`                             |
| "list my past sessions"               | `/sessions`                               |
| "check health then list integrations" | `/health` then `/integrations list`       |
| "how do I configure Datadog?"         | Doc-grounded answer (no mutating command) |

**List intents** — there is no global `/list`:

| Intent                    | Command                  |
| ------------------------- | ------------------------ |
| Connected integrations    | `/integrations list`     |
| Tools                     | `/tools`                 |
| Background tasks          | `/tasks`                 |
| Human todos and reminders | `/work`                  |
| MCP servers               | `/mcp list`              |
| Cron jobs                 | `/loops` or `/cron list` |
| Past REPL sessions        | `/sessions`              |

When the planner is uncertain, it asks for clarification or falls back to help — it does not silently run elevated commands.

Compound requests ("health then integrations") execute as an ordered sequence of slash actions.

***

## Common workflows

### First-time setup

```text theme={null}
/account status
/health
/verify
/model show
```

Run `opensre` to sign in before this workflow is reachable. Every launch opens the demo picker; choose **E** or press Escape to continue to the prompt, or run `opensre --skip-onboarding` to bypass it. The recommended option analyzes CI/CD performance; see [CI/CD analytics demo](/docs/cicd/cicd-analytics-demo).

### Incident triage (local)

```text theme={null}
/status
/alerts
/health
```

Paste alert text or describe the incident in plain language and the agent will triage it with your connected integrations.

### Pick up yesterday's thread

```text theme={null}
/sessions
/resume 9b2e4f7a
```

Continue chatting, then optionally:

```text theme={null}
/new
```

### Inspect account and model state

```text theme={null}
/account status
/model show
/cost
```

### Debug integration failures

```text theme={null}
/integrations show datadog
/doctor
/verbose on
```

***

## Troubleshooting

| Symptom                              | Try                                                                                                                      |
| ------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ |
| `unknown command`                    | `/help`; check spelling; use suggested correction                                                                        |
| Elevated command blocked in CI       | Use the CLI equivalent or run interactively                                                                              |
| `/cost` shows zero                   | No LLM turns yet this session; chat once and retry                                                                       |
| `/resume` not found                  | Run `/sessions`; use longer ID prefix                                                                                    |
| `/resume` ambiguous prefix           | Add more characters from Session ID column                                                                               |
| `/model set` reports an account lock | The hosted model is working as designed; `/account logout` closes the shell rather than switching it to a local provider |
| `/integrations show` not found       | Run `/integrations list` for exact service slug                                                                          |
| History pause not working            | Requires redacting backend — see `/privacy`                                                                              |
| Garbage in next prompt after table   | Known TTY issue — upgrade OpenSRE; report if persistent                                                                  |

***

## Related docs

* [Goals](/docs/getting-started/goals) — `/goal` set, pause, resume, edit, clear
* [Session History](/docs/platform/sessions) — persistence format, privacy, `/new` vs `/clear`
* [Interactive Shell Privacy](/docs/platform/interactive-shell-privacy) — redaction, env vars, threat model
* [LLM providers](/docs/platform/llm-providers) — `/model` and `/effort`
* [Agents](/docs/platform/fleet) — fleet dashboard, bus, trace, budgets
* [Cron](/docs/platform/cron) — `/cron` scheduled deliveries
* [Sync to your own object store](/docs/install/remote-sync) — `/remote-sync`

<Accordion title="/demo">
  Open the demo picker that every launch shows: CI/CD analysis of a repository on this machine (recommended), the recurring CI/CD reliability agent, remote CI/CD repairs, or Slack setup. Menus need an interactive terminal.

  ```text theme={null}
  /demo
  ```

  See [CI/CD with OpenSRE](/docs/cicd/overview).
</Accordion>

## Scheduled CI repair demo

Choose scheduled CI repair from `/demo` to try a tiny failure in the private
`opensre-onboarding-ci-repair-demo` repository. OpenSRE creates that repository
once and reuses it, with a fresh branch and PR for each completed demonstration.
An existing unrelated repository with that name stops setup.

The demo starts on the next scheduled minute and has a ten-minute total limit.
It uses the macOS or Linux background scheduler so it can finish after you close
the terminal. Configure GitHub and authenticate your coding agent before starting.
The initial run also needs permission to create a private repository and workflow.

* Read the complete outcome and evidence links with `/loops show <task-id>`.
* Stop an active repair with `/loops stop <task-id>`.
* Starting the demo again while it is active returns the same run and deadline.
* Successful runs close the demo PR and remove its branch. Unsuccessful runs keep
  the PR, branch, and diagnostics. The repository and stopped loop history remain.
