bigpowers 2.73.9 → 2.74.1
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/.continue/rules/context7-mcp.md +0 -0
- package/.continue/rules/diagnose-stall.md +0 -0
- package/.kilocode/rules/context7-mcp.md +0 -0
- package/.kilocode/rules/diagnose-stall.md +0 -0
- package/.pi/package.json +2 -2
- package/.pi/prompts/audit-code.md +17 -13
- package/.pi/prompts/build-epic.md +5 -0
- package/.pi/prompts/change-request.md +4 -1
- package/.pi/prompts/compose-workflow.md +17 -0
- package/.pi/prompts/context7-mcp.md +54 -0
- package/.pi/prompts/craft-skill.md +28 -0
- package/.pi/prompts/deepen-architecture.md +20 -0
- package/.pi/prompts/delegate-task.md +14 -0
- package/.pi/prompts/deploy.md +8 -0
- package/.pi/prompts/develop-tdd.md +15 -4
- package/.pi/prompts/diagnose-stall.md +53 -0
- package/.pi/prompts/dispatch-agents.md +53 -19
- package/.pi/prompts/evolve-skill.md +7 -0
- package/.pi/prompts/gate-trace.md +9 -1
- package/.pi/prompts/guard-git.md +14 -0
- package/.pi/prompts/kickoff-branch.md +4 -0
- package/.pi/prompts/migrate-spec.md +18 -0
- package/.pi/prompts/plan-work.md +62 -2
- package/.pi/prompts/publish-package.md +11 -0
- package/.pi/prompts/release-branch.md +46 -43
- package/.pi/prompts/request-review.md +57 -17
- package/.pi/prompts/research-first.md +3 -0
- package/.pi/prompts/run-benchmark.md +3 -3
- package/.pi/prompts/run-evals.md +26 -6
- package/.pi/prompts/run-planning.md +1 -0
- package/.pi/prompts/scope-work.md +3 -0
- package/.pi/prompts/search-skills.md +3 -0
- package/.pi/prompts/security-review.md +66 -12
- package/.pi/prompts/seed-conventions.md +68 -0
- package/.pi/prompts/session-state.md +5 -10
- package/.pi/prompts/slice-tasks.md +3 -0
- package/.pi/prompts/smoke-test.md +11 -0
- package/.pi/prompts/stocktake-skills.md +6 -1
- package/.pi/prompts/validate-contracts.md +12 -0
- package/.pi/prompts/validate-fix.md +2 -0
- package/.pi/prompts/verify-work.md +42 -20
- package/.pi/prompts/wire-ci.md +11 -0
- package/.pi/prompts/write-document.md +10 -0
- package/.pi/skills/audit-code/SKILL.md +17 -13
- package/.pi/skills/build-epic/SKILL.md +5 -0
- package/.pi/skills/change-request/SKILL.md +4 -1
- package/.pi/skills/compose-workflow/SKILL.md +17 -0
- package/.pi/skills/context7-mcp/SKILL.md +56 -0
- package/.pi/skills/craft-skill/SKILL.md +28 -0
- package/.pi/skills/deepen-architecture/SKILL.md +20 -0
- package/.pi/skills/delegate-task/SKILL.md +14 -0
- package/.pi/skills/deploy/SKILL.md +8 -0
- package/.pi/skills/develop-tdd/SKILL.md +15 -4
- package/.pi/skills/diagnose-stall/SKILL.md +55 -0
- package/.pi/skills/dispatch-agents/SKILL.md +53 -19
- package/.pi/skills/evolve-skill/SKILL.md +7 -0
- package/.pi/skills/gate-trace/SKILL.md +9 -1
- package/.pi/skills/guard-git/SKILL.md +14 -0
- package/.pi/skills/kickoff-branch/SKILL.md +4 -0
- package/.pi/skills/migrate-spec/SKILL.md +18 -0
- package/.pi/skills/plan-work/SKILL.md +62 -2
- package/.pi/skills/publish-package/SKILL.md +11 -0
- package/.pi/skills/release-branch/SKILL.md +46 -43
- package/.pi/skills/request-review/SKILL.md +57 -17
- package/.pi/skills/research-first/SKILL.md +3 -0
- package/.pi/skills/run-benchmark/SKILL.md +3 -3
- package/.pi/skills/run-evals/SKILL.md +26 -6
- package/.pi/skills/run-planning/SKILL.md +1 -0
- package/.pi/skills/scope-work/SKILL.md +3 -0
- package/.pi/skills/search-skills/SKILL.md +3 -0
- package/.pi/skills/security-review/SKILL.md +66 -12
- package/.pi/skills/seed-conventions/SKILL.md +68 -0
- package/.pi/skills/session-state/SKILL.md +5 -10
- package/.pi/skills/slice-tasks/SKILL.md +3 -0
- package/.pi/skills/smoke-test/SKILL.md +11 -0
- package/.pi/skills/stocktake-skills/SKILL.md +6 -1
- package/.pi/skills/validate-contracts/SKILL.md +12 -0
- package/.pi/skills/validate-fix/SKILL.md +2 -0
- package/.pi/skills/verify-work/SKILL.md +42 -20
- package/.pi/skills/wire-ci/SKILL.md +11 -0
- package/.pi/skills/write-document/SKILL.md +10 -0
- package/CHANGELOG.md +15 -0
- package/CLAUDE.md +59 -1
- package/CONVENTIONS.md +81 -0
- package/README.md +1 -1
- package/SKILL-INDEX.md +1 -1
- package/package.json +1 -1
- package/scripts/bp-churn-rank.sh +49 -0
- package/scripts/bp-read-agents.sh +1 -0
- package/scripts/check-import-boundaries.sh +64 -0
- package/scripts/compile-rule-matrix.sh +114 -0
- package/scripts/hooks/rtk-rewrite.sh +11 -0
- package/scripts/hooks/token-mgmt-pre-tool-use.sh +53 -0
- package/scripts/install.sh +6 -0
- package/scripts/lib/completeness-critic.sh +62 -0
- package/scripts/lib/doc-fetch-cache.sh +71 -0
- package/scripts/lib/golden-suite-gates.sh +3 -1
- package/scripts/lib/parallel-review-worktrees.sh +34 -0
- package/scripts/lib/plan-consistency-check.sh +88 -0
- package/scripts/lib/run-benchmark.py +210 -0
- package/scripts/lib/sync-context-engineering-ref.sh +19 -0
- package/scripts/references-manifest.yaml +19 -0
- package/scripts/run-benchmark.sh +6 -0
- package/scripts/run-skill-verify.sh +1 -0
- package/scripts/sync-references.sh +25 -0
- package/scripts/sync-skills.sh +12 -1
- package/scripts/validate-skill-catalog.sh +147 -0
- package/scripts/validate-skill-description.sh +70 -0
- package/skills/audit-code/SKILL.md +19 -13
- package/skills/build-epic/SKILL.md +6 -1
- package/skills/change-request/SKILL.md +4 -1
- package/skills/compose-workflow/SKILL.md +17 -0
- package/skills/context7-mcp/SKILL.md +57 -0
- package/skills/craft-skill/SKILL.md +29 -0
- package/skills/deepen-architecture/SKILL.md +22 -0
- package/skills/delegate-task/SKILL.md +14 -0
- package/skills/deploy/SKILL.md +9 -0
- package/skills/develop-tdd/SKILL.md +18 -4
- package/skills/diagnose-stall/SKILL.md +56 -0
- package/skills/dispatch-agents/SKILL.md +53 -19
- package/skills/elaborate-spec/SKILL.md +1 -0
- package/skills/evolve-skill/SKILL.md +7 -0
- package/skills/gate-trace/SKILL.md +11 -1
- package/skills/guard-git/REFERENCE.md +14 -0
- package/skills/kickoff-branch/SKILL.md +4 -1
- package/skills/migrate-spec/REFERENCE.md +12 -0
- package/skills/migrate-spec/SKILL.md +6 -0
- package/skills/plan-work/REFERENCE.md +29 -2
- package/skills/plan-work/SKILL.md +38 -0
- package/skills/publish-package/REFERENCE.md +11 -0
- package/skills/release-branch/REFERENCE.md +14 -0
- package/skills/release-branch/SKILL.md +33 -44
- package/skills/request-review/SKILL.md +59 -17
- package/skills/research-first/SKILL.md +3 -0
- package/skills/run-benchmark/SKILL.md +5 -4
- package/skills/run-evals/REFERENCE.md +14 -4
- package/skills/run-evals/SKILL.md +13 -2
- package/skills/run-planning/SKILL.md +1 -0
- package/skills/scope-work/SKILL.md +3 -0
- package/skills/search-skills/SKILL.md +3 -0
- package/skills/security-review/REFERENCE-false-positives.md +9 -8
- package/skills/security-review/REFERENCE-vuln-categories.md +4 -0
- package/skills/security-review/SKILL.md +53 -4
- package/skills/security-review/fixtures/CWE-79-xss-negative.js +6 -0
- package/skills/security-review/fixtures/CWE-79-xss-positive.js +6 -0
- package/skills/security-review/fixtures/CWE-89-sqli-negative.py +8 -0
- package/skills/security-review/fixtures/CWE-89-sqli-positive.py +9 -0
- package/skills/seed-conventions/REFERENCE.md +40 -0
- package/skills/seed-conventions/SKILL.md +28 -1
- package/skills/session-state/SKILL.md +5 -10
- package/skills/slice-tasks/SKILL.md +3 -0
- package/skills/smoke-test/REFERENCE.md +11 -0
- package/skills/stocktake-skills/SKILL.md +8 -1
- package/skills/validate-contracts/REFERENCE.md +12 -0
- package/skills/validate-fix/SKILL.md +3 -0
- package/skills/verify-work/REFERENCE.md +17 -0
- package/skills/verify-work/SKILL.md +25 -22
- package/skills/wire-ci/REFERENCE.md +11 -0
- package/skills/write-document/REFERENCE.md +10 -0
- package/skills-lock.json +41 -31
|
@@ -105,6 +105,14 @@ For comprehensive health-checking, chain to the `smoke-test` skill:
|
|
|
105
105
|
bash scripts/run-smoke.sh "$DEPLOY_URL"
|
|
106
106
|
```
|
|
107
107
|
|
|
108
|
+
### 7. Three-independent-facts verification (e45s15)
|
|
109
|
+
|
|
110
|
+
Before declaring deploy success, verify **three independent facts** — build artifact, platform accept, live/registry reachability. See [REFERENCE.md](REFERENCE.md#three-independent-facts).
|
|
111
|
+
|
|
112
|
+
## Verify
|
|
113
|
+
|
|
114
|
+
→ verify: `command -v curl >/dev/null 2>&1 && grep -qi 'three-independent-facts' skills/deploy/SKILL.md && echo OK || echo FAIL`
|
|
115
|
+
|
|
108
116
|
---
|
|
109
117
|
|
|
110
118
|
# Deploy — Reference
|
|
@@ -51,16 +51,27 @@ Apply the **enforce-first** F.I.R.S.T rubric: Fast, Independent, Repeatable, Sel
|
|
|
51
51
|
Write ONE test that confirms ONE thing about the system:
|
|
52
52
|
|
|
53
53
|
```
|
|
54
|
-
RED: Write test for first behavior → test fails → commit: test(<scope>): ...
|
|
55
|
-
GREEN: Write minimal code to pass → test passes → commit: feat(<scope>): ...
|
|
54
|
+
RED: Write test for first behavior → test fails → commit: test(<scope>): ... (test-only; red in CI)
|
|
55
|
+
GREEN: Write minimal code to pass → test passes → commit: feat(<scope>): ... (fix commit; green)
|
|
56
56
|
REFACTOR (optional): clean up → commit: refactor(<scope>): ...
|
|
57
57
|
```
|
|
58
58
|
|
|
59
|
+
> **Two-commit red/green policy (HARD GATE — e45s08)** — Each behavior cycle requires **two separate commits**: (1) test-only commit that fails in CI (RED), then (2) implementation commit that makes it pass (GREEN). Never combine test + fix in one commit. Show `git log -2 --oneline` as evidence before proceeding to the next behavior.
|
|
60
|
+
|
|
61
|
+
> **tasks.yaml ledger (e45s06)** — After each task's `verify:` exits 0, update `eNNsYY-tasks.yaml`: set that task's `status: passing`. Story-level `status: passing` only when all tasks pass.
|
|
62
|
+
|
|
59
63
|
### 3. Incremental Loop
|
|
60
64
|
|
|
61
|
-
> **
|
|
65
|
+
> **Snapshot-before-transition (e45s34):** Before each RED → GREEN or GREEN → REFACTOR transition, create a checkpoint so a failed transition can be rolled back cleanly:
|
|
66
|
+
|
|
67
|
+
```bash
|
|
68
|
+
bash scripts/bp-yaml-snapshot.sh specs/state.yaml # if state changed this cycle
|
|
69
|
+
git stash push -m "tdd-checkpoint-$(git rev-parse --short HEAD)-red" --keep-index 2>/dev/null || true
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
After GREEN passes and is committed, drop the stash (`git stash drop` if empty). Never refactor while RED.
|
|
62
73
|
|
|
63
|
-
For each remaining behavior: RED → GREEN → REFACTOR (optional). One test at a time. Commit after every GREEN phase.
|
|
74
|
+
For each remaining behavior: RED → GREEN → REFACTOR (optional). One test at a time. **Two commits per behavior** (test-only RED, then fix GREEN). Commit after every GREEN phase.
|
|
64
75
|
|
|
65
76
|
### 4. Visual Slices (UI alternate workflow)
|
|
66
77
|
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: diagnose-stall
|
|
3
|
+
description: "Diagnose why agent orchestration stopped producing progress — silent stalls in /loop, dispatch-agents, or execute-plan. Use when work appears hung, no output for several minutes, or a subagent never returned."
|
|
4
|
+
model: haiku
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# Diagnose Stall
|
|
9
|
+
|
|
10
|
+
> **HARD GATE** — Do NOT restart work blindly. Run this diagnostic first when orchestration goes quiet without an explicit terminal state.
|
|
11
|
+
|
|
12
|
+
Explicit handler for silent stalls in long-running agent workflows (`/loop`, `dispatch-agents`, `execute-plan`, `build-epic` resume mode).
|
|
13
|
+
|
|
14
|
+
## Stall signals
|
|
15
|
+
|
|
16
|
+
| Signal | Likely cause |
|
|
17
|
+
|--------|----------------|
|
|
18
|
+
| No stdout for >5 min on a monitored loop tick | Sleep/watcher misconfigured or prompt never re-armed |
|
|
19
|
+
| Subagent dispatched but no completion message | Agent hung, blocked on approval, or scope too large |
|
|
20
|
+
| `dispatch-agents` cycle 3 reached with gaps | Circuit exhausted — needs human escalation |
|
|
21
|
+
| Verify command running >15 min | Missing timeout or waiting on external service |
|
|
22
|
+
| `handoff.next_skill` unchanged across turns | Prior skill never wrote handoff |
|
|
23
|
+
|
|
24
|
+
## Process
|
|
25
|
+
|
|
26
|
+
1. **Read state** — `specs/state.yaml`: `handoff.next_skill`, `active_flow`, `metrics.story_start`, open decisions.
|
|
27
|
+
2. **Check locks** — `bash scripts/check-stale-locks.sh` if present; read `specs/agent-locks.yaml`.
|
|
28
|
+
3. **Inspect terminals** — list background shells; note PIDs, last output timestamp, exit codes.
|
|
29
|
+
4. **Classify stall type:**
|
|
30
|
+
- **waiting_approval** — tool blocked on user consent
|
|
31
|
+
- **blocked_dependency** — prior task incomplete or red gate
|
|
32
|
+
- **agent_exhausted** — max iterations/cycles reached
|
|
33
|
+
- **misconfigured_loop** — duplicate sentinel, wrong regex, or sleeper not re-armed
|
|
34
|
+
- **external_io** — network, CI, or deploy wait without timeout
|
|
35
|
+
- **unknown** — escalate with evidence bundle
|
|
36
|
+
5. **Recommend recovery** — one action only (resume, kill PID, re-dispatch with smaller brief, escalate to user).
|
|
37
|
+
6. **Write report** — `specs/verifications/STALL-<timestamp>.md` with classification, evidence, and recommended next skill.
|
|
38
|
+
|
|
39
|
+
## Integration
|
|
40
|
+
|
|
41
|
+
| Caller | When to invoke |
|
|
42
|
+
|--------|----------------|
|
|
43
|
+
| `/loop` (Cursor) | After two consecutive ticks with no observable progress |
|
|
44
|
+
| `dispatch-agents` | When a wave exceeds expected duration with zero returns |
|
|
45
|
+
| `execute-plan` | When a step checkpoint is overdue |
|
|
46
|
+
| User | "Why did this stop?" / "Nothing is happening" |
|
|
47
|
+
|
|
48
|
+
## Verify
|
|
49
|
+
|
|
50
|
+
→ verify: `test -f specs/state.yaml && echo "OK: diagnose-stall can read session state" || echo "WARN: no state.yaml — diagnostic limited"`
|
|
51
|
+
|
|
52
|
+
## Handoff
|
|
53
|
+
|
|
54
|
+
Gate: READY → next: survey-context (if state unclear) or resume prior skill from `state.yaml`
|
|
55
|
+
Writes: `specs/verifications/STALL-*.md`
|
|
@@ -5,6 +5,13 @@ model: sonnet
|
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
|
|
8
|
+
# story: e09s04
|
|
9
|
+
# story: e45s38
|
|
10
|
+
<!-- story: e45s11 -->
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
# story: e45s30
|
|
14
|
+
|
|
8
15
|
# Dispatch Agents
|
|
9
16
|
> **HARD GATE** — **HARD GATE** — Agent work must be parallelizable and have explicit synchronization points. Do NOT dispatch work that has hidden dependencies between agents.
|
|
10
17
|
|
|
@@ -36,30 +43,57 @@ Before dispatching, verify each task pair is truly independent:
|
|
|
36
43
|
|
|
37
44
|
If any two tasks conflict, sequence them with `delegate-task` or `execute-plan` instead.
|
|
38
45
|
|
|
39
|
-
|
|
46
|
+
## Subagent depth tiers (e45s30)
|
|
40
47
|
|
|
41
|
-
|
|
48
|
+
Map `effort:` frontmatter and story `risk:` to prompt depth — do not send `minimal_decisive` agents a `full_maturity` brief.
|
|
42
49
|
|
|
43
|
-
|
|
50
|
+
| Tier | When | Brief shape | Token budget |
|
|
51
|
+
|------|------|-------------|----------------|
|
|
52
|
+
| `full_maturity` | `effort: heavy`, `risk: P0`, security-sensitive diffs | Full `task_brief` + CONVENTIONS excerpts + threat model if present | Full envelope |
|
|
53
|
+
| `standard` | `effort: standard`, `risk: P1`–`P2` | Standard `task_brief` fields below | Default |
|
|
54
|
+
| `minimal_decisive` | `effort: light`, `risk: P3`, read-only exploration | `goal` + `verify` + `in_scope` only | ≤15 lines |
|
|
44
55
|
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
56
|
+
Record `depth: <tier>` in the Agent tool description when dispatching.
|
|
57
|
+
|
|
58
|
+
### 2. Write typed task briefs (Orca message protocol)
|
|
59
|
+
|
|
60
|
+
Before writing briefs, read `specs/state.yaml` if it exists — each agent gets only the decisions relevant to its task, nothing else.
|
|
61
|
+
|
|
62
|
+
Every inter-agent message uses a **typed envelope** — no freeform prose between waves:
|
|
63
|
+
|
|
64
|
+
| `type` | When | Required fields |
|
|
65
|
+
|--------|------|-----------------|
|
|
66
|
+
| `task_brief` | Dispatch | `task_id`, `goal`, `in_scope`, `out_of_bounds`, `verify`, `prior_decisions` |
|
|
67
|
+
| `checkpoint` | Mid-wave progress | `task_id`, `status` (`running`\|`blocked`), `comment` (one line) |
|
|
68
|
+
| `result` | Agent return | `task_id`, `exit` (`pass`\|`fail`), `summary`, `verify_output` |
|
|
69
|
+
| `circuit_open` | 3 consecutive failures | `task_id`, `failures` (3), `escalate_to` (`user`) |
|
|
70
|
+
|
|
71
|
+
Example `task_brief` (each agent starts cold — brief size directly controls token cost and hallucination risk):
|
|
72
|
+
|
|
73
|
+
```yaml
|
|
74
|
+
type: task_brief
|
|
75
|
+
task_id: agent-1
|
|
76
|
+
goal: [one sentence — what success looks like]
|
|
77
|
+
in_scope: [explicit file or module list]
|
|
78
|
+
out_of_bounds: [what NOT to touch]
|
|
79
|
+
verify: [runnable command]
|
|
80
|
+
prior_decisions: [relevant entries from specs/state.yaml — omit if none]
|
|
51
81
|
```
|
|
52
82
|
|
|
83
|
+
Emit **`checkpoint`** comments when an agent is slow or blocked — one line, no stack traces. Parent reads checkpoints before spawning follow-ups.
|
|
84
|
+
|
|
53
85
|
Do not include the full conversation, full file contents, or decisions unrelated to this agent's task.
|
|
54
86
|
|
|
55
|
-
### 3.
|
|
87
|
+
### 3. Circuit breaker + iterative retrieval (max 3 cycles)
|
|
88
|
+
|
|
89
|
+
Track **consecutive failures per `task_id`**. On the **3rd consecutive `result.exit: fail`** for the same task, emit `type: circuit_open` and **stop dispatching** that task — escalate to user with the three failure summaries. Reset counter on any `pass`.
|
|
56
90
|
|
|
57
91
|
After each wave completes:
|
|
58
|
-
1. **Dispatch** — run parallel agents with
|
|
59
|
-
2. **Evaluate** — read
|
|
92
|
+
1. **Dispatch** — run parallel agents with typed `task_brief` envelopes.
|
|
93
|
+
2. **Evaluate** — read `result` messages; list gaps vs goal; honor open circuits.
|
|
60
94
|
3. **Refine** — tighten briefs or spawn follow-up agents (max **3 cycles** total).
|
|
61
95
|
|
|
62
|
-
Stop when gaps empty or cycle 3 reached — escalate to user.
|
|
96
|
+
Stop when gaps empty, circuit opens, or cycle 3 reached — escalate to user. If agents go silent without returning, invoke `diagnose-stall` before spawning another wave.
|
|
63
97
|
|
|
64
98
|
### 4. Dispatch in parallel
|
|
65
99
|
|
|
@@ -73,13 +107,13 @@ Agent 3: brief for task C
|
|
|
73
107
|
|
|
74
108
|
### 5. Collect and review results
|
|
75
109
|
|
|
76
|
-
When all agents return:
|
|
77
|
-
- Review each result independently
|
|
78
|
-
- Run all verify commands
|
|
79
|
-
- Check diffs for scope violations or CONVENTIONS.md breaches
|
|
110
|
+
When all agents return: review each result, run verify commands, check diffs for scope violations.
|
|
80
111
|
|
|
81
112
|
### 6. Integrate
|
|
82
113
|
|
|
83
|
-
Merge accepted results.
|
|
114
|
+
Merge accepted results. Resolve conflicts manually; note in summary.
|
|
115
|
+
|
|
116
|
+
Report: which tasks succeeded, which need revision, overall verify status.
|
|
84
117
|
|
|
85
|
-
|
|
118
|
+
## Verify
|
|
119
|
+
→ verify: `grep -q 'circuit_open' skills/dispatch-agents/SKILL.md && grep -q 'task_brief' skills/dispatch-agents/SKILL.md && echo OK || echo FAIL`
|
|
@@ -4,6 +4,10 @@ description: "Benchmark-gated skill evolution — consume bigpowers-benchmark re
|
|
|
4
4
|
model: opus
|
|
5
5
|
---
|
|
6
6
|
|
|
7
|
+
# story: e23s03
|
|
8
|
+
|
|
9
|
+
# story: e09s01
|
|
10
|
+
# story: e09s05
|
|
7
11
|
|
|
8
12
|
# Evolve Skill
|
|
9
13
|
|
|
@@ -32,6 +36,9 @@ model: opus
|
|
|
32
36
|
|
|
33
37
|
See [REFERENCE.md](REFERENCE.md) for ADR template.
|
|
34
38
|
|
|
39
|
+
|
|
40
|
+
<!-- story: e31s07 -->
|
|
41
|
+
|
|
35
42
|
---
|
|
36
43
|
|
|
37
44
|
# Evolve Skill — ADR snippet
|
|
@@ -38,7 +38,15 @@ TEA-inspired: if trace links rely on heuristics rather than explicit tags, confi
|
|
|
38
38
|
5. Apply oracle confidence downgrade based on the heuristic link ratio from the matrix's `oracle_stats`.
|
|
39
39
|
6. **Drift check (e39s03):** If `specs/drift-report.json` exists and has suspect links, mark verdict as CONCERNS with note: "Drift detected — some implementing files are newer than their specs. Run scripts/check-spec-drift.sh for details."
|
|
40
40
|
7. Output verdict + rationale to stdout.
|
|
41
|
-
|
|
41
|
+
8. **Adversarial refute check (e45s32):** Before emitting PASS, attempt to **refute** the verdict — list at least one concrete traceability gap that would block merge if it were real. If the gap is real, downgrade the verdict. Rubber-stamping is prohibited; every PASS must survive one refutation attempt.
|
|
42
|
+
9. **Completeness critic (e45s05)** — Run adversarial gap-finding:
|
|
43
|
+
|
|
44
|
+
```bash
|
|
45
|
+
bash scripts/lib/completeness-critic.sh
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
Classify output as **BLOCKER / WARNING / FILLED**. **BLOCKER overrides any PASS verdict → FAIL.** Append critic summary to rationale.
|
|
49
|
+
10. Update `specs/execution-status.yaml` with gate-trace result.
|
|
42
50
|
|
|
43
51
|
## Verdict Semantics
|
|
44
52
|
|
|
@@ -48,6 +48,20 @@ Full JSON examples, merge rules, Antigravity deny-list entries, and test command
|
|
|
48
48
|
|
|
49
49
|
# Git guardrails — reference
|
|
50
50
|
|
|
51
|
+
## Navigation
|
|
52
|
+
|
|
53
|
+
| Lines | Section |
|
|
54
|
+
|-------|---------|
|
|
55
|
+
| 1 | Title |
|
|
56
|
+
| 3–14 | Navigation |
|
|
57
|
+
| 16–24 | Secret patterns |
|
|
58
|
+
| 26–44 | Copy layout |
|
|
59
|
+
| 46–72 | Claude Code |
|
|
60
|
+
| 74–92 | Cursor and Cursor CLI |
|
|
61
|
+
| 94–120 | Gemini CLI |
|
|
62
|
+
| 122–135 | Google Antigravity |
|
|
63
|
+
| 137–178 | Verify (local tests) |
|
|
64
|
+
|
|
51
65
|
## Secret patterns (audit + pre-commit)
|
|
52
66
|
|
|
53
67
|
Agents must not commit files containing:
|
|
@@ -4,6 +4,12 @@ description: "Detect GSD, spec-kit, or BMAD spec artifacts and transform them in
|
|
|
4
4
|
model: sonnet
|
|
5
5
|
---
|
|
6
6
|
|
|
7
|
+
# story: e25s01
|
|
8
|
+
# story: e25s02
|
|
9
|
+
# story: e25s03
|
|
10
|
+
# story: e25s04
|
|
11
|
+
# story: e25s05
|
|
12
|
+
# story: e25s06
|
|
7
13
|
|
|
8
14
|
# Migrate Spec
|
|
9
15
|
|
|
@@ -240,6 +246,18 @@ These GSD artifacts are not migrated — they are execution records, not plannin
|
|
|
240
246
|
|
|
241
247
|
# Migrate Spec — Reference
|
|
242
248
|
|
|
249
|
+
## Navigation
|
|
250
|
+
|
|
251
|
+
| Lines | Section |
|
|
252
|
+
|-------|---------|
|
|
253
|
+
| 1 | Title |
|
|
254
|
+
| 3–22 | Navigation |
|
|
255
|
+
| 24–62 | spec-kit → bigpowers Mapping |
|
|
256
|
+
| 64–130 | BMAD → bigpowers Mapping |
|
|
257
|
+
| 132–154 | Learnings to Adopt |
|
|
258
|
+
| 156–350 | Output Formats + state.yaml template |
|
|
259
|
+
| 352–620 | Reference blocks 1–2 + extended mappings |
|
|
260
|
+
|
|
243
261
|
# migrate-spec Reference — spec-kit, BMAD, Learnings
|
|
244
262
|
|
|
245
263
|
Transformation rules for spec-kit and BMAD projects, plus learnings to adopt and output formats.
|
|
@@ -5,6 +5,8 @@ model: opus
|
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
|
|
8
|
+
# story: e45s29
|
|
9
|
+
|
|
8
10
|
# Plan Work
|
|
9
11
|
|
|
10
12
|
> **Spine position:** Step 3 — scope-work → slice-tasks → plan-work.
|
|
@@ -46,14 +48,45 @@ If this plan touches an existing module, run `assess-impact` first to understand
|
|
|
46
48
|
|
|
47
49
|
3. **Write capsule story spec + tasks** — Output two files inside the active epic capsule. See [REFERENCE.md](REFERENCE.md) for file formats and the plan-template. Each task MUST include a `risk:` field (`P0` | `P1` | `P2` | `P3`) based on BCP + story type heuristics (see REFERENCE.md). If a test plan artifact (`specs/tech-architecture/eNN-TEST_PLAN_LATEST.md`) exists, read it and inherit its P0/P1 risk classifications and scenario IDs (`SC-eNNsYY-P0-NN`). Each task optionally includes a `security:` field (`none` / `low` / `medium` / `high`) sourced from the epic's `specs/security/epics/<id>/THREAT_MODEL.md`. Tasks with `security: medium` or `security: high` MUST include "no new security findings in affected paths" in their verify steps.
|
|
48
50
|
|
|
51
|
+
**Requirement delta tags (e45s29):** When a story modifies existing behavior, the story spec § Requirements MUST use OpenSpec-style delta tags with mandatory before/after content:
|
|
52
|
+
|
|
53
|
+
| Tag | When | Required content |
|
|
54
|
+
|-----|------|------------------|
|
|
55
|
+
| `ADDED` | New requirement | Full requirement text |
|
|
56
|
+
| `MODIFIED` | Changed behavior | **Before:** prior behavior · **After:** new behavior |
|
|
57
|
+
| `REMOVED` | Retired requirement | **Before:** what existed · **After:** (removed) + rationale |
|
|
58
|
+
| `RENAMED` | ID or title change only | **Before:** old ID/title · **After:** new ID/title |
|
|
59
|
+
|
|
60
|
+
Net-new stories (greenfield) use `ADDED` only. `MODIFIED`/`REMOVED`/`RENAMED` without before/after blocks fail the plan-work gate.
|
|
61
|
+
|
|
49
62
|
4. **Verify step format** — Every step MUST follow: `N. <What to do> → verify: <runnable command>`. See [REFERENCE.md](REFERENCE.md) for good/bad examples.
|
|
50
63
|
|
|
64
|
+
4a. **Cross-artifact consistency pass (HARD GATE — e45s04)** — Before handoff, run:
|
|
65
|
+
|
|
66
|
+
```bash
|
|
67
|
+
bash scripts/lib/plan-consistency-check.sh specs/epics/<capsule>/
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
Print CRITICAL / HIGH / MED findings. **CRITICAL or HIGH blocks code generation** — fix capsule artifacts first. MED requires explicit user acknowledgment.
|
|
71
|
+
|
|
72
|
+
4b. **tasks.yaml failing ledger (e45s06)** — Every new task entry starts with `status: failing`. Only flip to `status: passing` after its `verify:` command exits 0 during `develop-tdd` or `verify-work`. Never pre-mark passing at plan time.
|
|
73
|
+
|
|
51
74
|
5. **Review with user** — Confirm step order, granularity, and that verify commands are runnable in this project.
|
|
52
75
|
|
|
76
|
+
## Lifecycle Gates (e45s09)
|
|
77
|
+
|
|
78
|
+
| Gate | When | Pass condition |
|
|
79
|
+
|------|------|----------------|
|
|
80
|
+
| **Pre-Implementation** | Before `kickoff-branch` / first RED commit | Root-cause stated for bugs; `assess-impact` done for module changes; plan-consistency-check PASS |
|
|
81
|
+
| **Validation** | Story marked done | All tasks `status: passing`; verify evidence in `specs/verifications/` |
|
|
82
|
+
| **Reopen-don't-refile** | Regression on shipped story | Reopen existing story/bug — do not create duplicate capsule entries |
|
|
83
|
+
|
|
53
84
|
After writing capsule tasks, suggest `kickoff-branch` (if not already on a feature branch) then `build-epic`, `execute-plan`, or `develop-tdd`.
|
|
54
85
|
|
|
55
86
|
## Verify
|
|
56
87
|
|
|
88
|
+
→ verify: `test -f scripts/lib/plan-consistency-check.sh && bash scripts/lib/plan-consistency-check.sh specs/epics/e45-quality-core/ 2>&1 | head -5`
|
|
89
|
+
|
|
57
90
|
|
|
58
91
|
|
|
59
92
|
## Handoff
|
|
@@ -65,6 +98,17 @@ Writes: state.yaml handoff.next_skill = kickoff-branch
|
|
|
65
98
|
|
|
66
99
|
# Plan Work — Reference
|
|
67
100
|
|
|
101
|
+
## Navigation
|
|
102
|
+
|
|
103
|
+
| Lines | Section |
|
|
104
|
+
|-------|---------|
|
|
105
|
+
| 1 | Title |
|
|
106
|
+
| 3–14 | Navigation |
|
|
107
|
+
| 16–38 | Output file formats |
|
|
108
|
+
| 40–71 | Plan template |
|
|
109
|
+
| 73–91 | Verify step format rules |
|
|
110
|
+
| 93–131 | Sub-operations (risk, define-success, zoom-out, slopcheck, delta tags) |
|
|
111
|
+
|
|
68
112
|
## Output file formats
|
|
69
113
|
|
|
70
114
|
### Story spec: `specs/epics/<capsule>/eNNsYY-<slug>.md`
|
|
@@ -76,14 +120,14 @@ Populated countable-story-format with all 20 sections. Minimum maturity: 3 (Coun
|
|
|
76
120
|
```yaml
|
|
77
121
|
story_id: e01s01
|
|
78
122
|
title: Login
|
|
79
|
-
status:
|
|
123
|
+
status: failing
|
|
80
124
|
bcps: 3
|
|
81
125
|
tasks:
|
|
82
126
|
- id: 1
|
|
83
127
|
description: "Add login form component tests"
|
|
84
128
|
verify: "npm test -- login-form.test.tsx"
|
|
85
129
|
risk: P1
|
|
86
|
-
status:
|
|
130
|
+
status: failing # flip to passing only after verify exits 0 (e45s06)
|
|
87
131
|
```
|
|
88
132
|
|
|
89
133
|
Update `specs/epics/<capsule>/epic.yaml` manifest to list the story and its BCPs. Run `bash scripts/sync-status-from-epics.sh` after structural changes.
|
|
@@ -154,6 +198,22 @@ Every task and story MUST be assigned a `risk:` level (P0, P1, P2, P3). When `sp
|
|
|
154
198
|
|
|
155
199
|
`verify-work` scales its UAT depth based on this field.
|
|
156
200
|
|
|
201
|
+
### Requirement delta tags (e45s29)
|
|
202
|
+
|
|
203
|
+
When modifying existing behavior in story spec § Requirements:
|
|
204
|
+
|
|
205
|
+
```markdown
|
|
206
|
+
#### MODIFIED: User can reset password via email link
|
|
207
|
+
**Before:** Password reset required admin approval.
|
|
208
|
+
**After:** Self-service reset via signed email link (expires 1h).
|
|
209
|
+
|
|
210
|
+
#### REMOVED: Legacy OAuth1 login
|
|
211
|
+
**Before:** OAuth1 provider supported for enterprise SSO.
|
|
212
|
+
**After:** (removed) — provider deprecated; OAuth2 only.
|
|
213
|
+
```
|
|
214
|
+
|
|
215
|
+
Tags: `ADDED`, `MODIFIED`, `REMOVED`, `RENAMED`. `MODIFIED`/`REMOVED`/`RENAMED` without before/after → plan-work gate FAIL.
|
|
216
|
+
|
|
157
217
|
### Define Success
|
|
158
218
|
|
|
159
219
|
Before planning, convert task statements into observable "step → verify: <cmd>" pairs:
|
|
@@ -79,6 +79,17 @@ See [REFERENCE.md](REFERENCE.md)
|
|
|
79
79
|
|
|
80
80
|
# Publish Package — Reference
|
|
81
81
|
|
|
82
|
+
## Navigation
|
|
83
|
+
|
|
84
|
+
| Lines | Section |
|
|
85
|
+
|-------|---------|
|
|
86
|
+
| 1 | Title |
|
|
87
|
+
| 3–18 | Navigation |
|
|
88
|
+
| 20–28 | Options |
|
|
89
|
+
| 30–60 | Examples |
|
|
90
|
+
| 62–72 | Integration with release-branch |
|
|
91
|
+
| 74–252 | Reference blocks 1–8 |
|
|
92
|
+
|
|
82
93
|
## Options
|
|
83
94
|
|
|
84
95
|
| Flag | Description |
|
|
@@ -5,6 +5,13 @@ model: haiku
|
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
|
|
8
|
+
<!-- story: e38s07 -->
|
|
9
|
+
<!-- story: e45s15 -->
|
|
10
|
+
<!-- story: e45s32 -->
|
|
11
|
+
<!-- story: e45s39 -->
|
|
12
|
+
<!-- story: e20s02 -->
|
|
13
|
+
|
|
14
|
+
|
|
8
15
|
# Release Branch
|
|
9
16
|
|
|
10
17
|
> **HARD GATE** — Do NOT merge or release if tests fail or if coverage gates are not met. If the branch is red, return to `develop-tdd` to fix regressions or add missing tests before proceeding.
|
|
@@ -54,6 +61,8 @@ If REVIEW.md is missing or stale → run `security-review` inline. Findings bloc
|
|
|
54
61
|
|
|
55
62
|
Run `gate-trace` before merge. FAIL blocks merge; CONCERNS requires explicit override in `specs/state.yaml` (`traceability_override: CONCERNS accepted, reason: <explanation>`). WAIVED if no matrix available.
|
|
56
63
|
|
|
64
|
+
> **Adversarial refute framing (e45s32):** The final pre-merge check is **refute, not rubber-stamp**. Before declaring ready, actively try to disprove traceability completeness — missing story tags, absent verify evidence, stale security review. Only proceed when refutation fails.
|
|
65
|
+
|
|
57
66
|
### 3. Diff review
|
|
58
67
|
|
|
59
68
|
- [ ] All commits intentional, no secrets, CONVENTIONS.md compliance
|
|
@@ -74,9 +83,26 @@ bash scripts/land-branch.sh <task-slug> "feat(scope): description"
|
|
|
74
83
|
|
|
75
84
|
### 6. Create PR (team-pr only)
|
|
76
85
|
|
|
77
|
-
Create the pull request
|
|
86
|
+
Create the pull request with a **literal provenance marker** in the body so agent-generated PRs are identifiable and do not rot silently:
|
|
87
|
+
|
|
88
|
+
```markdown
|
|
89
|
+
<!-- bigpowers-provenance: agent-generated -->
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
Place the marker on its own line immediately after the `## Summary` heading. Then merge via `gh`:
|
|
78
93
|
|
|
79
94
|
```bash
|
|
95
|
+
gh pr create --title "..." --body "$(cat <<'EOF'
|
|
96
|
+
## Summary
|
|
97
|
+
<!-- bigpowers-provenance: agent-generated -->
|
|
98
|
+
|
|
99
|
+
- ...
|
|
100
|
+
|
|
101
|
+
## Test plan
|
|
102
|
+
- [ ] ...
|
|
103
|
+
|
|
104
|
+
EOF
|
|
105
|
+
)"
|
|
80
106
|
gh pr merge --squash --delete-branch
|
|
81
107
|
```
|
|
82
108
|
|
|
@@ -92,55 +118,18 @@ mv specs/epics/eNN-slug specs/epics/archive/
|
|
|
92
118
|
|
|
93
119
|
### 7b. CI verification & agent lock release (e39s02)
|
|
94
120
|
|
|
95
|
-
> **HARD GATE** — Do NOT declare success until CI completes.
|
|
96
|
-
|
|
97
|
-
After push, run CI polling:
|
|
121
|
+
> **HARD GATE** — Do NOT declare success until CI completes. **Three-independent-facts** (e45s15): commit landed, workflow green, registry visible — see [REFERENCE.md](REFERENCE.md#three-independent-facts-release).
|
|
98
122
|
|
|
99
123
|
```bash
|
|
100
124
|
bash scripts/wait-for-ci.sh --timeout 600 --interval 30
|
|
101
125
|
```
|
|
102
126
|
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
```bash
|
|
106
|
-
LOCK="specs/agent-locks.yaml"; STORY="<story-id>"
|
|
107
|
-
[ -f "$LOCK" ] && python3 -c "
|
|
108
|
-
import yaml
|
|
109
|
-
d=yaml.safe_load(open('$LOCK'))
|
|
110
|
-
if d:d['locks']=[l for l in d['locks'] if l.get('story_id')!='$STORY']
|
|
111
|
-
yaml.dump(d,open('$LOCK','w'),default_flow_style=False)
|
|
112
|
-
print(f'LOCK RELEASED: $STORY')
|
|
113
|
-
"||echo "No lock for $STORY — idempotent"
|
|
114
|
-
```
|
|
115
|
-
|
|
116
|
-
- [ ] CI workflow passes after push (wait-for-ci.sh exit 0)
|
|
117
|
-
- [ ] `release.ci_verified: true` documented in state.yaml
|
|
118
|
-
- On failure: `handoff.next_skill = fix-bug` with CI failure URL
|
|
119
|
-
|
|
120
|
-
### 8. Clean up worktree
|
|
121
|
-
|
|
122
|
-
```bash
|
|
123
|
-
git worktree prune
|
|
124
|
-
git worktree remove ../<branch-name> 2>/dev/null || true
|
|
125
|
-
git branch -d <branch-name>
|
|
126
|
-
```
|
|
127
|
-
|
|
128
|
-
### 8a. Cycle-time recording
|
|
129
|
-
|
|
130
|
-
After landing, record delivery metrics with the git-derived, additive script:
|
|
131
|
-
|
|
132
|
-
```bash
|
|
133
|
-
bash scripts/record-cycle-time.sh append \
|
|
134
|
-
--story <story_id> --bcps <bcps> \
|
|
135
|
-
--range "$(git merge-base main HEAD)..HEAD" \
|
|
136
|
-
--file specs/metrics/cycle-times.yaml
|
|
137
|
-
```
|
|
127
|
+
- [ ] CI passes; `release.ci_verified: true` in state.yaml
|
|
128
|
+
- On failure: `handoff.next_skill = fix-bug`
|
|
138
129
|
|
|
139
|
-
###
|
|
130
|
+
### 8. Clean up & return
|
|
140
131
|
|
|
141
|
-
|
|
142
|
-
git checkout main && git status && pwd
|
|
143
|
-
```
|
|
132
|
+
Worktree prune, branch delete, `git checkout main`. Cycle-time: see [REFERENCE.md](REFERENCE.md#cycle-time).
|
|
144
133
|
|
|
145
134
|
Report: "Branch released."
|
|
146
135
|
|
|
@@ -152,6 +141,20 @@ Report: "Branch released."
|
|
|
152
141
|
|
|
153
142
|
# Release Branch — Reference
|
|
154
143
|
|
|
144
|
+
## Navigation
|
|
145
|
+
|
|
146
|
+
| Lines | Section |
|
|
147
|
+
|-------|---------|
|
|
148
|
+
| 1–3 | Title |
|
|
149
|
+
| 5–16 | Navigation |
|
|
150
|
+
| 18–41 | PR body template |
|
|
151
|
+
| 43–54 | Worktree cleanup |
|
|
152
|
+
| 56–96 | Cycle-time recording |
|
|
153
|
+
| 98–119 | CI verification |
|
|
154
|
+
| 121–126 | Solo-local fallback |
|
|
155
|
+
| 128–134 | Handoff |
|
|
156
|
+
| 136–155 | Reference block 1 (manual squash) |
|
|
157
|
+
|
|
155
158
|
# Release Branch — Reference
|
|
156
159
|
|
|
157
160
|
## PR body template (team-pr mode)
|