@mu-crew/mu 3.13.3 → 4.1.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.
- package/AGENTS.md +73 -35
- package/README.md +71 -57
- package/dist/chunk-4ULY3ZKO.js +4482 -0
- package/dist/chunk-4ULY3ZKO.js.map +1 -0
- package/dist/chunk-7M634JMD.js +375 -0
- package/dist/chunk-7M634JMD.js.map +1 -0
- package/dist/{chunk-3BARPJLY.js → chunk-PZ5GOCWH.js} +16 -2
- package/dist/chunk-PZ5GOCWH.js.map +1 -0
- package/dist/chunk-SS7NQSSZ.js +3660 -0
- package/dist/chunk-SS7NQSSZ.js.map +1 -0
- package/dist/chunk-UCZPJX7K.js +14253 -0
- package/dist/chunk-UCZPJX7K.js.map +1 -0
- package/dist/{cli-CKOMHBXV.js → cli-TV3N47AZ.js} +7317 -4593
- package/dist/cli-TV3N47AZ.js.map +1 -0
- package/dist/cli.js +2 -3
- package/dist/cli.js.map +1 -1
- package/dist/errors-GRONKWFS.js +65 -0
- package/dist/extension/mu-pi.js +1632 -837
- package/dist/extension/mu-pi.js.map +1 -1
- package/dist/index.d.ts +4067 -2561
- package/dist/index.js +614 -297
- package/dist/index.js.map +1 -1
- package/dist/tui-FUBQ326D.js +1848 -0
- package/dist/tui-FUBQ326D.js.map +1 -0
- package/docs/ARCHITECTURE.md +118 -66
- package/docs/VOCABULARY.md +113 -49
- package/docs/guide/README.md +3 -3
- package/docs/guide/backends.md +8 -4
- package/docs/guide/cleanup.md +69 -33
- package/docs/guide/delegate.md +149 -66
- package/docs/guide/dispatch.md +148 -53
- package/docs/guide/getting-started.md +37 -44
- package/docs/guide/other-agent-clis.md +102 -0
- package/docs/guide/recovery.md +31 -50
- package/docs/guide/remote.md +122 -45
- package/docs/guide/sql.md +104 -24
- package/docs/guide/stop-a-worker.md +30 -37
- package/docs/guide/sync.md +11 -3
- package/docs/guide/upgrade.md +93 -43
- package/docs/reference/env.md +24 -32
- package/docs/reference/naming.md +14 -7
- package/docs/reference/surface-contract.md +153 -0
- package/package.json +33 -11
- package/prompts/mu-debug.md +3 -1
- package/prompts/mu-refute.md +2 -1
- package/prompts/mu-research.md +3 -1
- package/prompts/mu-review.md +2 -1
- package/prompts/mu-rules-audit.md +5 -4
- package/prompts/mu-sweep.md +2 -1
- package/prompts/mu-tournament.md +4 -2
- package/prompts/mu-until.md +3 -1
- package/prompts/ultrathink.md +1 -1
- package/skills/mu/SKILL.md +60 -291
- package/skills/mu/recipes/adversarial-review.md +12 -103
- package/skills/mu/recipes/brief.md +14 -61
- package/skills/mu/recipes/course-correct.md +23 -0
- package/skills/mu/recipes/findings.md +17 -111
- package/skills/mu/recipes/models.md +17 -92
- package/skills/mu/recipes/move.md +14 -0
- package/skills/mu/recipes/orchestrator-loop.md +20 -119
- package/skills/mu/recipes/recovery.md +8 -29
- package/skills/mu/recipes/remote-workers.md +17 -318
- package/skills/mu/recipes/tasks-or-calls.md +15 -78
- package/skills/mu/recipes/test-health.md +19 -77
- package/skills/mu/recipes/worker.md +17 -24
- package/dist/chunk-45KQLMEL.js +0 -2908
- package/dist/chunk-45KQLMEL.js.map +0 -1
- package/dist/chunk-G434JKV2.js +0 -641
- package/dist/chunk-G434JKV2.js.map +0 -1
- package/dist/chunk-KUGUFBWH.js +0 -12527
- package/dist/chunk-KUGUFBWH.js.map +0 -1
- package/dist/chunk-QITLNZEM.js +0 -87
- package/dist/chunk-QITLNZEM.js.map +0 -1
- package/dist/chunk-VIEYQMQA.js +0 -393
- package/dist/chunk-VIEYQMQA.js.map +0 -1
- package/dist/chunk-WI6AWCMK.js +0 -19
- package/dist/chunk-WI6AWCMK.js.map +0 -1
- package/dist/cli-CKOMHBXV.js.map +0 -1
- package/dist/devtools-LS4ZEPWM.js +0 -3772
- package/dist/devtools-LS4ZEPWM.js.map +0 -1
- package/dist/tui-LFJ5P4Y2.js +0 -40956
- package/dist/tui-LFJ5P4Y2.js.map +0 -1
- package/dist/tui-sync-worker.js +0 -17
- package/dist/tui-sync-worker.js.map +0 -1
- package/dist/yank-XDOONQSL.js +0 -13
- package/dist/yank-XDOONQSL.js.map +0 -1
- package/docs/ROADMAP.md +0 -123
- package/docs/VISION.md +0 -298
- package/docs/architecture/control-socket.md +0 -142
- package/docs/architecture/dag.md +0 -117
- package/docs/architecture/mux.md +0 -167
- package/docs/architecture/ops-log.md +0 -160
- package/docs/architecture/sdk.md +0 -187
- package/docs/architecture/sync.md +0 -159
- package/docs/architecture/tui.md +0 -165
- package/docs/guide/tui.md +0 -98
- package/docs/history/CHANGELOG-pre-3.md +0 -4866
- package/docs/img/tui-dashboard.png +0 -0
- package/docs/specs/2026-09-28-agent-state-from-murmur.md +0 -333
- package/docs/specs/2026-09-29-task-substates.md +0 -247
- package/docs/specs/2026-10-03-keep-driving-nudge.md +0 -163
- package/docs/specs/2026-10-21-fast-and-slow-gates.md +0 -229
- package/skills/mu/recipes/backlog-triage.md +0 -45
- package/skills/mu/recipes/codemode-driver.md +0 -118
- package/skills/mu/recipes/deep-research.md +0 -69
- package/skills/mu/recipes/drift-audit.md +0 -75
- package/skills/mu/recipes/fan-out.md +0 -42
- package/skills/mu/recipes/hypothesis-panel.md +0 -48
- package/skills/mu/recipes/long-run.md +0 -32
- package/skills/mu/recipes/loop-until-done.md +0 -45
- package/skills/mu/recipes/plan.md +0 -67
- package/skills/mu/recipes/refute.md +0 -55
- package/skills/mu/recipes/review-panel.md +0 -65
- package/skills/mu/recipes/rules-audit.md +0 -89
- package/skills/mu/recipes/tournament.md +0 -44
- package/skills/mu/recipes/ultrathink.md +0 -86
- package/skills/mu/recipes/watcher.md +0 -28
- package/skills/mu/recipes/waves.md +0 -21
- /package/dist/{chunk-3BARPJLY.js.map → errors-GRONKWFS.js.map} +0 -0
package/docs/reference/naming.md
CHANGED
|
@@ -45,6 +45,11 @@ clears all blockers.
|
|
|
45
45
|
`mu agent spawn <name> -w scratch`, and `mu workstream init scratch`
|
|
46
46
|
is rejected. The `mu-` prefix is reserved too.
|
|
47
47
|
|
|
48
|
+
Why the shape: tmux rewrites `.` to `_` in a session name and reserves `:` as a
|
|
49
|
+
target separator, so a name holding either would make a session mu cannot look
|
|
50
|
+
up again. mu adds `mu-` to name the session, so a `mu-` name would be
|
|
51
|
+
double-prefixed.
|
|
52
|
+
|
|
48
53
|
## Workstream names
|
|
49
54
|
|
|
50
55
|
Name a workstream `<project>-<purpose>`: `hail-auth`, `swayward-v2`,
|
|
@@ -54,7 +59,7 @@ groups by project. `workstream init` prints a hint for a name with no
|
|
|
54
59
|
`-`.
|
|
55
60
|
|
|
56
61
|
- **One workstream per effort.** Tear it down when the effort ships;
|
|
57
|
-
the ops log keeps the history
|
|
62
|
+
the ops log keeps the history. A long-lived
|
|
58
63
|
catch-all becomes a log nobody reads: `mu state` hints once a
|
|
59
64
|
workstream passes 300 tasks with fewer than 10% open.
|
|
60
65
|
- **Ultrathink runs** get their own: `<project>-ut-<topic>`.
|
|
@@ -81,26 +86,28 @@ fixtures may use human names.
|
|
|
81
86
|
|
|
82
87
|
## File paths
|
|
83
88
|
|
|
84
|
-
The state dir is `MU_STATE_DIR`, else `$XDG_STATE_HOME/mu`, else
|
|
85
|
-
`~/.local/state/mu`.
|
|
89
|
+
The state dir is `MU_STATE_DIR`, else `$XDG_STATE_HOME/mu-next`, else
|
|
90
|
+
`~/.local/state/mu-next`. (`~/.local/state/mu` is 3.x's; the separate name keeps 4.0 off a 3.x DB.)
|
|
86
91
|
|
|
87
92
|
| Path | Contents |
|
|
88
93
|
| --- | --- |
|
|
89
94
|
| `<state-dir>/mu.db` | The SQLite DB for every workstream |
|
|
90
|
-
| `<state-dir>/
|
|
95
|
+
| `<state-dir>/worktrees/<workstream>/<agent>/` | Per-agent git worktree, created by `mu agent spawn --worktree` |
|
|
96
|
+
| `<state-dir>/delegate-sessions/<workstream>/<task>/` | A pane delegate's pi session (kept out of the caller's `/resume` list). `mu delegates prune` removes it with the call |
|
|
97
|
+
| `<state-dir>/delegate-process/<hash>/` | A mux-free delegate's receipt, `pi.log` and pi session. `mu delegates prune` removes it with the call |
|
|
91
98
|
| `<sync-dir>/<machine_id>.jsonl` | This machine's segment; `<sync-dir>` is `MU_SYNC_DIR` |
|
|
92
99
|
| `<sync-dir>/<machine_id>.manifest` | `{count, last_hlc, sha256}` for segment verification |
|
|
93
100
|
|
|
94
101
|
Never put `MU_DB_PATH` inside `MU_SYNC_DIR`: syncing a live SQLite
|
|
95
|
-
file and its `-wal` and `-shm` sidecars corrupts it.
|
|
96
|
-
|
|
102
|
+
file and its `-wal` and `-shm` sidecars corrupts it. Every verb
|
|
103
|
+
refuses to run (exit 4) when it happens.
|
|
97
104
|
|
|
98
105
|
The cache dir is `$XDG_CACHE_HOME/mu`, else `~/.cache/mu`. Anything in
|
|
99
106
|
it can be deleted at any time.
|
|
100
107
|
|
|
101
108
|
| Path | Contents |
|
|
102
109
|
| --- | --- |
|
|
103
|
-
| `<cache-dir>/delegate-
|
|
110
|
+
| `<cache-dir>/delegate-trace.log` | One JSON line per delegate wake send and pi lifecycle event, under `MU_DELEGATE_TRACE=1` |
|
|
104
111
|
|
|
105
112
|
mu reads no agent-template directory (`~/.pi/agent/agents/`,
|
|
106
113
|
`.pi/agents/`). A role is a name and a brief.
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
# Surface contract
|
|
2
|
+
|
|
3
|
+
The contract mu 4.0 is built to: what every result, wait, delegate and
|
|
4
|
+
CLOSE block promises an agent caller, and the budgets on what it reads.
|
|
5
|
+
Terms are in [VOCABULARY](../VOCABULARY.md), the module map in
|
|
6
|
+
[ARCHITECTURE](../ARCHITECTURE.md), the reasons in the
|
|
7
|
+
[design history](../history/mu-next-design/README.md). Where this page
|
|
8
|
+
and the source disagree, the source is right and this page is a bug.
|
|
9
|
+
|
|
10
|
+
A change that alters a contract here updates this page, ARCHITECTURE
|
|
11
|
+
(module map) and VOCABULARY (term) in the same commit as the code. No
|
|
12
|
+
module-map row, runnable guide snippet or `next` hint exists for code
|
|
13
|
+
that has not shipped.
|
|
14
|
+
|
|
15
|
+
## What ships
|
|
16
|
+
|
|
17
|
+
Schema 13, `CAPTURE_VERSION` 5, 26 classified tables and 4 views
|
|
18
|
+
(`PORTABLE_TABLES`: `workstreams`, `tasks`, `task_edges`, `task_notes`;
|
|
19
|
+
every other table is machine-local, see `src/db.ts`). The verbs and
|
|
20
|
+
their guarantees:
|
|
21
|
+
|
|
22
|
+
- **Output.** `{ok,data,next}` on stdout for every `--json` verb and
|
|
23
|
+
every failure; `next` is computed once per result (`computeNext`).
|
|
24
|
+
Task, log, state and notes reads are capped records.
|
|
25
|
+
- **Wait.** `mu wait` (typed refs, first event, one JSON result,
|
|
26
|
+
`resume`, `--all`, `--until-text`, `--wave`, `--blockers-of`,
|
|
27
|
+
`--on-stall exit|warn|steer|release`); `mu task wait` is its alias over
|
|
28
|
+
task refs; `mu agent wait` is the agent-keyed form over the same engine. Producers
|
|
29
|
+
(`spawn`, `send`, `claim --for`) arm a registered wait from real state.
|
|
30
|
+
- **Tasks and agents.** Batch `task add`, `--blocks`, note kinds,
|
|
31
|
+
`--if <rev>` fences on membership changes and destructive verbs,
|
|
32
|
+
task-bound spawn with receipts and replay, `mu agent check`, soft
|
|
33
|
+
teardown with a preview revision, `mu human-needed`.
|
|
34
|
+
- **Executor.** `mu task auto` and `mu next` (`--dry`, `--hold`,
|
|
35
|
+
`--workers`, `--refute`), `dispatch_host`.
|
|
36
|
+
- **Delegates.** A `mu_delegate` call is a `kind=delegate` task with a
|
|
37
|
+
durable `call_id` (`mu delegates`, wave tally, `mu_delegate_reissue`),
|
|
38
|
+
and `mu delegates run <call-id>` runs one with no multiplexer.
|
|
39
|
+
- **CLOSE block.** A pi worker's final `CLOSE:` lines are applied once
|
|
40
|
+
per settled run by the wait engine (`src/close-block.ts`).
|
|
41
|
+
- **Remote.** Host profiles, remote spawn, `agent collect`, the close
|
|
42
|
+
rule, remote command gates, recovery records.
|
|
43
|
+
- **Surfaces.** In-process `mu db query` (alias `mu sql`), five-tab
|
|
44
|
+
read-only dashboard, pi package (3.x's link verb is gone), `mu pi migrate`.
|
|
45
|
+
|
|
46
|
+
- **Settle wait.** The pi extension's keep-driving nudge is the settle
|
|
47
|
+
wait (`extension/nudge.ts`): every completed settle of an orchestrator
|
|
48
|
+
runs `mu wait --first --on-stall exit --json` as its callers (no shell
|
|
49
|
+
line parsed, no once-per-prompt latch) and continues the turn with the
|
|
50
|
+
event. It stops when nothing is owed, a `mu human-needed` stop is open,
|
|
51
|
+
the user cancels, or the wait fails. A cancelled wait drains through
|
|
52
|
+
`MuRunOpts.drainMs`. Skipped under `MU_REMOTE=1` and in a nested pi.
|
|
53
|
+
Delegate answers arrive through it (`v_settle_delivery`): a `delegate`
|
|
54
|
+
event's continuation carries that call's report (capped, with the
|
|
55
|
+
`mu task notes` pointer); a wave's waits for its siblings and shows ONE
|
|
56
|
+
summary. The pi message is only a **wake** (a pointer, no answer text)
|
|
57
|
+
when no settle wait will show an answer.
|
|
58
|
+
|
|
59
|
+
- **Delegates without a multiplexer.** `mu_delegate` registers in any
|
|
60
|
+
unmanaged pi. A spawn that fails `NoMultiplexerError` (only that error)
|
|
61
|
+
runs the call through `mu delegates run <call-id>`: one child
|
|
62
|
+
`pi --mode rpc`, no pane, no agents row, `transport: process`,
|
|
63
|
+
`attach: null`. Admission, record and cancel are unchanged; `keep` is
|
|
64
|
+
dropped; `/reload` leaves the run going; quit cancels it.
|
|
65
|
+
|
|
66
|
+
## Fixed contract
|
|
67
|
+
|
|
68
|
+
**Output.** Success `{ok:true,data,next}`; error `{ok:false,error,message,next,exit}`
|
|
69
|
+
on stdout with the real non-zero exit. `next` is `NextPlan`
|
|
70
|
+
`{mode:'seq'|'alt',commands:string[]}` or `null`; a `seq` is never
|
|
71
|
+
truncated. Op payloads keep history names; output keys equal SQL
|
|
72
|
+
column names, `id` is `local_id`. Ordinary result <= 4 KB, list record
|
|
73
|
+
<= 400 chars, a cut says `more=N`/`cut=N` and names the exact
|
|
74
|
+
retrieval command. Whole pinned brief, report and verdict are exempt
|
|
75
|
+
from the cap (they are the content). Text record: escaped, one record
|
|
76
|
+
per line; the exemption allows no multiline framing. NDJSON only for
|
|
77
|
+
explicitly streaming logs; `mu wait` is one object.
|
|
78
|
+
|
|
79
|
+
**Wait.** One `mu wait` over refs the caller owns. Default **first**
|
|
80
|
+
event (`--first-of` alias); `--all` / `--all-of` keeps the all-of
|
|
81
|
+
completion loop. Result `data`: `event` (alias `firing`: `kind`, `ref`,
|
|
82
|
+
`incarnation`, `runs`), `exit`, `snapshots`, `resume`, `timedOut`,
|
|
83
|
+
`cursor`. Event kinds: `closed settled input dead stall delegate
|
|
84
|
+
pane-exit exited pane-text heartbeat interrupted`. `exited` is a remote
|
|
85
|
+
command gate's own numeric status (`exit` is that code, 23 stays 23; under
|
|
86
|
+
`--all` the first nonzero). Timeout is `ok:true` with `timedOut`
|
|
87
|
+
and exit 0; dead 6, stall 7, interrupt 130. Heartbeat cap 1500 s.
|
|
88
|
+
`--until-idle`, `--until-text <re>` (bounded RegExp over authoritative
|
|
89
|
+
ctl `lastText` or the task report, never pane text for a settle; an agent
|
|
90
|
+
with no answering ctl socket matches its pane tail and ends the wait as the
|
|
91
|
+
distinct `pane-text` event, never `settled`; invalid or oversized rejects), `--status`, `--stuck-after`, `--on-stall exit|steer|release`
|
|
92
|
+
(steer and release only on `auto` tasks on this `dispatch_host`;
|
|
93
|
+
release reopens, never closes). SIGINT/SIGTERM emit one final snapshot;
|
|
94
|
+
**SIGKILL cannot, and no output is promised.** Unknown is never idle.
|
|
95
|
+
`send --wait` / `claim --for <w> --and-wait` enter the wait (one JSON document, the producer's
|
|
96
|
+
receipt as `data.sent` / `data.claimed`); spawn, send and claim arm a registered wait from real
|
|
97
|
+
state, not shell parsing (`v_wait_arming`: `src/cli/wait-arm.ts`).
|
|
98
|
+
|
|
99
|
+
**Delegates.** Every `mu_delegate` call is a `kind=delegate` task in the
|
|
100
|
+
caller's workstream or `scratch`, with durable `call_id`, optional
|
|
101
|
+
`wave`, and states `queued starting running recording done failed
|
|
102
|
+
refused cancelled`. A refusal past the cap is recorded and reissuable,
|
|
103
|
+
never dropped. The verdict is written to the judged task before the
|
|
104
|
+
delegate's report and close. The full multi-line evidence stays on the
|
|
105
|
+
judged task; the answer is the delegate task's report. Pi echo is
|
|
106
|
+
optional, one summary per wave. Admission control, arriving-answer
|
|
107
|
+
safety and `murmur:pending {source,count}` are unchanged.
|
|
108
|
+
|
|
109
|
+
**Next.** One rule set over current state computes `next` on every
|
|
110
|
+
call (`computeNext`); the dashboard asks the same function. Agents
|
|
111
|
+
follow state-advancing hints far more often than read hints, so `next`
|
|
112
|
+
holds only state-advancing moves (a send's exact wait, a preview's
|
|
113
|
+
apply, a claim's brief, `mu next` over authorised work, the wait over
|
|
114
|
+
owned refs) and is usually null; reads are never hinted. Every command
|
|
115
|
+
is executable as printed: POSIX-quoted, real ids, no `<…>`, `...` or
|
|
116
|
+
`a|b`; a move mu cannot fill is omitted. Safe moves rank before
|
|
117
|
+
destructive ones, and a destructive move carries `--if <rev>`. Never a
|
|
118
|
+
resend.
|
|
119
|
+
|
|
120
|
+
**Guards.** `--if <rev>` on membership-changing and destructive verbs;
|
|
121
|
+
teardown and `agent close` print a preview revision first. A wrong id
|
|
122
|
+
returns read-only candidates, never a fuzzy write. An ambiguous ctl
|
|
123
|
+
delivery returns a receipt to check (`msgId`), never a resend.
|
|
124
|
+
|
|
125
|
+
**Sync.** Every verb ingests peer ops before its body and flushes its
|
|
126
|
+
own after, on the error path too; `mu db query` writes flush as well. A
|
|
127
|
+
DB inside `MU_SYNC_DIR` is refused before anything is opened, and so is
|
|
128
|
+
a `MU_SYNC_DIR` holding a 3.x segment (exit 4, nothing written).
|
|
129
|
+
|
|
130
|
+
**CLOSE block.** Final lines of a settled pi run's `lastText`, `task=`
|
|
131
|
+
the agent's own task; applied once per (agent, incarnation, runs) as
|
|
132
|
+
report + close in one op group; malformed writes "no close (malformed)".
|
|
133
|
+
`mu task close` stays. No automatic human decisions: the loop stops
|
|
134
|
+
only for a caller-scoped human-needed task or when nothing it owns runs.
|
|
135
|
+
|
|
136
|
+
**Budgets (pinned by tests).** SKILL 600 words, each recipe 250, all
|
|
137
|
+
recipes 4,000 (`test/prose-budget.test.ts`; the remote recipe's separate
|
|
138
|
+
200-word target is not met and not tested); per-verb `--help` description at most 3 lines at 80 columns
|
|
139
|
+
(`test/help-budget.test.ts`); each `next` and error one line
|
|
140
|
+
(`src/messages.ts`). They do not cap canonical docs such as this page.
|
|
141
|
+
|
|
142
|
+
## Where each part lives
|
|
143
|
+
|
|
144
|
+
Every shipped unit has its modules in the
|
|
145
|
+
[ARCHITECTURE module map](../ARCHITECTURE.md#module-map) and its what-and-why
|
|
146
|
+
in the [CHANGELOG](../../CHANGELOG.md) (unit ids such as `v_wait_surface`
|
|
147
|
+
appear in both). Machine-local tables (`spawn_receipts`, `host_channels`,
|
|
148
|
+
`human_needs`, `wait_registrations`, `wait_resumes`, `wait_action_receipts`,
|
|
149
|
+
`remote_recovery`, and the older `delegate_calls`, `wait_cursors`,
|
|
150
|
+
`agent_settles`, `host_profiles`, `task_auto`, `worktrees`) are classified in
|
|
151
|
+
`MACHINE_LOCAL_TABLES` (`src/db.ts`); `test/entities.test.ts` fails on an
|
|
152
|
+
unclassified one. The build-time ownership table and reconciliation notes
|
|
153
|
+
are in git history.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mu-crew/mu",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.1.0",
|
|
4
4
|
"description": "A persistent, observable crew of pi agents running in one tmux or herdr session per workstream, coordinated through a built-in task DAG.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -45,10 +45,24 @@
|
|
|
45
45
|
"dist",
|
|
46
46
|
"skills",
|
|
47
47
|
"prompts",
|
|
48
|
-
"docs",
|
|
48
|
+
"docs/guide",
|
|
49
|
+
"docs/reference",
|
|
50
|
+
"docs/VOCABULARY.md",
|
|
51
|
+
"docs/ARCHITECTURE.md",
|
|
49
52
|
"README.md",
|
|
50
53
|
"AGENTS.md"
|
|
51
54
|
],
|
|
55
|
+
"pi": {
|
|
56
|
+
"extensions": [
|
|
57
|
+
"./dist/extension/mu-pi.js"
|
|
58
|
+
],
|
|
59
|
+
"skills": [
|
|
60
|
+
"./skills"
|
|
61
|
+
],
|
|
62
|
+
"prompts": [
|
|
63
|
+
"./prompts/*.md"
|
|
64
|
+
]
|
|
65
|
+
},
|
|
52
66
|
"scripts": {
|
|
53
67
|
"build": "tsup",
|
|
54
68
|
"dev": "tsup --watch",
|
|
@@ -56,31 +70,39 @@
|
|
|
56
70
|
"test:fast": "vitest run --config vitest.fast.config.ts",
|
|
57
71
|
"test:watch": "vitest",
|
|
58
72
|
"test:watch:fast": "vitest --config vitest.fast.config.ts",
|
|
59
|
-
"lint": "biome check src test scripts extension",
|
|
60
|
-
"lint:fix": "biome check --write src test scripts extension",
|
|
61
|
-
"format": "biome format --write src test scripts extension",
|
|
62
|
-
"typecheck": "tsc --noEmit && tsc -p tsconfig.test.json --noEmit",
|
|
73
|
+
"lint": "biome check src test scripts extension tools",
|
|
74
|
+
"lint:fix": "biome check --write src test scripts extension tools",
|
|
75
|
+
"format": "biome format --write src test scripts extension tools",
|
|
76
|
+
"typecheck": "tsc --noEmit && tsc -p tsconfig.test.json --noEmit && tsc -p tools/eval/tsconfig.json --noEmit",
|
|
63
77
|
"prepare": "npm run build",
|
|
64
|
-
"test:stress": "tools/test-stress.sh"
|
|
78
|
+
"test:stress": "tools/test-stress.sh",
|
|
79
|
+
"eval": "node tools/eval/main.ts"
|
|
65
80
|
},
|
|
66
81
|
"dependencies": {
|
|
67
82
|
"better-sqlite3": "^13.0.3",
|
|
68
83
|
"cli-table3": "^0.6.5",
|
|
69
84
|
"commander": "^15.0.0",
|
|
70
|
-
"
|
|
71
|
-
"ink": "^7.1.1",
|
|
85
|
+
"ink": "^8.0.0",
|
|
72
86
|
"picocolors": "^1.1.1",
|
|
73
|
-
"react": "^19.3.
|
|
74
|
-
"react-devtools-core": "^8.0.0",
|
|
87
|
+
"react": "^19.3.1",
|
|
75
88
|
"signal-exit": "^4.1.0",
|
|
76
89
|
"string-width": "^8.2.2"
|
|
77
90
|
},
|
|
91
|
+
"peerDependencies": {
|
|
92
|
+
"@earendil-works/pi-coding-agent": "*"
|
|
93
|
+
},
|
|
94
|
+
"peerDependenciesMeta": {
|
|
95
|
+
"@earendil-works/pi-coding-agent": {
|
|
96
|
+
"optional": true
|
|
97
|
+
}
|
|
98
|
+
},
|
|
78
99
|
"devDependencies": {
|
|
79
100
|
"@biomejs/biome": "^2.5.14",
|
|
80
101
|
"@types/better-sqlite3": "^9.6.0",
|
|
81
102
|
"@types/node": "^26.6.2",
|
|
82
103
|
"@types/react": "^19.3.0",
|
|
83
104
|
"@typescript/native": "npm:typescript@^7.0.2",
|
|
105
|
+
"execa": "^10.0.1",
|
|
84
106
|
"fast-check": "^4.10.1",
|
|
85
107
|
"tsup": "^8.5.1",
|
|
86
108
|
"typescript": "npm:@typescript/typescript6@^6.0.2",
|
package/prompts/mu-debug.md
CHANGED
|
@@ -3,6 +3,8 @@ description: "Debug with mu: independent hypotheses from separate evidence, each
|
|
|
3
3
|
argument-hint: "<symptom>"
|
|
4
4
|
---
|
|
5
5
|
Debug this with mu. Load the mu skill, then read its
|
|
6
|
-
`recipes/
|
|
6
|
+
`recipes/tasks-or-calls.md` in full. One delegate call per independent
|
|
7
|
+
hypothesis, each reading separate evidence and ending in `PREDICTS:`; a
|
|
8
|
+
refuter attacks each survivor; fix the one that holds, then a review gate.
|
|
7
9
|
|
|
8
10
|
Symptom: $@
|
package/prompts/mu-refute.md
CHANGED
|
@@ -3,6 +3,7 @@ description: "Find, refute, synthesize with mu: audit or fact-check with a refut
|
|
|
3
3
|
argument-hint: "<what to audit or check>"
|
|
4
4
|
---
|
|
5
5
|
Run a find-refute-synthesize pass with mu. Load the mu skill, then read
|
|
6
|
-
its `recipes/
|
|
6
|
+
its `recipes/findings.md` in full and follow it. Finders record findings,
|
|
7
|
+
one refuter call per finding, report from the task graph.
|
|
7
8
|
|
|
8
9
|
Scope: $@
|
package/prompts/mu-research.md
CHANGED
|
@@ -3,6 +3,8 @@ description: "Deep research with mu: fan out searches, check every claim, cited
|
|
|
3
3
|
argument-hint: "<question>"
|
|
4
4
|
---
|
|
5
5
|
Research this with mu. Load the mu skill, then read its
|
|
6
|
-
`recipes/
|
|
6
|
+
`recipes/tasks-or-calls.md` in full. One searcher call per angle, each claim
|
|
7
|
+
as `CLAIM:` with source and quote, one checker call per claim; the report
|
|
8
|
+
keeps confirmed claims only.
|
|
7
9
|
|
|
8
10
|
Question: $@
|
package/prompts/mu-review.md
CHANGED
|
@@ -3,6 +3,7 @@ description: "Review panel with mu: parallel focused reviewers, refuted findings
|
|
|
3
3
|
argument-hint: "[diff, PR, branch, or path]"
|
|
4
4
|
---
|
|
5
5
|
Run a review panel with mu. Load the mu skill, then read its
|
|
6
|
-
`recipes/
|
|
6
|
+
`recipes/findings.md` in full. One reviewer call per angle on the target,
|
|
7
|
+
duplicates merged, each finding refuted before it is reported.
|
|
7
8
|
|
|
8
9
|
Target: ${@:-the uncommitted changes in this repo}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: "Rules audit with mu: check a change against AGENTS.md rule by rule,
|
|
3
|
-
argument-hint: "[
|
|
2
|
+
description: "Rules audit with mu: check a change against AGENTS.md rule by rule, a checker per rule"
|
|
3
|
+
argument-hint: "[diff, PR, branch, or path]"
|
|
4
4
|
---
|
|
5
5
|
Run a rules audit with mu. Load the mu skill, then read its
|
|
6
|
-
`recipes/
|
|
6
|
+
`recipes/findings.md` in full. One checker call per AGENTS.md rule, then a
|
|
7
|
+
skeptic pass; each violation is a finding.
|
|
7
8
|
|
|
8
|
-
|
|
9
|
+
Target: ${@:-the uncommitted changes in this repo}
|
package/prompts/mu-sweep.md
CHANGED
|
@@ -3,6 +3,7 @@ description: "Sweep with mu: the same change over many files or call sites, one
|
|
|
3
3
|
argument-hint: "<change, and where>"
|
|
4
4
|
---
|
|
5
5
|
Run a sweep with mu. Load the mu skill, then read its
|
|
6
|
-
`recipes/
|
|
6
|
+
`recipes/orchestrator-loop.md` in full. Enumerate the units with a command,
|
|
7
|
+
one task per unit under an umbrella, a shared brief on the umbrella.
|
|
7
8
|
|
|
8
9
|
Change: $@
|
package/prompts/mu-tournament.md
CHANGED
|
@@ -3,7 +3,9 @@ description: "Tournament with mu: competing attempts judged in pairs against a r
|
|
|
3
3
|
argument-hint: "<what to choose or build>"
|
|
4
4
|
---
|
|
5
5
|
Run a tournament with mu. Load the mu skill, then read its
|
|
6
|
-
`recipes/
|
|
7
|
-
|
|
6
|
+
`recipes/tasks-or-calls.md` in full. Ask me for the rubric first if the task
|
|
7
|
+
does not imply one. Attempts are tasks, each naming what it rejected; each
|
|
8
|
+
pairwise judge is a call, order swapped on a close one. Wild divergence means
|
|
9
|
+
an under-specified brief: reframe and re-run.
|
|
8
10
|
|
|
9
11
|
Task: $@
|
package/prompts/mu-until.md
CHANGED
|
@@ -3,6 +3,8 @@ description: "Loop with mu until a check is clean (tsc, lint, tests), with a sto
|
|
|
3
3
|
argument-hint: "<stop rule, e.g. npx tsc --noEmit exits 0>"
|
|
4
4
|
---
|
|
5
5
|
Loop with mu until this holds. Load the mu skill, then read its
|
|
6
|
-
`recipes/loop
|
|
6
|
+
`recipes/orchestrator-loop.md` in full. Write the stop rule and a
|
|
7
|
+
no-progress rule on the umbrella first; one task per round; you run the
|
|
8
|
+
check.
|
|
7
9
|
|
|
8
10
|
Stop rule: $@
|
package/prompts/ultrathink.md
CHANGED
|
@@ -3,7 +3,7 @@ description: "Run a large or risky job the mu way: DAG, fan-out, adversarial rev
|
|
|
3
3
|
argument-hint: "<job>"
|
|
4
4
|
---
|
|
5
5
|
Ultrathink this job with mu. Load the mu skill, then read its
|
|
6
|
-
`recipes/
|
|
6
|
+
`recipes/orchestrator-loop.md` in full and follow it. Every unit, review, and
|
|
7
7
|
round goes in the task DAG; checks (refuters, judges, skeptics) are
|
|
8
8
|
delegate calls. Keep driving until the stop rule holds.
|
|
9
9
|
|