@mcpbox/mcpbox-claude 0.1.28 → 0.1.29
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.
- package/.claude-plugin/plugin.json +2 -2
- package/.codex-plugin/plugin.json +4 -4
- package/README.md +261 -26
- package/bin/mcpbox-claude.mjs +21 -8
- package/commands/close.md +2 -0
- package/commands/mine.md +4 -4
- package/commands/mode.md +4 -12
- package/commands/next.md +4 -3
- package/commands/pipeline-run.md +4 -4
- package/commands/plan.md +4 -4
- package/commands/sync.md +1 -1
- package/commands/tasks.md +4 -4
- package/hooks/acceptance-guard.mjs +5 -62
- package/hooks/bootstrap.mjs +167 -0
- package/hooks/edit-gate.mjs +7 -0
- package/hooks/hooks.json +12 -2
- package/hooks/impl/acceptance-guard.mjs +63 -0
- package/hooks/impl/edit-gate.mjs +32 -0
- package/hooks/impl/prepare-commit-msg.mjs +8 -0
- package/hooks/impl/session-gate.mjs +81 -0
- package/hooks/impl/session-start.mjs +89 -0
- package/hooks/impl/stop.mjs +64 -0
- package/hooks/impl/track-claims.mjs +35 -0
- package/hooks/impl/user-prompt-submit.mjs +234 -0
- package/hooks/prepare-commit-msg.mjs +5 -9
- package/hooks/session-gate.mjs +5 -82
- package/hooks/session-start.mjs +5 -75
- package/hooks/stop.mjs +5 -58
- package/hooks/track-claims.mjs +5 -30
- package/hooks/user-prompt-submit.mjs +5 -259
- package/lib/cloud-knowledge.mjs +19 -3
- package/lib/codex.mjs +2 -2
- package/lib/cursor.mjs +1 -1
- package/lib/edit-gate.mjs +120 -0
- package/lib/harness-hooks.mjs +53 -5
- package/lib/hook-doctor.mjs +517 -0
- package/lib/hook-output.mjs +16 -0
- package/lib/kimi.mjs +9 -3
- package/lib/knowledge-skills.mjs +259 -0
- package/lib/mode.mjs +2 -12
- package/lib/policy.mjs +54 -127
- package/lib/session-gate.mjs +195 -15
- package/lib/version.mjs +1 -1
- package/package.json +2 -2
- package/skills/mcpbox/SKILL.md +17 -94
- package/skills/mcpbox-close/SKILL.md +2 -0
- package/skills/mcpbox-mine/SKILL.md +4 -4
- package/skills/mcpbox-mode/SKILL.md +4 -12
- package/skills/mcpbox-next/SKILL.md +4 -3
- package/skills/mcpbox-pipeline-run/SKILL.md +4 -4
- package/skills/mcpbox-plan/SKILL.md +4 -4
- package/skills/mcpbox-sync/SKILL.md +1 -1
- package/skills/mcpbox-tasks/SKILL.md +4 -4
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mcpbox-claude",
|
|
3
|
-
"description": "MCPBox for Claude Code:
|
|
4
|
-
"version": "0.1.
|
|
3
|
+
"description": "MCPBox for Claude Code: Daruma tasks, project memory, and optional idea exploration over MCP. Ships /mcpbox:* commands, session hooks, and a managed CLAUDE.md policy that makes mcpbox the default tracker.",
|
|
4
|
+
"version": "0.1.29",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "tupical"
|
|
7
7
|
},
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mcpbox",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"description": "MCPBox for Codex:
|
|
3
|
+
"version": "0.1.29",
|
|
4
|
+
"description": "MCPBox for Codex: Daruma plans and project memory over MCP.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "tupical"
|
|
7
7
|
},
|
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
"mcpServers": "./.mcp.json",
|
|
11
11
|
"interface": {
|
|
12
12
|
"displayName": "MCPBox",
|
|
13
|
-
"shortDescription": "
|
|
14
|
-
"longDescription": "One MCP endpoint (https://mcpbox.ru/v1/mcp) with
|
|
13
|
+
"shortDescription": "Daruma plans and project memory for agents.",
|
|
14
|
+
"longDescription": "One MCP endpoint (https://mcpbox.ru/v1/mcp) with Daruma tasks, project memory, and an optional workflow for exploring ideas. Ships the policy and command workflows as Codex skills.",
|
|
15
15
|
"developerName": "tupical",
|
|
16
16
|
"category": "Productivity",
|
|
17
17
|
"websiteURL": "https://mcpbox.ru"
|
package/README.md
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# @mcpbox/mcpbox-claude
|
|
2
2
|
|
|
3
3
|
MCPBox agent harness for **Claude Code**, **Codex**, **Cursor**, **Kimi Code**, and **OpenCode**.
|
|
4
|
-
Wires the single canonical MCP server (`https://mcpbox.ru/v1/mcp` — the
|
|
5
|
-
tracker
|
|
4
|
+
Wires the single canonical MCP server (`https://mcpbox.ru/v1/mcp` — the Daruma
|
|
5
|
+
tracker and project memory)
|
|
6
6
|
and drops a managed policy into each agent's native config file.
|
|
7
7
|
|
|
8
8
|
Normally installed for you by `npx @mcpbox/mcpbox setup` (or
|
|
@@ -10,6 +10,37 @@ Normally installed for you by `npx @mcpbox/mcpbox setup` (or
|
|
|
10
10
|
server and picks Repository, Repository (user scope), or Global. Use this CLI directly to manage
|
|
11
11
|
just the policy.
|
|
12
12
|
|
|
13
|
+
## Start with a plan
|
|
14
|
+
|
|
15
|
+
Once connected, ask your agent to create a Daruma plan with tasks and acceptance
|
|
16
|
+
criteria. For example, “Plan a CSV import. Skip duplicate email addresses and
|
|
17
|
+
report how many rows were skipped.” On servers with MeiSei Critique, creating
|
|
18
|
+
a plan can also return advisory findings, such as two tasks with the same
|
|
19
|
+
title. Review the finding and decide whether to amend the plan.
|
|
20
|
+
|
|
21
|
+
Critique uses the recorded plan by default. Local Git observations require a
|
|
22
|
+
separate Daruma CLI invocation with an explicit checkout. They are self-reported
|
|
23
|
+
and do not attest that tests passed. For an undecided idea, the existing
|
|
24
|
+
`mcpbox_pipeline_run` workflow and its handoff remain available.
|
|
25
|
+
|
|
26
|
+
## Add the Claude Code policy to a project
|
|
27
|
+
|
|
28
|
+
First install the CLI globally with `npm install -g @mcpbox/mcpbox-claude`
|
|
29
|
+
and ensure npm's global bin directory is on your PATH. Then, from the project
|
|
30
|
+
directory, run:
|
|
31
|
+
|
|
32
|
+
```bash
|
|
33
|
+
mcpbox-claude init
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
The command creates a managed policy in `CLAUDE.md` and prints:
|
|
37
|
+
|
|
38
|
+
```text
|
|
39
|
+
Open Claude Code in this directory to pick it up.
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
Running it again leaves the policy unchanged.
|
|
43
|
+
|
|
13
44
|
## Install and update
|
|
14
45
|
|
|
15
46
|
Claude Code and Codex install from the public git marketplace, which is the only
|
|
@@ -104,6 +135,102 @@ until the next release: the skill shipped inside the Codex plugin package
|
|
|
104
135
|
(a session of that plugin keeps `AGENTS.md` on the server text) and the
|
|
105
136
|
Kimi hooks frozen at `kimi-init`.
|
|
106
137
|
|
|
138
|
+
### Windows / Codex: "hook exited with code 1"
|
|
139
|
+
|
|
140
|
+
Codex shows only `hook exited with code N` and drops the hook's stderr, so the
|
|
141
|
+
reason is not visible in the session. `npx -y @mcpbox/mcpbox-claude doctor`
|
|
142
|
+
reproduces it: for every mcpbox entry in `~/.codex/hooks.json` (or
|
|
143
|
+
`$CODEX_HOME/hooks.json`), `~/.cursor/hooks.json` and `~/.claude/settings.json`
|
|
144
|
+
it runs the command the way the host does — Windows `%COMSPEC% /C "<command>"`,
|
|
145
|
+
Unix `$SHELL -lc <command>`, Claude Code `bash -c` (Git Bash on Windows), the
|
|
146
|
+
event JSON on stdin — and prints the exit
|
|
147
|
+
code, the first 20 lines of stderr and, for a failing hook, of stdout
|
|
148
|
+
(`hooks` in `--json`). It does not change READY or the exit code and fixes
|
|
149
|
+
nothing itself.
|
|
150
|
+
|
|
151
|
+
It also runs the hooks Codex takes from the mcpbox plugin: the
|
|
152
|
+
`hooks/hooks.json` of an `[plugins."<name>@<marketplace>"]` with
|
|
153
|
+
`enabled = true` in `config.toml`, from the cache copy
|
|
154
|
+
`$CODEX_HOME/plugins/cache/<marketplace>/<name>/<version>` (the newest), when
|
|
155
|
+
its `.codex-plugin/plugin.json` says `"name": "mcpbox"` — other plugins' hooks
|
|
156
|
+
are never run, whatever their scripts are called. Its commands run with
|
|
157
|
+
`${PLUGIN_ROOT}` / `${CLAUDE_PLUGIN_ROOT}` replaced by that root and
|
|
158
|
+
`PLUGIN_ROOT`, `CLAUDE_PLUGIN_ROOT`, `PLUGIN_DATA` set the way Codex sets them.
|
|
159
|
+
Codex runs this file without a `hooks` key in `.codex-plugin/plugin.json`
|
|
160
|
+
(`hooks/list` of `codex app-server` 0.165.0 lists all nine with
|
|
161
|
+
`source: plugin`). Codex 0.141.0 (seen in the Windows desktop app) parses that
|
|
162
|
+
file strictly, rejects it for the top-level `description` key
|
|
163
|
+
(`unknown field`) and runs none of the plugin hooks; `doctor` says so next to
|
|
164
|
+
the file — update Codex.
|
|
165
|
+
|
|
166
|
+
The hooks run in a sandbox: a throwaway home, `CODEX_HOME`,
|
|
167
|
+
`CLAUDE_CONFIG_DIR`, plugin data dir and working directory, with
|
|
168
|
+
`MCPBOX_NO_POLICY_SYNC`, `MCPBOX_NO_KNOWLEDGE_SKILLS`, `MCPBOX_NO_UPDATE_CHECK`
|
|
169
|
+
and `MCPBOX_NO_POLICY_FETCH` set. A SessionStart under `doctor` therefore does
|
|
170
|
+
not refresh `AGENTS.md`, `CLAUDE.md` or skills and reaches no tracker (the
|
|
171
|
+
credentials live in the real home). The shell itself keeps the real
|
|
172
|
+
environment and working directory: `${HOME}`, `%USERPROFILE%` or a relative
|
|
173
|
+
path in a command resolve to the script Codex would run, and the login
|
|
174
|
+
profile gives the same PATH and `node`. The sandbox starts inside the hook's
|
|
175
|
+
node — a `--require` preload added to `NODE_OPTIONS` swaps `HOME`,
|
|
176
|
+
`USERPROFILE`, `CODEX_HOME`, `CLAUDE_CONFIG_DIR` and the working directory
|
|
177
|
+
before the script loads. The policy files around the project and the user skill
|
|
178
|
+
dirs are hashed before and after; a difference is reported as an error
|
|
179
|
+
(`hooks.touched`). A hook that hits its timeout is killed with everything it
|
|
180
|
+
started (its process group on Unix, `taskkill /T` on Windows), so `doctor`
|
|
181
|
+
does not wait for a leftover child.
|
|
182
|
+
|
|
183
|
+
- **`${CLAUDE_PLUGIN_ROOT}` in a user hooks file.** Codex expands
|
|
184
|
+
`${PLUGIN_ROOT}` / `${CLAUDE_PLUGIN_ROOT}` only for hooks a plugin ships.
|
|
185
|
+
Copied into `~/.codex/hooks.json` (for example from this package's
|
|
186
|
+
`hooks/hooks.json`) it stays literal: node looks for
|
|
187
|
+
`…\${CLAUDE_PLUGIN_ROOT}\hooks\session-start.mjs` and exits 1 on every event.
|
|
188
|
+
`doctor` marks such entries; delete them and run `codex-init`, which writes
|
|
189
|
+
absolute paths into the harness copy (`~/.agents/mcpbox/harness`). Under
|
|
190
|
+
`cmd.exe` no `${VAR}` is expanded at all.
|
|
191
|
+
- **Which node.** The hooks run `node` from the PATH Codex was started with
|
|
192
|
+
(the desktop app or the shell that launched it), not from the terminal where
|
|
193
|
+
you type. `doctor` asks the hooks' own shell and prints the version and
|
|
194
|
+
`execPath`. Node 20 or newer is required (`engines`); OpenServer, OSPanel and
|
|
195
|
+
similar panels, as well as version managers, can put another `node` first on
|
|
196
|
+
that PATH.
|
|
197
|
+
- **Harness copy.** `doctor` reports harness files that are missing or differ
|
|
198
|
+
from the installed package (`codex-init` / `cursor-init` rewrite them) and any
|
|
199
|
+
relative import of a harness script that the copy does not include.
|
|
200
|
+
|
|
201
|
+
### When a hook itself fails
|
|
202
|
+
|
|
203
|
+
Every `hooks/<name>.mjs` is a thin entry over `hooks/bootstrap.mjs`; the hook
|
|
204
|
+
lives in `hooks/impl/<name>.mjs` and is loaded by a dynamic import. A failure
|
|
205
|
+
to load it (a missing harness file, a SyntaxError), a throw in it or a node
|
|
206
|
+
older than 20 does not exit 1: the bootstrap writes one line
|
|
207
|
+
|
|
208
|
+
```
|
|
209
|
+
[mcpbox] hook <name> failed: <error> (<code>) — node <version> <execPath>; run: mcpbox-claude doctor
|
|
210
|
+
```
|
|
211
|
+
|
|
212
|
+
as the hook's stdout JSON, the same line plus the stack to stderr, and exits 0.
|
|
213
|
+
The line is capped at 1 KB of UTF-8 (the error message is cut, at a code
|
|
214
|
+
point, before the runtime part). A hook that already wrote its own output gets
|
|
215
|
+
no second document (Codex parses exactly one): then the line goes to stderr
|
|
216
|
+
only; output the hook still writes after the failure (a timer, a deferred
|
|
217
|
+
write) goes to stderr as well. Tracker and network errors
|
|
218
|
+
stay silent inside the hooks, as before — only unexpected failures surface.
|
|
219
|
+
|
|
220
|
+
| Surface | SessionStart / UserPromptSubmit | Stop, SessionEnd, Pre/PostToolUse |
|
|
221
|
+
|---|---|---|
|
|
222
|
+
| Claude Code, Kimi | `systemMessage` (user) + `hookSpecificOutput.additionalContext` (model) | `systemMessage` |
|
|
223
|
+
| Codex (`PLUGIN_DATA` or `--surface=codex`) | `systemMessage` (user) + `hookSpecificOutput.additionalContext` (model) | `systemMessage` |
|
|
224
|
+
| Cursor (`--surface=cursor`) | `additional_context` | stderr only |
|
|
225
|
+
| git `prepare-commit-msg` | — | stderr only; the commit proceeds |
|
|
226
|
+
|
|
227
|
+
`acceptance-guard` keeps its exit 2 with the reason on stderr for a broken
|
|
228
|
+
acceptance lock; only its load failures go through the bootstrap. `doctor`
|
|
229
|
+
counts a hook that printed the `[mcpbox] hook … failed:` line as failing even
|
|
230
|
+
with exit 0. Not covered: a command whose entry script itself is not found
|
|
231
|
+
(the literal `${CLAUDE_PLUGIN_ROOT}` case above) or a node too old to parse
|
|
232
|
+
the bootstrap (before 12.17) — node exits 1 before any of our code runs.
|
|
233
|
+
|
|
107
234
|
### Project knowledge in every session
|
|
108
235
|
|
|
109
236
|
Agents answer repo questions right when they have the project's knowledge
|
|
@@ -117,18 +244,39 @@ npx -y @mcpbox/mcpbox-claude login # confirm the code in the browser
|
|
|
117
244
|
The workspace-bound token is kept in `~/.agents/mcpbox/credentials.json`
|
|
118
245
|
(mode 0600) and only ever sent over https; `logout` deletes the file, and
|
|
119
246
|
revoking the token itself happens in the workspace settings (Tokens). The
|
|
120
|
-
repo path of each new session goes to the server to find its project.
|
|
121
|
-
unbound in the paired workspace, the hook adds a ready `mcpbox_knowledge_read`
|
|
247
|
+
repo path of each new session goes to the server to find its project. The hook inlines complete, framed knowledge up to 800 UTF-8 bytes. For larger or truncated results, an unpaired or rejected token, or an unbound path, it adds a ready `mcpbox_knowledge_read`
|
|
122
248
|
call instead of the text. Knowledge rows arrive
|
|
123
|
-
marked as workspace data, not instructions
|
|
124
|
-
|
|
125
|
-
|
|
249
|
+
marked as workspace data, not instructions, with their source `id`, `maturity` and
|
|
250
|
+
`plan_id`: a `raw` row is one agent's working note for a plan, not verified
|
|
251
|
+
knowledge. Mode `off` disables both.
|
|
252
|
+
|
|
253
|
+
Paired, `SessionStart` also turns the project's published skills
|
|
254
|
+
(`kind=skill`, `maturity=consolidated`) into skill files of the running client:
|
|
255
|
+
`~/.claude/skills` for Claude Code (`$CLAUDE_CONFIG_DIR/skills` when set),
|
|
256
|
+
`$CODEX_HOME/skills` for Codex. One flat directory per row,
|
|
257
|
+
`mcpbox-<workspace-slug>-<title>/SKILL.md` (the slug is a hash of the paired
|
|
258
|
+
workspace id; Claude Code finds user skills one level deep only). The row's
|
|
259
|
+
text travels inside the same untrusted frame as above. Each file carries a
|
|
260
|
+
marker with the project id, the knowledge id and `updated_at`: an unchanged
|
|
261
|
+
row is not rewritten, and a row of the project just read that is gone from
|
|
262
|
+
the answer (retired or superseded) loses its directory. The skill root is
|
|
263
|
+
shared by every project of the workspace and one read answers for one
|
|
264
|
+
project, so skills of the other projects stay; a title another project already
|
|
265
|
+
holds gets an id suffix. A failed, unbound or truncated read changes nothing,
|
|
266
|
+
and neither does an answer that names no project (a server older than this
|
|
267
|
+
contract, when it has no rows). Directories without the marker, with extra
|
|
268
|
+
files, or of another workspace are never touched. A file written before the
|
|
269
|
+
marker carried a project is adopted by the read that returns its row; until
|
|
270
|
+
then it stays, and removal after a retire needs that adoption first.
|
|
271
|
+
`MCPBOX_NO_KNOWLEDGE_SKILLS=1` or mode `off` turns this off.
|
|
272
|
+
|
|
273
|
+
The session gate tracks work taken by the current session. Its Stop and SessionEnd rules are listed below.
|
|
126
274
|
If the lookup times out, it exits silently; lingering network connections do not delay process exit. Any blocking response is flushed before exit.
|
|
127
275
|
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
the
|
|
131
|
-
anything there — check manually, or let
|
|
276
|
+
Claude and Codex check for updates at session start. Kimi can deliver the notice on the first prompt.
|
|
277
|
+
Cursor's hooks are the session gate (every `cursor-init`) plus, for global
|
|
278
|
+
installs, the user-level `sessionStart` that carries the policy; none of them
|
|
279
|
+
checks for updates, so nothing announces anything there — check manually, or let
|
|
132
280
|
`cursor-init` in a routine update pass do it. Set
|
|
133
281
|
`MCPBOX_NO_UPDATE_CHECK=1` to disable the registry lookup entirely (air-gapped
|
|
134
282
|
installs, CI).
|
|
@@ -148,7 +296,7 @@ that provide Claude's `/mcpbox:*` commands, plus `skills/mcpbox` from the shared
|
|
|
148
296
|
plain policy (`BLOCK_BODY_PLAIN`). Codex selects these skills by their
|
|
149
297
|
descriptions; they are not user-entered slash commands.
|
|
150
298
|
|
|
151
|
-
All
|
|
299
|
+
All five agents accept `mcpbox mode [off|lite|full]` through the managed
|
|
152
300
|
policy. Claude also exposes `/mcpbox:mode`, Cursor exposes `/mcpbox-mode`, and
|
|
153
301
|
the shared value lives in `~/.agents/mcpbox/mode`.
|
|
154
302
|
|
|
@@ -158,23 +306,68 @@ Kimi specifics:
|
|
|
158
306
|
`~/.kimi-code/config.toml`; `$KIMI_CODE_HOME` is honored). One
|
|
159
307
|
`/mcp-config login mcpbox` OAuth then covers every project.
|
|
160
308
|
- The hook scripts (`SessionStart` notices, `UserPromptSubmit` routing
|
|
161
|
-
hints, `PostToolUse` claim tracking, `Stop` guard) are the same ones the Claude plugin ships;
|
|
309
|
+
hints, `PostToolUse` claim/write tracking, `Stop` guard) are the same ones the Claude plugin ships;
|
|
162
310
|
`kimi-init` copies them into `~/.kimi-code/mcpbox/` so the config never
|
|
163
311
|
references an ephemeral npx cache path. `kimi-uninit` removes that directory.
|
|
164
312
|
|
|
165
313
|
Session gate (Claude, Codex, Cursor, Kimi) — one set of scripts, different
|
|
166
|
-
configs; `--surface=codex|cursor` selects the host's stdin/stdout wire
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
314
|
+
configs; `--surface=codex|cursor` selects the host's stdin/stdout wire. Kimi
|
|
315
|
+
uses `track-claims.mjs` and `stop.mjs` for claim tracking and the Stop gate:
|
|
316
|
+
|
|
317
|
+
- `hooks/session-gate.mjs start` — SessionStart (also after compaction): the
|
|
318
|
+
claim this session holds (from local hook state, so also unpaired/offline),
|
|
319
|
+
then this agent's `in_progress` claims and the repo's `in_review` tasks
|
|
320
|
+
(`scope_path` = the session cwd): a header, up to 10 tasks, and one
|
|
321
|
+
`… and N more` line when truncated; silent when there are none.
|
|
170
322
|
- `hooks/track-claims.mjs` — PostToolUse (Cursor: `afterMCPExecution`):
|
|
171
323
|
successful claims plus `daruma_plan_materialize` / `daruma_set_status` /
|
|
172
324
|
`daruma_comment` writes; a `kind=outcome` comment marks its task reported.
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
(
|
|
176
|
-
|
|
177
|
-
|
|
325
|
+
A claim is stored as a projection of the server claim, not a session entity
|
|
326
|
+
of its own: plan/task/run/claim ids, the claiming agent, expiry, MCP server,
|
|
327
|
+
paired workspace, git toplevel (worktree) and cwd. Only a parsed successful
|
|
328
|
+
`daruma_plan_drain_next` / `daruma_ready_drain` / `daruma_claim` result
|
|
329
|
+
makes one — an MCP error (`rule_blocked` included), a null drain, a busy
|
|
330
|
+
claim or an unknown shape do not. `daruma_release`, `daruma_complete` and
|
|
331
|
+
`daruma_set_status` off `in_progress` end it (`<session>.cleared`).
|
|
332
|
+
- `hooks/user-prompt-submit.mjs` — besides routing hints, one line with the
|
|
333
|
+
held claim's ids (`run_id` for the run step calls), or why the recorded
|
|
334
|
+
claim no longer counts: expired, unknown expiry (older records), another
|
|
335
|
+
paired workspace or another repo/worktree. No tracker call.
|
|
336
|
+
- `hooks/stop.mjs` — blocks while a task this session took (a claim, or
|
|
337
|
+
`daruma_set_status` to `in_progress`) is `todo`/`in_progress` and the
|
|
338
|
+
session has not settled it since: `daruma_complete`, `daruma_release`,
|
|
339
|
+
`daruma_set_status` to `todo`/`in_review`/`blocked`/`done`, or a
|
|
340
|
+
`kind=outcome` comment. Creating tasks (`daruma_plan_materialize`) or
|
|
341
|
+
commenting on them takes nothing, so a session that only planned ends
|
|
342
|
+
freely; a task the server shows closed or held by another claim is not
|
|
343
|
+
pending. `<session>.tracked` records the kind of each write
|
|
344
|
+
(`via`: `materialize`, `set_status:<status>`, `comment:<kind>`); older
|
|
345
|
+
records without it keep the former rule. Two reminders per pending
|
|
346
|
+
set, then a warning (Cursor: `followup_message`, and the release after two
|
|
347
|
+
reminders is silent — Cursor has no warning field). A claim the server no
|
|
348
|
+
longer shows (task out of `in_progress`, another claim holder) is cleared
|
|
349
|
+
from the projection; an unread task (offline, no access) clears nothing.
|
|
350
|
+
- `hooks/session-gate.mjs end` — SessionEnd: releases the exact claim generation recorded by this session.
|
|
351
|
+
On a server without generation-aware release, the claim expires normally.
|
|
352
|
+
- `hooks/edit-gate.mjs` — PreToolUse, **Claude Code only**: claim-before-edit
|
|
353
|
+
gate over the same claim projection (no tracker call, no model call). A held
|
|
354
|
+
claim that still counts here lets every call through. Without one, coverage
|
|
355
|
+
is **partial** and stated as such:
|
|
356
|
+
- `Edit` / `Write` / `MultiEdit` / `NotebookEdit` — the first-line surface;
|
|
357
|
+
- `Bash` / `PowerShell` — commands are **not** classified (no regex over
|
|
358
|
+
arbitrary shell); every command but a narrow read-only exception
|
|
359
|
+
(`git status|diff|log|show|rev-parse`, `ls`, `pwd` — one plain command, no
|
|
360
|
+
character the shell interprets, no `--output`/`--ext-diff`/`--textconv`)
|
|
361
|
+
gets a consultative note. Advisory for shell, not a security boundary;
|
|
362
|
+
- Serena MCP tools outside its read-only set (`find_symbol`, `read_file`,
|
|
363
|
+
`search_for_pattern`, …) — same as shell.
|
|
364
|
+
|
|
365
|
+
Other MCP tools, subagents, Codex/Cursor/Kimi and claims made outside the
|
|
366
|
+
session's MCP tools (`mcporter`, another session) are not seen by the gate.
|
|
367
|
+
`MCPBOX_EDIT_GATE` selects the mode: `advisory` (default) adds a context
|
|
368
|
+
note once per session and surface; `strict` (opt-in pilot on one host, not a
|
|
369
|
+
default) denies the edit tools and asks the human for shell/Serena; `off`
|
|
370
|
+
disables the gate.
|
|
178
371
|
|
|
179
372
|
Codex and Cursor run copies in `~/.agents/mcpbox/harness/` (written by
|
|
180
373
|
`codex-init` / `cursor-init`), never the ephemeral npx cache.
|
|
@@ -189,7 +382,8 @@ mcpbox-claude codex-uninit [--dir DIR]
|
|
|
189
382
|
mcpbox-claude codex-skill User-level routing skill only (Codex without the plugin).
|
|
190
383
|
mcpbox-claude codex-skill-retire Remove that user-level copy once the plugin ships it.
|
|
191
384
|
mcpbox-claude cursor-init [--dir DIR] .cursor/rules policy + .cursor/mcp.json server
|
|
192
|
-
|
|
385
|
+
+ session gate in ~/.cursor/hooks.json
|
|
386
|
+
(in $HOME: a sessionStart policy hook, not a rule).
|
|
193
387
|
mcpbox-claude cursor-uninit [--dir DIR]
|
|
194
388
|
mcpbox-claude kimi-init [--dir DIR] AGENTS.md policy + ~/.kimi-code/mcp.json server
|
|
195
389
|
+ ~/.kimi-code/config.toml [[hooks]].
|
|
@@ -197,8 +391,10 @@ mcpbox-claude kimi-uninit [--dir DIR]
|
|
|
197
391
|
mcpbox-claude opencode-init [--dir DIR] AGENTS.md policy + `mcpbox` entry under
|
|
198
392
|
"mcp" in ~/.config/opencode/opencode.json.
|
|
199
393
|
mcpbox-claude opencode-uninit [--dir DIR]
|
|
200
|
-
mcpbox-claude doctor [--json] Check the mcpbox MCP server + policy are wired
|
|
201
|
-
|
|
394
|
+
mcpbox-claude doctor [--json] Check the mcpbox MCP server + policy are wired;
|
|
395
|
+
run the mcpbox hooks as their host does
|
|
396
|
+
(exit code + stderr, see Windows / Codex).
|
|
397
|
+
mcpbox-claude mode [off|lite|full] Show or set the shared prompt-hint mode.
|
|
202
398
|
mcpbox-claude git-hook [install|uninstall] [--dir DIR]
|
|
203
399
|
git prepare-commit-msg hook: adds
|
|
204
400
|
"Daruma-Task: <id>" for the work/<id> branch,
|
|
@@ -223,7 +419,17 @@ UNLICENSED — MCPBox is a closed SaaS.
|
|
|
223
419
|
If a parent already has a managed MCPBox block, init inherits it and removes only
|
|
224
420
|
the requested directory's redundant managed block. Other local instructions and
|
|
225
421
|
parent files are preserved. A managed-only child file is removed. Re-running init
|
|
226
|
-
is idempotent;
|
|
422
|
+
is idempotent; malformed markers are refused.
|
|
423
|
+
|
|
424
|
+
No policy file is written through a symlink or hard link: it is shared with
|
|
425
|
+
another path (`AGENTS.md -> CLAUDE.md`, a parent's `CLAUDE.md` linked into a
|
|
426
|
+
child), so an edit there would change that path too. `init`, `codex-init`,
|
|
427
|
+
`kimi-init` and `opencode-init` check `CLAUDE.md` / `AGENTS.md` before every
|
|
428
|
+
write and fail with `Refusing to write policy through symlink/hardlink`; the
|
|
429
|
+
`*-uninit` commands leave such a file as is and report it. Session-start sync
|
|
430
|
+
skips linked files the same way. User configs (`~/.codex/config.toml`,
|
|
431
|
+
`~/.kimi-code/config.toml`) are written through a symlink on purpose — dotfile
|
|
432
|
+
managers keep them as links.
|
|
227
433
|
|
|
228
434
|
`doctor --json` reports `policy_paths` and `policy_duplicate`; duplicate blocks
|
|
229
435
|
make readiness false. Parent blocks are not refreshed by a child install: run init
|
|
@@ -247,3 +453,32 @@ Routing and the execution-path verification rule before editing are supplied by
|
|
|
247
453
|
MCP `initialize.instructions` (`PLATFORM_INSTRUCTIONS` in
|
|
248
454
|
`crates/cloud-api/src/v1_gateway.rs`); clients without command skills use the plain tool
|
|
249
455
|
entry points. Reconnect the MCP server if its instructions are unavailable.
|
|
456
|
+
|
|
457
|
+
Pipeline and advisor calls are optional in every mode. Each fresh hosted `tools/list` reflects the current workspace provider capabilities. Provider-only discovery requires workspace-wide project access, an owner/admin role and agent dispatch capability. The complexity tool also requires the full profile. The advisor still accepts direct calls from existing sessions under its usual authorization and can return null advice. Clients caching a catalogue can refresh it by listing tools again or reconnecting.
|
|
458
|
+
|
|
459
|
+
## Audit findings
|
|
460
|
+
|
|
461
|
+
Use `daruma_audit_findings` with the project ID to list open findings. Pass a finding ID to read its detail and history. Use `daruma_audit_finding_ack` to change its status. Both tools are in the default profile. For REST clients:
|
|
462
|
+
|
|
463
|
+
- project ids: `daruma_project_list` (one repo path can map to two ids —
|
|
464
|
+
list findings for each).
|
|
465
|
+
- token: `access_token` in `~/.agents/mcpbox/credentials.json` (created by
|
|
466
|
+
`npx -y @mcpbox/mcpbox-claude@latest login`).
|
|
467
|
+
- list: `curl -H "Authorization: Bearer $TOKEN" -H "X-Daruma-Plugin-Contract: 1"
|
|
468
|
+
"https://mcpbox.ru/v1/audit/findings?project_id=<id>&status=open"`
|
|
469
|
+
(optional `severity`, `category`); one: `GET /v1/audit/findings/<id>`.
|
|
470
|
+
- set status for a finding without a plan revision: `curl -X POST -H "Authorization: Bearer $TOKEN" -H "X-Daruma-Plugin-Contract: 1"
|
|
471
|
+
-H "Content-Type: application/json" -d '{"status":"resolved"}'
|
|
472
|
+
https://mcpbox.ru/v1/audit/findings/<id>/status`; body values: open,
|
|
473
|
+
acknowledged, muted or resolved.
|
|
474
|
+
|
|
475
|
+
For a revision-bound `critique.*` finding, read its detail and `history` first.
|
|
476
|
+
Post `acknowledged` with the finding's current `plan_revision`, a non-empty
|
|
477
|
+
`reason`, and `evidence_ids` from the plan or the task named in the finding.
|
|
478
|
+
An independent reviewer sends `muted` or `resolved` with the same required
|
|
479
|
+
fields. The reviewer must be independent of both the finding author and the respondent.
|
|
480
|
+
|
|
481
|
+
Triage one finding at a time, never one task per finding.
|
|
482
|
+
`task.duplicate_candidate`: read both tasks — a done/cancelled side resolves
|
|
483
|
+
it at once; two active tasks need the human's call or a `relates_to` link.
|
|
484
|
+
`task.no_acceptance_criteria`: add the criterion to the task, then resolve.
|
package/bin/mcpbox-claude.mjs
CHANGED
|
@@ -3,10 +3,11 @@
|
|
|
3
3
|
//
|
|
4
4
|
// Subcommands:
|
|
5
5
|
// mcpbox-claude init [--dir DIR] Write the managed CLAUDE.md policy block
|
|
6
|
-
// (
|
|
6
|
+
// (Daruma plans and optional idea pipeline). Idempotent.
|
|
7
7
|
// mcpbox-claude uninit [--dir DIR] Remove the managed policy block.
|
|
8
|
-
// mcpbox-claude doctor [--json] Check the mcpbox MCP server + policy are wired
|
|
9
|
-
//
|
|
8
|
+
// mcpbox-claude doctor [--json] Check the mcpbox MCP server + policy are wired,
|
|
9
|
+
// and run the mcpbox hooks the way their host does.
|
|
10
|
+
// mcpbox-claude mode [off|lite|full] Get/set prompt hints.
|
|
10
11
|
// mcpbox-claude --version | --help
|
|
11
12
|
//
|
|
12
13
|
// ponytail: no orchestrator (start/team-from-plan) or self-update here — the
|
|
@@ -46,6 +47,7 @@ import {
|
|
|
46
47
|
} from "../lib/cursor.mjs";
|
|
47
48
|
import { installKimi, removeKimi } from "../lib/kimi.mjs";
|
|
48
49
|
import { installCodexHooks, installCursorHooks, removeCodexHooks, removeCursorHooks } from "../lib/harness-hooks.mjs";
|
|
50
|
+
import { formatHookReport, hookReport } from "../lib/hook-doctor.mjs";
|
|
49
51
|
import { installOpencode, removeOpencode } from "../lib/opencode.mjs";
|
|
50
52
|
import { readMode, writeMode, MODES } from "../lib/mode.mjs";
|
|
51
53
|
import { installGitHook, prepareCommitMsg, removeGitHook } from "../lib/git-trailer.mjs";
|
|
@@ -57,7 +59,7 @@ const HELP = `mcpbox-claude v${pkg.version} — MCPBox agent harness (Claude / C
|
|
|
57
59
|
|
|
58
60
|
Usage:
|
|
59
61
|
mcpbox-claude init [--dir DIR] Write the managed CLAUDE.md policy block
|
|
60
|
-
(
|
|
62
|
+
(Daruma plans and optional idea pipeline). Idempotent.
|
|
61
63
|
mcpbox-claude uninit [--dir DIR] Remove the managed CLAUDE.md policy block.
|
|
62
64
|
mcpbox-claude codex-init [--dir DIR] Write AGENTS.md policy, ~/.codex/config.toml
|
|
63
65
|
[mcp_servers.mcpbox], the mcpbox skill
|
|
@@ -81,9 +83,12 @@ Usage:
|
|
|
81
83
|
opencode.json. Idempotent.
|
|
82
84
|
mcpbox-claude opencode-uninit [--dir DIR]
|
|
83
85
|
mcpbox-claude doctor [--json] Check the mcpbox MCP server + policy are wired.
|
|
86
|
+
Runs the mcpbox entries of ~/.codex/hooks.json,
|
|
87
|
+
~/.cursor/hooks.json and ~/.claude/settings.json
|
|
88
|
+
as the host would and prints exit code + stderr.
|
|
84
89
|
mcpbox-claude login Pair this machine so hooks load project knowledge.
|
|
85
90
|
mcpbox-claude logout Forget the pairing token.
|
|
86
|
-
mcpbox-claude mode [off|lite|full] Get/set
|
|
91
|
+
mcpbox-claude mode [off|lite|full] Get/set prompt hints.
|
|
87
92
|
mcpbox-claude git-hook [install|uninstall] [--dir DIR]
|
|
88
93
|
Manage the git prepare-commit-msg hook that adds
|
|
89
94
|
"Daruma-Task: <id>" trailers (work/<id> branch or
|
|
@@ -121,6 +126,7 @@ const VERB = {
|
|
|
121
126
|
"removed-file": "Removed",
|
|
122
127
|
missing: "No mcpbox block found at",
|
|
123
128
|
malformed: "Left alone (broken or repeated mcpbox markers — fix by hand):",
|
|
129
|
+
linked: "Left alone (symlink/hardlink — edit the real file by hand):",
|
|
124
130
|
};
|
|
125
131
|
|
|
126
132
|
async function cmdInit(rest) {
|
|
@@ -277,11 +283,11 @@ function mcpServerPresent() {
|
|
|
277
283
|
async function cmdMode(rest) {
|
|
278
284
|
const [arg] = rest;
|
|
279
285
|
if (!arg || arg === "--show") {
|
|
280
|
-
process.stdout.write(`mcpbox
|
|
286
|
+
process.stdout.write(`mcpbox prompt-hint mode: ${readMode()} (${MODES.join(" | ")})\n`);
|
|
281
287
|
return;
|
|
282
288
|
}
|
|
283
289
|
const m = await writeMode(arg); // throws on invalid → caught by main().catch
|
|
284
|
-
process.stdout.write(`✓ mcpbox
|
|
290
|
+
process.stdout.write(`✓ mcpbox prompt-hint mode: ${m}\n`);
|
|
285
291
|
}
|
|
286
292
|
|
|
287
293
|
// Pairs this machine with a workspace so hooks can put its project knowledge
|
|
@@ -342,6 +348,9 @@ async function cmdDoctor(rest) {
|
|
|
342
348
|
const competing = await competingPolicyPaths({ projectDir });
|
|
343
349
|
// Not required: without it hooks hint at the knowledge instead of loading it.
|
|
344
350
|
const paired = (await readCredentials()) !== null;
|
|
351
|
+
// Diagnosis only, not part of READY: a broken hook does not unwire the
|
|
352
|
+
// server or the policy, and the section names its own fix.
|
|
353
|
+
const hooks = await hookReport({ cwd: resolve(projectDir ?? process.cwd()) });
|
|
345
354
|
|
|
346
355
|
if (json) {
|
|
347
356
|
process.stdout.write(JSON.stringify({
|
|
@@ -357,6 +366,7 @@ async function cmdDoctor(rest) {
|
|
|
357
366
|
cursor_rule_stale_paths: cursorStale,
|
|
358
367
|
knowledge_paired: paired,
|
|
359
368
|
policy_server: policyServer,
|
|
369
|
+
hooks,
|
|
360
370
|
}) + "\n");
|
|
361
371
|
} else {
|
|
362
372
|
const mark = (v) => (v === true ? "✓" : v === false ? "✗" : "?");
|
|
@@ -373,10 +383,13 @@ async function cmdDoctor(rest) {
|
|
|
373
383
|
cursorStale.map((p) => ` ${p} (stale — run: mcpbox-claude cursor-init)\n`).join("") +
|
|
374
384
|
competing.map((p) => ` ! ${p} also holds a daruma CLI policy block — keep one\n`).join("") +
|
|
375
385
|
`Project knowledge: ${paired ? "✓ paired" : "hint only — run: npx -y @mcpbox/mcpbox-claude login"}\n` +
|
|
386
|
+
formatHookReport(hooks) +
|
|
376
387
|
`${ready ? "READY" : "NOT READY — run: npx @mcpbox/mcpbox setup"}\n`
|
|
377
388
|
);
|
|
378
389
|
}
|
|
379
|
-
|
|
390
|
+
// A pipe is asynchronous on macOS: exiting right after the write cuts the
|
|
391
|
+
// report at the first 8 KiB. Same flush as hooks/bootstrap.mjs.
|
|
392
|
+
process.stdout.write("", () => process.exit(ready ? 0 : 1));
|
|
380
393
|
}
|
|
381
394
|
|
|
382
395
|
// The marketplace repo is private, so `claude plugin marketplace add
|
package/commands/close.md
CHANGED
|
@@ -16,4 +16,6 @@ The user invoked `/mcpbox:close` (optionally with a task id or title in `$ARGUME
|
|
|
16
16
|
comment, so no separate `daruma_comment` call. Fallback:
|
|
17
17
|
`daruma_set_status status=done comment={ body: "<summary>", kind: "outcome" }`
|
|
18
18
|
(the comment lands atomically with the transition).
|
|
19
|
+
When the completion schema includes `side_findings`, review them first and pass
|
|
20
|
+
`{reviewed:true, occurrence_ids:[…]}` on either transition. Use an empty list only after review.
|
|
19
21
|
3. Confirm: `✓ closed <id> — <title>`. Do not touch other tasks.
|
package/commands/mine.md
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Show
|
|
2
|
+
description: Show project tasks in progress or in review.
|
|
3
3
|
---
|
|
4
4
|
|
|
5
5
|
The user invoked `/mcpbox:mine`.
|
|
6
6
|
|
|
7
7
|
## Steps
|
|
8
8
|
|
|
9
|
-
1. Resolve project
|
|
9
|
+
1. Resolve project as in `/mcpbox:tasks`.
|
|
10
10
|
2. `daruma_list project_id=<resolved> status="in_progress,in_review" limit=30`.
|
|
11
|
-
3. Render the same compact table as `/mcpbox:tasks`, titled `##
|
|
12
|
-
4. If empty: "
|
|
11
|
+
3. Render the same compact table as `/mcpbox:tasks`, titled `## Project tasks in progress or in review — <N>`. These are project-wide tasks, not necessarily claimed by this session. If the response has more pages, say so.
|
|
12
|
+
4. If empty: "No project tasks in progress or in review." On error, print it verbatim. Read-only.
|
package/commands/mode.md
CHANGED
|
@@ -1,30 +1,22 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Set
|
|
2
|
+
description: Set MCPBox prompt hints (off | lite | full).
|
|
3
3
|
---
|
|
4
4
|
|
|
5
5
|
The user invoked `/mcpbox:mode` with `$ARGUMENTS` = `off` | `lite` | `full` (empty → show current).
|
|
6
6
|
|
|
7
7
|
## What each level does
|
|
8
8
|
|
|
9
|
-
Mode sets how eagerly to suggest `mcpbox_pipeline_run`: `off`
|
|
9
|
+
Mode sets how eagerly to suggest `mcpbox_pipeline_run`: `off` hides pipeline hints, `lite` matches explicit intents, `full` also reminds you to skip tracking operational work.
|
|
10
10
|
|
|
11
11
|
- **off** — no pipeline nudging; don't raise the pipeline on your own.
|
|
12
12
|
- **lite** (default) — nudge toward the pipeline only when the input explicitly mentions it
|
|
13
13
|
(pipeline / maturity / handoff / конвейер …).
|
|
14
|
-
- **full** —
|
|
15
|
-
undecided direction matures through the pipeline (`mcpbox_pipeline_run` → handoff)
|
|
16
|
-
before it becomes a task.
|
|
17
|
-
|
|
18
|
-
The mode only tunes how actively you *offer* the pipeline. It does not change where work
|
|
19
|
-
lands — that is the MCP server's routing rule: decided-and-bounded work and
|
|
20
|
-
follow-ups extending a run that already handed off go straight to daruma; raw material — and
|
|
21
|
-
anything belonging to a run still in flight — goes through the pipeline.
|
|
14
|
+
- **full** — add the operational reminder to matched intents. Unmatched prompts stay silent. Pipeline and advisor calls are optional in every mode.
|
|
22
15
|
|
|
23
16
|
The level persists across sessions (stored in `~/.agents/mcpbox/mode`) and is read by the
|
|
24
17
|
UserPromptSubmit hook, which injects the matching reminder on each prompt.
|
|
25
18
|
|
|
26
|
-
|
|
27
|
-
MCP URL (`?mode=`), so re-run it after changing the mode.
|
|
19
|
+
Hosts with a configured MCP URL record its `?mode=` in metrics. Re-run the host’s `*-init` command to refresh that URL.
|
|
28
20
|
|
|
29
21
|
## Steps
|
|
30
22
|
|
package/commands/next.md
CHANGED
|
@@ -7,10 +7,10 @@ to the user/agent to actually execute it.
|
|
|
7
7
|
|
|
8
8
|
## Steps
|
|
9
9
|
|
|
10
|
-
1. Resolve project
|
|
11
|
-
2. Active plan: `daruma_plan_list` with `status = "active"`, `sort = "updated"`,
|
|
10
|
+
1. Resolve the project as in `/mcpbox:tasks`.
|
|
11
|
+
2. Active plan: `daruma_plan_list` with the resolved project_id, `status = "active"`, `sort = "updated"`,
|
|
12
12
|
`limit = 1` — the most recently updated plan (the default order is by creation).
|
|
13
|
-
If none, stop with "no active plan — decided work: `daruma_plan_materialize`;
|
|
13
|
+
If none, stop with "no active plan — decided work: `daruma_plan_materialize`; optional exploration: `/mcpbox:pipeline-run`".
|
|
14
14
|
3. `daruma_plan_drain_next` with the plan id. The server atomically picks the next
|
|
15
15
|
ready (unblocked) task and claims it for this session; it returns null when no
|
|
16
16
|
unclaimed ready task remains. Keep the returned `run_id`: the server opened that
|
|
@@ -40,6 +40,7 @@ to the user/agent to actually execute it.
|
|
|
40
40
|
then daruma_run_abort run_id=<run_id> reason=<reason>
|
|
41
41
|
```
|
|
42
42
|
|
|
43
|
+
When the completion schema includes `side_findings`, review and include them as in `/mcpbox:close`.
|
|
43
44
|
An open run keeps the plan from auto-closing after its last task; the
|
|
44
45
|
`plan_close_blocked_by_run` warning names it in `details.run_id`.
|
|
45
46
|
|
package/commands/pipeline-run.md
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Open an mcpbox pipeline run from a raw idea;
|
|
2
|
+
description: Open an mcpbox pipeline run from a raw idea; hand off a ready action packet to Daruma.
|
|
3
3
|
---
|
|
4
4
|
|
|
5
5
|
The user invoked `/mcpbox:pipeline-run` with a raw idea/request in `$ARGUMENTS`.
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
never by materializing it directly.
|
|
7
|
+
Only a ready action packet can become a task through handoff. Report a terminal run without a packet and stop.
|
|
9
8
|
|
|
10
9
|
## Steps
|
|
11
10
|
|
|
@@ -18,7 +17,8 @@ never by materializing it directly.
|
|
|
18
17
|
`run_id` immediately while the run proceeds in the background. Poll
|
|
19
18
|
`mcpbox_trace_get { run_id }` until the status is no longer `running`.
|
|
20
19
|
3. On failure, report the reason from `mcpbox_trace_get`; do not hand off an
|
|
21
|
-
incomplete run.
|
|
20
|
+
incomplete run. For `needs_input`, show the recorded question and use
|
|
21
|
+
`mcpbox_pipeline_answer` with the user’s answer before continuing. Recovery: a run `failed` at layer L → retry with
|
|
22
22
|
`mcpbox_pipeline_advance { run_id, layer: L }` after fixing the input; fujin
|
|
23
23
|
`not_ready` → advance from `yatagarasu`; or ask the owner. Never
|
|
24
24
|
`daruma_plan_materialize` the idea directly to get around a failed run.
|
package/commands/plan.md
CHANGED
|
@@ -6,10 +6,10 @@ The user invoked `/mcpbox:plan`.
|
|
|
6
6
|
|
|
7
7
|
## Steps
|
|
8
8
|
|
|
9
|
-
1. Resolve project
|
|
10
|
-
2. `daruma_plan_list status="draft,active" sort="updated" limit=1` — the most recently
|
|
9
|
+
1. Resolve the project as in `/mcpbox:tasks`.
|
|
10
|
+
2. `daruma_plan_list project_id=<resolved> status="draft,active" sort="updated" limit=1` — the most recently
|
|
11
11
|
updated plan (the default order is by creation, and its first page can miss it).
|
|
12
|
-
If none, stop with "no active plan — decided work: `daruma_plan_materialize`;
|
|
12
|
+
If none, stop with "no active plan — decided work: `daruma_plan_materialize`; optional exploration: `/mcpbox:pipeline-run`".
|
|
13
13
|
3. For the chosen plan, `daruma_plan_get view="tasks"` (single call — do not enumerate the archive).
|
|
14
14
|
It lists every plan task (done included) with `status`, `priority`, `depends_on` and
|
|
15
15
|
`blocked_by`; the default `progress` view caps each group at five open tasks.
|
|
@@ -25,4 +25,4 @@ The user invoked `/mcpbox:plan`.
|
|
|
25
25
|
|
|
26
26
|
- Progress bar from `progress.tasks_done`/`progress.tasks_total`; one row per task in plan order.
|
|
27
27
|
- Tasks with a non-empty `blocked_by` marked ⛔ with those blocker ids.
|
|
28
|
-
5. Do not call `daruma_plan_list status=completed` (token-heavy). Read-only.
|
|
28
|
+
5. Do not call `daruma_plan_list project_id=<resolved> status=completed` (token-heavy). Read-only.
|