@enderfga/claw-orchestrator 7.14.0 → 7.16.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (145) hide show
  1. package/README.md +162 -135
  2. package/configs/autoloop-reviewer-prompt.md +1 -1
  3. package/configs/engines/README.md +31 -11
  4. package/dist/bin/acp-server.js +7 -12
  5. package/dist/bin/acp-server.js.map +1 -1
  6. package/dist/bin/cli.js +84 -46
  7. package/dist/bin/cli.js.map +1 -1
  8. package/dist/bin/mcp-server.js +2 -54
  9. package/dist/bin/mcp-server.js.map +1 -1
  10. package/dist/src/acp-server.d.ts +17 -9
  11. package/dist/src/acp-server.js +149 -30
  12. package/dist/src/acp-server.js.map +1 -1
  13. package/dist/src/autoloop/agent-tools.d.ts +2 -0
  14. package/dist/src/autoloop/agent-tools.js +7 -0
  15. package/dist/src/autoloop/agent-tools.js.map +1 -1
  16. package/dist/src/autoloop/dispatcher.d.ts +6 -0
  17. package/dist/src/autoloop/dispatcher.js +72 -9
  18. package/dist/src/autoloop/dispatcher.js.map +1 -1
  19. package/dist/src/autoloop/planner-tools.js +2 -0
  20. package/dist/src/autoloop/planner-tools.js.map +1 -1
  21. package/dist/src/claude-goal-session.d.ts +147 -0
  22. package/dist/src/claude-goal-session.js +355 -0
  23. package/dist/src/claude-goal-session.js.map +1 -0
  24. package/dist/src/council.d.ts +8 -0
  25. package/dist/src/council.js +45 -12
  26. package/dist/src/council.js.map +1 -1
  27. package/dist/src/dashboard/index.html +28 -14
  28. package/dist/src/embedded-server.js +27 -8
  29. package/dist/src/embedded-server.js.map +1 -1
  30. package/dist/src/engine-spawn.js +3 -1
  31. package/dist/src/engine-spawn.js.map +1 -1
  32. package/dist/src/fanout.d.ts +13 -3
  33. package/dist/src/fanout.js +10 -0
  34. package/dist/src/fanout.js.map +1 -1
  35. package/dist/src/inbox-manager.d.ts +9 -0
  36. package/dist/src/inbox-manager.js +8 -2
  37. package/dist/src/inbox-manager.js.map +1 -1
  38. package/dist/src/index.d.ts +2 -0
  39. package/dist/src/index.js +135 -53
  40. package/dist/src/index.js.map +1 -1
  41. package/dist/src/kernel/agent-step.d.ts +6 -0
  42. package/dist/src/kernel/agent-step.js.map +1 -1
  43. package/dist/src/kernel/conditions.d.ts +1 -1
  44. package/dist/src/kernel/conditions.js +1 -1
  45. package/dist/src/kernel/engine.d.ts +28 -8
  46. package/dist/src/kernel/engine.js +93 -19
  47. package/dist/src/kernel/engine.js.map +1 -1
  48. package/dist/src/kernel/nodes/agent.js +2 -0
  49. package/dist/src/kernel/nodes/agent.js.map +1 -1
  50. package/dist/src/kernel/nodes/council.js +9 -4
  51. package/dist/src/kernel/nodes/council.js.map +1 -1
  52. package/dist/src/kernel/nodes/fanout.js +5 -0
  53. package/dist/src/kernel/nodes/fanout.js.map +1 -1
  54. package/dist/src/kernel/nodes/goal.d.ts +19 -5
  55. package/dist/src/kernel/nodes/goal.js +81 -34
  56. package/dist/src/kernel/nodes/goal.js.map +1 -1
  57. package/dist/src/kernel/nodes/subflow.js +9 -1
  58. package/dist/src/kernel/nodes/subflow.js.map +1 -1
  59. package/dist/src/kernel/nodes/ultraapp.d.ts +1 -0
  60. package/dist/src/kernel/nodes/ultraapp.js +1 -0
  61. package/dist/src/kernel/nodes/ultraapp.js.map +1 -1
  62. package/dist/src/kernel/nodes/verifier.js +5 -1
  63. package/dist/src/kernel/nodes/verifier.js.map +1 -1
  64. package/dist/src/kernel/projections.d.ts +1 -0
  65. package/dist/src/kernel/projections.js +7 -1
  66. package/dist/src/kernel/projections.js.map +1 -1
  67. package/dist/src/kernel/templates/index.d.ts +16 -11
  68. package/dist/src/kernel/templates/index.js +14 -8
  69. package/dist/src/kernel/templates/index.js.map +1 -1
  70. package/dist/src/kernel/types.d.ts +37 -13
  71. package/dist/src/kernel/types.js.map +1 -1
  72. package/dist/src/logger.d.ts +6 -0
  73. package/dist/src/logger.js +14 -0
  74. package/dist/src/logger.js.map +1 -1
  75. package/dist/src/mcp-annotations.d.ts +13 -0
  76. package/dist/src/mcp-annotations.js +100 -0
  77. package/dist/src/mcp-annotations.js.map +1 -0
  78. package/dist/src/models.d.ts +7 -0
  79. package/dist/src/models.js +9 -0
  80. package/dist/src/models.js.map +1 -1
  81. package/dist/src/openai-compat.d.ts +11 -5
  82. package/dist/src/openai-compat.js +55 -54
  83. package/dist/src/openai-compat.js.map +1 -1
  84. package/dist/src/persistent-acp-session.d.ts +7 -0
  85. package/dist/src/persistent-acp-session.js +26 -2
  86. package/dist/src/persistent-acp-session.js.map +1 -1
  87. package/dist/src/persistent-codex-app-session.d.ts +2 -0
  88. package/dist/src/persistent-codex-app-session.js +18 -9
  89. package/dist/src/persistent-codex-app-session.js.map +1 -1
  90. package/dist/src/persistent-codex-session.d.ts +14 -3
  91. package/dist/src/persistent-codex-session.js +22 -19
  92. package/dist/src/persistent-codex-session.js.map +1 -1
  93. package/dist/src/persistent-custom-session.d.ts +9 -0
  94. package/dist/src/persistent-custom-session.js +41 -21
  95. package/dist/src/persistent-custom-session.js.map +1 -1
  96. package/dist/src/persistent-grok-session.js +1 -1
  97. package/dist/src/persistent-grok-session.js.map +1 -1
  98. package/dist/src/persistent-session.d.ts +9 -0
  99. package/dist/src/persistent-session.js +23 -0
  100. package/dist/src/persistent-session.js.map +1 -1
  101. package/dist/src/run-ledger.d.ts +3 -3
  102. package/dist/src/session-manager.d.ts +45 -1
  103. package/dist/src/session-manager.js +199 -34
  104. package/dist/src/session-manager.js.map +1 -1
  105. package/dist/src/types.d.ts +34 -11
  106. package/dist/src/types.js.map +1 -1
  107. package/dist/src/ultraapp/build.d.ts +5 -11
  108. package/dist/src/ultraapp/build.js +5 -11
  109. package/dist/src/ultraapp/build.js.map +1 -1
  110. package/dist/src/ultraapp/council-adapter.d.ts +5 -2
  111. package/dist/src/ultraapp/council-adapter.js +6 -6
  112. package/dist/src/ultraapp/council-adapter.js.map +1 -1
  113. package/dist/src/ultraapp/files.d.ts +7 -0
  114. package/dist/src/ultraapp/files.js +7 -1
  115. package/dist/src/ultraapp/files.js.map +1 -1
  116. package/dist/src/ultraapp/manager.d.ts +23 -3
  117. package/dist/src/ultraapp/manager.js +170 -72
  118. package/dist/src/ultraapp/manager.js.map +1 -1
  119. package/dist/src/ultraapp/narrator.js +1 -1
  120. package/dist/src/ultraapp/narrator.js.map +1 -1
  121. package/dist/src/ultraapp/versions.d.ts +27 -5
  122. package/dist/src/ultraapp/versions.js +58 -13
  123. package/dist/src/ultraapp/versions.js.map +1 -1
  124. package/openclaw.plugin.json +4 -13
  125. package/package.json +13 -6
  126. package/skills/SKILL.md +52 -24
  127. package/skills/references/acp.md +140 -61
  128. package/skills/references/autoloop.md +148 -38
  129. package/skills/references/claude-cli-tracking.md +9 -6
  130. package/skills/references/cli.md +139 -108
  131. package/skills/references/council.md +44 -22
  132. package/skills/references/dashboard.md +37 -21
  133. package/skills/references/getting-started.md +49 -15
  134. package/skills/references/inbox.md +13 -8
  135. package/skills/references/mcp.md +25 -17
  136. package/skills/references/multi-engine.md +161 -145
  137. package/skills/references/observability.md +90 -58
  138. package/skills/references/openai-compat.md +172 -82
  139. package/skills/references/sessions.md +101 -65
  140. package/skills/references/tools.md +217 -158
  141. package/skills/references/ultra.md +7 -7
  142. package/skills/references/ultraapp.md +101 -56
  143. package/skills/references/verification.md +112 -56
  144. package/skills/references/workflow.md +275 -97
  145. package/assets/banner.jpg +0 -0
