bigpowers 2.34.1 → 2.35.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.pi/package.json +2 -2
- package/.pi/prompts/deploy.md +53 -28
- package/.pi/prompts/develop-tdd.md +5 -80
- package/.pi/prompts/migrate-spec.md +273 -197
- package/.pi/prompts/publish-package.md +125 -67
- package/.pi/prompts/release-branch.md +85 -69
- package/.pi/prompts/security-review.md +323 -0
- package/.pi/prompts/smoke-test.md +98 -58
- package/.pi/prompts/using-bigpowers.md +2 -2
- package/.pi/prompts/validate-contracts.md +169 -54
- package/.pi/prompts/wire-ci.md +147 -89
- package/.pi/skills/deploy/SKILL.md +53 -28
- package/.pi/skills/develop-tdd/SKILL.md +5 -80
- package/.pi/skills/migrate-spec/SKILL.md +273 -197
- package/.pi/skills/publish-package/SKILL.md +125 -67
- package/.pi/skills/release-branch/SKILL.md +85 -69
- package/.pi/skills/security-review/SKILL.md +324 -0
- package/.pi/skills/smoke-test/SKILL.md +98 -58
- package/.pi/skills/using-bigpowers/SKILL.md +2 -2
- package/.pi/skills/validate-contracts/SKILL.md +169 -54
- package/.pi/skills/wire-ci/SKILL.md +147 -89
- package/CHANGELOG.md +14 -0
- package/README.md +4 -4
- package/SKILL-INDEX.md +2 -2
- package/deploy/REFERENCE.md +82 -0
- package/deploy/SKILL.md +3 -63
- package/develop-tdd/SKILL.md +5 -80
- package/migrate-spec/REFERENCE.md +268 -0
- package/migrate-spec/SKILL.md +5 -199
- package/package.json +2 -2
- package/publish-package/REFERENCE.md +239 -0
- package/publish-package/SKILL.md +8 -192
- package/release-branch/REFERENCE.md +83 -0
- package/release-branch/SKILL.md +2 -69
- package/scripts/generate-reference-tables.sh +1 -0
- package/scripts/sync-skills.sh +4 -1
- package/security-review/REFERENCE-confidence-rubric.md +85 -0
- package/security-review/REFERENCE-false-positives.md +68 -0
- package/security-review/REFERENCE-vuln-categories.md +103 -0
- package/security-review/SKILL.md +63 -0
- package/skills-lock.json +14 -9
- package/smoke-test/REFERENCE.md +162 -0
- package/smoke-test/SKILL.md +5 -130
- package/using-bigpowers/SKILL.md +2 -2
- package/validate-contracts/REFERENCE.md +183 -0
- package/validate-contracts/SKILL.md +6 -77
- package/wire-ci/REFERENCE.md +257 -0
- package/wire-ci/SKILL.md +8 -210
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
# Deploy — Reference
|
|
2
|
+
|
|
3
|
+
## Configuration
|
|
4
|
+
|
|
5
|
+
| Variable | Default | Description |
|
|
6
|
+
|----------|---------|-------------|
|
|
7
|
+
| `ARTIFACT_DIR` | `dist` | Build output directory |
|
|
8
|
+
| `DEPLOY_URL` | *(required)* | Live URL for smoke test |
|
|
9
|
+
| `DEPLOY_TIMEOUT` | `300` | Max wait for deploy completion (seconds) |
|
|
10
|
+
| `DEPLOY_POLL_INTERVAL` | `30` | Polling interval (seconds) |
|
|
11
|
+
| `RETRY_MAX` | `3` | Max deploy retry attempts |
|
|
12
|
+
| `BUILD_COMMAND` | *(auto-detect)* | Override build command |
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
## Verification
|
|
18
|
+
|
|
19
|
+
→ verify: `test -f deploy/SKILL.md && grep -q 'name: deploy' deploy/SKILL.md && echo OK`
|
|
20
|
+
→ verify: `grep -qi 'build\|artifact\|deploy\|smoke' deploy/SKILL.md && echo OK`
|
|
21
|
+
→ verify: `grep -ci 'package.json\|Cargo.toml\|Makefile\|manifest' deploy/SKILL.md | awk '{if($1>=1) print "OK"; else print "FAIL"}'`
|
|
22
|
+
→ verify: `grep -ci 'timeout\|poll\|status\|retry\|backoff' deploy/SKILL.md | awk '{if($1>=2) print "OK"; else print "FAIL"}'`
|
|
23
|
+
→ verify: `grep -q 'curl.*DEPLOY_URL\|smoke\|health' deploy/SKILL.md && echo OK`
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
## Reference block 1
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
DEPLOY_TIMEOUT="${DEPLOY_TIMEOUT:-300}" # seconds (default 5 minutes)
|
|
31
|
+
DEPLOY_POLL_INTERVAL="${DEPLOY_POLL_INTERVAL:-30}" # seconds
|
|
32
|
+
|
|
33
|
+
start_time=$(date +%s)
|
|
34
|
+
while true; do
|
|
35
|
+
elapsed=$(( $(date +%s) - start_time ))
|
|
36
|
+
if [ "$elapsed" -ge "$DEPLOY_TIMEOUT" ]; then
|
|
37
|
+
echo "FAIL: deploy status polling timed out after ${DEPLOY_TIMEOUT}s"
|
|
38
|
+
exit 1
|
|
39
|
+
fi
|
|
40
|
+
|
|
41
|
+
status=$(get_deploy_status) # platform-specific status check
|
|
42
|
+
if [ "$status" = "ready" ] || [ "$status" = "done" ]; then
|
|
43
|
+
echo "Deploy completed in ${elapsed}s"
|
|
44
|
+
break
|
|
45
|
+
fi
|
|
46
|
+
|
|
47
|
+
sleep "$DEPLOY_POLL_INTERVAL"
|
|
48
|
+
done
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
---
|
|
52
|
+
|
|
53
|
+
## Reference block 2
|
|
54
|
+
|
|
55
|
+
```bash
|
|
56
|
+
RETRY_MAX="${RETRY_MAX:-3}"
|
|
57
|
+
base_delay=2
|
|
58
|
+
for attempt in $(seq 1 "$RETRY_MAX"); do
|
|
59
|
+
if deploy_command; then
|
|
60
|
+
break
|
|
61
|
+
fi
|
|
62
|
+
if [ "$attempt" -eq "$RETRY_MAX" ]; then
|
|
63
|
+
echo "FAIL: deploy failed after ${RETRY_MAX} attempts"
|
|
64
|
+
exit 1
|
|
65
|
+
fi
|
|
66
|
+
sleep $(( base_delay * 2 ** (attempt - 1) ))
|
|
67
|
+
done
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
---
|
|
71
|
+
|
|
72
|
+
## Reference block 3
|
|
73
|
+
|
|
74
|
+
```bash
|
|
75
|
+
DEPLOY_URL="${DEPLOY_URL:?DEPLOY_URL must be set}"
|
|
76
|
+
if curl -sSf "$DEPLOY_URL" > /dev/null 2>&1; then
|
|
77
|
+
echo "OK: $DEPLOY_URL responds with HTTP 200"
|
|
78
|
+
else
|
|
79
|
+
echo "FAIL: $DEPLOY_URL is not responding with HTTP 200"
|
|
80
|
+
exit 1
|
|
81
|
+
fi
|
|
82
|
+
```
|
package/deploy/SKILL.md
CHANGED
|
@@ -87,56 +87,15 @@ exit 1
|
|
|
87
87
|
|
|
88
88
|
After invoking the deploy command, poll for completion:
|
|
89
89
|
|
|
90
|
-
|
|
91
|
-
DEPLOY_TIMEOUT="${DEPLOY_TIMEOUT:-300}" # seconds (default 5 minutes)
|
|
92
|
-
DEPLOY_POLL_INTERVAL="${DEPLOY_POLL_INTERVAL:-30}" # seconds
|
|
93
|
-
|
|
94
|
-
start_time=$(date +%s)
|
|
95
|
-
while true; do
|
|
96
|
-
elapsed=$(( $(date +%s) - start_time ))
|
|
97
|
-
if [ "$elapsed" -ge "$DEPLOY_TIMEOUT" ]; then
|
|
98
|
-
echo "FAIL: deploy status polling timed out after ${DEPLOY_TIMEOUT}s"
|
|
99
|
-
exit 1
|
|
100
|
-
fi
|
|
101
|
-
|
|
102
|
-
status=$(get_deploy_status) # platform-specific status check
|
|
103
|
-
if [ "$status" = "ready" ] || [ "$status" = "done" ]; then
|
|
104
|
-
echo "Deploy completed in ${elapsed}s"
|
|
105
|
-
break
|
|
106
|
-
fi
|
|
107
|
-
|
|
108
|
-
sleep "$DEPLOY_POLL_INTERVAL"
|
|
109
|
-
done
|
|
110
|
-
```
|
|
90
|
+
See [REFERENCE.md](REFERENCE.md)
|
|
111
91
|
|
|
112
92
|
Use exponential backoff for retries on transient failures:
|
|
113
93
|
|
|
114
|
-
|
|
115
|
-
RETRY_MAX="${RETRY_MAX:-3}"
|
|
116
|
-
base_delay=2
|
|
117
|
-
for attempt in $(seq 1 "$RETRY_MAX"); do
|
|
118
|
-
if deploy_command; then
|
|
119
|
-
break
|
|
120
|
-
fi
|
|
121
|
-
if [ "$attempt" -eq "$RETRY_MAX" ]; then
|
|
122
|
-
echo "FAIL: deploy failed after ${RETRY_MAX} attempts"
|
|
123
|
-
exit 1
|
|
124
|
-
fi
|
|
125
|
-
sleep $(( base_delay * 2 ** (attempt - 1) ))
|
|
126
|
-
done
|
|
127
|
-
```
|
|
94
|
+
See [REFERENCE.md](REFERENCE.md)
|
|
128
95
|
|
|
129
96
|
### 6. Baseline smoke test
|
|
130
97
|
|
|
131
|
-
|
|
132
|
-
DEPLOY_URL="${DEPLOY_URL:?DEPLOY_URL must be set}"
|
|
133
|
-
if curl -sSf "$DEPLOY_URL" > /dev/null 2>&1; then
|
|
134
|
-
echo "OK: $DEPLOY_URL responds with HTTP 200"
|
|
135
|
-
else
|
|
136
|
-
echo "FAIL: $DEPLOY_URL is not responding with HTTP 200"
|
|
137
|
-
exit 1
|
|
138
|
-
fi
|
|
139
|
-
```
|
|
98
|
+
See [REFERENCE.md](REFERENCE.md)
|
|
140
99
|
|
|
141
100
|
For comprehensive health-checking, chain to the `smoke-test` skill:
|
|
142
101
|
|
|
@@ -144,22 +103,3 @@ For comprehensive health-checking, chain to the `smoke-test` skill:
|
|
|
144
103
|
# After deploy success
|
|
145
104
|
bash scripts/run-smoke.sh "$DEPLOY_URL"
|
|
146
105
|
```
|
|
147
|
-
|
|
148
|
-
## Configuration
|
|
149
|
-
|
|
150
|
-
| Variable | Default | Description |
|
|
151
|
-
|----------|---------|-------------|
|
|
152
|
-
| `ARTIFACT_DIR` | `dist` | Build output directory |
|
|
153
|
-
| `DEPLOY_URL` | *(required)* | Live URL for smoke test |
|
|
154
|
-
| `DEPLOY_TIMEOUT` | `300` | Max wait for deploy completion (seconds) |
|
|
155
|
-
| `DEPLOY_POLL_INTERVAL` | `30` | Polling interval (seconds) |
|
|
156
|
-
| `RETRY_MAX` | `3` | Max deploy retry attempts |
|
|
157
|
-
| `BUILD_COMMAND` | *(auto-detect)* | Override build command |
|
|
158
|
-
|
|
159
|
-
## Verification
|
|
160
|
-
|
|
161
|
-
→ verify: `test -f deploy/SKILL.md && grep -q 'name: deploy' deploy/SKILL.md && echo OK`
|
|
162
|
-
→ verify: `grep -qi 'build\|artifact\|deploy\|smoke' deploy/SKILL.md && echo OK`
|
|
163
|
-
→ verify: `grep -ci 'package.json\|Cargo.toml\|Makefile\|manifest' deploy/SKILL.md | awk '{if($1>=1) print "OK"; else print "FAIL"}'`
|
|
164
|
-
→ verify: `grep -ci 'timeout\|poll\|status\|retry\|backoff' deploy/SKILL.md | awk '{if($1>=2) print "OK"; else print "FAIL"}'`
|
|
165
|
-
→ verify: `grep -q 'curl.*DEPLOY_URL\|smoke\|health' deploy/SKILL.md && echo OK`
|
package/develop-tdd/SKILL.md
CHANGED
|
@@ -70,70 +70,15 @@ After all tests pass: extract duplication, deepen modules, apply SOLID principle
|
|
|
70
70
|
|
|
71
71
|
After every behavior cycle, run the verify command from the active epic task. Show evidence before declaring the step done.
|
|
72
72
|
|
|
73
|
-
### 6a. CI dry-run sub-step (when modifying workflows)
|
|
74
|
-
|
|
75
|
-
If this cycle modified files in `.github/workflows/`, run a CI dry-run before pushing:
|
|
76
|
-
|
|
77
|
-
```bash
|
|
78
|
-
# 1. Check for workflow file changes
|
|
79
|
-
CHANGED_WORKFLOWS=$(git diff --name-only HEAD | grep '\.github/workflows/' || true)
|
|
80
|
-
if [ -n "$CHANGED_WORKFLOWS" ]; then
|
|
81
|
-
echo "==> CI dry-run: workflow files changed"
|
|
82
|
-
echo " $CHANGED_WORKFLOWS"
|
|
83
|
-
|
|
84
|
-
# 2. Validate YAML syntax
|
|
85
|
-
if command -v yamllint &>/dev/null; then
|
|
86
|
-
for f in $CHANGED_WORKFLOWS; do
|
|
87
|
-
yamllint "$f" && echo " OK: $f passes YAML lint" || echo " WARN: $f has YAML issues"
|
|
88
|
-
done
|
|
89
|
-
else
|
|
90
|
-
# Fallback: Python YAML parse
|
|
91
|
-
for f in $CHANGED_WORKFLOWS; do
|
|
92
|
-
python3 -c "import yaml; yaml.safe_load(open('$f'))" 2>/dev/null && \
|
|
93
|
-
echo " OK: $f YAML syntax valid" || \
|
|
94
|
-
echo " FAIL: $f has YAML syntax errors"
|
|
95
|
-
done
|
|
96
|
-
fi
|
|
97
|
-
|
|
98
|
-
# 3. Run actionlint if available
|
|
99
|
-
if command -v actionlint &>/dev/null; then
|
|
100
|
-
for f in $CHANGED_WORKFLOWS; do
|
|
101
|
-
actionlint "$f" && echo " OK: $f passes actionlint" || echo " WARN: $f has actionlint issues"
|
|
102
|
-
done
|
|
103
|
-
fi
|
|
104
|
-
|
|
105
|
-
# 4. Check common pitfalls
|
|
106
|
-
for f in $CHANGED_WORKFLOWS; do
|
|
107
|
-
# Missing permissions block
|
|
108
|
-
if ! grep -q 'permissions:' "$f"; then
|
|
109
|
-
echo " WARNING: $f missing permissions block — add one for security"
|
|
110
|
-
fi
|
|
111
|
-
# npm publish without NPM_TOKEN
|
|
112
|
-
if grep -q 'npm publish\|npx semantic-release' "$f" && ! grep -q 'NPM_TOKEN' "$f"; then
|
|
113
|
-
echo " WARNING: $f has npm publish/semantic-release but no NPM_TOKEN in secrets"
|
|
114
|
-
fi
|
|
115
|
-
# Hardcoded Node versions
|
|
116
|
-
if grep -q 'node-version: [0-9]' "$f"; then
|
|
117
|
-
echo " NOTE: $f has hardcoded Node version — consider node-version-file: .nvmrc"
|
|
118
|
-
fi
|
|
119
|
-
done
|
|
120
|
-
|
|
121
|
-
# 5. Suggest local dry-run
|
|
122
|
-
if command -v act &>/dev/null; then
|
|
123
|
-
echo " SUGGESTION: Run 'act push --dry-run' to test workflows locally"
|
|
124
|
-
fi
|
|
125
|
-
fi
|
|
126
|
-
```
|
|
127
|
-
|
|
128
|
-
Checklist:
|
|
129
|
-
- [ ] YAML syntax validated for all changed workflow files
|
|
130
|
-
- [ ] No missing permissions, secrets, or hardcoded versions flagged
|
|
131
|
-
- [ ] Local dry-run suggested if `act` is available
|
|
132
|
-
|
|
133
73
|
### 7. Manual Verification Handover
|
|
134
74
|
|
|
135
75
|
Once all tests pass: locate the Verification Script in the active epic capsule, present it to the user step-by-step, and wait for confirmation of behavioral correctness.
|
|
136
76
|
|
|
77
|
+
|
|
78
|
+
### 6a. CI dry-run sub-step
|
|
79
|
+
|
|
80
|
+
If this cycle modified files in `.github/workflows/`, run the CI dry-run procedure documented in [REFERENCE.md](REFERENCE.md#ci-dry-run).
|
|
81
|
+
|
|
137
82
|
## Checklist Per Cycle
|
|
138
83
|
|
|
139
84
|
```
|
|
@@ -149,26 +94,6 @@ Once all tests pass: locate the Verification Script in the active epic capsule,
|
|
|
149
94
|
[ ] verify: command passes
|
|
150
95
|
```
|
|
151
96
|
|
|
152
|
-
## --config mode
|
|
153
|
-
|
|
154
|
-
For pure-config tasks (update package.json, edit YAML, tweak manifest) where there is no test infrastructure to write against. The RED state is "verify command fails"; GREEN is "verify command passes."
|
|
155
|
-
|
|
156
|
-
**When to use:** task has a runnable `verify:` command and the deliverable is a config file change with no new behavior to unit-test. Invoke as `develop-tdd --config`.
|
|
157
|
-
|
|
158
|
-
**Cycle:**
|
|
159
|
-
|
|
160
|
-
```
|
|
161
|
-
RED: Run verify command → it fails (expected)
|
|
162
|
-
GREEN: Apply config change → verify passes
|
|
163
|
-
COMMIT: commit: chore(<scope>): <change>
|
|
164
|
-
```
|
|
165
|
-
|
|
166
|
-
**Rules:**
|
|
167
|
-
- Skips test-writing phase entirely — do NOT write a test file for config tasks.
|
|
168
|
-
- `verify:` command is **required** and must be runnable (no placeholder).
|
|
169
|
-
- Commit message follows Conventional Commits (`chore:` or `feat:` as appropriate).
|
|
170
|
-
- Still runs full `verify-work` after all tasks complete.
|
|
171
|
-
|
|
172
97
|
## Handoff
|
|
173
98
|
|
|
174
99
|
Gate: READY -> next: verify-work
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
# Migrate Spec — Reference
|
|
2
|
+
|
|
1
3
|
# migrate-spec Reference — spec-kit, BMAD, Learnings
|
|
2
4
|
|
|
3
5
|
Transformation rules for spec-kit and BMAD projects, plus learnings to adopt and output formats.
|
|
@@ -332,3 +334,269 @@ two_pass_spec: # Optional: only if user activates two-pass spec writing gate
|
|
|
332
334
|
technical_pass: pending
|
|
333
335
|
approved_at: null
|
|
334
336
|
```
|
|
337
|
+
|
|
338
|
+
---
|
|
339
|
+
|
|
340
|
+
## Reference block 1
|
|
341
|
+
|
|
342
|
+
```
|
|
343
|
+
Detected: GSD
|
|
344
|
+
Found:
|
|
345
|
+
✓ .planning/ROADMAP.md
|
|
346
|
+
✓ .planning/REQUIREMENTS.md (12 REQ-XX items)
|
|
347
|
+
✓ .planning/state.yaml
|
|
348
|
+
✓ .planning/phases/01-auth/01-CONTEXT.md
|
|
349
|
+
✗ .planning/METHODOLOGY.md (not present)
|
|
350
|
+
|
|
351
|
+
Skipping:
|
|
352
|
+
.planning/phases/01-auth/01-01-SUMMARY.md (execution record; archived only)
|
|
353
|
+
|
|
354
|
+
Proceed with migration? [yes / skip <artifact> / abort]
|
|
355
|
+
```
|
|
356
|
+
|
|
357
|
+
---
|
|
358
|
+
|
|
359
|
+
## Reference block 2
|
|
360
|
+
|
|
361
|
+
```yaml
|
|
362
|
+
# CORRECT — first-class id: field
|
|
363
|
+
in_scope:
|
|
364
|
+
- id: REQ-001
|
|
365
|
+
description: "User can register with email/password"
|
|
366
|
+
source: "REQUIREMENTS.md"
|
|
367
|
+
|
|
368
|
+
# DEPRECATED — comment-only
|
|
369
|
+
in_scope:
|
|
370
|
+
- "User can register with email/password" # REQ-001
|
|
371
|
+
```
|
|
372
|
+
|
|
373
|
+
---
|
|
374
|
+
|
|
375
|
+
## Reference block 3
|
|
376
|
+
|
|
377
|
+
```yaml
|
|
378
|
+
trace:
|
|
379
|
+
- id: FR-001
|
|
380
|
+
type: functional_requirement
|
|
381
|
+
description: "User can register with email/password"
|
|
382
|
+
epic: e02-auth-ui
|
|
383
|
+
story: e02s01
|
|
384
|
+
verify: "grep -q 'FR-001' specs/product/SCOPE_LATEST.yaml && echo OK"
|
|
385
|
+
- id: UJ-001
|
|
386
|
+
type: user_journey
|
|
387
|
+
description: "New user completes registration flow"
|
|
388
|
+
epic: e02-auth-ui
|
|
389
|
+
story: e02s01
|
|
390
|
+
```
|
|
391
|
+
|
|
392
|
+
---
|
|
393
|
+
|
|
394
|
+
## Reference block 4
|
|
395
|
+
|
|
396
|
+
```yaml
|
|
397
|
+
active_flow: null
|
|
398
|
+
active_epic_id: null
|
|
399
|
+
active_story_id: null
|
|
400
|
+
|
|
401
|
+
# ... other state fields ...
|
|
402
|
+
|
|
403
|
+
handoff:
|
|
404
|
+
last_step_completed: "Migrated from <framework> on <date>"
|
|
405
|
+
open_decisions:
|
|
406
|
+
- "decision text here"
|
|
407
|
+
required_reading:
|
|
408
|
+
- specs/product/VISION_LATEST.yaml
|
|
409
|
+
- specs/product/SCOPE_LATEST.yaml
|
|
410
|
+
- specs/tech-architecture/TECH_STACK_LATEST.md
|
|
411
|
+
- specs/release-plan.yaml
|
|
412
|
+
next_skill: survey-context
|
|
413
|
+
```
|
|
414
|
+
|
|
415
|
+
---
|
|
416
|
+
|
|
417
|
+
## Reference block 5
|
|
418
|
+
|
|
419
|
+
```markdown
|
|
420
|
+
# Migration Audit — <project-name> from <framework>
|
|
421
|
+
|
|
422
|
+
**Date:** <ISO 8601 timestamp>
|
|
423
|
+
**Status:** Pass / Fail with findings
|
|
424
|
+
|
|
425
|
+
## Findings
|
|
426
|
+
|
|
427
|
+
### High Priority
|
|
428
|
+
- Artifact: specs/epics/e02-auth-ui/epic.yaml
|
|
429
|
+
Finding: No verify: commands in story tasks
|
|
430
|
+
Recommendation: Add `verify:` to each task before develop-tdd
|
|
431
|
+
|
|
432
|
+
### Information
|
|
433
|
+
- Count of TODO markers: 3 (normal for fresh migration)
|
|
434
|
+
```
|
|
435
|
+
|
|
436
|
+
---
|
|
437
|
+
|
|
438
|
+
## Reference block 6
|
|
439
|
+
|
|
440
|
+
```
|
|
441
|
+
Which lenses to include in specs/tech-architecture/METHODOLOGY_LATEST.md?
|
|
442
|
+
|
|
443
|
+
[x] Cost of Delay (CD3) — Priority & trade-off assessment
|
|
444
|
+
[ ] STRIDE — Security threat modeling
|
|
445
|
+
[ ] F.I.R.S.T — Test quality principles
|
|
446
|
+
[ ] Bayesian Updating — Probabilistic decision-making
|
|
447
|
+
[ ] OWASP Top 10 — Web security framework
|
|
448
|
+
```
|
|
449
|
+
|
|
450
|
+
---
|
|
451
|
+
|
|
452
|
+
### Step 7 — Post-migration: Optional two-pass spec writing gate
|
|
453
|
+
|
|
454
|
+
After Steps 1–6, offer the user an optional two-pass spec writing workflow (spec-kit learning):
|
|
455
|
+
|
|
456
|
+
Prompt: "Use two-pass spec writing (user journeys first, then technical)? [yes / no]"
|
|
457
|
+
|
|
458
|
+
If **yes**, initialize the gate in `specs/state.yaml`:
|
|
459
|
+
|
|
460
|
+
```yaml
|
|
461
|
+
two_pass_spec:
|
|
462
|
+
journey_pass: pending
|
|
463
|
+
technical_pass: pending
|
|
464
|
+
approved_at: null
|
|
465
|
+
```
|
|
466
|
+
|
|
467
|
+
The journey pass must be marked "complete" by the user (after stakeholder approval of user-journey specs) before the technical pass begins:
|
|
468
|
+
|
|
469
|
+
```yaml
|
|
470
|
+
two_pass_spec:
|
|
471
|
+
journey_pass: complete
|
|
472
|
+
approved_at: "2026-06-26T12:00:00Z"
|
|
473
|
+
technical_pass: pending
|
|
474
|
+
```
|
|
475
|
+
|
|
476
|
+
Inform the user: "Journey pass is pending. Run `elaborate-spec` for user journeys, get stakeholder approval, then update `two_pass_spec.journey_pass: complete` in state.yaml before proceeding to technical specs."
|
|
477
|
+
|
|
478
|
+
If **no**, skip the two-pass gate. Proceed directly to plan-work.
|
|
479
|
+
|
|
480
|
+
→ verify: `grep -q 'two_pass_spec:' specs/state.yaml && echo "two-pass gate initialized" || echo "two-pass gate not activated"`
|
|
481
|
+
|
|
482
|
+
|
|
483
|
+
---
|
|
484
|
+
|
|
485
|
+
### Step 8 — Post-migration: Optional methodology doc template
|
|
486
|
+
|
|
487
|
+
After Steps 1–7, offer the user an optional analytical framework scaffold (GSD learning):
|
|
488
|
+
|
|
489
|
+
Prompt: "Create a methodology doc? [yes / no]"
|
|
490
|
+
|
|
491
|
+
If **yes**, present a checklist of analytical lenses:
|
|
492
|
+
|
|
493
|
+
```
|
|
494
|
+
Which lenses to include in specs/tech-architecture/METHODOLOGY_LATEST.md?
|
|
495
|
+
|
|
496
|
+
[x] Cost of Delay (CD3) — Priority & trade-off assessment
|
|
497
|
+
[ ] STRIDE — Security threat modeling
|
|
498
|
+
[ ] F.I.R.S.T — Test quality principles
|
|
499
|
+
[ ] Bayesian Updating — Probabilistic decision-making
|
|
500
|
+
[ ] OWASP Top 10 — Web security framework
|
|
501
|
+
```
|
|
502
|
+
|
|
503
|
+
Copy the template from `migrate-spec/templates/METHODOLOGY_LATEST.md` to `specs/tech-architecture/METHODOLOGY_LATEST.md`.
|
|
504
|
+
- Active lenses remain uncommented
|
|
505
|
+
- Unselected lenses are left commented out
|
|
506
|
+
- Populate `{{project_name}}` with the migrated project's name
|
|
507
|
+
|
|
508
|
+
If **no**, skip. Add note to handoff: "Methodology doc: skipped — can be added later via `cp migrate-spec/templates/METHODOLOGY_LATEST.md specs/tech-architecture/`"
|
|
509
|
+
|
|
510
|
+
→ verify: `test -f specs/tech-architecture/METHODOLOGY_LATEST.md && echo "methodology doc created" || echo "methodology doc skipped"`
|
|
511
|
+
|
|
512
|
+
---
|
|
513
|
+
|
|
514
|
+
|
|
515
|
+
---
|
|
516
|
+
|
|
517
|
+
## Artifact Mapping Summary
|
|
518
|
+
|
|
519
|
+
Full mapping tables: [REFERENCE-GSD.md](./REFERENCE-GSD.md) (GSD) · [REFERENCE.md](./REFERENCE.md) (spec-kit, BMAD, learnings).
|
|
520
|
+
|
|
521
|
+
| Source | Target |
|
|
522
|
+
|--------|--------|
|
|
523
|
+
| GSD `ROADMAP.md` | `specs/release-plan.yaml + epic shards` |
|
|
524
|
+
| GSD `REQUIREMENTS.md` | `specs/product/SCOPE_LATEST.yaml` |
|
|
525
|
+
| GSD `CONTEXT.md` (phases) | `specs/tech-architecture/tech-stack.md` + `specs/adr/` |
|
|
526
|
+
| GSD `PLAN.md` | `specs/epics/eNN-slug/epic.yaml` (tasks with verify in `-tasks.yaml`) |
|
|
527
|
+
| GSD `METHODOLOGY.md` | `specs/tech-architecture/tech-stack.md` |
|
|
528
|
+
| spec-kit `spec.md` | `specs/product/SCOPE_LATEST.yaml` + `specs/tech-architecture/tech-stack.md` |
|
|
529
|
+
| spec-kit `plan.md` | `specs/tech-architecture/tech-stack.md` + `specs/release-plan.yaml` + `specs/epics/` |
|
|
530
|
+
| spec-kit `tasks.md` | `specs/epics/ (see slice-tasks)` |
|
|
531
|
+
| BMAD `prd.md` | `specs/product/SCOPE_LATEST.yaml` |
|
|
532
|
+
| BMAD `architecture.md` | `specs/tech-architecture/tech-stack.md` + `specs/adr/` |
|
|
533
|
+
| BMAD `epic-*.md` | `specs/release-plan.yaml + epic shards` |
|
|
534
|
+
| BMAD `story-*.md` | `specs/epics/ (see slice-tasks)` |
|
|
535
|
+
| BMAD `project-context.md` | `CLAUDE.md` (append project-specific section) |
|
|
536
|
+
| BMAD `decision-log.md` | `specs/adr/` (one ADR per logged decision) |
|
|
537
|
+
|
|
538
|
+
---
|
|
539
|
+
|
|
540
|
+
|
|
541
|
+
---
|
|
542
|
+
|
|
543
|
+
## Rules
|
|
544
|
+
|
|
545
|
+
- **Preserve source IDs** — REQ-XX, FR-XX, UJ-XX are emitted as first-class `id:` fields in bigpowers YAML targets (e.g., `in_scope` entries). Never silently renumber. See Step 3 ID Tracking subsection for details.
|
|
546
|
+
- **Never merge contradictory docs** — if source has both `CONTEXT.md` and `architecture.md`, create sections in bigpowers `CONTEXT.md`; don't collapse them.
|
|
547
|
+
- **ADRs are opt-in** — only create an ADR when: hard to reverse, surprising without context, result of a real trade-off. Lightweight decisions go to `specs/DECISION-LOG.md`.
|
|
548
|
+
- **state.yaml is always regenerated** — never migrate source STATE verbatim; bigpowers state.yaml needs its own format.
|
|
549
|
+
- **specs/ is the only output location** — no files are created outside `specs/` and `CLAUDE.md`.
|
|
550
|
+
|
|
551
|
+
---
|
|
552
|
+
|
|
553
|
+
### Step 5 — Surface learnings (optional)
|
|
554
|
+
|
|
555
|
+
After migration, offer the user a brief analysis of what the source framework did that bigpowers doesn't have yet.
|
|
556
|
+
|
|
557
|
+
Use the learnings table from [REFERENCE.md](./REFERENCE.md#learnings-to-adopt). Present as checkboxes so the user can decide which to adopt.
|
|
558
|
+
|
|
559
|
+
→ verify: `grep -c "\- \[ \]" specs/state.yaml 2>/dev/null && echo "pending items recorded" || echo "no pending items in state.yaml"`
|
|
560
|
+
|
|
561
|
+
|
|
562
|
+
---
|
|
563
|
+
|
|
564
|
+
### Step 6 — Adversarial review (optional)
|
|
565
|
+
|
|
566
|
+
Before the user runs `plan-work`, offer an optional lightweight audit of the migrated artifacts. This catches common migration errors early — incomplete specs, missing verification commands, unresolved decisions.
|
|
567
|
+
|
|
568
|
+
Prompt: "Run adversarial review of migrated artifacts? [yes / skip]"
|
|
569
|
+
|
|
570
|
+
If yes, perform these checks:
|
|
571
|
+
|
|
572
|
+
1. **Scan for incomplete markers** — Find TODO, FIXME, MISSING in specs/
|
|
573
|
+
2. **Verify every epic has `verify:` commands** — Parse all `eNN-*/epic.yaml` files
|
|
574
|
+
3. **Check state.yaml handoff** — Ensure `open_decisions` is documented (even if empty)
|
|
575
|
+
|
|
576
|
+
Collect findings and write to `specs/archive/MIGRATION-AUDIT.md`:
|
|
577
|
+
|
|
578
|
+
```markdown
|
|
579
|
+
# Migration Audit — <project-name> from <framework>
|
|
580
|
+
|
|
581
|
+
**Date:** <ISO 8601 timestamp>
|
|
582
|
+
**Status:** Pass / Fail with findings
|
|
583
|
+
|
|
584
|
+
|
|
585
|
+
---
|
|
586
|
+
|
|
587
|
+
## Findings
|
|
588
|
+
|
|
589
|
+
### High Priority
|
|
590
|
+
- Artifact: specs/epics/e02-auth-ui/epic.yaml
|
|
591
|
+
Finding: No verify: commands in story tasks
|
|
592
|
+
Recommendation: Add `verify:` to each task before develop-tdd
|
|
593
|
+
|
|
594
|
+
### Information
|
|
595
|
+
- Count of TODO markers: 3 (normal for fresh migration)
|
|
596
|
+
```
|
|
597
|
+
|
|
598
|
+
If findings exist, the handoff block should note: "Adversarial review: N findings — see `specs/archive/MIGRATION-AUDIT.md`"
|
|
599
|
+
|
|
600
|
+
If skip is chosen, add to handoff: "Adversarial review: skipped — review manually before plan-work"
|
|
601
|
+
|
|
602
|
+
→ verify: `test -f specs/archive/MIGRATION-AUDIT.md && echo "audit completed" || echo "audit skipped or not performed"`
|