plumbbob 0.8.3 → 0.8.5
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 +1 -1
- package/dist/cli-core.js +5 -1
- package/dist/lib/latch.js +10 -8
- package/dist/verbs/agent.js +5 -0
- package/dist/verbs/build.js +24 -4
- package/dist/verbs/handoff.js +103 -0
- package/package.json +11 -11
- package/skills/pb-build/SKILL.md +95 -61
- package/skills/pb-verify/SKILL.md +13 -14
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "plumbbob",
|
|
3
3
|
"displayName": "PlumbBob",
|
|
4
|
-
"version": "0.8.
|
|
4
|
+
"version": "0.8.5",
|
|
5
5
|
"description": "Attention-first build process — driver skills + a CLI that keep you the decider: guidance on the work, a latch on the record.",
|
|
6
6
|
"author": { "name": "Rob McLarty", "email": "hello@robmclarty.com", "url": "https://robmclarty.com" },
|
|
7
7
|
"homepage": "https://github.com/robmclarty/plumbbob#readme",
|
package/dist/cli-core.js
CHANGED
|
@@ -9,6 +9,7 @@ import { start } from "./verbs/start.js";
|
|
|
9
9
|
import { status } from "./verbs/status.js";
|
|
10
10
|
import { park } from "./verbs/park.js";
|
|
11
11
|
import { build } from "./verbs/build.js";
|
|
12
|
+
import { handoff } from "./verbs/handoff.js";
|
|
12
13
|
import { check } from "./verbs/check.js";
|
|
13
14
|
import { checkpoint } from "./verbs/checkpoint.js";
|
|
14
15
|
import { revert } from "./verbs/revert.js";
|
|
@@ -22,7 +23,8 @@ import { turn } from "./verbs/turn.js";
|
|
|
22
23
|
const VERBS = [
|
|
23
24
|
{ name: 'start', summary: 'scaffold .plumbbob/; open the session; record the baseline commit' },
|
|
24
25
|
{ name: 'status', summary: 'print the orientation dashboard, or NO ACTIVE SESSION' },
|
|
25
|
-
{ name: 'build', summary: 'build <n
|
|
26
|
+
{ name: 'build', summary: 'build [<n>]: write the seam from step n, or the next undone step (in-flight, not a lock)' },
|
|
27
|
+
{ name: 'handoff', summary: 'print the standardized build hand-off block (pause or post-checkpoint); read-only' },
|
|
26
28
|
{ name: 'check', summary: 'run the heavy check and report; no state change (--bail --only a,b … narrow the checkride gate)' },
|
|
27
29
|
{ name: 'checkpoint', summary: 'checkpoint [<n>]: gate on green, commit/record SHA, mark step done (executor-agnostic)' },
|
|
28
30
|
{ name: 'revert', summary: 'revert [--to n]: git reset --hard to a checkpoint SHA' },
|
|
@@ -71,6 +73,8 @@ async function dispatch(verb, cwd, rest) {
|
|
|
71
73
|
return park(cwd, rest);
|
|
72
74
|
case 'build':
|
|
73
75
|
return build(cwd, rest);
|
|
76
|
+
case 'handoff':
|
|
77
|
+
return handoff(cwd, rest);
|
|
74
78
|
case 'check':
|
|
75
79
|
return check(cwd, rest);
|
|
76
80
|
case 'checkpoint':
|
package/dist/lib/latch.js
CHANGED
|
@@ -10,15 +10,17 @@ import { readFileSync } from 'node:fs';
|
|
|
10
10
|
import { grantPath, tickPath, turnPath } from "./sidecar.js";
|
|
11
11
|
import { resolveBoolean } from "./settings.js";
|
|
12
12
|
const ALLOW = { allow: true };
|
|
13
|
-
// The
|
|
14
|
-
// it
|
|
15
|
-
//
|
|
16
|
-
// at plan time — what the human approves
|
|
13
|
+
// The refusal message is the affordance — it tells the model what the pause is,
|
|
14
|
+
// how it ends (approval on the next turn lands it; `/pb-build` only starts the next
|
|
15
|
+
// step), and names the only legitimate grants. The plan commit gets its own wording:
|
|
16
|
+
// there is no step, no diff, and no self-review at plan time — what the human approves
|
|
17
|
+
// is the plan itself.
|
|
17
18
|
const NO_TURN_MESSAGE = `plumbbob: checkpoint refused — no human turn since this step began. This is the
|
|
18
|
-
pause: present the diff and the self-review, then end the turn
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
19
|
+
pause: present the diff and the self-review, then end the turn. The human's approval on
|
|
20
|
+
their next turn is what lets this land — re-run \`checkpoint\` then and stop at the
|
|
21
|
+
boundary; \`/pb-build\` only starts the next step, it never lands this one. (An explicit
|
|
22
|
+
\`/pb-build --auto\` or a step range in the human's own prompt grants self-approval;
|
|
23
|
+
\`auto: true\` in settings.local.json is the standing grant.)
|
|
22
24
|
`;
|
|
23
25
|
const NO_TURN_PLAN_MESSAGE = `plumbbob: checkpoint refused — no human turn since \`start\` stamped this plan. This
|
|
24
26
|
is the plan pause: present the plan, then end the turn; the human's approving
|
package/dist/verbs/agent.js
CHANGED
|
@@ -101,6 +101,11 @@ async function runOne(root, slug, step, spec) {
|
|
|
101
101
|
settings: {
|
|
102
102
|
auto: resolveBoolean(root, 'auto', false),
|
|
103
103
|
agentTimeout: resolveNumber(root, 'agentTimeout', 0),
|
|
104
|
+
// Hand this agent its own config block over the frozen envelope `settings`
|
|
105
|
+
// field (D5/D6): settings.json → agentConfig[name], with the local overlay
|
|
106
|
+
// shadowing the project rung whole (D7 — no deep merge), and {} when neither
|
|
107
|
+
// defines it. No new envelope field, no new verb — the config just rides here.
|
|
108
|
+
agent: resolveRecord(root, 'agentConfig')[spec.name] ?? {},
|
|
104
109
|
},
|
|
105
110
|
});
|
|
106
111
|
if (!composed.ok) {
|
package/dist/verbs/build.js
CHANGED
|
@@ -5,6 +5,7 @@ import { readFileSync, writeFileSync } from 'node:fs';
|
|
|
5
5
|
import { findRepoRoot } from "../lib/git.js";
|
|
6
6
|
import { hasSession, intentPath, resolveBuild, seamPath, stampStepStat, stampTick, stepPath } from "../lib/sidecar.js";
|
|
7
7
|
import { parseStepSeam } from "../lib/intent.js";
|
|
8
|
+
import { parseSteps } from "../lib/orient.js";
|
|
8
9
|
export function build(cwd, args) {
|
|
9
10
|
const root = findRepoRoot(cwd);
|
|
10
11
|
if (root === null || !hasSession(root)) {
|
|
@@ -20,12 +21,30 @@ export function build(cwd, args) {
|
|
|
20
21
|
process.stderr.write(`plumbbob: build takes one step number; \`${raw}\` step ranges are a \`/pb-build\` feature (auto-approve through the range, then pause). Try \`plumbbob build ${raw.split('-')[0]}\`.\n`);
|
|
21
22
|
return 1;
|
|
22
23
|
}
|
|
23
|
-
|
|
24
|
+
// An explicit arg that isn't a positive integer is a usage error — caught before
|
|
25
|
+
// reading intent.md so the message doesn't depend on the plan being present.
|
|
26
|
+
if (raw !== undefined && (!/^\d+$/.test(raw) || Number(raw) < 1)) {
|
|
24
27
|
process.stderr.write('plumbbob: build needs a step number. Try: plumbbob build 2.\n');
|
|
25
28
|
return 1;
|
|
26
29
|
}
|
|
27
|
-
const
|
|
28
|
-
|
|
30
|
+
const intent = readFileSync(intentPath(root, slug), 'utf8');
|
|
31
|
+
// No argument ⇒ enter the next undone step in intent.md (the same idiom
|
|
32
|
+
// `checkpoint` uses), so a bare `plumbbob build` advances the loop without the
|
|
33
|
+
// skill re-deriving the step in prose. Every step checkpointed ⇒ a `/pb-step`
|
|
34
|
+
// nudge, not a silent no-op.
|
|
35
|
+
let step;
|
|
36
|
+
if (raw === undefined) {
|
|
37
|
+
const nextUndone = parseSteps(intent).find((s) => !s.done);
|
|
38
|
+
if (nextUndone === undefined) {
|
|
39
|
+
process.stderr.write('plumbbob: no undone step to build — every planned step is checkpointed. `/pb-step` to add an increment, or `/pb-finish`.\n');
|
|
40
|
+
return 1;
|
|
41
|
+
}
|
|
42
|
+
step = nextUndone.n;
|
|
43
|
+
}
|
|
44
|
+
else {
|
|
45
|
+
step = Number(raw);
|
|
46
|
+
}
|
|
47
|
+
const parsed = parseStepSeam(intent, step);
|
|
29
48
|
if (!parsed.ok) {
|
|
30
49
|
process.stderr.write(`plumbbob: ${parsed.error} Fix the step's seam in intent.md, then \`build ${step}\` again.\n`);
|
|
31
50
|
return 1;
|
|
@@ -36,6 +55,7 @@ export function build(cwd, args) {
|
|
|
36
55
|
// The wall-clock receipt starts here (research/07 Build 2b): checkpoint stamps
|
|
37
56
|
// landedAt, and the pair becomes the step's duration in the finish report.
|
|
38
57
|
stampStepStat(root, slug, step, 'startedAt', new Date().toISOString());
|
|
39
|
-
|
|
58
|
+
const picked = raw === undefined ? ' (next undone)' : '';
|
|
59
|
+
process.stdout.write(`plumbbob: building step ${step}${picked}. Seam (for orientation; not a lock):\n${parsed.seam.map((p) => ` ${p}`).join('\n')}\n`);
|
|
40
60
|
return 0;
|
|
41
61
|
}
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
// `plumbbob handoff` — print the standardized build hand-off block (D67): the
|
|
2
|
+
// "state / choice / what's next" the human sees at each step boundary. Read-only,
|
|
3
|
+
// no state change. It derives the moment from the session — a step in flight ⇒ the
|
|
4
|
+
// pause block (built → looks-good/needs-work → next), none ⇒ the post-checkpoint
|
|
5
|
+
// boundary block — and renders the next undone step plus its advisory `- model:`
|
|
6
|
+
// recommendation straight from intent.md. This block lived as prose in pb-build's
|
|
7
|
+
// SKILL.md; owning it here keeps the skill from drifting out of sync with `status`,
|
|
8
|
+
// which renders the same next-step detail (both read `parseSteps`).
|
|
9
|
+
import { readFileSync } from 'node:fs';
|
|
10
|
+
import { findRepoRoot } from "../lib/git.js";
|
|
11
|
+
import { checkpointsPath, hasSession, intentPath, resolveBuild, stepPath } from "../lib/sidecar.js";
|
|
12
|
+
import { parseLastCheckpoint, parseSteps } from "../lib/orient.js";
|
|
13
|
+
export function handoff(cwd, args = []) {
|
|
14
|
+
const root = findRepoRoot(cwd);
|
|
15
|
+
if (root === null || !hasSession(root)) {
|
|
16
|
+
process.stderr.write('plumbbob: no active session. Run `plumbbob start "<title>"` first.\n');
|
|
17
|
+
return 1;
|
|
18
|
+
}
|
|
19
|
+
const { build: slug, rest } = resolveBuild(root, args);
|
|
20
|
+
const steps = parseSteps(readOr(intentPath(root, slug)));
|
|
21
|
+
const inFlight = readStep(stepPath(root, slug));
|
|
22
|
+
const explicit = rest.find((a) => /^\d+$/.test(a));
|
|
23
|
+
const lastDone = parseLastCheckpoint(readOr(checkpointsPath(root, slug)));
|
|
24
|
+
// The step this hand-off is about: an explicit arg wins (the skill's override),
|
|
25
|
+
// else the in-flight step (the pause), else the last checkpointed step (the
|
|
26
|
+
// boundary). Null only on a fresh session the skill would not hand off from.
|
|
27
|
+
const current = explicit !== undefined ? Number(explicit) : (inFlight ?? lastDone?.n ?? null);
|
|
28
|
+
// Next up: the first undone step that is not the current one. At the pause the
|
|
29
|
+
// current step is still `[ ]`, so excluding it by number is what makes "next"
|
|
30
|
+
// mean the step *after* it; at the boundary the current step is already `[x]`,
|
|
31
|
+
// so the `!== current` clause is a harmless no-op. Skipping-ahead builds still
|
|
32
|
+
// land on the earliest remaining step, never a gap.
|
|
33
|
+
const nextUp = steps.find((s) => !s.done && s.n !== current);
|
|
34
|
+
if (current === null) {
|
|
35
|
+
// No step to report as just-done (fresh session): emit only the forward pointer.
|
|
36
|
+
process.stdout.write(`${nextUpLine(nextUp)}\n`);
|
|
37
|
+
return 0;
|
|
38
|
+
}
|
|
39
|
+
const block = inFlight !== null ? pauseBlock(current, titleOf(steps, current), nextUp) : boundaryBlock(current, titleOf(steps, current), nextUp);
|
|
40
|
+
process.stdout.write(`${block}\n`);
|
|
41
|
+
return 0;
|
|
42
|
+
}
|
|
43
|
+
// The pause block: the step is built and awaiting approval. The opener is neutral
|
|
44
|
+
// (the CLI cannot vouch for the diff), pointing at the diff and self-review the
|
|
45
|
+
// skill shows above it.
|
|
46
|
+
function pauseBlock(step, title, nextUp) {
|
|
47
|
+
return [
|
|
48
|
+
`Step ${step}${paren(title)} is built. Review the diff and self-review above, then:`,
|
|
49
|
+
` - looks good → I'll checkpoint it (lands step ${step} as its own commit, back to the boundary)`,
|
|
50
|
+
` - needs work → tell me what to change and I'll iterate on this same step`,
|
|
51
|
+
'',
|
|
52
|
+
nextUpLine(nextUp),
|
|
53
|
+
].join('\n');
|
|
54
|
+
}
|
|
55
|
+
// The boundary block: the checkpoint has landed and the loop is back at the
|
|
56
|
+
// step boundary, pointing at what to build next.
|
|
57
|
+
function boundaryBlock(step, title, nextUp) {
|
|
58
|
+
return [`Step ${step}${paren(title)} checkpointed — back at the boundary.`, '', nextUpLine(nextUp)].join('\n');
|
|
59
|
+
}
|
|
60
|
+
// The forward pointer, shared by both blocks: the next undone step, its title, and
|
|
61
|
+
// its advisory `- model:` recommendation (as just the model token for the `/model`
|
|
62
|
+
// call — the full rationale lives on the `status` dashboard). No next step ⇒ the
|
|
63
|
+
// finish/step nudge instead.
|
|
64
|
+
function nextUpLine(nextUp) {
|
|
65
|
+
if (nextUp === undefined) {
|
|
66
|
+
return 'No planned steps remain — /pb-step to add an increment, or /pb-finish.';
|
|
67
|
+
}
|
|
68
|
+
const head = `Next up: step ${nextUp.n}${paren(nextUp.title)}`;
|
|
69
|
+
const token = modelToken(nextUp.model);
|
|
70
|
+
return token === null ? `${head} — /pb-build to start it.` : `${head} · model: ${token} — /model ${token} then /pb-build.`;
|
|
71
|
+
}
|
|
72
|
+
// A step's title in parentheses, or nothing when the title is empty.
|
|
73
|
+
function paren(title) {
|
|
74
|
+
return title !== null && title.length > 0 ? ` (${title})` : '';
|
|
75
|
+
}
|
|
76
|
+
function titleOf(steps, n) {
|
|
77
|
+
return steps.find((s) => s.n === n)?.title ?? null;
|
|
78
|
+
}
|
|
79
|
+
// The model token from a `- model:` recommendation — the first word, so a
|
|
80
|
+
// `model: opus — <rationale>` line yields `opus` for the `/model` call. Null when
|
|
81
|
+
// there is no recommendation, or it degraded to whitespace (folding the null model
|
|
82
|
+
// into the same guard keeps both branches live).
|
|
83
|
+
function modelToken(model) {
|
|
84
|
+
const first = model?.trim().split(/\s+/)[0];
|
|
85
|
+
return first !== undefined && first.length > 0 ? first : null;
|
|
86
|
+
}
|
|
87
|
+
function readOr(path) {
|
|
88
|
+
try {
|
|
89
|
+
return readFileSync(path, 'utf8');
|
|
90
|
+
}
|
|
91
|
+
catch {
|
|
92
|
+
return '';
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
function readStep(path) {
|
|
96
|
+
try {
|
|
97
|
+
const raw = readFileSync(path, 'utf8').trim();
|
|
98
|
+
return /^\d+$/.test(raw) ? Number(raw) : null;
|
|
99
|
+
}
|
|
100
|
+
catch {
|
|
101
|
+
return null;
|
|
102
|
+
}
|
|
103
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "plumbbob",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.5",
|
|
4
4
|
"description": "Attention-first build process: 12 skills + a CLI that keep you the decider — guidance on the work, a latch on the record.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"claude-code",
|
|
@@ -42,17 +42,17 @@
|
|
|
42
42
|
}
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
|
-
"@ast-grep/cli": "
|
|
46
|
-
"@stryker-mutator/core": "
|
|
47
|
-
"@stryker-mutator/vitest-runner": "
|
|
48
|
-
"@types/node": "
|
|
49
|
-
"@vitest/coverage-v8": "
|
|
50
|
-
"fallow": "
|
|
45
|
+
"@ast-grep/cli": "0.43.0",
|
|
46
|
+
"@stryker-mutator/core": "9.6.1",
|
|
47
|
+
"@stryker-mutator/vitest-runner": "9.6.1",
|
|
48
|
+
"@types/node": "24.13.1",
|
|
49
|
+
"@vitest/coverage-v8": "4.1.9",
|
|
50
|
+
"fallow": "2.103.0",
|
|
51
51
|
"fascicle": "0.8.16",
|
|
52
|
-
"markdownlint-cli2": "
|
|
53
|
-
"oxlint": "
|
|
54
|
-
"typescript": "
|
|
55
|
-
"vitest": "
|
|
52
|
+
"markdownlint-cli2": "0.22.1",
|
|
53
|
+
"oxlint": "1.69.0",
|
|
54
|
+
"typescript": "6.0.3",
|
|
55
|
+
"vitest": "4.1.9"
|
|
56
56
|
},
|
|
57
57
|
"dependencies": {
|
|
58
58
|
"checkride": "0.3.0"
|
package/skills/pb-build/SKILL.md
CHANGED
|
@@ -3,7 +3,7 @@ name: pb-build
|
|
|
3
3
|
description: The default engine — read the next planned step from intent, implement it (its done-when, seam, Decisions, Constraints), then verify it through to the approval pause. Swappable — build by hand/vibed/another harness and run /pb-verify instead. `--auto` self-approves and chains to done; a step range like `1-3` self-approves through step 3, then pauses.
|
|
4
4
|
argument-hint: "[step-number | step-range] [--auto]"
|
|
5
5
|
disable-model-invocation: true
|
|
6
|
-
allowed-tools: Read, Edit, Write, Bash(plumbbob status:*), Bash(plumbbob build:*), Bash(plumbbob check:*), Bash(plumbbob checkpoint:*), Bash(plumbbob agent:*), Bash(git diff:*)
|
|
6
|
+
allowed-tools: Read, Edit, Write, Bash(plumbbob status:*), Bash(plumbbob build:*), Bash(plumbbob handoff:*), Bash(plumbbob check:*), Bash(plumbbob checkpoint:*), Bash(plumbbob agent:*), Bash(git diff:*)
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
# PlumbBob — build a step (the default engine)
|
|
@@ -30,51 +30,33 @@ differs from the model you're running as, say so before implementing — the hum
|
|
|
30
30
|
1. **Pick the step.** Use the number you were invoked with (e.g. `/pb-build 4`) — or,
|
|
31
31
|
if you were given a range like `/pb-build 1-3`, start at the first number and treat
|
|
32
32
|
the second as the auto-approve ceiling (see the range note under `--auto`). With no
|
|
33
|
-
argument,
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
33
|
+
argument, don't resolve the next step yourself — the CLI does: bare `plumbbob build`
|
|
34
|
+
(step 2) enters the next undone step and refuses with a `/pb-step` nudge when every
|
|
35
|
+
step is checkpointed.
|
|
36
|
+
2. **Enter the step.** Run `plumbbob build <n>` — or bare `plumbbob build` to enter the
|
|
37
|
+
next undone step (records the in-flight STEP + SEAM so `/pb-status` shows the step in
|
|
38
|
+
flight; the seam is awareness, not a lock).
|
|
38
39
|
3. **Read the plan.** Read the step's **done-when**, its **seam**, and the
|
|
39
40
|
**Decisions** and **Constraints** in `intent.md`. Build to *that* — the deciding
|
|
40
41
|
already happened, off the chat.
|
|
41
|
-
- **
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
appends to the step's `handoff.json`, and its `summary`/`body` become **context you
|
|
45
|
-
read into the build** (that is the whole point of the slot — load the context in
|
|
46
|
-
before you write). No binding, or no harness, is a clean no-op — just build.
|
|
42
|
+
- **Bound `before`-agents load context first.** If `plumbbob status` shows a
|
|
43
|
+
`harness bindings:` block, this build binds agents — see **§ Running bound agents**
|
|
44
|
+
and load their context in before you write. No bindings, no harness: just build.
|
|
47
45
|
4. **Implement** the step, and only that step, staying within the declared seam. A
|
|
48
46
|
new problem or "ooh what if" that surfaces mid-build is a `/pb-park`, **not** an
|
|
49
47
|
edit — capture it and stay on the step. If you genuinely cannot finish without
|
|
50
48
|
touching more than the seam, that is scope drift: surface it to the human rather
|
|
51
49
|
than sprawling.
|
|
52
|
-
- **
|
|
53
|
-
`
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
- **A manifest's `when` prose is your cue to fire an agent mid-build**.
|
|
57
|
-
The three slots are the only *declarative* lifecycle points; there is no config for
|
|
58
|
-
"a salient moment in the middle." That is judgment, and you are the frontier model
|
|
59
|
-
in the room: when the work reaches the situation a bound agent's `when` (or a step
|
|
60
|
-
`note`) describes, fire `plumbbob agent run <name> --step <n>` yourself. Prose is
|
|
61
|
-
the orchestration language; you are the workflow engine.
|
|
62
|
-
- **Route a non-`done` envelope by its status**. An agent that returns
|
|
63
|
-
`blocked` couldn't finish (missing input, failed precondition): surface its `notes`,
|
|
64
|
-
let the human unblock, and re-run it — don't work around it. One that returns
|
|
65
|
-
`drift` finished but found the plan no longer matches reality: **stop and send the
|
|
66
|
-
human to `/pb-refine`** to repair the plan before continuing, rather than building
|
|
67
|
-
on a plan that's now wrong. A non-zero exit is a failed run: report it and stop.
|
|
50
|
+
- **Bound agents can shape the build.** If `plumbbob status` shows a
|
|
51
|
+
`harness bindings:` block, a `build`-slot agent may author the diff, a `when`-cue may
|
|
52
|
+
fire an agent mid-build, and a non-`done` envelope routes by its status — see
|
|
53
|
+
**§ Running bound agents**.
|
|
68
54
|
5. **Verify, through to the pause.** Run the verify tick exactly as `/pb-verify`
|
|
69
55
|
does: `plumbbob check` (on red, read `.check/summary.json` and the failing slot's
|
|
70
56
|
raw output under `.check/` for the actual diagnostics; while iterating on a fix,
|
|
71
57
|
narrow the loop with `plumbbob check --bail --only <slots>` — the checkpoint gate
|
|
72
|
-
still runs everything) →
|
|
73
|
-
|
|
74
|
-
input** — they inform, they never gate (checkride gates, the human is the clock; an
|
|
75
|
-
`after`-agent that could fail a step is the lock in autonomy's costume) →
|
|
76
|
-
self-review the diff against the done-when, the Decisions, and the Constraints (a
|
|
77
|
-
single structured read) → validate → **PAUSE
|
|
58
|
+
still runs everything) → self-review the diff against the done-when, the Decisions,
|
|
59
|
+
and the Constraints (a single structured read) → validate → **PAUSE
|
|
78
60
|
for the human's approval** → only on approval, checkpoint with
|
|
79
61
|
`plumbbob checkpoint <n> --body <<'BODY' … BODY` — a commit body **proportional to the
|
|
80
62
|
step** (a line for a trivial change, a short paragraph for a meatier one; no TIL scan,
|
|
@@ -82,24 +64,73 @@ differs from the model you're running as, say so before implementing — the hum
|
|
|
82
64
|
build-log's `## Log`, so the history writes itself — you only supply the body (or omit
|
|
83
65
|
`--body` for the deterministic done-when + seam + diffstat fallback). Do **not** bump
|
|
84
66
|
the version or changelog — that is the human's `/version` call.
|
|
67
|
+
- **If `plumbbob status` shows a `harness bindings:` block**, fold any bound
|
|
68
|
+
`after`-agents into that self-review as advisory input — see **§ Running bound
|
|
69
|
+
agents**.
|
|
85
70
|
|
|
86
71
|
**The latch makes this pause real.** On the default (non-`--auto`) path you
|
|
87
72
|
build the step and reach the pause *in one turn* — so under plumbbob's turn hook the
|
|
88
73
|
checkpoint at the end of that turn is **refused** ("no human turn since this step
|
|
89
74
|
began"), and that refusal **is** the pause working as designed. Do exactly what the
|
|
90
|
-
pause
|
|
91
|
-
human's next message
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
75
|
+
pause asks: present the diff and the self-review, emit the closing block below, and
|
|
76
|
+
**end the turn**. The human's next message — their approval — is the human turn that
|
|
77
|
+
lets the checkpoint land: on that turn you run `plumbbob checkpoint <n>` (now allowed)
|
|
78
|
+
and **stop at the boundary**. Landing the checkpoint is its own deliberate beat — the
|
|
79
|
+
thing approval triggers — never a side effect of starting the next step, and
|
|
80
|
+
`/pb-build` only ever starts the *next* step. **Never route around a refusal with a
|
|
81
|
+
raw `git commit`** — the work plane stays free, but the *record* is latched on purpose.
|
|
82
|
+
|
|
83
|
+
**End every default build turn with the standardized hand-off block.** Run `plumbbob
|
|
84
|
+
handoff` and present its output — it renders the same three-part shape (the state, the
|
|
85
|
+
choice, what's next) straight from the session: step N built, the looks-good /
|
|
86
|
+
needs-work choice, and the next undone step with its `- model:` recommendation. Show
|
|
87
|
+
your diff and self-review above it. The CLI owns the block so it can't drift from what
|
|
88
|
+
`/pb-status` reports; you supply only the judgment above it. It already drops the model
|
|
89
|
+
clause when the next step has none, and says so when no planned step remains — you
|
|
90
|
+
don't reproduce the template by hand.
|
|
91
|
+
|
|
92
|
+
**Then hand off with the next model.** Once the checkpoint lands in the approval turn,
|
|
93
|
+
run `plumbbob handoff` again and relay its boundary block — with the step gone from
|
|
94
|
+
in-flight it renders "step N checkpointed" and points at the next undone step, carrying
|
|
95
|
+
that step's `- model:` recommendation (the plan's smallest-model-that-fits call) so the
|
|
96
|
+
human knows which `/model` to select before firing `/pb-build` again. It is what
|
|
97
|
+
carries the plan's suggestion across a fresh context window, which inherits the session
|
|
98
|
+
model, not the plan's. No `- model:` line means any model will do. Guidance, never a
|
|
99
|
+
gate.
|
|
100
|
+
|
|
101
|
+
## Running bound agents
|
|
102
|
+
|
|
103
|
+
Skip this section unless `plumbbob status` shows a `harness bindings:` block. Nearly every
|
|
104
|
+
build binds **no** agents — for them the default path above is the whole story. When a
|
|
105
|
+
harness *is* bound, this is what each affected step gains, in lifecycle order.
|
|
106
|
+
|
|
107
|
+
- **`before` — load context in (step 3).** If the build's `harness.json` binds agents to
|
|
108
|
+
this step's `before` slot, run `plumbbob agent run --step <n> --mode before` first: each
|
|
109
|
+
returns a validated envelope on stdout that plumbbob also appends to the step's
|
|
110
|
+
`handoff.json`, and its `summary`/`body` become **context you read into the build** (that
|
|
111
|
+
is the whole point of the slot — load the context in before you write). No binding, or no
|
|
112
|
+
harness, is a clean no-op — just build.
|
|
113
|
+
- **`build` — delegate the diff (step 4).** If a `build`-slot agent is bound, run
|
|
114
|
+
`plumbbob agent run --step <n> --mode build` and let that agent author the step's code
|
|
115
|
+
instead of writing it yourself; its envelope reports what it did. You still own the verify
|
|
116
|
+
tick — the diff is reviewed the same way whoever wrote it.
|
|
117
|
+
- **A manifest's `when` prose is your cue to fire an agent mid-build (step 4).** The three
|
|
118
|
+
slots are the only *declarative* lifecycle points; there is no config for "a salient
|
|
119
|
+
moment in the middle." That is judgment, and you are the frontier model in the room: when
|
|
120
|
+
the work reaches the situation a bound agent's `when` (or a step `note`) describes, fire
|
|
121
|
+
`plumbbob agent run <name> --step <n>` yourself. Prose is the orchestration language; you
|
|
122
|
+
are the workflow engine.
|
|
123
|
+
- **Route a non-`done` envelope by its status (step 4).** An agent that returns `blocked`
|
|
124
|
+
couldn't finish (missing input, failed precondition): surface its `notes`, let the human
|
|
125
|
+
unblock, and re-run it — don't work around it. One that returns `drift` finished but found
|
|
126
|
+
the plan no longer matches reality: **stop and send the human to `/pb-refine`** to repair
|
|
127
|
+
the plan before continuing, rather than building on a plan that's now wrong. A non-zero
|
|
128
|
+
exit is a failed run: report it and stop.
|
|
129
|
+
- **`after` — advisory input to the verify tick (step 5).** After `plumbbob check`, run any
|
|
130
|
+
bound `after`-agents (`plumbbob agent run --step <n> --mode after`) and fold their
|
|
131
|
+
envelopes into the self-review as **advisory input** — they inform, they never gate
|
|
132
|
+
(checkride gates, the human is the clock; an `after`-agent that could fail a step is the
|
|
133
|
+
lock in autonomy's costume).
|
|
103
134
|
|
|
104
135
|
## `--auto` — let the agent be the clock (opt-in)
|
|
105
136
|
|
|
@@ -107,8 +138,8 @@ differs from the model you're running as, say so before implementing — the hum
|
|
|
107
138
|
progress instead of approving each step. It does the same work, but **the agent reviews
|
|
108
139
|
and approves in the human's place**, and it **chains**:
|
|
109
140
|
|
|
110
|
-
- Build the next step, running its slots
|
|
111
|
-
path: bound `before`-agents → implement (or the bound `build`-agent) → bound
|
|
141
|
+
- Build the next step, running its slots (see **§ Running bound agents**) in the same
|
|
142
|
+
order as the default path: bound `before`-agents → implement (or the bound `build`-agent) → bound
|
|
112
143
|
`after`-agents → `check` → self-review → **if the check is green AND the
|
|
113
144
|
self-review finds no done-when / Decision / Constraint mismatch, checkpoint** and move
|
|
114
145
|
straight on to the next planned step. Repeat. `--auto` adds no new machinery — the
|
|
@@ -118,9 +149,10 @@ and approves in the human's place**, and it **chains**:
|
|
|
118
149
|
bound agent returns `blocked` or `drift` (unblock-and-re-run, or `/pb-refine` — an
|
|
119
150
|
agent cannot advance the loop), a new decision is needed, no planned steps
|
|
120
151
|
remain, or the top of a requested range is reached. **When `--auto` halts back to the
|
|
121
|
-
human, give the same hand-off the default pause does** —
|
|
122
|
-
next undone step, and that next step's
|
|
123
|
-
fresh context window knows which `/model`
|
|
152
|
+
human, give the same hand-off the default pause does** — run `plumbbob handoff` and
|
|
153
|
+
relay its block: the step just completed, the next undone step, and that next step's
|
|
154
|
+
`- model:` recommendation if it has one, so a fresh context window knows which `/model`
|
|
155
|
+
to select.
|
|
124
156
|
|
|
125
157
|
`--auto` and a step range are the only paths that checkpoint without a human pause, and
|
|
126
158
|
only because the human asked for it by name; a range re-imposes the pause at its top.
|
|
@@ -161,13 +193,15 @@ just the one more entry already in the halt list above.
|
|
|
161
193
|
- **Agents feed the beat; they never advance it**. `before` loads context,
|
|
162
194
|
`build` writes the diff, `after` is advisory — none can checkpoint, flip a step, or
|
|
163
195
|
chain. `blocked` → unblock and re-run; `drift` → `/pb-refine`. You are still the one
|
|
164
|
-
who verifies and (bar `--auto`) the human is still the clock.
|
|
196
|
+
who verifies and (bar `--auto`) the human is still the clock. See **§ Running bound
|
|
197
|
+
agents** for the mechanics.
|
|
165
198
|
- **A refused checkpoint is the pause, not an error.** Under plumbbob's turn
|
|
166
|
-
hook a same-turn `checkpoint` is refused by design — present the diff
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
199
|
+
hook a same-turn `checkpoint` is refused by design — present the diff and the closing
|
|
200
|
+
block, **end the turn**; the human's approval on their next turn is what lets you land
|
|
201
|
+
it, and landing it is a deliberate beat, not a side effect of the next `/pb-build`.
|
|
202
|
+
Never route around it with a raw `git commit`; `--auto`, a typed range, or `auto: true`
|
|
203
|
+
are the only self-approvals.
|
|
204
|
+
- **Close with the next model.** When a step lands, run `plumbbob handoff` and relay its
|
|
205
|
+
block — it cites the completed step and the next undone step, and names that next step's
|
|
206
|
+
`- model:` recommendation if it has one, which is what a fresh context window needs to
|
|
207
|
+
pick the right `/model` before re-firing. Guidance, never a gate.
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
name: pb-verify
|
|
3
3
|
description: "The verify tick — run the check, self-review the diff against intent, validate the step's done-when, pause for your approval, then checkpoint. Executor-agnostic: it reads the diff, not who wrote it."
|
|
4
4
|
disable-model-invocation: true
|
|
5
|
-
allowed-tools: Read, Bash(plumbbob status:*), Bash(plumbbob check:*), Bash(plumbbob checkpoint:*), Bash(plumbbob agent:*), Bash(git diff:*), Bash(git status:*)
|
|
5
|
+
allowed-tools: Read, Bash(plumbbob status:*), Bash(plumbbob handoff:*), Bash(plumbbob check:*), Bash(plumbbob checkpoint:*), Bash(plumbbob agent:*), Bash(git diff:*), Bash(git status:*)
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
# PlumbBob — verify a step (the tick)
|
|
@@ -63,15 +63,14 @@ this skill verifies it the same way: **it reads the diff, not the author**.
|
|
|
63
63
|
(done-when + seam + diffstat) on its own. Either way, do **not** bump the version or
|
|
64
64
|
touch the changelog — that is the human's `/version` call.
|
|
65
65
|
7. **Hand off with the next model** *(once the checkpoint lands)*. `plumbbob checkpoint`
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
will do — say nothing about it. Guidance, never a gate.
|
|
66
|
+
returns to DESIGN; then run `plumbbob handoff` and relay its boundary block. With the
|
|
67
|
+
step gone from in-flight it renders `step N checkpointed — back at the boundary` and
|
|
68
|
+
points at the **next undone step**, carrying that step's `- model:` recommendation (the
|
|
69
|
+
plan's smallest-model-that-fits call) so the human knows which `/model` to select before
|
|
70
|
+
firing `/pb-build` again. This matters most across a context boundary: a fresh window
|
|
71
|
+
inherits the *session's* model, not the plan's suggestion, so this line is what carries
|
|
72
|
+
the recommendation over. The CLI owns the block, so it can't drift from what `plumbbob
|
|
73
|
+
status` reports; no `- model:` line means any model will do. Guidance, never a gate.
|
|
75
74
|
|
|
76
75
|
## The latch makes the pause real
|
|
77
76
|
|
|
@@ -104,7 +103,7 @@ in settings is the standing one.
|
|
|
104
103
|
hook a same-turn checkpoint is refused *by design* — present the diff, **end the
|
|
105
104
|
turn**, and let the human's next message re-tick it. Never route around it with a raw
|
|
106
105
|
`git commit`; the latch guards the record, not the work.
|
|
107
|
-
- **Close with the next model.** After the checkpoint lands,
|
|
108
|
-
and the next undone step, and
|
|
109
|
-
|
|
110
|
-
|
|
106
|
+
- **Close with the next model.** After the checkpoint lands, run `plumbbob handoff` and
|
|
107
|
+
relay its block — it cites the completed step and the next undone step, and surfaces that
|
|
108
|
+
next step's `- model:` recommendation when it has one, which is what a fresh context
|
|
109
|
+
window needs to pick the right `/model`. Guidance, never a gate.
|