@@ -2,12 +2,14 @@
2
2
 
3
3
  This document tracks which Claude Code CLI version Claw Orchestrator is currently synced to, and which features have been integrated. Recent rows also record the other engines' versions checked in the same sync.
4
4
 
5
- ## Currently tracked: **Claude Code CLI 2.1.310** (as of 2026-10-25, plugin v7.14.0)
5
+ ## Currently tracked: **Claude Code CLI 2.1.310** (as of 2026-10-28, plugin v7.16.0)
6
6
 
7
7
  ## Sync history
8
8
 
9
9
  | Plugin Version | Claude CLI Version | Date | Notable integrations |
10
10
  | ------------------- | ------------------ | ---------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
11
+ | v7.16.0 | 2.1.310 | 2026-10-28 | Pins as tracked in v7.15.0; not re-run live this release (installed: CC 2.1.312, Codex 0.165.0, agy 1.4.9). Integrated: `/goal` on Claude Code behind the `goal` node — measured on CC 2.1.312 in stream-json mode (bare `/goal` probe, Stop-hook turns, `interrupt` control request). |
12
+ | v7.15.0 | 2.1.310 | 2026-10-26 | Engine versions as tracked in v7.14.0 (agy 1.4.7 is installed but not yet run live; the pin stays 1.4.6). Integrated: `codex-app` passes reasoning effort — `turn/start` `effort` and `model_reasoning_effort` in the thread `config` on `thread/start` / `thread/resume` (Codex 0.164.0). |
11
13
  | v7.14.0 | 2.1.310 | 2026-10-25 | CC 2.1.307→2.1.310, agy 1.4.4→1.4.6, grok 1.0.67→1.0.70, OpenCode 1.19.3→1.19.4; Codex 0.164.0 unchanged. No flag the wrappers pass changed; one live turn per engine ok. Integrated: the `acp` engine (an ACP client over `@agentclientprotocol/sdk` 1.3.0), run against Kimi Code 2.3.1 (`kimi acp`, model from `KIMI_MODEL_*`), dsh 0.2.1-rc.2 (`dsh --profile acp`, `--patch` honoured) and OpenCode 1.19.4 (`opencode acp`, recall across a resumed session). Kimi Code and dsh report no usage over ACP. |
12
14
  | v7.13.0 | 2.1.307 | 2026-10-24 | Codex 0.163.0→0.164.0; the other engines as tracked in v7.12.1. Integrated: Codex 0.164 app-server goal RPCs (`thread/goal/set` / `get` / `clear`, six goal states, `tokenBudget`, `thread/goal/updated`), structured `error` notifications (`codexErrorInfo`, `willRetry`), `turn/steer` during goal turns, and `approvalPolicy` on `thread/start` / `thread/resume`; the `goal` workflow node is built on them. Measured: a goal objective is capped at 4,000 characters, and a thread can be resumed only after its first turn. |
13
15
  | v7.12.1 | 2.1.307 | 2026-10-22 | CC 2.1.302→2.1.307, agy 1.4.0→1.4.4, grok 1.0.62→1.0.67; Codex 0.163.0 and OpenCode 1.19.3 unchanged. No flag the wrappers pass changed. grok 1.0.67 makes `grok-4.7` its default and only model: registered (same prices and 500K window as `grok-4.6`), the `grok` alias moved to it, and a session with no `model` is labelled with the model grok reports. grok read-only re-measured on 1.0.67 (direct and shell writes blocked; the subagent probe hit the free-tier limit). OpenCode 2 still beta-only, still refused. |
@@ -49,8 +51,9 @@ This document tracks which Claude Code CLI version Claw Orchestrator is currentl
49
51
  When syncing to a new Claude Code CLI version:
50
52
 
51
53
  1. Run `claude --version` to confirm target version
