@thierrynakoa/fire-flow 10.0.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/.claude-plugin/plugin.json +64 -0
- package/ARCHITECTURE-DIAGRAM.md +440 -0
- package/COMMAND-REFERENCE.md +172 -0
- package/DOMINION-FLOW-OVERVIEW.md +421 -0
- package/LICENSE +21 -0
- package/QUICK-START.md +351 -0
- package/README.md +398 -0
- package/TROUBLESHOOTING.md +264 -0
- package/agents/fire-codebase-mapper.md +484 -0
- package/agents/fire-debugger.md +535 -0
- package/agents/fire-executor.md +949 -0
- package/agents/fire-fact-checker.md +276 -0
- package/agents/fire-learncoding-explainer.md +237 -0
- package/agents/fire-learncoding-walker.md +147 -0
- package/agents/fire-planner.md +675 -0
- package/agents/fire-project-researcher.md +155 -0
- package/agents/fire-research-synthesizer.md +166 -0
- package/agents/fire-researcher.md +723 -0
- package/agents/fire-reviewer.md +499 -0
- package/agents/fire-roadmapper.md +203 -0
- package/agents/fire-verifier.md +880 -0
- package/bin/cli.js +208 -0
- package/commands/fire-0-orient.md +476 -0
- package/commands/fire-1-new.md +281 -0
- package/commands/fire-1a-discuss.md +455 -0
- package/commands/fire-2-plan.md +527 -0
- package/commands/fire-3-execute.md +1303 -0
- package/commands/fire-4-verify.md +845 -0
- package/commands/fire-5-handoff.md +515 -0
- package/commands/fire-6-resume.md +501 -0
- package/commands/fire-7-review.md +409 -0
- package/commands/fire-add-new-skill.md +598 -0
- package/commands/fire-analytics.md +499 -0
- package/commands/fire-assumptions.md +78 -0
- package/commands/fire-autonomous.md +528 -0
- package/commands/fire-brainstorm.md +413 -0
- package/commands/fire-complete-milestone.md +270 -0
- package/commands/fire-dashboard.md +375 -0
- package/commands/fire-debug.md +663 -0
- package/commands/fire-discover.md +616 -0
- package/commands/fire-double-check.md +460 -0
- package/commands/fire-execute-plan.md +182 -0
- package/commands/fire-learncoding.md +242 -0
- package/commands/fire-loop-resume.md +272 -0
- package/commands/fire-loop-stop.md +198 -0
- package/commands/fire-loop.md +1168 -0
- package/commands/fire-map-codebase.md +313 -0
- package/commands/fire-new-milestone.md +356 -0
- package/commands/fire-reflect.md +235 -0
- package/commands/fire-research.md +246 -0
- package/commands/fire-search.md +330 -0
- package/commands/fire-security-audit-repo.md +293 -0
- package/commands/fire-security-scan.md +484 -0
- package/commands/fire-session-summary.md +252 -0
- package/commands/fire-skills-diff.md +506 -0
- package/commands/fire-skills-history.md +388 -0
- package/commands/fire-skills-rollback.md +408 -0
- package/commands/fire-skills-sync.md +470 -0
- package/commands/fire-test.md +520 -0
- package/commands/fire-todos.md +335 -0
- package/commands/fire-transition.md +186 -0
- package/commands/fire-update.md +312 -0
- package/commands/fire-verify-uat.md +146 -0
- package/commands/fire-vuln-scan.md +493 -0
- package/hooks/hooks.json +16 -0
- package/hooks/run-hook.cmd +69 -0
- package/hooks/run-hook.sh +8 -0
- package/hooks/run-session-end.cmd +49 -0
- package/hooks/run-session-end.sh +7 -0
- package/hooks/session-end.sh +90 -0
- package/hooks/session-start.sh +111 -0
- package/package.json +52 -0
- package/plugin.json +7 -0
- package/references/auto-skill-extraction.md +136 -0
- package/references/behavioral-directives.md +365 -0
- package/references/blocker-tracking.md +155 -0
- package/references/checkpoints.md +165 -0
- package/references/circuit-breaker.md +410 -0
- package/references/context-engineering.md +587 -0
- package/references/decision-time-guidance.md +289 -0
- package/references/error-classification.md +326 -0
- package/references/execution-mode-intelligence.md +242 -0
- package/references/git-integration.md +217 -0
- package/references/honesty-protocols.md +304 -0
- package/references/integration-architecture.md +470 -0
- package/references/issue-to-pr-pipeline.md +150 -0
- package/references/metrics-and-trends.md +234 -0
- package/references/playwright-e2e-testing.md +326 -0
- package/references/questioning.md +125 -0
- package/references/research-improvements.md +110 -0
- package/references/skills-usage-guide.md +429 -0
- package/references/tdd.md +131 -0
- package/references/testing-enforcement.md +192 -0
- package/references/ui-brand.md +383 -0
- package/references/validation-checklist.md +456 -0
- package/references/verification-patterns.md +187 -0
- package/references/warrior-principles.md +173 -0
- package/skills-library/SKILLS-INDEX.md +588 -0
- package/skills-library/_general/frontend/html-visual-reports.md +292 -0
- package/skills-library/_general/methodology/debug-swarm-researcher-escape-hatch.md +240 -0
- package/skills-library/_general/methodology/learncoding-agentic-pattern.md +114 -0
- package/skills-library/_general/methodology/shell-autonomous-loop-fixplan.md +238 -0
- package/skills-library/basics/api-rest-basics.md +162 -0
- package/skills-library/basics/env-variables.md +96 -0
- package/skills-library/basics/error-handling-basics.md +125 -0
- package/skills-library/basics/git-commit-conventions.md +106 -0
- package/skills-library/basics/readme-template.md +108 -0
- package/skills-library/common-tasks/async-await-patterns.md +157 -0
- package/skills-library/common-tasks/auth-jwt-basics.md +164 -0
- package/skills-library/common-tasks/database-schema-design.md +166 -0
- package/skills-library/common-tasks/file-upload-basics.md +166 -0
- package/skills-library/common-tasks/form-validation.md +159 -0
- package/skills-library/debugging/FAILURE_TAXONOMY_CLASSIFICATION.md +117 -0
- package/skills-library/debugging/THREE_AGENT_HYPOTHESIS_DEBUGGING.md +86 -0
- package/skills-library/methodology/BREATH_BASED_PARALLEL_EXECUTION.md +678 -0
- package/skills-library/methodology/CONFIDENCE_GATED_EXECUTION.md +243 -0
- package/skills-library/methodology/EVIDENCE_BASED_VALIDATION.md +308 -0
- package/skills-library/methodology/MULTI_PERSPECTIVE_CODE_REVIEW.md +330 -0
- package/skills-library/methodology/PATH_VERIFICATION_GATE.md +211 -0
- package/skills-library/methodology/REFLEXION_MEMORY_PATTERN.md +183 -0
- package/skills-library/methodology/RESEARCH_BACKED_WORKFLOW_UPGRADE.md +263 -0
- package/skills-library/methodology/SABBATH_REST_PATTERN.md +267 -0
- package/skills-library/methodology/STONE_AND_SCAFFOLD.md +220 -0
- package/skills-library/performance/cache-augmented-generation.md +172 -0
- package/skills-library/quality-safety/debugging-steps.md +147 -0
- package/skills-library/quality-safety/deployment-checklist.md +155 -0
- package/skills-library/quality-safety/security-checklist.md +204 -0
- package/skills-library/quality-safety/testing-basics.md +180 -0
- package/skills-library/security/agent-security-scanner.md +445 -0
- package/skills-library/specialists/api-architecture/api-designer.md +49 -0
- package/skills-library/specialists/api-architecture/graphql-architect.md +49 -0
- package/skills-library/specialists/api-architecture/mcp-developer.md +51 -0
- package/skills-library/specialists/api-architecture/microservices-architect.md +50 -0
- package/skills-library/specialists/api-architecture/websocket-engineer.md +48 -0
- package/skills-library/specialists/backend/django-expert.md +52 -0
- package/skills-library/specialists/backend/fastapi-expert.md +52 -0
- package/skills-library/specialists/backend/laravel-specialist.md +52 -0
- package/skills-library/specialists/backend/nestjs-expert.md +51 -0
- package/skills-library/specialists/backend/rails-expert.md +53 -0
- package/skills-library/specialists/backend/spring-boot-engineer.md +56 -0
- package/skills-library/specialists/data-ml/fine-tuning-expert.md +48 -0
- package/skills-library/specialists/data-ml/ml-pipeline.md +47 -0
- package/skills-library/specialists/data-ml/pandas-pro.md +47 -0
- package/skills-library/specialists/data-ml/rag-architect.md +51 -0
- package/skills-library/specialists/data-ml/spark-engineer.md +47 -0
- package/skills-library/specialists/frontend/angular-architect.md +52 -0
- package/skills-library/specialists/frontend/flutter-expert.md +51 -0
- package/skills-library/specialists/frontend/nextjs-developer.md +54 -0
- package/skills-library/specialists/frontend/react-native-expert.md +50 -0
- package/skills-library/specialists/frontend/vue-expert.md +51 -0
- package/skills-library/specialists/infrastructure/chaos-engineer.md +74 -0
- package/skills-library/specialists/infrastructure/cloud-architect.md +70 -0
- package/skills-library/specialists/infrastructure/database-optimizer.md +64 -0
- package/skills-library/specialists/infrastructure/devops-engineer.md +70 -0
- package/skills-library/specialists/infrastructure/kubernetes-specialist.md +52 -0
- package/skills-library/specialists/infrastructure/monitoring-expert.md +70 -0
- package/skills-library/specialists/infrastructure/sre-engineer.md +70 -0
- package/skills-library/specialists/infrastructure/terraform-engineer.md +51 -0
- package/skills-library/specialists/languages/cpp-pro.md +74 -0
- package/skills-library/specialists/languages/csharp-developer.md +69 -0
- package/skills-library/specialists/languages/dotnet-core-expert.md +54 -0
- package/skills-library/specialists/languages/golang-pro.md +51 -0
- package/skills-library/specialists/languages/java-architect.md +49 -0
- package/skills-library/specialists/languages/javascript-pro.md +68 -0
- package/skills-library/specialists/languages/kotlin-specialist.md +68 -0
- package/skills-library/specialists/languages/php-pro.md +49 -0
- package/skills-library/specialists/languages/python-pro.md +52 -0
- package/skills-library/specialists/languages/react-expert.md +51 -0
- package/skills-library/specialists/languages/rust-engineer.md +50 -0
- package/skills-library/specialists/languages/sql-pro.md +56 -0
- package/skills-library/specialists/languages/swift-expert.md +69 -0
- package/skills-library/specialists/languages/typescript-pro.md +51 -0
- package/skills-library/specialists/platform/atlassian-mcp.md +52 -0
- package/skills-library/specialists/platform/embedded-systems.md +53 -0
- package/skills-library/specialists/platform/game-developer.md +53 -0
- package/skills-library/specialists/platform/salesforce-developer.md +53 -0
- package/skills-library/specialists/platform/shopify-expert.md +49 -0
- package/skills-library/specialists/platform/wordpress-pro.md +49 -0
- package/skills-library/specialists/quality/code-documenter.md +51 -0
- package/skills-library/specialists/quality/code-reviewer.md +67 -0
- package/skills-library/specialists/quality/debugging-wizard.md +51 -0
- package/skills-library/specialists/quality/fullstack-guardian.md +51 -0
- package/skills-library/specialists/quality/legacy-modernizer.md +50 -0
- package/skills-library/specialists/quality/playwright-expert.md +65 -0
- package/skills-library/specialists/quality/spec-miner.md +56 -0
- package/skills-library/specialists/quality/test-master.md +65 -0
- package/skills-library/specialists/security/secure-code-guardian.md +55 -0
- package/skills-library/specialists/security/security-reviewer.md +53 -0
- package/skills-library/specialists/workflow/architecture-designer.md +53 -0
- package/skills-library/specialists/workflow/cli-developer.md +70 -0
- package/skills-library/specialists/workflow/feature-forge.md +65 -0
- package/skills-library/specialists/workflow/prompt-engineer.md +54 -0
- package/skills-library/specialists/workflow/the-fool.md +62 -0
- package/templates/ASSUMPTIONS.md +125 -0
- package/templates/BLOCKERS.md +73 -0
- package/templates/DECISION_LOG.md +116 -0
- package/templates/UAT.md +96 -0
- package/templates/blueprint.md +94 -0
- package/templates/brainstorm.md +185 -0
- package/templates/conscience.md +92 -0
- package/templates/fire-handoff.md +159 -0
- package/templates/metrics.md +67 -0
- package/templates/phase-prompt.md +142 -0
- package/templates/record.md +131 -0
- package/templates/review-report.md +117 -0
- package/templates/skills-index.md +157 -0
- package/templates/verification.md +149 -0
- package/templates/vision.md +79 -0
- package/validation-config.yml +793 -0
- package/version.json +7 -0
- package/workflows/execute-phase.md +732 -0
- package/workflows/handoff-session.md +678 -0
- package/workflows/new-project.md +578 -0
- package/workflows/plan-phase.md +592 -0
- package/workflows/verify-phase.md +874 -0
|
@@ -0,0 +1,242 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Linear code walkthrough learning mode — transforms any repo into a step-by-step learning experience. Based on Simon Willison's Agentic Engineering Patterns.
|
|
3
|
+
argument-hint: "[on|off|--from-github URL|--from-path PATH] [--watch|--active] [--step N]"
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# /fire-learncoding
|
|
7
|
+
|
|
8
|
+
> Turn any codebase into a linear learning walkthrough. Anti-vibe-coding. Anti-cognitive-debt.
|
|
9
|
+
> Grounded in Simon Willison's Agentic Engineering Patterns (simonwillison.net/guides/agentic-engineering-patterns/)
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
## The Philosophy
|
|
14
|
+
|
|
15
|
+
> "If you don't understand the code, your only recourse is to ask AI to fix it for you —
|
|
16
|
+
> like paying off credit card debt with another credit card." — Simon Willison
|
|
17
|
+
|
|
18
|
+
This mode prevents cognitive debt by walking through every file from the entry point outward,
|
|
19
|
+
explaining WHAT each piece does, WHY it's written that way, and WHICH pattern it uses.
|
|
20
|
+
Real code is extracted via shell tools (grep, cat, sed) — never paraphrased from memory.
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## Arguments
|
|
25
|
+
|
|
26
|
+
```yaml
|
|
27
|
+
arguments:
|
|
28
|
+
action:
|
|
29
|
+
required: false
|
|
30
|
+
type: string
|
|
31
|
+
options: [on, off, --from-github, --from-path]
|
|
32
|
+
description: "Toggle mode or load source"
|
|
33
|
+
|
|
34
|
+
--from-github:
|
|
35
|
+
type: string
|
|
36
|
+
description: "GitHub repo URL to learn from"
|
|
37
|
+
example: "/fire-learncoding --from-github https://github.com/user/repo"
|
|
38
|
+
|
|
39
|
+
--from-path:
|
|
40
|
+
type: string
|
|
41
|
+
description: "Local path to learn from"
|
|
42
|
+
example: "/fire-learncoding --from-path ./src"
|
|
43
|
+
|
|
44
|
+
--watch:
|
|
45
|
+
type: boolean
|
|
46
|
+
default: true
|
|
47
|
+
description: "Mode 1: Agent explains + scaffolds. You read and say 'next'."
|
|
48
|
+
|
|
49
|
+
--active:
|
|
50
|
+
type: boolean
|
|
51
|
+
default: false
|
|
52
|
+
description: "Mode 2: Agent explains purpose, you write the key logic."
|
|
53
|
+
|
|
54
|
+
--step:
|
|
55
|
+
type: integer
|
|
56
|
+
description: "Jump to a specific step (resume)"
|
|
57
|
+
example: "/fire-learncoding --step 5"
|
|
58
|
+
|
|
59
|
+
--entry:
|
|
60
|
+
type: string
|
|
61
|
+
description: "Override entry point detection"
|
|
62
|
+
example: "/fire-learncoding --entry src/server.ts"
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
---
|
|
66
|
+
|
|
67
|
+
## Mode Reference
|
|
68
|
+
|
|
69
|
+
| Mode | Flag | You do | Agent does |
|
|
70
|
+
|------|------|--------|------------|
|
|
71
|
+
| Watch | `--watch` (default) | Read + say "next" | Explains, scaffolds file |
|
|
72
|
+
| Active | `--active` | Write key logic sections | Explains purpose, marks `// WRITE THIS:` |
|
|
73
|
+
| Hybrid | `--hybrid` (future) | Fill in business logic TODOs | Scaffolds all boilerplate |
|
|
74
|
+
|
|
75
|
+
---
|
|
76
|
+
|
|
77
|
+
## Process
|
|
78
|
+
|
|
79
|
+
### Step 0: Load/Check Mode State
|
|
80
|
+
|
|
81
|
+
```bash
|
|
82
|
+
# Read mode config
|
|
83
|
+
MODE_FILE=".planning/learncoding.rc"
|
|
84
|
+
STEP_FILE=".planning/learncoding-progress.json"
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
**If `on` argument:**
|
|
88
|
+
```bash
|
|
89
|
+
mkdir -p .planning
|
|
90
|
+
echo 'LEARNCODING_MODE=watch' > .planning/learncoding.rc
|
|
91
|
+
echo "✓ Learncoding mode ON (--watch). Use /fire-learncoding --from-github URL to start."
|
|
92
|
+
exit 0
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
**If `off` argument:**
|
|
96
|
+
```bash
|
|
97
|
+
rm -f .planning/learncoding.rc .planning/learncoding-progress.json
|
|
98
|
+
echo "✓ Learncoding mode OFF."
|
|
99
|
+
exit 0
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
**If `--active` flag:**
|
|
103
|
+
```bash
|
|
104
|
+
echo 'LEARNCODING_MODE=active' > .planning/learncoding.rc
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
**Resume check:** If `.planning/learncoding-progress.json` exists and has `currentStep < totalSteps`:
|
|
108
|
+
|
|
109
|
+
```
|
|
110
|
+
📖 Learncoding session found — Step [N] of [M]
|
|
111
|
+
Source: [repo/path]
|
|
112
|
+
Mode: [watch|active]
|
|
113
|
+
|
|
114
|
+
→ Type "resume" to continue from Step N
|
|
115
|
+
→ Type "restart" to start from Step 1
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
### Step 1: Load Source
|
|
119
|
+
|
|
120
|
+
**If `--from-github <url>`:**
|
|
121
|
+
|
|
122
|
+
```bash
|
|
123
|
+
# Extract owner/repo from URL
|
|
124
|
+
REPO=$(echo "$URL" | sed 's|https://github.com/||')
|
|
125
|
+
# e.g. "simonw/datasette"
|
|
126
|
+
|
|
127
|
+
# Fetch file tree using gh CLI
|
|
128
|
+
gh api repos/$REPO/git/trees/HEAD?recursive=1 \
|
|
129
|
+
--jq '.tree[] | select(.type=="blob") | .path' \
|
|
130
|
+
> .planning/learncoding-files.txt
|
|
131
|
+
|
|
132
|
+
# Fetch key files content as needed per step using:
|
|
133
|
+
# gh api repos/$REPO/contents/{path} --jq '.content' | base64 -d
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
**If `--from-path <path>`:**
|
|
137
|
+
```bash
|
|
138
|
+
find "$PATH" -type f \( -name "*.ts" -o -name "*.js" -o -name "*.py" -o -name "*.rs" \) \
|
|
139
|
+
| grep -v node_modules | grep -v __pycache__ | grep -v .git \
|
|
140
|
+
> .planning/learncoding-files.txt
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
Display:
|
|
144
|
+
```
|
|
145
|
+
📦 Source loaded: [repo or path]
|
|
146
|
+
Files found: [N]
|
|
147
|
+
Detecting entry point...
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
### Step 2: Detect Entry Point
|
|
151
|
+
|
|
152
|
+
Spawn `fire-learncoding-walker` agent with the file list.
|
|
153
|
+
|
|
154
|
+
Walker returns:
|
|
155
|
+
```json
|
|
156
|
+
{
|
|
157
|
+
"entryPoint": "src/index.ts",
|
|
158
|
+
"steps": [
|
|
159
|
+
{ "order": 1, "file": "src/index.ts", "role": "Application entry", "imports": ["src/app.ts", "src/config.ts"] },
|
|
160
|
+
{ "order": 2, "file": "src/config.ts", "role": "Configuration loader", "imports": [] },
|
|
161
|
+
{ "order": 3, "file": "src/app.ts", "role": "Express app setup", "imports": ["src/routes/index.ts"] }
|
|
162
|
+
],
|
|
163
|
+
"totalSteps": 12
|
|
164
|
+
}
|
|
165
|
+
```
|
|
166
|
+
|
|
167
|
+
Write to `.planning/learncoding-plan.json`.
|
|
168
|
+
|
|
169
|
+
Display learning plan:
|
|
170
|
+
```
|
|
171
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
172
|
+
║ LEARNCODING — LEARNING PLAN ║
|
|
173
|
+
║ Source: [repo/path] Mode: [watch|active] ║
|
|
174
|
+
╠══════════════════════════════════════════════════════════════╣
|
|
175
|
+
║ Entry point: src/index.ts ║
|
|
176
|
+
║ Total steps: 12 ║
|
|
177
|
+
╠══════════════════════════════════════════════════════════════╣
|
|
178
|
+
║ Step 1: src/index.ts — Application entry ║
|
|
179
|
+
║ Step 2: src/config.ts — Configuration loader ║
|
|
180
|
+
║ Step 3: src/app.ts — Express app setup ║
|
|
181
|
+
║ Step 4: src/routes/index.ts — Route registry ║
|
|
182
|
+
║ ... ║
|
|
183
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
184
|
+
|
|
185
|
+
Ready to start?
|
|
186
|
+
→ Type "start" to begin Step 1
|
|
187
|
+
→ Type "start --step N" to jump to a specific step
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
### Step 3: Run the Step Loop
|
|
191
|
+
|
|
192
|
+
For each step N from current position to totalSteps:
|
|
193
|
+
|
|
194
|
+
**Update progress:**
|
|
195
|
+
```json
|
|
196
|
+
{ "currentStep": N, "totalSteps": 12, "mode": "watch", "source": "..." }
|
|
197
|
+
```
|
|
198
|
+
Write to `.planning/learncoding-progress.json`.
|
|
199
|
+
|
|
200
|
+
**Spawn `fire-learncoding-explainer`** with:
|
|
201
|
+
- `step`: current step object (file path, role, order)
|
|
202
|
+
- `mode`: watch | active
|
|
203
|
+
- `source`: github repo or local path
|
|
204
|
+
- `totalSteps`: for breadcrumb display
|
|
205
|
+
|
|
206
|
+
**Wait for explainer to complete.**
|
|
207
|
+
|
|
208
|
+
**Read user input:**
|
|
209
|
+
- `next` / `n` / `continue` → advance to step N+1
|
|
210
|
+
- `explain more` / `more` → re-spawn explainer with `--deep` flag for deeper dive
|
|
211
|
+
- `why` → re-spawn explainer with `--why` flag for architectural reasoning
|
|
212
|
+
- `skip` → advance without scaffolding (mark as skipped in progress)
|
|
213
|
+
- `exit` / `done` → save progress, exit mode
|
|
214
|
+
|
|
215
|
+
**If mode is `--active`:** Wait for user to paste their code before accepting "next".
|
|
216
|
+
|
|
217
|
+
### Step 4: Completion
|
|
218
|
+
|
|
219
|
+
When all steps complete:
|
|
220
|
+
|
|
221
|
+
```
|
|
222
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
223
|
+
║ LEARNCODING — WALKTHROUGH COMPLETE ║
|
|
224
|
+
╠══════════════════════════════════════════════════════════════╣
|
|
225
|
+
║ Files walked: [N] ║
|
|
226
|
+
║ Files written: [N] ║
|
|
227
|
+
║ Patterns seen: [list of patterns encountered] ║
|
|
228
|
+
║ ║
|
|
229
|
+
║ Your code is in: [output directory] ║
|
|
230
|
+
║ ║
|
|
231
|
+
║ What you built: ║
|
|
232
|
+
║ "[one sentence summary of what was learned]" ║
|
|
233
|
+
║ ║
|
|
234
|
+
║ Recommended next steps: ║
|
|
235
|
+
║ 1. Run the tests: [test command] ║
|
|
236
|
+
║ 2. Start the app: [start command] ║
|
|
237
|
+
║ 3. Read: simonwillison.net/guides/agentic-engineering-patterns/ ║
|
|
238
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
239
|
+
```
|
|
240
|
+
|
|
241
|
+
Save walkthrough document to `.planning/learncoding-walkthrough.md` —
|
|
242
|
+
a full record of all steps, snippets, and explanations (reference for later).
|
|
@@ -0,0 +1,272 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Resume a Power Loop from Sabbath Rest or stopped state
|
|
3
|
+
argument-hint: "[LOOP_ID]"
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# /fire-loop-resume
|
|
7
|
+
|
|
8
|
+
> Resume Power Loop from Sabbath Rest snapshot with full context restoration
|
|
9
|
+
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
## Purpose
|
|
13
|
+
|
|
14
|
+
Resume a Power Loop that was:
|
|
15
|
+
- Paused due to Sabbath Rest (context rot warning)
|
|
16
|
+
- Stopped by user via `/fire-loop-stop`
|
|
17
|
+
- Interrupted by session end
|
|
18
|
+
|
|
19
|
+
This command restores context from the Sabbath Rest snapshot and continues the loop with fresh context.
|
|
20
|
+
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
## Arguments
|
|
24
|
+
|
|
25
|
+
```yaml
|
|
26
|
+
arguments:
|
|
27
|
+
loop_id:
|
|
28
|
+
required: false
|
|
29
|
+
type: string
|
|
30
|
+
description: "Loop ID to resume (omit to resume most recent)"
|
|
31
|
+
example: "/fire-loop-resume 20260123-143052"
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
---
|
|
35
|
+
|
|
36
|
+
## Process
|
|
37
|
+
|
|
38
|
+
### Step 1: Find Loop to Resume
|
|
39
|
+
|
|
40
|
+
**If LOOP_ID provided:**
|
|
41
|
+
```bash
|
|
42
|
+
SABBATH_FILE=$(ls .planning/loops/sabbath-${LOOP_ID}*.md 2>/dev/null | head -1)
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
**If no LOOP_ID (resume most recent):**
|
|
46
|
+
```bash
|
|
47
|
+
# Check Sabbath Rest state first
|
|
48
|
+
if [ -f ".claude/dominion-flow.local.md" ]; then
|
|
49
|
+
LOOP_ID=$(grep "Loop ID:" .claude/dominion-flow.local.md | head -1 | cut -d: -f2 | xargs)
|
|
50
|
+
fi
|
|
51
|
+
|
|
52
|
+
# Or find most recent sabbath file
|
|
53
|
+
SABBATH_FILE=$(ls -t .planning/loops/sabbath-*.md 2>/dev/null | head -1)
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
### Step 2: Validate Sabbath File Exists
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
if [ ! -f "$SABBATH_FILE" ]; then
|
|
60
|
+
echo "No Sabbath Rest snapshot found for loop ${LOOP_ID}"
|
|
61
|
+
echo "Available loops:"
|
|
62
|
+
ls .planning/loops/*.md
|
|
63
|
+
exit 1
|
|
64
|
+
fi
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
### Step 3: Load Sabbath Rest Context
|
|
68
|
+
|
|
69
|
+
Read the Sabbath snapshot and extract:
|
|
70
|
+
|
|
71
|
+
```yaml
|
|
72
|
+
From sabbath file:
|
|
73
|
+
- loop_id
|
|
74
|
+
- iteration (where we stopped)
|
|
75
|
+
- original prompt
|
|
76
|
+
- files modified
|
|
77
|
+
- hypotheses tested
|
|
78
|
+
- next steps
|
|
79
|
+
- key context to restore
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
### Step 4: Display Context Restoration
|
|
83
|
+
|
|
84
|
+
```
|
|
85
|
+
+------------------------------------------------------------------------------+
|
|
86
|
+
| POWER LOOP RESUME |
|
|
87
|
+
+------------------------------------------------------------------------------+
|
|
88
|
+
| |
|
|
89
|
+
| Restoring Loop: ${LOOP_ID} |
|
|
90
|
+
| Paused At: Iteration [N] |
|
|
91
|
+
| Reason: [context_rot | user_stop | session_end] |
|
|
92
|
+
| |
|
|
93
|
+
| Sabbath Rest Snapshot: |
|
|
94
|
+
| ${SABBATH_FILE} |
|
|
95
|
+
| |
|
|
96
|
+
+------------------------------------------------------------------------------+
|
|
97
|
+
| RESTORED CONTEXT |
|
|
98
|
+
+------------------------------------------------------------------------------+
|
|
99
|
+
| |
|
|
100
|
+
| Progress Summary: |
|
|
101
|
+
| [from sabbath file] |
|
|
102
|
+
| |
|
|
103
|
+
| Files Modified: |
|
|
104
|
+
| - [file]: [change] |
|
|
105
|
+
| - [file]: [change] |
|
|
106
|
+
| |
|
|
107
|
+
| Key Context: |
|
|
108
|
+
| [critical information from sabbath file] |
|
|
109
|
+
| |
|
|
110
|
+
| Immediate Next Step: |
|
|
111
|
+
| [exactly what to do] |
|
|
112
|
+
| |
|
|
113
|
+
+------------------------------------------------------------------------------+
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
### Step 5: Restore Loop State
|
|
117
|
+
|
|
118
|
+
Recreate active loop config:
|
|
119
|
+
|
|
120
|
+
```bash
|
|
121
|
+
cat > .planning/loops/active-loop.json << 'EOF'
|
|
122
|
+
{
|
|
123
|
+
"id": "${LOOP_ID}",
|
|
124
|
+
"prompt": "[original prompt from sabbath file]",
|
|
125
|
+
"completion_promise": "[promise]",
|
|
126
|
+
"max_iterations": [original max],
|
|
127
|
+
"current_iteration": [where we stopped],
|
|
128
|
+
"checkpoint_interval": [N],
|
|
129
|
+
"loop_file": "[original loop file]",
|
|
130
|
+
"resumed_from_sabbath": true,
|
|
131
|
+
"resume_timestamp": "[now]"
|
|
132
|
+
}
|
|
133
|
+
EOF
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
### Step 6: Update Loop File
|
|
137
|
+
|
|
138
|
+
Add resume entry:
|
|
139
|
+
|
|
140
|
+
```markdown
|
|
141
|
+
## Sabbath Rest Resume
|
|
142
|
+
|
|
143
|
+
- **Resumed At:** [timestamp]
|
|
144
|
+
- **Previous Iteration:** [N]
|
|
145
|
+
- **Context:** Fresh (post-Sabbath Rest)
|
|
146
|
+
- **Sabbath File:** ${SABBATH_FILE}
|
|
147
|
+
|
|
148
|
+
### Restored Context Summary
|
|
149
|
+
[Key points from sabbath file]
|
|
150
|
+
|
|
151
|
+
---
|
|
152
|
+
|
|
153
|
+
## Loop Progress (Continued)
|
|
154
|
+
|
|
155
|
+
| Iteration | Timestamp | Action | Result | Context |
|
|
156
|
+
|-----------|-----------|--------|--------|---------|
|
|
157
|
+
| [N+1] | [now] | Resumed from Sabbath Rest | Fresh context | Fresh |
|
|
158
|
+
```
|
|
159
|
+
|
|
160
|
+
### Step 7: Update CONSCIENCE.md
|
|
161
|
+
|
|
162
|
+
```markdown
|
|
163
|
+
## Active Power Loop (Resumed)
|
|
164
|
+
|
|
165
|
+
- **ID:** ${LOOP_ID}
|
|
166
|
+
- **Resumed:** [timestamp]
|
|
167
|
+
- **Iteration:** [N] / [max] (continuing)
|
|
168
|
+
- **Status:** Running (fresh context)
|
|
169
|
+
- **Promise:** "[completion_promise]"
|
|
170
|
+
- **Context Health:** Fresh (post-Sabbath)
|
|
171
|
+
|
|
172
|
+
To cancel: `/fire-loop-stop`
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
### Step 8: Run /fire-discover (Optional)
|
|
176
|
+
|
|
177
|
+
If the loop was paused due to being stuck:
|
|
178
|
+
|
|
179
|
+
```
|
|
180
|
+
Would you like to run /fire-discover to find new patterns?
|
|
181
|
+
This may help if the loop was stuck before Sabbath Rest.
|
|
182
|
+
|
|
183
|
+
[Yes - run discovery] [No - continue with existing approach]
|
|
184
|
+
```
|
|
185
|
+
|
|
186
|
+
### Step 9: Display Resume Banner and Continue
|
|
187
|
+
|
|
188
|
+
```
|
|
189
|
+
+------------------------------------------------------------------------------+
|
|
190
|
+
| POWER LOOP RESUMED - ITERATION [N+1] |
|
|
191
|
+
+------------------------------------------------------------------------------+
|
|
192
|
+
| |
|
|
193
|
+
| Loop ID: ${LOOP_ID} |
|
|
194
|
+
| Continuing from: Iteration [N] |
|
|
195
|
+
| Remaining: [max - N] iterations |
|
|
196
|
+
| Context: FRESH |
|
|
197
|
+
| |
|
|
198
|
+
| Original Task: |
|
|
199
|
+
| [prompt] |
|
|
200
|
+
| |
|
|
201
|
+
| Completion Promise: "[promise]" |
|
|
202
|
+
| |
|
|
203
|
+
| Immediate Action: |
|
|
204
|
+
| [next step from sabbath file] |
|
|
205
|
+
| |
|
|
206
|
+
+------------------------------------------------------------------------------+
|
|
207
|
+
```
|
|
208
|
+
|
|
209
|
+
Then continue executing the task with fresh context.
|
|
210
|
+
|
|
211
|
+
---
|
|
212
|
+
|
|
213
|
+
## Edge Cases
|
|
214
|
+
|
|
215
|
+
### No Loops to Resume
|
|
216
|
+
|
|
217
|
+
```
|
|
218
|
+
+------------------------------------------------------------------------------+
|
|
219
|
+
| NO LOOPS TO RESUME |
|
|
220
|
+
+------------------------------------------------------------------------------+
|
|
221
|
+
| |
|
|
222
|
+
| No paused or stopped Power Loops found. |
|
|
223
|
+
| |
|
|
224
|
+
| To start a new loop: |
|
|
225
|
+
| /fire-loop "Your task" --max-iterations 30 |
|
|
226
|
+
| |
|
|
227
|
+
| To list all loop files: |
|
|
228
|
+
| ls .planning/loops/ |
|
|
229
|
+
| |
|
|
230
|
+
+------------------------------------------------------------------------------+
|
|
231
|
+
```
|
|
232
|
+
|
|
233
|
+
### Multiple Loops Available
|
|
234
|
+
|
|
235
|
+
```
|
|
236
|
+
+------------------------------------------------------------------------------+
|
|
237
|
+
| MULTIPLE LOOPS AVAILABLE |
|
|
238
|
+
+------------------------------------------------------------------------------+
|
|
239
|
+
| |
|
|
240
|
+
| Found multiple paused loops. Specify which to resume: |
|
|
241
|
+
| |
|
|
242
|
+
| 1. 20260123-143052 - "Fix auth bug" (iter 15/30, context_rot) |
|
|
243
|
+
| 2. 20260122-091530 - "Build API" (iter 8/50, user_stop) |
|
|
244
|
+
| 3. 20260121-162045 - "Refactor DB" (iter 22/40, session_end) |
|
|
245
|
+
| |
|
|
246
|
+
| Resume with: |
|
|
247
|
+
| /fire-loop-resume 20260123-143052 |
|
|
248
|
+
| |
|
|
249
|
+
+------------------------------------------------------------------------------+
|
|
250
|
+
```
|
|
251
|
+
|
|
252
|
+
---
|
|
253
|
+
|
|
254
|
+
## Success Criteria
|
|
255
|
+
|
|
256
|
+
- [ ] Sabbath Rest snapshot found and loaded
|
|
257
|
+
- [ ] Context fully restored from snapshot
|
|
258
|
+
- [ ] Active loop config recreated
|
|
259
|
+
- [ ] Loop file updated with resume entry
|
|
260
|
+
- [ ] CONSCIENCE.md updated
|
|
261
|
+
- [ ] Fresh context confirmed
|
|
262
|
+
- [ ] Loop continues from correct iteration
|
|
263
|
+
- [ ] Original prompt and promise preserved
|
|
264
|
+
|
|
265
|
+
---
|
|
266
|
+
|
|
267
|
+
## References
|
|
268
|
+
|
|
269
|
+
- **Related:** `/fire-loop` - Start new loop
|
|
270
|
+
- **Related:** `/fire-loop-stop` - Stop active loop
|
|
271
|
+
- **Related:** `/fire-discover` - Find patterns when stuck
|
|
272
|
+
- **Skills:** `@skills-library/methodology/SABBATH_REST_PATTERN.md`
|