@gobing-ai/spur 0.3.65 → 0.3.67
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/marketplace.json +1 -1
- package/config/corpus-baseline.json +495 -10491
- package/config/workflows/history-anatomy.yaml +5 -4
- package/package.json +1 -1
- package/plugins/sp/agents/expert-spur.md +61 -88
- package/plugins/sp/commands/dev-review-session.md +11 -6
- package/plugins/sp/plugin.json +1 -1
- package/plugins/sp/scripts/dogfood-testing/detect-pipeline-driving.mjs +4 -0
- package/plugins/sp/scripts/dogfood-testing/detect-pipeline-driving.ts +4 -0
- package/plugins/sp/scripts/dogfood-testing/validate-report.mjs +1 -1
- package/plugins/sp/scripts/dogfood-testing/validate-report.ts +3 -2
- package/plugins/sp/skills/dogfood-testing/SKILL.md +11 -11
- package/plugins/sp/skills/session-review/SKILL.md +39 -6
- package/plugins/sp/skills/spur-cli/SKILL.md +38 -13
- package/plugins/sp/skills/spur-cli/references/agent.md +7 -4
- package/plugins/sp/skills/spur-cli/references/history.md +69 -0
- package/plugins/sp/skills/spur-cli/references/message.md +2 -2
- package/plugins/sp/skills/spur-cli/references/projects.md +59 -0
- package/plugins/sp/skills/spur-cli/references/tasks/verbs.md +35 -1
- package/plugins/sp/skills/spur-cli/references/team.md +1 -1
- package/plugins/sp/skills/spur-cli/references/workflows.md +6 -0
- package/plugins/sp/skills/spur-dev/SKILL.md +5 -0
- package/plugins/sp/skills/spur-dev/references/dev-operations.md +2 -2
- package/plugins/sp/skills/spur-dev/references/execution-batch.md +71 -15
- package/spur.js +363 -174
|
@@ -44,7 +44,6 @@
|
|
|
44
44
|
# spurBin — PATH-independent spur invocation (overridden by CLI at run start)
|
|
45
45
|
# __runId — run-scoped id for explicit artifact paths (allocated in start)
|
|
46
46
|
# stepTimeoutMs — agent.run budget for enrich/validate
|
|
47
|
-
# correctionCount — bounded correction loop counter file path bits (name resolved in correct)
|
|
48
47
|
|
|
49
48
|
"$schema": "@gobing-ai/spur/schemas/state-machine-workflow.schema.json"
|
|
50
49
|
kind: state-machine
|
|
@@ -73,7 +72,6 @@ vars:
|
|
|
73
72
|
spurBin: "spur"
|
|
74
73
|
__runId: ""
|
|
75
74
|
stepTimeoutMs: "1800000"
|
|
76
|
-
correctionCount: "0"
|
|
77
75
|
workflowFile: "config/workflows/history-anatomy.yaml"
|
|
78
76
|
contractVersion: "1"
|
|
79
77
|
reportDir: "docs/report"
|
|
@@ -231,8 +229,11 @@ states:
|
|
|
231
229
|
- id: correct
|
|
232
230
|
description: >
|
|
233
231
|
A two-pass correction budget (0690). onEnter increments the counter; retry edges guard on
|
|
234
|
-
the run-scoped correction-count file
|
|
235
|
-
|
|
232
|
+
the run-scoped correction-count file
|
|
233
|
+
`.spur/run/$__runId-correction-count` < 2 (the live bound — the
|
|
234
|
+
former `vars.correctionCount` declared-but-unread var was removed,
|
|
235
|
+
0702 R3), and a failure after the second repair takes the -> failed
|
|
236
|
+
edge. The
|
|
236
237
|
counter is shared by the structure-gate and validate FAIL edges, so a structure repair can
|
|
237
238
|
still be followed by one validation-driven repair. The
|
|
238
239
|
model half re-authors the candidate in place from the gate findings and validation notes —
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gobing-ai/spur",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.67",
|
|
4
4
|
"description": "Spur CLI — local-first harness for mainstream coding agents: constraint checking, workflow orchestration, agent health, and history analytics. Bun-native; exposes the `spur` command.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"spur",
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: expert-spur
|
|
3
3
|
description: |
|
|
4
|
-
Use PROACTIVELY for "create tasks for this feature", "update all task statuses", "audit task traceability", "create a feature with acceptance criteria", "harden the rule catalog", "author a batch of workflows", or "expert-spur". Multi-step
|
|
4
|
+
Use PROACTIVELY for "create tasks for this feature", "update all task statuses", "audit task traceability", "create a feature with acceptance criteria", "harden the rule catalog", "author a batch of workflows", or "expert-spur". Multi-step corpus work across `spur task`, `feature`, `rule`, and `workflow`: batch creation, status sweeps, section campaigns, traceability audits, rule hardening, and workflow authoring/refactoring. For one deterministic operation, run the CLI directly.
|
|
5
5
|
|
|
6
6
|
<example>
|
|
7
|
-
Context: Batch task status update across a feature
|
|
7
|
+
Context: Batch task status update across a feature.
|
|
8
8
|
user: "Move all A1 tasks from backlog to wip."
|
|
9
|
-
assistant: "Delegating to sp:expert-spur —
|
|
10
|
-
<commentary>
|
|
9
|
+
assistant: "Delegating to sp:expert-spur — loads the task reference, resolves the set, then applies and checks each transition."
|
|
10
|
+
<commentary>A multi-task sweep needs isolated sequencing and between-operation judgment.</commentary>
|
|
11
11
|
</example>
|
|
12
12
|
tools: [Read, Grep, Glob, Bash, Skill]
|
|
13
13
|
model: inherit
|
|
@@ -17,113 +17,86 @@ skills: [sp:spur-cli]
|
|
|
17
17
|
|
|
18
18
|
# Expert Spur
|
|
19
19
|
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
rule-catalog hardening, workflow refactors) that benefits from isolation; for a single operation,
|
|
24
|
-
use the `spur` CLI directly or invoke `sp:spur-dev`.
|
|
20
|
+
Thin specialist for multi-step Spur **corpus** work. The backend skill `sp:spur-cli` owns noun,
|
|
21
|
+
verb, flag, output, and exit semantics; this agent selects its task/feature/rule/workflow reference,
|
|
22
|
+
sequences operations, and evaluates each result before continuing.
|
|
25
23
|
|
|
26
24
|
## Role
|
|
27
25
|
|
|
28
|
-
You are the
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
`docs/design/workflow-shell-ownership.md`; never reformat to dodge the measure.
|
|
58
|
-
- **Latency and observability are authoring decisions.** Minimize `agent.run` node count first;
|
|
59
|
-
soft status-file probe over repeated probing; guards ordered cheapest-discriminating-first;
|
|
60
|
-
`iterationBound` from a latency budget; states named for outcomes; `failureStates` declared.
|
|
61
|
-
- **Refactor in a named direction** — promote (prose → workflow), demote (workflow → prose),
|
|
62
|
-
or optimize in place. Back an optimization with a before/after `spur workflow trace` pair,
|
|
63
|
-
never with a feel.
|
|
64
|
-
- Composition-advisory findings (`workflow validate --json` → `composition`) are advisory only;
|
|
65
|
-
never block a run or edit an executing pipeline over them.
|
|
66
|
-
- **Corpus health checks** — run `check`/`validate` across a batch and report findings.
|
|
67
|
-
|
|
68
|
-
For a single operation, use the `spur` CLI directly. For the planning/execution lifecycle, use
|
|
69
|
-
`sp:spur-dev`.
|
|
70
|
-
|
|
71
|
-
## Skill invocation
|
|
72
|
-
|
|
73
|
-
Invoke `sp:spur-cli` for verb guidance and per-noun conventions:
|
|
74
|
-
|
|
75
|
-
| Platform | Invocation |
|
|
76
|
-
| ---------- | ----------- |
|
|
77
|
-
| Claude Code | `Skill(skill="sp:spur-cli", args="<noun> <query>")` |
|
|
78
|
-
| Other platforms | Invoke `sp:spur-cli` directly as a skill |
|
|
26
|
+
You are the Spur corpus steward: a specialist sequencer over `skill: sp:spur-cli`, not a second
|
|
27
|
+
implementation of the CLI or lifecycle spine.
|
|
28
|
+
|
|
29
|
+
## Scope
|
|
30
|
+
|
|
31
|
+
Use for:
|
|
32
|
+
|
|
33
|
+
- Batch task or feature creation, mutation, status, section, refresh, and check campaigns.
|
|
34
|
+
- Cross-corpus traceability or structural audits.
|
|
35
|
+
- Rule catalog authoring, validation, execution, and hardening.
|
|
36
|
+
- Workflow fit decisions, authoring/refactoring, validation, dry-runs, and trace comparison.
|
|
37
|
+
|
|
38
|
+
Do not use for one CLI invocation. Do not use for planning→implementation→verification lifecycle
|
|
39
|
+
or batch task execution; `sp:spur-dev` owns that orchestration. The backend skill covers the other
|
|
40
|
+
CLI nouns for direct use, but they are not this corpus specialist's scope.
|
|
41
|
+
|
|
42
|
+
## Process
|
|
43
|
+
|
|
44
|
+
1. Load `plugins/sp/skills/spur-cli/SKILL.md` and the exact noun reference before invoking a verb.
|
|
45
|
+
2. Resolve and freeze the target set. Report ambiguity instead of guessing identifiers or flags.
|
|
46
|
+
3. Run the noun's read/check/validate path before mutation where available.
|
|
47
|
+
4. Mutate only through `spur`; parse `--json` output when the verb advertises it.
|
|
48
|
+
5. Inspect each result before the next dependent operation; stop on structural or validation failure.
|
|
49
|
+
6. Run the scoped check/validate/refresh path after mutation. After task/feature batch writes, run
|
|
50
|
+
`spur task check --corpus --json` once.
|
|
51
|
+
|
|
52
|
+
Workflow fit, mode selection, simplicity budgets, authoring, and tuning live in the workflow
|
|
53
|
+
references under `plugins/sp/skills/spur-cli/references/workflows/`; load them rather than copying
|
|
54
|
+
their runbook here.
|
|
79
55
|
|
|
80
56
|
## Rules
|
|
81
57
|
|
|
82
58
|
### Always
|
|
83
59
|
|
|
84
|
-
-
|
|
85
|
-
-
|
|
86
|
-
-
|
|
87
|
-
-
|
|
88
|
-
- [ ] Run the noun's scoped `refresh` after batch operations where one exists (`spur task refresh`, `spur feature refresh --feature <id>` or `--all`).
|
|
89
|
-
- [ ] Run the workflow fit gate before authoring any new workflow, and recommend a descriptive procedure when it does not clear all three parts.
|
|
60
|
+
- Use the source-local CLI when working in the Spur repository.
|
|
61
|
+
- Use `spur task update --section --from-file` for task section writes.
|
|
62
|
+
- Keep check-before/write/check-after evidence and the final scoped refresh result.
|
|
63
|
+
- Preserve declaration order and currently executing runs when changing workflows.
|
|
90
64
|
|
|
91
65
|
### Never
|
|
92
66
|
|
|
93
|
-
-
|
|
94
|
-
-
|
|
95
|
-
-
|
|
96
|
-
-
|
|
67
|
+
- Edit task or feature corpus files directly.
|
|
68
|
+
- Invent a noun, verb, flag, JSON field, or exit code.
|
|
69
|
+
- Reimplement CLI validation in prose or shell.
|
|
70
|
+
- Never drive the planning/execution lifecycle; do not run application implementation or task
|
|
71
|
+
pipelines through this agent.
|
|
97
72
|
|
|
98
73
|
## Output Format
|
|
99
74
|
|
|
100
|
-
Report using this template:
|
|
101
|
-
|
|
102
75
|
```markdown
|
|
103
76
|
## Spur Corpus Operations Report
|
|
104
77
|
|
|
105
|
-
**Noun(s)
|
|
106
|
-
**
|
|
107
|
-
**Confidence
|
|
78
|
+
**Noun(s):** task | feature | rule | workflow
|
|
79
|
+
**Scope:** <resolved ids/files>
|
|
80
|
+
**Confidence:** HIGH | MEDIUM | LOW
|
|
108
81
|
|
|
109
82
|
### Changes
|
|
110
|
-
|
|
|
111
|
-
|
|
112
|
-
| 0042 | update wip |
|
|
113
|
-
|
|
114
|
-
###
|
|
115
|
-
- check
|
|
116
|
-
-
|
|
117
|
-
|
|
118
|
-
### Next Steps
|
|
119
|
-
1. [Actionable step]
|
|
83
|
+
| Target | Operation | Result |
|
|
84
|
+
| --- | --- | --- |
|
|
85
|
+
| 0042 | update wip | pass |
|
|
86
|
+
|
|
87
|
+
### Gates
|
|
88
|
+
- pre-check: <result>
|
|
89
|
+
- post-check/validate: <result>
|
|
90
|
+
- refresh/corpus sweep: <result or n/a>
|
|
120
91
|
```
|
|
121
92
|
|
|
122
93
|
## Platform Notes
|
|
123
94
|
|
|
124
|
-
-
|
|
125
|
-
-
|
|
95
|
+
- Claude Code: use `Skill(skill="sp:spur-cli", args="<noun> <query>")`, then Bash for `spur`.
|
|
96
|
+
- Other platforms: invoke `sp:spur-cli` directly; the agent wrapper is optional.
|
|
126
97
|
|
|
127
98
|
## Dispatch surface
|
|
128
99
|
|
|
129
|
-
|
|
100
|
+
If corpus work must be dispatched again, follow
|
|
101
|
+
[dispatch-surface.md](../skills/parallel-execution/references/dispatch-surface.md): native subagent
|
|
102
|
+
by default, `spur agent run` only on a named trigger.
|
|
@@ -1,22 +1,25 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: "Review the active coding-agent session immediately: summarize outcomes, distinguish resolved and open issues with evidence, and propose bounded improvements. Triggers: review this session, session wrap-up, immediate retrospective, what happened, what was resolved"
|
|
2
|
+
description: "Review the active coding-agent session immediately: summarize outcomes, distinguish resolved and open issues with evidence, and propose bounded improvements. With --triage: apply pure-doc / one-to-two-line fixes inline, then file remaining findings as one new task. Triggers: review this session, session wrap-up, immediate retrospective, what happened, what was resolved, triage findings"
|
|
3
3
|
role: reviewer
|
|
4
|
-
argument-hint: "[<focus>]"
|
|
4
|
+
argument-hint: "[<focus>] [--triage]"
|
|
5
5
|
allowed-tools: ["Bash", "Read", "Grep", "Glob", "Skill"]
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
# Dev Review Session
|
|
9
9
|
|
|
10
|
-
Wraps the **sp:session-review** skill for a lightweight
|
|
11
|
-
|
|
12
|
-
session context is preserved
|
|
13
|
-
applies
|
|
10
|
+
Wraps the **sp:session-review** skill for a lightweight review of the active host session. By
|
|
11
|
+
default it is report-only: current conversation plus read-only repository evidence, run inline so
|
|
12
|
+
the session context is preserved — no workflow launch, history import, task creation, or
|
|
13
|
+
remediation. With `--triage`, it first triages the findings, then applies direct fixes (pure
|
|
14
|
+
documentation work and one-to-two-line fixes) inline and files everything remaining as exactly one
|
|
15
|
+
new task for further fixing.
|
|
14
16
|
|
|
15
17
|
## Argument Flags
|
|
16
18
|
|
|
17
19
|
| Flag | Description | Default |
|
|
18
20
|
| --- | --- | --- |
|
|
19
21
|
| `[<focus>]` | Optional question or operation to emphasize without excluding material session outcomes. | full active session |
|
|
22
|
+
| `--triage` | After the report: bucket findings → apply pure-doc / 1–2-line fixes inline → create one task for the remainder. | off (report-only) |
|
|
20
23
|
|
|
21
24
|
For shared semantics, see the [flag glossary](../skills/spur-dev/references/flag-glossary.md).
|
|
22
25
|
|
|
@@ -25,6 +28,8 @@ For shared semantics, see the [flag glossary](../skills/spur-dev/references/flag
|
|
|
25
28
|
```
|
|
26
29
|
/sp:dev-review-session
|
|
27
30
|
/sp:dev-review-session "why the verification loop repeated"
|
|
31
|
+
/sp:dev-review-session --triage
|
|
32
|
+
/sp:dev-review-session "F95 findings" --triage
|
|
28
33
|
```
|
|
29
34
|
|
|
30
35
|
## Implementation
|
package/plugins/sp/plugin.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "sp",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.67",
|
|
4
4
|
"description": "Spur — a local-first harness engineering toolkit that wraps mainstream coding agents with constraint checking, workflow orchestration, and history analytics.",
|
|
5
5
|
"extensions": {
|
|
6
6
|
"pi": ["./hooks/pi/guard-extension.ts"]
|
|
@@ -18,7 +18,7 @@ function countLedgerDataRows(markdown) {
|
|
|
18
18
|
const nextHeading = after.search(/^### /m);
|
|
19
19
|
const body = nextHeading === -1 ? after : after.slice(0, nextHeading);
|
|
20
20
|
const rows = body.split(`
|
|
21
|
-
`).filter((line) => line.trim().startsWith("|")).filter((line) => !/^\|[\s:|-]+\|?\s*$/.test(line.trim())).filter((line) => !/^\|\s
|
|
21
|
+
`).filter((line) => line.trim().startsWith("|")).filter((line) => !/^\|[\s:|-]+\|?\s*$/.test(line.trim())).filter((line) => !/^\|\s*`?drift:/.test(line.trim()));
|
|
22
22
|
return Math.max(rows.length - 1, 0);
|
|
23
23
|
}
|
|
24
24
|
function declaredExecutedSteps(markdown) {
|
|
@@ -37,8 +37,9 @@ function countLedgerDataRows(markdown: string): number | null {
|
|
|
37
37
|
.filter((line) => line.trim().startsWith('|'))
|
|
38
38
|
.filter((line) => !/^\|[\s:|-]+\|?\s*$/.test(line.trim()))
|
|
39
39
|
// drift:external rows are documentary (task 0296) — included in the table but
|
|
40
|
-
// subtracted from the executed-step count, per the @1.2 cardinality contract
|
|
41
|
-
|
|
40
|
+
// subtracted from the executed-step count, per the @1.2 cardinality contract;
|
|
41
|
+
// the prescribed code-span form (`drift:external`) matches too (task 0701 R5b).
|
|
42
|
+
.filter((line) => !/^\|\s*`?drift:/.test(line.trim()));
|
|
42
43
|
// Minus the header row; what remains are data rows.
|
|
43
44
|
return Math.max(rows.length - 1, 0);
|
|
44
45
|
}
|
|
@@ -408,22 +408,22 @@ no fix applications and a clean tree at finalize needs no drift row.
|
|
|
408
408
|
|
|
409
409
|
### What drift is — and is not
|
|
410
410
|
|
|
411
|
-
**Drift** = a tracked file changes that neither the driver nor
|
|
412
|
-
**Explained** set = files named in ledger `Fix Applied` cells (driver fixes) plus
|
|
413
|
-
|
|
414
|
-
|
|
411
|
+
**Drift** = a tracked file changes that neither the driver nor a testee ledger row names.
|
|
412
|
+
**Explained** set = files named in ledger `Fix Applied` cells (driver fixes) plus testee writes the
|
|
413
|
+
driver recorded in the ledger. Anything else new or modified in `git status --porcelain` since
|
|
414
|
+
baseline is drift.
|
|
415
415
|
|
|
416
416
|
### On detecting drift
|
|
417
417
|
|
|
418
418
|
- Append a **warning ledger row** tagged `drift:external` in the Step column: paths in `Fix Applied`,
|
|
419
|
-
`Outcome: drift`, `Basis: <fingerprint diff>`. Do NOT mark the step PASSED/FIXED
|
|
420
|
-
drift; the row records the drift, it does not change a step's outcome.
|
|
419
|
+
`Outcome: drift`, `Basis: <fingerprint diff>`. Do NOT mark the step PASSED/FIXED because of
|
|
420
|
+
drift; the row records the drift, it does not change a step's outcome. Write the Step cell as
|
|
421
|
+
the code span `` `drift:external` `` — the validator drops it from the data-row count (0701 R5b).
|
|
421
422
|
- Emit a **mandatory report finding** under §6 Findings — `P2 — workspace drift detected during
|
|
422
|
-
run; attribution to external writer` — naming the drifted paths and the snapshot delta. The
|
|
423
|
-
|
|
424
|
-
- The driver **never** claims drifted files as its own or the testee's work
|
|
425
|
-
`Fix Applied` cites only
|
|
426
|
-
separately.
|
|
423
|
+
run; attribution to external writer` — naming the drifted paths and the snapshot delta. The
|
|
424
|
+
report states the run's evidence is degraded, not voided.
|
|
425
|
+
- The driver **never** claims drifted files as its own or the testee's work: a fix row's
|
|
426
|
+
`Fix Applied` cites only what the driver changed; drift rows cite drifted paths separately.
|
|
427
427
|
|
|
428
428
|
### Worktree advisory (mutating dogfoods)
|
|
429
429
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: session-review
|
|
3
|
-
description: "Review the active coding-agent session
|
|
3
|
+
description: "Review the active coding-agent session: separate resolved from open issues with evidence, propose bounded improvements. With --triage, apply pure-doc / 1–2-line fixes inline and file the rest as one task. Triggers: review this session, wrap-up, triage findings."
|
|
4
4
|
license: Apache-2.0
|
|
5
|
-
version: 1.
|
|
5
|
+
version: 1.1.0
|
|
6
6
|
metadata:
|
|
7
7
|
author: spur
|
|
8
8
|
platforms: "claude-code,codex,openclaw,opencode,antigravity,pi"
|
|
@@ -31,6 +31,7 @@ cross-agent windows, recurrence, trends, or quantitative performance forensics.
|
|
|
31
31
|
| Argument | Description | Default |
|
|
32
32
|
| --- | --- | --- |
|
|
33
33
|
| `[focus]` | Question or operation to emphasize. It changes ordering, not evidence collection. | full active session |
|
|
34
|
+
| `--triage` | Opt into bounded remediation after the report: apply direct fixes (pure docs / one-to-two-line fixes) inline, then file all remaining actionable findings as exactly one new task via the CLI-gated corpus surface. | off (report-only) |
|
|
34
35
|
|
|
35
36
|
## Evidence boundary
|
|
36
37
|
|
|
@@ -46,6 +47,28 @@ cross-agent windows, recurrence, trends, or quantitative performance forensics.
|
|
|
46
47
|
- State `not available` when compaction or missing output removed evidence. Never reconstruct it from
|
|
47
48
|
memory or claim a verification that did not run.
|
|
48
49
|
|
|
50
|
+
## Triage mode (`--triage`)
|
|
51
|
+
|
|
52
|
+
Report-only stays the default. With `--triage`, run the same evidence pass, then remediate in
|
|
53
|
+
three buckets — never skip triage and start fixing from the raw findings list.
|
|
54
|
+
|
|
55
|
+
1. **Triage every finding into exactly one bucket:**
|
|
56
|
+
- **Direct fix** — pure documentation work, or a one-to-two-line fix with obvious, local,
|
|
57
|
+
low-risk scope. Read the root cause first; a "one-liner" that needs design or touches a
|
|
58
|
+
shared write path is not direct.
|
|
59
|
+
- **Task** — real, actionable, and not already owned by an existing task. Deferred
|
|
60
|
+
requirements recorded inside their own task files are pointers, not duplicates.
|
|
61
|
+
- **Note** — pre-existing, environmental, or ownerless observations; report only.
|
|
62
|
+
2. **Apply direct fixes inline** — smallest surgical diff, project style, and re-verify each
|
|
63
|
+
with the targeted check (lint / test / the exact command that exhibited the issue).
|
|
64
|
+
3. **Create exactly one task** for the Task bucket through the CLI-gated corpus surface
|
|
65
|
+
(`spur task create`, then `spur task update <wbs> --section <s> --from-file` per section).
|
|
66
|
+
One task, not one per finding: each finding keeps its evidence, a suggested fix direction,
|
|
67
|
+
and an AC where verifiable. Exclude what direct fixes already resolved — say so in the task
|
|
68
|
+
Background instead.
|
|
69
|
+
4. **Report** — add a Triage section: applied fixes (path + one-line what + verification) and
|
|
70
|
+
the created task WBS. The Resolved/Open tables keep their evidence rules unchanged.
|
|
71
|
+
|
|
49
72
|
## Protocol
|
|
50
73
|
|
|
51
74
|
1. **Resolve scope.** Review the active session from the operator's initiating request through the
|
|
@@ -86,6 +109,14 @@ session. Do not list ordinary implementation steps as issues.
|
|
|
86
109
|
For each supported proposal, name its owner surface, expected impact, verification method, and
|
|
87
110
|
reversibility. Proposals remain report-only: apply no change and create no task.
|
|
88
111
|
|
|
112
|
+
### Triage (only when `--triage` was passed)
|
|
113
|
+
|
|
114
|
+
| Applied fix / created task | Bucket | What + verification |
|
|
115
|
+
| --- | --- | --- |
|
|
116
|
+
|
|
117
|
+
One row per applied fix and one per created task (with its WBS). Omit the section entirely when
|
|
118
|
+
`--triage` was not passed.
|
|
119
|
+
|
|
89
120
|
### Next actions
|
|
90
121
|
|
|
91
122
|
List only actions needed to finish partial scope, confirm a hypothesis, or preserve a demonstrated
|
|
@@ -94,10 +125,12 @@ improvement. Use `None` when the session is complete and no follow-up is justifi
|
|
|
94
125
|
## Boundaries
|
|
95
126
|
|
|
96
127
|
- Stay in the active host session. Do not delegate; a fresh context loses the evidence being reviewed.
|
|
97
|
-
- Do not launch a workflow, import history,
|
|
98
|
-
|
|
99
|
-
-
|
|
100
|
-
|
|
128
|
+
- Do not launch a workflow, import history, append indexed-context memory, perform baseline
|
|
129
|
+
comparison or recurrence classification, or emit a twelve-section forensic report; those belong
|
|
130
|
+
to imported-history analysis.
|
|
131
|
+
- Report-only by default: do not create or update corpus items or edit files. The single exception
|
|
132
|
+
is `--triage` mode, which permits exactly two mutation classes — direct fixes from the triage
|
|
133
|
+
bucket, and the one triage task. Anything beyond that stays a proposal.
|
|
101
134
|
- Do not turn a single low-impact observation into a new policy. Report it as a candidate until it
|
|
102
135
|
recurs or demonstrates a high-impact contract violation.
|
|
103
136
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: spur-cli
|
|
3
|
-
description: "
|
|
3
|
+
description: "Reference and operate the complete `spur` CLI surface: task, feature, rule, workflow, builder, agent, message, team, self, history, and projects. Use for verb or flag lookup, machine-readable output and exit contracts, or CLI-gated corpus writes. Triggers: \"spur task\", \"spur history\", \"spur projects\", \"create a task\", \"task check\", and any Spur CLI convention. Not for planning or execution lifecycle orchestration (`sp:spur-dev`)."
|
|
4
4
|
license: Apache-2.0
|
|
5
5
|
metadata:
|
|
6
6
|
author: spur
|
|
@@ -19,15 +19,17 @@ metadata:
|
|
|
19
19
|
- message
|
|
20
20
|
- team
|
|
21
21
|
- self
|
|
22
|
+
- history
|
|
23
|
+
- projects
|
|
22
24
|
openclaw:
|
|
23
25
|
emoji: "🧰"
|
|
24
26
|
---
|
|
25
27
|
|
|
26
28
|
# spur-cli — the CLI facade for the Spur command surface
|
|
27
29
|
|
|
28
|
-
`spur-cli` is the single reference for operating the **`spur` command-line surface**. Each
|
|
29
|
-
noun
|
|
30
|
-
|
|
30
|
+
`spur-cli` is the single reference for operating the **`spur` command-line surface**. Each visible
|
|
31
|
+
noun has one reference file that documents *what each verb is, how to use it well, its flags,
|
|
32
|
+
machine-readable output, and material exit semantics*. This skill is a **facade /
|
|
31
33
|
dispatch reference** — it tells you which verb does what and routes you to the noun's detail. It is
|
|
32
34
|
**not** an orchestrator and contains **no competency logic**: the skill knows *how to invoke*; the
|
|
33
35
|
CLI knows *what is valid*; the **spine** (`sp:spur-dev`) knows *how to drive the lifecycle*.
|
|
@@ -47,18 +49,20 @@ Pick the noun, read its reference. Each Tier A and Tier B reference owns that no
|
|
|
47
49
|
| **Tier B** | **message** | Durable inter-agent messaging: send, inbox, reply, watch | [references/message.md](references/message.md) |
|
|
48
50
|
| **Tier B** | **team** | Team coordination and supervision: assign, status, up/down rosters, start/stop supervised processes | [references/team.md](references/team.md) |
|
|
49
51
|
| **Tier B** | **self** | Self-management verbs: scaffold (`init`), schema migrations (`migrate`), local web server (`serve`), status overview (`status`); `self init` runs post-scaffold validation probes & layout classification | [references/self.md](references/self.md) |
|
|
50
|
-
| **Tier
|
|
52
|
+
| **Tier B** | **history** | Import agent histories, aggregate forensic artifacts, render reports, and run the checkpoint-resumed daily pipeline | [references/history.md](references/history.md) |
|
|
53
|
+
| **Tier B** | **projects** | Manage the local multi-project registry and start/stop project servers | [references/projects.md](references/projects.md) |
|
|
54
|
+
| **Tier C** | **help** | Commander-generated help command; not a Spur noun | Generated `--help` |
|
|
51
55
|
|
|
52
|
-
**Execute-First Contract:** Load
|
|
56
|
+
**Execute-First Contract:** Load the noun reference first and execute Tier A or Tier B commands
|
|
57
|
+
without calling `spur --help`. Use the source-local `spur <noun> [verb] --help` only for version
|
|
58
|
+
skew, unlisted long-tail flags, or a parity assertion failure.
|
|
53
59
|
|
|
54
60
|
### Tier C exclusion reasons
|
|
55
61
|
|
|
56
|
-
|
|
62
|
+
The only exclusion is generated by Commander and is not a product noun:
|
|
57
63
|
|
|
58
64
|
| Noun | Reason |
|
|
59
65
|
| ------ | -------- |
|
|
60
|
-
| `history` | `report` verb is a TODO stub (`spur history report` prints a marker); surface is still converging. |
|
|
61
|
-
| `projects` | Multi-project management surface (`add`/`remove`/`list`/`start`/`stop`); still evolving and not yet stable enough for a reference. |
|
|
62
66
|
| `help` | Auto-generated by Commander.js; not a real noun. |
|
|
63
67
|
|
|
64
68
|
Each noun's per-topic detail lives one level deeper under `references/<noun>/` (e.g.
|
|
@@ -74,6 +78,8 @@ Use this skill to:
|
|
|
74
78
|
or run a workflow, from the command line.
|
|
75
79
|
- **Author within a noun** — write a rule, author a workflow, write acceptance criteria — following
|
|
76
80
|
the noun reference's conventions.
|
|
81
|
+
- **Operate local analytics and project management** — import/analyze/report history or manage the
|
|
82
|
+
multi-project registry through their references.
|
|
77
83
|
|
|
78
84
|
Do **not** use this skill for:
|
|
79
85
|
|
|
@@ -89,6 +95,22 @@ file** (`references/<noun>.md`), plus an optional `references/<noun>/` subdir fo
|
|
|
89
95
|
detail, plus one row in the Noun-routing table above. Do not create a separate `spur-<noun>` skill —
|
|
90
96
|
the whole point of this facade is that the CLI surface has a single, scalable home.
|
|
91
97
|
|
|
98
|
+
## Source and machine-output contract
|
|
99
|
+
|
|
100
|
+
The implementation authority is `apps/cli/src/index.ts` plus the noun registration module under
|
|
101
|
+
`apps/cli/src/commands/`; application-service output types remain authoritative for payload fields.
|
|
102
|
+
When a reference and the source-local CLI disagree, stop, cite the source symbol, and repair the
|
|
103
|
+
reference in the same change. The live parity gate is
|
|
104
|
+
`plugins/sp/tests/cli-surface-parity.test.ts`.
|
|
105
|
+
|
|
106
|
+
Do not assume every verb supports JSON. When `<noun> <verb> --help` advertises `--json`, parse
|
|
107
|
+
stdout as one JSON document (or one document per row for documented streams). When it also
|
|
108
|
+
advertises `--json-envelope`, raw JSON remains the default; the opt-in shape is
|
|
109
|
+
`{ ok: true, data }` / `{ ok: false, error }`, with paginated list metadata where applicable.
|
|
110
|
+
`SPUR_JSON_ENVELOPE=1` enables the same seam unless an explicit flag overrides it. The guarded
|
|
111
|
+
inventory and deliberate raw exceptions live in `docs/04_DESIGN.md` §4.1 and
|
|
112
|
+
`apps/cli/tests/json-envelope-inventory.test.ts`; do not duplicate that inventory here.
|
|
113
|
+
|
|
92
114
|
## What this skill is NOT
|
|
93
115
|
|
|
94
116
|
- **Not the spine.** Driving a task through `task-pipeline.yaml`, HITL surfacing, decomposition, and
|
|
@@ -126,20 +148,23 @@ and spreading it; full contract in `docs/04_DESIGN.md` §1.0.1.
|
|
|
126
148
|
- **[references/self.md](references/self.md)** - `spur self init|migrate|serve|status` CLI verbs
|
|
127
149
|
(the four legacy top-level nouns remain hidden aliases). `self init` runs post-scaffold init
|
|
128
150
|
validation (Phase 1.5/1.6 probes).
|
|
151
|
+
- **[references/history.md](references/history.md)** - history import, forensic artifact analysis,
|
|
152
|
+
pure report rendering, and the daily pipeline.
|
|
153
|
+
- **[references/projects.md](references/projects.md)** - local multi-project registry and server
|
|
154
|
+
lifecycle.
|
|
129
155
|
- **`sp:spur-dev`** - the spine that dispatches these verbs into the planning +
|
|
130
156
|
execution lifecycle. Use it to *drive* work; use this facade to *look up or operate a verb*.
|
|
131
157
|
- **`plugins/sp/references/roles.md`** — the Layer-1 role→tier table (`scribe` / `coder` /
|
|
132
158
|
`reviewer` / `planner`, one per tier). The facade's nouns/verbs serve those roles; the table is
|
|
133
159
|
the role vocabulary, the operator config maps tiers to executors.
|
|
134
|
-
- **`sp:expert-spur`** — the subagent that loads this facade for multi-step, multi-noun corpus work
|
|
135
|
-
in its own context window.
|
|
136
160
|
|
|
137
161
|
## Platform Notes
|
|
138
162
|
|
|
139
163
|
### Claude Code
|
|
140
164
|
|
|
141
|
-
`spur` CLI via the Bash tool
|
|
142
|
-
directly via `Skill(skill="sp:spur-cli", args="<noun> <verb> …")` to look up or operate
|
|
165
|
+
Run the `spur` CLI via the Bash tool. Use `--json` only where the selected verb advertises it. Invoke
|
|
166
|
+
this skill directly via `Skill(skill="sp:spur-cli", args="<noun> <verb> …")` to look up or operate
|
|
167
|
+
a verb.
|
|
143
168
|
|
|
144
169
|
### Codex / OpenClaw / OpenCode / Antigravity
|
|
145
170
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: spur-cli-agent
|
|
3
|
-
description: "spur-cli noun reference: operate `spur agent` as the coding-agent execution surface - run prompts
|
|
3
|
+
description: "spur-cli noun reference: operate `spur agent` as the coding-agent execution surface - run prompts, wait on pinned occupants, manage team agent specs, run the persistent self-draining loop, and check readiness."
|
|
4
4
|
see_also:
|
|
5
5
|
- spur-cli
|
|
6
6
|
---
|
|
@@ -9,7 +9,7 @@ see_also:
|
|
|
9
9
|
|
|
10
10
|
`spur agent` is the CLI for **running and inspecting coding agents**. It wraps the agents the
|
|
11
11
|
operator already has installed (Claude Code, Codex, omp, OpenCode, Antigravity, etc.) behind a
|
|
12
|
-
uniform
|
|
12
|
+
uniform run, wait, loop, and spec-management surface, so the rest of the harness can dispatch work without
|
|
13
13
|
hard-coding a specific agent.
|
|
14
14
|
|
|
15
15
|
This is a **companion reference**, not an orchestrator. It documents *what each verb is and how to
|
|
@@ -30,8 +30,9 @@ that before using `run` for fan-out dispatch.
|
|
|
30
30
|
| `edit <id>` | Open an agent spec in `$EDITOR`, or print its path | - |
|
|
31
31
|
| `delete <id>` | Remove an agent spec | `--force` |
|
|
32
32
|
|
|
33
|
-
|
|
34
|
-
|
|
33
|
+
`list`, `doctor`, `run`, `wait`, and `create` accept `--json` plus `--json-envelope`. `loop`, `edit`,
|
|
34
|
+
and `delete` are human/process-control surfaces. **Exit codes:** `0` success, `1` failure, and `2`
|
|
35
|
+
invalid usage; `run` can also propagate the invoked agent's non-zero result.
|
|
35
36
|
|
|
36
37
|
## `run` - execute a prompt via a coding agent
|
|
37
38
|
|
|
@@ -56,6 +57,7 @@ through a coding agent as an external process, producing a persisted run record
|
|
|
56
57
|
| `--spec <id>` | Team agent spec id (occupant addressing, 0542 R1). Pairs with `--drain`; with `--spec` alone the run is addressed to the occupant without touching the inbox. A legacy `--agent <spec-id>` still works during the transition with a one-time warning (shim `agent-flag-spec-id`). |
|
|
57
58
|
| `--drain` | Prepend pending inbox messages addressed to `--spec <id>` before the prompt. |
|
|
58
59
|
| `--json` | Output machine-readable JSON where supported. |
|
|
60
|
+
| `--json-envelope` | Wrap JSON using the facade's standard output contract. |
|
|
59
61
|
|
|
60
62
|
`--json` adds a `resolved` block (`{ role?, tier?, executor?, agent, source }`) reporting the
|
|
61
63
|
resolution decision — the role, its tier, and the executor that won for role routing; the pin for
|
|
@@ -125,6 +127,7 @@ exits 2 naming the accepted vocabulary. Resolution collapses onto the same ident
|
|
|
125
127
|
|
|
126
128
|
| Flag | Purpose |
|
|
127
129
|
| ------ | --------- |
|
|
130
|
+
| `--role <name>` | Resolve a Layer-1 role or executor name to exactly one materialized instance; mutually exclusive with `[specId]`. |
|
|
128
131
|
| `--run <runId>` | Pin a specific run id (default: the spec's latest run). |
|
|
129
132
|
| `--until <state>` | Lifecycle state to wait for (repeatable OR): `idle` \| `working` \| `invoke-exit` \| `blocked`. Default `idle`. |
|
|
130
133
|
| `--timeout <ms>` | Caller deadline. Undefined = no deadline (stall budget still applies). |
|