52
- 2. Check Claude Code changelog / release notes for new flags, events, env vars since the last tracked version
53
- 3. Decide which features are valuable for programmatic/agent use (vs human-interactive only)
54
- 4. Implement worthwhile features (add to `SessionConfig` → wire into `persistent-session.ts` → expose in tool schema → document)
55
- 5. Update this file with the new version + notable integrations
56
- 6. Update the engine tables in `AGENTS.md` and `README.md`
54
+ 2. Run `npx tsx scripts/sweep.ts` (or `--no-live` for versions and flags only) to see installed, pinned and upstream versions of every core engine, the flags each wrapper passes against the binary's `--help`, and one live turn per engine
55
+ 3. Check Claude Code changelog / release notes for new flags, events, env vars since the last tracked version
56
+ 4. Decide which features are valuable for programmatic/agent use (vs human-interactive only)
57
+ 5. Implement worthwhile features (add to `SessionConfig` → wire into `persistent-session.ts` → expose in tool schema → document)
58
+ 6. Update this file: the "Currently tracked" line and a new row with the version + notable integrations
59
+ 7. Update the tested versions: the engine table in `AGENTS.md` (the pins the sweep reads), the engine compatibility table in `README.md`, and the "Tested with" line of each engine in [multi-engine.md](./multi-engine.md)
@@ -1,6 +1,12 @@
1
1
  # CLI Reference
2
2
 
3
- The CLI is an HTTP client that talks to the Claw Orchestrator embedded server. In plugin mode, the server auto-starts. In standalone mode, run `clawo serve` first.
3
+ The CLI is an HTTP client that talks to the Claw Orchestrator embedded server. Under OpenClaw, the plugin starts the server on its first tool call (unless `CLAWO_NO_EMBEDDED_SERVER=1`). In standalone mode, run `clawo serve` first. `clawo acp` and `clawo engines` run locally and do not need the server.
4
+
5
+ ## Connecting to the server
6
+
7
+ - **Address**: commands reach the server at `CLAWO_API_URL` (default `http://127.0.0.1:18796`).
8
+ - **Token**: every request carries the server's token, when the CLI finds one, as `Authorization: Bearer <token>`. The CLI reads it from `CLAWO_AUTH_TOKEN`, then `OPENCLAW_SERVER_TOKEN`, then `~/.openclaw/server-token`, which the server writes when it starts. See [Getting Started](./getting-started.md) for how the server chooses the token.
9
+ - **Errors**: when the server reports an error or cannot be reached, a command prints `Failed: <error>` to stderr and exits 1. With `--json`, `session-send` and `session-status` print the JSON result instead and still exit 1.
4
10
 
5
11
  ## Server
6
12
 
@@ -8,7 +14,9 @@ The CLI is an HTTP client that talks to the Claw Orchestrator embedded server. I
8
14
  clawo serve [-p, --port <port>] [-H, --host <host>] [--ultraapp-runtime host|docker]
9
15
  ```
10
16
 
11
- Start standalone embedded server (default port 18796, bound to `127.0.0.1`; pass `-H 0.0.0.0` for remote access). `--ultraapp-runtime` selects how ultraapp builds run: `host` (default, spawns Node directly) or `docker`. CLI commands reach the server at `CLAWO_API_URL` (default `http://127.0.0.1:18796`).
17
+ Start the standalone embedded server (default port 18796, bound to `127.0.0.1`, or `OPENCLAW_SERVER_HOST` when set; pass `-H 0.0.0.0` for remote access). `--ultraapp-runtime` selects how ultraapp builds run: `host` (default, spawns Node directly) or `docker`. The server also starts the ultraapp reverse-proxy router on port 19000 (or the next free port); if the router cannot start, ultraapp deploys are skipped and the server runs without it. If the server's port is already in use, `clawo serve` prints an error and exits 1.
18
+
19
+ Under `clawo serve` the session manager allows 32 concurrent sessions and unloads a session after 60 idle minutes (the plugin defaults are 5 and 120). Override with `OPENCLAW_SERVE_MAX_SESSIONS` and `OPENCLAW_SERVE_TTL_MINUTES`.
12
20
 
13
21
  ### Rate Limiting
14
22
 
@@ -16,14 +24,15 @@ The embedded server limits each IP address to 300 requests per minute (sliding w
16
24
 
17
25
  ### OpenAI-Compatible API
18
26
 
19
- The server exposes an OpenAI-compatible chat completions endpoint, enabling any webchat frontend to use it as a backend.
27
+ The server exposes an OpenAI-compatible chat completions endpoint, enabling any webchat frontend to use it as a backend. The full rules — session keying, `X-Session-Reset`, tool calls and environment variables — are in [openai-compat.md](./openai-compat.md).
20
28
 
21
29
  **Endpoints:**
22
30
 
23
- | Endpoint | Method | Description |
24
- | ---------------------- | ------ | -------------------------------------------- |
25
- | `/v1/chat/completions` | POST | Chat completions (streaming + non-streaming) |
26
- | `/v1/models` | GET | List available models |
31
+ | Endpoint | Method | Description |
32
+ | ---------------------- | ------ | ------------------------------------------------------------------------------------------------------ |
33
+ | `/v1/chat/completions` | POST | Chat completions (streaming + non-streaming) |
34
+ | `/v1/models` | GET | List available models |
35
+ | `/v1/sessions` | GET | List the live OpenAI-compatible sessions, each with turns, tokens, cached tokens, context use and cost |
27
36
 
28
37
  **Request format** (same as OpenAI):
29
38
 
@@ -42,17 +51,17 @@ The server exposes an OpenAI-compatible chat completions endpoint, enabling any
42
51
  3. A hash of the model, system prompt and tool definitions (`sys-<hash>`)
43
52
  4. `default`, when all of those are empty
44
53
 
45
- **Model routing:** The `model` field auto-routes to the correct engine:
54
+ An `X-Session-Reset: 1` (or `true`) header answers the request from a fresh session: the session under that key is stopped first, and the fresh one is stopped once the reply is sent.
55
+
56
+ **Model routing:** The `model` field picks the engine. A model id or alias in the model registry routes to the engine it is registered under (`opus` → Claude, `gemini-3.8-flash` / `agy-pro` → Antigravity), and an `agy/` prefix always selects Antigravity (`agy`). Other names route by prefix:
46
57
 
47
- - `claude-*`, `opus`, `sonnet`, `haiku` → Claude engine
48
- - `gpt-*`, `o3*`, `o4*`, `codex*` → Codex engine
58
+ - `gpt*`, `o3*`, `o4*`, `codex*` → Codex engine
49
59
  - `grok*` → Grok engine
50
- - `composer*`, `cursor*`, `auto` → Cursor engine (legacy)
51
- - `agy/*`, the `agy-flash` / `agy-pro` aliases, and the registered Antigravity models (e.g. `gemini-3.8-flash`, `gemini-3.1-pro`) → Antigravity (`agy`) engine
52
- - other `gemini*` → the legacy `gemini` engine (Gemini CLI is sunset; prefer `agy`)
60
+ - any other name containing `gemini` → the legacy `gemini` engine (Gemini CLI is sunset; prefer `agy/<model>` or a registered Antigravity model)
61
+ - `composer*`, `cursor*`, `auto` → the legacy `cursor` engine
53
62
  - anything else → Claude engine
54
63
 
55
- **CORS:** `/v1/` paths allow cross-origin requests by default. Set `OPENCLAW_CORS_ORIGINS=*` to allow all origins on all paths.
64
+ **CORS:** `/v1/` paths allow cross-origin requests by default, and `localhost` origins are allowed on every path. Set `OPENCLAW_CORS_ORIGINS=*` to allow all origins on all paths.
56
65
 
57
66
  **Auto-compact:** When a session's context utilization exceeds 80%, the endpoint automatically compacts the session before sending the next message.
58
67
 
@@ -72,38 +81,40 @@ Run as an Agent Client Protocol agent over stdio (same as the `clawo-acp` binary
72
81
  clawo session-start [name] [options]
73
82
  ```
74
83
 
75
- | Flag | Description |
76
- | ------------------------------- | ----------------------------------------------------------------------------------------------- |
77
- | `-d, --cwd <dir>` | Working directory |
78
- | `-e, --engine <engine>` | Engine: `claude` (default), `codex`, `codex-app`, `agy`, `grok`, `opencode`, `acp`, or `custom` |
79
- | `-m, --model <model>` | Model name or alias |
80
- | `--permission-mode <mode>` | `acceptEdits` (default), `plan`, `auto`, `bypassPermissions`, `manual`, `dontAsk` |
81
- | `--effort <level>` | `low`, `medium`, `high`, `xhigh`, `max`, `ultra`, `auto` |
82
- | `--allowed-tools <tools>` | Comma-separated tool whitelist |
83
- | `--disallowed-tools <tools>` | Comma-separated tools to deny |
84
- | `--max-turns <n>` | Max agent loop turns |
85
- | `--max-budget <usd>` | API cost ceiling |
86
- | `--system-prompt <text>` | Replace system prompt |
87
- | `--append-system-prompt <text>` | Append to system prompt |
88
- | `--agents <json>` | Custom sub-agents JSON |
89
- | `--agent <name>` | Default agent |
90
- | `--bare` | No CLAUDE.md, no git context |
91
- | `-w, --worktree [name]` | Git worktree |
92
- | `--fallback-model <model>` | Fallback model |
93
- | `--json-schema <schema>` | JSON Schema for structured output |
94
- | `--mcp-config <paths>` | MCP config files (comma-separated) |
95
- | `--settings <pathOrJson>` | Settings.json path or inline JSON |
96
- | `--skip-persistence` | Do not save the session — neither the engine's transcript nor the resume registry |
97
- | `--betas <headers>` | Beta headers (comma-separated) |
98
- | `--enable-agent-teams` | Enable agent teams |
99
- | `--enable-auto-mode` | Enable auto permission mode |
100
- | `--resume-session-id <id>` | Resume an existing session by ID |
101
- | `--base-url <url>` | Custom API endpoint (for proxy) |
102
- | `--add-dir <dirs>` | Comma-separated additional working directories |
103
- | `--custom-engine <preset>` | With `-e custom`: the id of a bundled engine preset (see [`clawo engines`](#clawo-engines)) |
104
- | `--acp-agent <preset>` | With `-e acp`: the id of a bundled ACP agent preset, e.g. `kimi-code`, `dsh` |
105
-
106
- The remaining `session_start` options (hook events, permission-prompt tool, debug output, `fromPr`, MCP channels, prompt-cache settings and others) are tool parameters only and have no CLI flag. See [Tools Reference](./tools.md#session_start).
84
+ `name` defaults to `session-<timestamp>`. Starting a name that is already live returns that session unchanged; a name in the resume registry resumes its conversation (see [sessions.md](./sessions.md#session-persistence)).
85
+
86
+ | Flag | Description |
87
+ | ------------------------------- | ----------------------------------------------------------------------------------------------------------- |
88
+ | `-d, --cwd <dir>` | Working directory |
89
+ | `-e, --engine <engine>` | Engine: `claude` (default), `codex`, `codex-app`, `agy`, `grok`, `opencode`, `acp`, or `custom` |
90
+ | `-m, --model <model>` | Model name or alias |
91
+ | `--permission-mode <mode>` | `acceptEdits` (default), `plan`, `auto`, `bypassPermissions`, `manual`, `dontAsk` |
92
+ | `--effort <level>` | `low`, `medium`, `high`, `xhigh`, `max`, `ultra`, `auto` (default); each engine clamps it to its own ladder |
93
+ | `--allowed-tools <tools>` | Comma-separated tools to auto-approve |
94
+ | `--disallowed-tools <tools>` | Comma-separated tools to deny |
95
+ | `--max-turns <n>` | Max agent loop turns |
96
+ | `--max-budget <usd>` | Spend cap in USD, checked before every send on every engine |
97
+ | `--system-prompt <text>` | Replace system prompt |
98
+ | `--append-system-prompt <text>` | Append to system prompt |
99
+ | `--agents <json>` | Custom sub-agents JSON |
100
+ | `--agent <name>` | Default agent |
101
+ | `--bare` | Claude Code minimal mode: skips hooks, LSP, auto-memory and CLAUDE.md discovery |
102
+ | `-w, --worktree [name]` | Git worktree |
103
+ | `--fallback-model <model>` | Fallback model |
104
+ | `--json-schema <schema>` | JSON Schema for structured output |
105
+ | `--mcp-config <paths>` | MCP config files (comma-separated) |
106
+ | `--settings <pathOrJson>` | Settings.json path or inline JSON |
107
+ | `--skip-persistence` | Keep the session out of the resume registry; Claude Code and Codex also skip writing their own transcript |
108
+ | `--betas <headers>` | Beta headers (comma-separated) |
109
+ | `--enable-agent-teams` | Enable agent teams |
110
+ | `--enable-auto-mode` | Enable auto permission mode |
111
+ | `--resume-session-id <id>` | Resume an earlier conversation by the engine's own id (Claude session id, Codex thread id, …) |
112
+ | `--base-url <url>` | Custom API endpoint (for proxy) |
113
+ | `--add-dir <dirs>` | Comma-separated additional working directories |
114
+ | `--custom-engine <preset>` | With `-e custom`: the id of a bundled engine preset (see [`clawo engines`](#clawo-engines)) |
115
+ | `--acp-agent <preset>` | With `-e acp`: the id of a bundled ACP agent preset, e.g. `kimi-code`, `dsh` |
116
+
117
+ Most of these flags map to Claude Code options; [multi-engine.md](./multi-engine.md) lists which ones each other engine honours. The remaining `session_start` options (`sandboxMode`, `autoCompactPercent`, `ultracode`, hook events, permission-prompt tool, debug output, `fromPr`, MCP channels, prompt-cache settings and others) are tool parameters only and have no CLI flag. See [Tools Reference](./tools.md#session_start).
107
118
 
108
119
  ### session-send
109
120
 
@@ -112,16 +123,16 @@ clawo session-send <name> <message> [options]
112
123
  clawo session-send <name> --message-file <file> [options]
113
124
  ```
114
125
 
115
- | Flag | Description |
116
- | ----------------------- | ---------------------------------------------------------------------------- |
117
- | `--message-file <file>` | Read the message from a file (long text, or text starting with `-`) |
118
- | `--effort <level>` | Override effort for this message |
119
- | `--plan` | Enable plan mode |
120
- | `-s, --stream` | Collect streaming chunks |
121
- | `-t, --timeout <ms>` | Timeout (default 300000) |
122
- | `--json` | Print the whole result (`ok`, `output`, `sessionId`, `error`, …) as one line |
126
+ | Flag | Description |
127
+ | ----------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
128
+ | `--message-file <file>` | Read the message from a file (long text, or text starting with `-`) |
129
+ | `--effort <level>` | Override effort for this message |
130
+ | `--plan` | Ask for a plan only: Claude Code and persistent custom engines get a plan-only instruction in front of the message; other engines ignore it |
131
+ | `-s, --stream` | Accepted, but has no effect: the server returns the reply when the turn ends, with no streamed chunks |
132
+ | `-t, --timeout <ms>` | Turn timeout (default 300000) |
133
+ | `--json` | Print the whole result as one line, including `ok`, `output`, `sessionId`, `error`, and `permissionDenials` / `images` when the turn had any |
123
134
 
124
- Every command that fails prints `Failed: …` and exits 1.
135
+ `--plan` does not change the permission mode. For a session that cannot write, start it with `--permission-mode plan` (Claude Code, Grok) or the `sandboxMode: 'read-only'` tool parameter.
125
136
 
126
137
  ### session-stop
127
138
 
@@ -129,19 +140,23 @@ Every command that fails prints `Failed: …` and exits 1.
129
140
  clawo session-stop <name>
130
141
  ```
131
142
 
143
+ Stops the session and removes it from the resume registry, so a later `session-start` with the same name begins a new conversation.
144
+
132
145
  ### session-list
133
146
 
134
147
  ```bash
135
148
  clawo session-list
136
149
  ```
137
150
 
151
+ Lists the server's live sessions as `name — model (cwd)`. Sessions held only in the resume registry are not listed.
152
+
138
153
  ### session-status
139
154
 
140
155
  ```bash
141
156
  clawo session-status <name> [--json]
142
157
  ```
143
158
 
144
- `--json` prints the whole status (`stats` with turns, tool calls, tokens, cost and the engine's resume id) as one line.
159
+ Prints turns, tool calls, cost, tokens and uptime. `--json` prints the whole status as one line: `name`, `cwd`, `model`, `created`, `claudeSessionId` (the engine's resume id), `costUsd` (and `budgetUsd` / `budgetExhausted` when a spend cap is set), and `stats` with turns, `turnsSucceeded`, tool calls, tokens, `contextPercent`, uptime and the engine's own conversation id.
145
160
 
146
161
  ### session-grep
147
162
 
@@ -149,12 +164,16 @@ clawo session-status <name> [--json]
149
164
  clawo session-grep <name> <pattern> [-n, --limit <n>]
150
165
  ```
151
166
 
167
+ Case-insensitive regular-expression search over the session's recent event history (`--limit` default 50). Prints the time and event type of each match.
168
+
152
169
  ### session-compact
153
170
 
154
171
  ```bash
155
172
  clawo session-compact <name> [--summary <text>]
156
173
  ```
157
174
 
175
+ Compacts the conversation; `--summary` is passed to the engine's compaction (`/compact <summary>` on Claude Code). Engines without compaction do nothing — see [sessions.md](./sessions.md#context-management).
176
+
158
177
  ## Run Ledger
159
178
 
160
179
  ```bash
@@ -164,33 +183,28 @@ clawo runs [-s, --since <window>] [-n, --limit <n>] [--session <name>] [--engine
164
183
  Show the durable per-turn record kept at `~/.claw-orchestrator/runs/`. Unlike
165
184
  `session-status`, this survives restarts and covers sessions this process never
166
185
  owned. `--since` takes `30m` / `24h` / `7d` / `2w` or an ISO timestamp (default
167
- `24h`); `--parent` filters to one council / fanout / autoloop / workflow run;
168
- `--verified` / `--refuted` keep only turns whose acceptance contract passed /
169
- failed. Costs marked with a trailing `~` came from estimated token counts. The
170
- `VERIFIED` column reads `yes`, `NO`, or `—` ("no contract was declared, so
171
- nothing checked it"). See [observability.md](observability.md).
186
+ `24h`); `--limit` caps the rows (default 50); `--parent` filters to one council /
187
+ fanout / autoloop / workflow run; `--verified` / `--refuted` keep only turns whose
188
+ acceptance contract passed / failed. Costs marked with a trailing `~` came from
189
+ estimated token counts. The `VERIFIED` column reads `yes`, `NO`, or `—` ("no
190
+ contract was declared, so nothing checked it"). `--json` prints `{ rows, summary }`.
191
+ See [observability.md](observability.md).
172
192
 
173
- ## Agent Management
193
+ ## Agents, Skills and Rules
174
194
 
175
195
  ```bash
176
196
  clawo agents-list [-d, --cwd <dir>]
177
- clawo agents-create <name> [--description <desc>] [--prompt <prompt>]
178
- ```
197
+ clawo agents-create <name> [-d, --cwd <dir>] [--description <desc>] [--prompt <prompt>]
179
198
 
180
- ## Skills Management
181
-
182
- ```bash
183
199
  clawo skills-list [-d, --cwd <dir>]
184
- clawo skills-create <name> [--description <desc>] [--prompt <prompt>] [--trigger <t>]
185
- ```
186
-
187
- ## Rules Management
200
+ clawo skills-create <name> [-d, --cwd <dir>] [--description <desc>] [--prompt <prompt>] [--trigger <t>]
188
201
 
189
- ```bash
190
202
  clawo rules-list [-d, --cwd <dir>]
191
- clawo rules-create <name> [--description <desc>] [--content <text>] [--paths <glob>] [--condition <expr>]
203
+ clawo rules-create <name> [-d, --cwd <dir>] [--description <desc>] [--content <text>] [--paths <glob>] [--condition <expr>]
192
204
  ```
193
205
 
206
+ These manage Claude Code's `.claude/agents/`, `.claude/skills/` and `.claude/rules/` directories. With `-d`, the create commands write under `<dir>/.claude/`; without it, under the user-level `~/.claude/`. The list commands show the entries under `<dir>/.claude/` first, then the user-level entries whose name the project does not define. A rule's `--paths` and `--condition` become its `paths:` and `if:` frontmatter.
207
+
194
208
  ## Agent Teams
195
209
 
196
210
  ```bash
@@ -198,11 +212,7 @@ clawo session-team-list <name>
198
212
  clawo session-team-send <name> <teammate> <message>
199
213
  ```
200
214
 
201
- ## Tools Without a CLI Command
202
-
203
- Tools without a CLI command are reachable through the OpenClaw plugin, the MCP
204
- server (`clawo-mcp`, see [mcp.md](./mcp.md)), or the `SessionManager` API. See
205
- [Tools Reference](./tools.md) for full parameter documentation.
215
+ `session-team-list` lists the server's other live sessions as virtual teammates, with each one's engine, state and turn count. `session-team-send` delivers a message to one of them through the session inbox — at once if it is idle, queued otherwise. See [inbox.md](./inbox.md).
206
216
 
207
217
  ## `clawo solve`
208
218
 
@@ -217,16 +227,16 @@ clawo solve "<task>" [--engine <engine[:model]>] [--check "<command>"]... [--con
217
227
 
218
228
  | Option | Default | Notes |
219
229
  | --------------- | ----------------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
220
- | `-e, --engine` | `claude` | The implementer, `engine` or `engine:model` (`codex:gpt-6.1-sol`) |
230
+ | `-e, --engine` | `claude` | The implementer, `engine` or `engine:model` (`codex:gpt-6.1-sol`), or `acp:<preset>` for an ACP agent (`acp:kimi-code`) |
221
231
  | `-c, --check` | — | A command check, repeatable. Split on whitespace and run as argv, never through a shell; anything that needs quoting belongs in `--contract` |
222
232
  | `--contract` | — | A contract JSON file ([verification.md](./verification.md)); `--check` entries are appended to it |
223
- | `--scouts` | the implementer | Comma-separated triage agents, `engine[:model]` each |
233
+ | `--scouts` | the implementer | Comma-separated triage agents, `engine[:model]` each (`acp:<preset>` for an ACP agent) |
224
234
  | `--reviewers` | — | Comma-separated reviewers of the finished change |
225
235
  | `--max-repairs` | `3` | Attempts the router allows while the checks are red; `0` keeps only the first attempt |
226
236
  | `--human-gate` | off | Park before anything is written until `clawo workflow approve` |
227
237
  | `--cwd` | current directory | Project directory |
228
238
  | `-w, --wait` | off | Follow the run, printing each node transition, then the verdict |
229
- | `--json` | off | Print `{ runId }`, or with `--wait` the final run record |
239
+ | `--json` | off | Print `{ runId, state }`, or with `--wait` the final run record |
230
240
 
231
241
  With `--wait` the exit code is the verdict: `0` when the run completed (verified,
232
242
  or unverified because no check was given), `1` when it was refuted, failed or
@@ -241,37 +251,48 @@ clawo fanout "<task>" [--engines <list>] [--synthesize] [--check "<command>"]...
241
251
  [--contract <file>] [--cwd <dir>] [--wait] [--json]
242
252
  ```
243
253
 
244
- `--engines` (default `claude,codex`) takes `engine[:model]` items; the same
245
- engine may appear more than once. With `--wait` the run is followed to the end
246
- and every answer is printed, followed by the synthesis when `--synthesize` was
247
- given. Checks run after the fan-out, as for `solve`.
254
+ | Option | Default | Notes |
255
+ | ------------------ | ----------------- | -------------------------------------------------------------------------------------------------------------- |
256
+ | `-e, --engines` | `claude,codex` | Comma-separated agents, `engine[:model]` each, or `acp:<preset>` for an ACP agent; an engine may repeat |
257
+ | `-s, --synthesize` | off | Merge the answers in a final pass. It runs only when at least two agents answered |
258
+ | `-c, --check` | — | A command check, repeatable, run after the fan-out, as for `solve` |
259
+ | `--contract` | — | A contract JSON file; `--check` entries are appended to it |
260
+ | `--cwd` | current directory | Project directory |
261
+ | `-w, --wait` | off | Follow the run to the end, then print every answer under a `## <agent>` heading — or the synthesis, if one ran |
262
+ | `--json` | off | Print `{ runId, state }`, or with `--wait` the final run record |
248
263
 
249
264
  ## `clawo goal`
250
265
 
251
- Run a Codex `/goal` on one `codex-app` thread, then have the runtime check the
252
- result: goal → verify → repair on the same thread. See [workflow.md](./workflow.md#goal).
266
+ Run a `/goal` on one thread — a Codex `codex-app` thread, or a Claude Code
267
+ session with `--engine claude` — then have the runtime check the result: goal →
268
+ verify → repair on the same thread. See [workflow.md](./workflow.md#goal).
253
269
 
254
270
  ```bash
255
271
  clawo goal "<objective>" | --objective-file <file>
256
272
  [--check "<command>"]... [--contract <file>] [--check-timeout <minutes>]
257
- [--launcher <arg>]... [--model <model>] [--effort <level>] [--sandbox <mode>] [--thread <id>]
273
+ [--engine codex|claude] [--launcher <arg>]... [--model <model>] [--effort <level>] [--sandbox <mode>] [--thread <id>]
258
274
  [--token-budget N] [--goal-timeout <minutes>] [--max-repairs N]
259
275
  [--cwd <dir>] [--wait] [--json]
260
276
  ```
261
277
 
262
- | Option | Default | Notes |
263
- | ------------------ | ----------------- | ------------------------------------------------------------------------------------------------------------------- |
264
- | `--objective-file` | — | Read the objective from a file instead of the argument. Codex accepts at most 4,000 characters |
265
- | `-c, --check` | — | A command check, repeatable, run after the goal. Split on whitespace; quote-needing commands go in `--contract` |
266
- | `--check-timeout` | 10 | Minutes for each `--check`. The verifier's node timeout is sized from the checks |
267
- | `--launcher` | — | Run codex under this command, one argv element per flag: `--launcher ./sandbox.sh --launcher task --launcher "0 1"` |
268
- | `-m, --model` | codex's own | Codex model |
269
- | `--sandbox` | `workspace-write` | Codex's own sandbox mode. With an outer sandbox as the boundary, `danger-full-access` |
270
- | `--thread` | — | Start on this existing codex thread: its goal is replaced, its history kept |
271
- | `--token-budget` | — | The goal stops as `budgetLimited` past this |
272
- | `--goal-timeout` | none | Wall-clock minutes for one goal pass |
273
- | `--max-repairs` | `1` | Times a red verdict sends the goal back to the same thread |
274
- | `-w, --wait` | off | Follow the run; exit `0` only if it completes |
278
+ | Option | Default | Notes |
279
+ | ------------------ | ----------------- | ------------------------------------------------------------------------------------------------------------------------ |
280
+ | `--objective-file` | — | Read the objective from a file instead of the argument. A goal accepts at most 4,000 characters |
281
+ | `-e, --engine` | `codex` | Who runs the goal: `codex` (a `codex-app` thread) or `claude` (a Claude Code session) |
282
+ | `-c, --check` | — | A command check, repeatable, run after the goal. Split on whitespace; quote-needing commands go in `--contract` |
283
+ | `--contract` | — | A contract JSON file; `--check` entries are appended to it |
284
+ | `--check-timeout` | 10 | Minutes for each `--check` (at least 1). The verifier's node timeout is sized from the checks |
285
+ | `--launcher` | — | Run the engine under this command, one argv element per flag: `--launcher ./sandbox.sh --launcher task --launcher "0 1"` |
286
+ | `-m, --model` | the engine's own | Model |
287
+ | `--effort` | the engine's own | Reasoning effort |
288
+ | `--sandbox` | `workspace-write` | Codex's own sandbox mode (claude has none). With an outer sandbox as the boundary, `danger-full-access` |
289
+ | `--thread` | — | Start on this existing codex thread or claude session: its goal is replaced, its history kept |
290
+ | `--token-budget` | — | The goal stops as `budgetLimited` past this |
291
+ | `--goal-timeout` | none | Wall-clock minutes for one goal pass |
292
+ | `--max-repairs` | `1` | Times a red verdict sends the goal back to the same thread |
293
+ | `--cwd` | current directory | Project directory |
294
+ | `-w, --wait` | off | Follow the run; exit `0` only if it completes |
295
+ | `--json` | off | Print `{ runId, state }`, or with `--wait` the final run record |
275
296
 
276
297
  `clawo workflow show <runId>` prints the goal's status, tokens, time, resume
277
298
  attempts and thread id while it runs; `clawo workflow steer <runId> "<text>"`
@@ -288,9 +309,12 @@ clawo workflow steer <runId> "<text>" # a correction for the next agent node, o
288
309
  clawo workflow approve <runId> [reject]
289
310
  ```
290
311
 
291
- `list` prints one row per run with its outcome as `verified` / `REFUTED` /
292
- `unchecked`. `unchecked` means no acceptance contract was declared — it is not a
293
- failure.
312
+ `list` prints one row per run (default limit 25) with its outcome as `verified` /
313
+ `REFUTED` / `unchecked`. `unchecked` means no acceptance contract was declared — it
314
+ is not a failure.
315
+
316
+ `approve` answers the gate a run is parked on: it approves unless the last
317
+ argument is `reject`, `false` or `no`.
294
318
 
295
319
  Runs survive restarts, so `list` sees runs started by other processes and by
296
320
  earlier sessions.
@@ -301,10 +325,11 @@ earlier sessions.
301
325
  clawo verify <runId> [--evidence <id>] [--json]
302
326
  ```
303
327
 
304
- Prints the evidence bundle: per-check pass/fail with the failing command and the
305
- lines of its output that say why (an assertion message, an error line — the last
306
- few lines when nothing stands out), the base and head commits, and the files the run changed (created
307
- files included).
328
+ Prints the evidence bundle (the run's latest unless `--evidence` names one):
329
+ per-check pass/fail with the failing command and the lines of its output that say
330
+ why (an assertion message, an error line — the last few lines when nothing stands
331
+ out), the base and head commits, and the files the run changed (created files
332
+ included).
308
333
 
309
334
  ## `clawo engines`
310
335
 
@@ -324,3 +349,9 @@ A preset id is the only form of custom engine or ACP agent the CLI can pass: it
324
349
  session through the HTTP surface, which refuses inline configs because those name
325
350
  a binary and its arguments. See [multi-engine.md](./multi-engine.md) for the tiers
326
351
  and what a community preset does and does not claim.
352
+
353
+ ## Tools Without a CLI Command
354
+
355
+ Tools without a CLI command are reachable through the OpenClaw plugin, the MCP
356
+ server (`clawo-mcp`, see [mcp.md](./mcp.md)), or the `SessionManager` API. See
357
+ [Tools Reference](./tools.md) for full parameter documentation.
@@ -48,13 +48,23 @@ project/
48
48
 
49
49
  Agents cannot interfere with each other's files. All integration happens via `git merge` to `main`.
50
50
 
51
+ If `projectDir` does not exist it is created; if it is not a git repository the council runs `git init`, and if
52
+ the repository has no commit yet it commits whatever the directory holds. Commits need a git identity: when the
53
+ repository has none at any level, the council sets a local `Council <council@openclaw>` in `.git/config`; an
54
+ identity you configured is left untouched. Agent names become branch names, so they must match
55
+ `^[a-zA-Z0-9_-]+$`. A council refuses to start with a `projectDir` inside the orchestrator's own package
56
+ directory.
57
+
51
58
  ### Consensus Voting
52
59
 
53
60
  Every agent must include `[CONSENSUS: YES]` or `[CONSENSUS: NO]` at the end of each round's response. The council continues until:
54
61
 
55
- - **All agents vote YES** — consensus reached
56
- - **Max rounds reached** — timeout
57
- - **Aborted** — user intervention
62
+ - **All agents vote YES** — consensus reached; status becomes `awaiting_user` (ready for review / accept / reject)
63
+ - **Max rounds reached** — status `max_rounds`
64
+ - **Aborted** — user intervention; status `error`
65
+
66
+ An agent that fails or errors in a round counts as a NO for that round. A loosely formatted vote (for example
67
+ `CONSENSUS=YES`) is still read, and a missing vote counts as NO.
58
68
 
59
69
  ## Quick Start
60
70
 
@@ -99,9 +109,12 @@ console.log(`Council started: ${session.id}`);
99
109
  const status = manager.councilStatus(session.id);
100
110
  ```
101
111
 
112
+ `councilStart`, `fanoutStart`, `ultraplanStart` and `ultrareviewStart` are async (each creates a durable run before
113
+ returning); direct TypeScript callers need `await`.
114
+
102
115
  ### Mixed Engines
103
116
 
104
- Agents can use different engines and models:
117
+ Agents can use different engines and models. Each agent also accepts `effort` and, on Claude, `ultracode`:
105
118
 
106
119
  ```json
107
120
  {
@@ -115,15 +128,15 @@ Agents can use different engines and models:
115
128
 
116
129
  ## Council Tools
117
130
 
118
- | Tool | Description |
119
- | ---------------- | --------------------------------------------------------------------------------------- |
120
- | `council_start` | Start a council. Runs in background, returns session ID immediately. |
121
- | `council_status` | Get current status (running/consensus/max_rounds/error), responses, votes. |
122
- | `council_abort` | Stop all agent sessions and terminate the council. |
123
- | `council_inject` | Inject a user message into all agents' prompts in the next round. |
124
- | `council_review` | Review completed council output: changed files, branches, plan status, agent summaries. |
125
- | `council_accept` | Accept work and clean up: remove worktrees, branches, plan.md, reviews/. |
126
- | `council_reject` | Reject work: rewrite plan.md with feedback for the council to retry. |
131
+ | Tool | Description |
132
+ | ---------------- | ----------------------------------------------------------------------------------------------------------------------- |
133
+ | `council_start` | Start a council. Runs in background, returns session ID immediately. |
134
+ | `council_status` | Status (`running`, `awaiting_user`, `max_rounds`, `error`, `accepted`, `rejected`) and each response with its vote. |
135
+ | `council_abort` | Stop all agent sessions, terminate a council running in this process, and remove the worktrees it created. |
136
+ | `council_inject` | Inject a user message into all agents' prompts in the next round. A second inject before that round replaces the first. |
137
+ | `council_review` | Review completed council output: changed files, branches, plan status, agent summaries. |
138
+ | `council_accept` | Accept work and clean up: remove worktrees, branches, plan.md, reviews/. |
139
+ | `council_reject` | Reject work: rewrite plan.md with feedback for the council to retry. |
127
140
 
128
141
  ## Post-Processing Lifecycle
129
142
 
@@ -143,6 +156,7 @@ Returns a structured report:
143
156
  - **planContent**: full plan.md text (check for unchecked tasks)
144
157
  - **reviews**: review files in `reviews/` directory
145
158
  - **agentSummaries**: final-round output preview from each agent
159
+ - **reviewerGuidance**: the checklist from `configs/council-reviewer-prompt.md`, for whoever reviews the output
146
160
 
147
161
  ### 2. Accept
148
162
 
@@ -150,14 +164,14 @@ Returns a structured report:
150
164
  { "tool": "council_accept", "args": { "id": "<council-id>" } }
151
165
  ```
152
166
 
153
- Cleans up all council scaffolding:
167
+ Checks out `main` (or `master`), then cleans up all council scaffolding:
154
168
 
155
169
  - Removes the worktrees under `{projectDir}/.worktrees/`, and that directory —
156
170
  selection is by containment, so a worktree of yours that merely has `council`
157
171
  somewhere in its path is never touched
158
172
  - Deletes all `council/*` branches
159
173
  - Removes `plan.md` and `reviews/` directory
160
- - Sets council status to `accepted`
174
+ - Sets council status to `accepted`, recorded on the run so `council_status` reports it
161
175
 
162
176
  ### 3. Reject
163
177
 
@@ -165,7 +179,7 @@ Cleans up all council scaffolding:
165
179
  { "tool": "council_reject", "args": { "id": "<council-id>", "feedback": "..." } }
166
180
  ```
167
181
 
168
- Rewrites `plan.md` with rejection feedback and commits it. All worktrees and branches are preserved so the council can be restarted to address the feedback.
182
+ Rewrites `plan.md` with rejection feedback and commits it, and sets council status to `rejected`, recorded on the run. All worktrees and branches are preserved so the council can be restarted to address the feedback: a new `council_start` on the same `projectDir` with the same agent names reuses those worktrees (resetting each to its branch head, which discards uncommitted changes in them).
169
183
 
170
184
  ## Configuration
171
185
 
@@ -176,6 +190,8 @@ Rewrites `plan.md` with rejection feedback and commits it. All worktrees and bra
176
190
  | `maxTurnsPerAgent` | 50 | Max tool turns per agent per round |
177
191
  | `maxBudgetUsd` | — | API spend limit per agent |
178
192
 
193
+ These are the `council_start` defaults. The `council` workflow template (`workflow_start`) runs up to 8 rounds.
194
+
179
195
  ### defaultPermissionMode
180
196
 
181
197
  Optional. Sets the default permission mode for council agents when individual agents don't specify one. Defaults to `bypassPermissions`.
@@ -238,18 +254,24 @@ workflow_start({
238
254
 
239
255
  Without a contract the run completes `unverified` — nothing checked it.
240
256
 
241
- `councilStart`, `fanoutStart`, `ultraplanStart` and `ultrareviewStart` are
242
- async (each creates a durable run before returning); direct TypeScript callers
243
- need `await`.
244
-
245
257
  ## Durable runs
246
258
 
247
259
  A council is a durable kernel run. `GET /council/list` (and the dashboard)
248
260
  returns real records from disk, across processes.
249
261
 
262
+ | Route | Purpose |
263
+ | -------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
264
+ | `GET /council/list` | Every council run, newest first. |
265
+ | `POST /council/new` | Body `{ task, projectDir, maxRounds? }`. Starts the dashboard preset: three Claude agents, 15 rounds by default. |
266
+ | `GET /council/<id>/state` | The council session (status, config, responses). |
267
+ | `GET /council/<id>/events` | SSE: a `snapshot`, then a `council-event` for each session, round and agent event (output chunks included). Only for a council running in this process; 404 otherwise. |
268
+
250
269
  `council_review` / `council_accept` / `council_reject` work after a restart:
251
- they act on the git state the council left behind, not on live agents.
252
- `council_inject` needs the live run and says so plainly when there is none.
270
+ they act on the git state the council left behind, not on live agents, and the
271
+ accept / reject decision is written to the run record.
272
+ `council_inject` and `council_abort` need the live run and say so plainly when
273
+ there is none: `council_abort` then returns `ok: false` with the run's state and
274
+ leaves the run and its worktrees as they are.
253
275
 
254
276
  ## Changed-file reporting
255
277