kyro-ai 3.2.0 → 3.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/plugin.json +1 -1
- package/README.md +46 -39
- package/WORKFLOW.yaml +1 -1
- package/commands/forge.md +22 -44
- package/commands/status.md +21 -79
- package/commands/wrap-up.md +18 -74
- package/dist/cli/adapters/codex.js +3 -3
- package/dist/cli/adapters/codex.js.map +1 -1
- package/dist/cli/adapters/command-skills.js +1 -1
- package/dist/cli/adapters/command-skills.js.map +1 -1
- package/dist/cli/adapters/opencode.d.ts +0 -2
- package/dist/cli/adapters/opencode.d.ts.map +1 -1
- package/dist/cli/adapters/opencode.js +2 -10
- package/dist/cli/adapters/opencode.js.map +1 -1
- package/dist/cli/adapters/registry.d.ts.map +1 -1
- package/dist/cli/adapters/registry.js +3 -1
- package/dist/cli/adapters/registry.js.map +1 -1
- package/dist/cli/adapters/standard.d.ts +5 -0
- package/dist/cli/adapters/standard.d.ts.map +1 -0
- package/dist/cli/adapters/standard.js +41 -0
- package/dist/cli/adapters/standard.js.map +1 -0
- package/dist/cli/app.js +1 -1
- package/dist/cli/app.js.map +1 -1
- package/dist/cli/commands/doctor.d.ts +2 -1
- package/dist/cli/commands/doctor.d.ts.map +1 -1
- package/dist/cli/commands/doctor.js +27 -18
- package/dist/cli/commands/doctor.js.map +1 -1
- package/dist/cli/commands/install.d.ts.map +1 -1
- package/dist/cli/commands/install.js +8 -7
- package/dist/cli/commands/install.js.map +1 -1
- package/dist/cli/commands/token-audit.d.ts +3 -0
- package/dist/cli/commands/token-audit.d.ts.map +1 -0
- package/dist/cli/commands/token-audit.js +141 -0
- package/dist/cli/commands/token-audit.js.map +1 -0
- package/dist/cli/commands/tui.d.ts.map +1 -1
- package/dist/cli/commands/tui.js +10 -6
- package/dist/cli/commands/tui.js.map +1 -1
- package/dist/cli/commands/uninstall.d.ts.map +1 -1
- package/dist/cli/commands/uninstall.js +9 -9
- package/dist/cli/commands/uninstall.js.map +1 -1
- package/dist/cli/constants.d.ts +12 -7
- package/dist/cli/constants.d.ts.map +1 -1
- package/dist/cli/constants.js +13 -5
- package/dist/cli/constants.js.map +1 -1
- package/dist/cli/fs.d.ts +3 -0
- package/dist/cli/fs.d.ts.map +1 -1
- package/dist/cli/fs.js +30 -5
- package/dist/cli/fs.js.map +1 -1
- package/dist/cli/help.d.ts.map +1 -1
- package/dist/cli/help.js +6 -4
- package/dist/cli/help.js.map +1 -1
- package/dist/cli/install-plan.d.ts.map +1 -1
- package/dist/cli/install-plan.js +27 -20
- package/dist/cli/install-plan.js.map +1 -1
- package/dist/cli/options.d.ts.map +1 -1
- package/dist/cli/options.js +8 -1
- package/dist/cli/options.js.map +1 -1
- package/dist/cli/state.js +1 -1
- package/dist/cli/state.js.map +1 -1
- package/dist/cli/types.d.ts +4 -1
- package/dist/cli/types.d.ts.map +1 -1
- package/docs/HOW-TO-USE-CODEX.md +28 -60
- package/docs/HOW-TO-USE-OPENCODE.md +26 -72
- package/docs/agent-adapters.md +40 -118
- package/docs/architecture.md +7 -2
- package/docs/cli.md +93 -29
- package/docs/commands-reference.md +22 -32
- package/docs/getting-started.md +65 -115
- package/package.json +1 -1
- package/skills/sprint-forge/SKILL.md +9 -8
- package/skills/sprint-forge/assets/README.md +27 -17
- package/skills/sprint-forge/assets/helpers/metrics.md +4 -4
- package/skills/sprint-forge/assets/helpers/reentry-generator.md +4 -4
- package/skills/sprint-forge/assets/modes/INIT.md +68 -169
- package/skills/sprint-forge/assets/modes/SPRINT.md +20 -246
- package/skills/sprint-forge/assets/modes/STATUS.md +46 -128
- package/skills/sprint-forge/assets/modes/close-sprint.md +29 -0
- package/skills/sprint-forge/assets/modes/execute-task.md +26 -0
- package/skills/sprint-forge/assets/modes/plan-sprint.md +29 -0
- package/skills/sprint-forge/assets/modes/recover.md +23 -0
- package/skills/sprint-forge/assets/modes/review-task.md +25 -0
- package/skills/sprint-forge/assets/templates/DEBT.summary.json +12 -0
- package/skills/sprint-forge/assets/templates/ROADMAP.summary.json +15 -0
- package/skills/sprint-forge/assets/templates/SPRINT.summary.json +16 -0
- package/skills/sprint-forge/assets/templates/index.json +15 -0
- package/skills/sprint-forge/assets/templates/state.json +11 -0
|
@@ -1,204 +1,103 @@
|
|
|
1
|
-
# INIT Mode — Analysis, Roadmap &
|
|
1
|
+
# INIT Mode — Analysis, Roadmap & Scoped State
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Use INIT when a scope has no Kyro roadmap yet. INIT creates human-readable evidence plus structured routing files so future commands do not reread everything.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
## Inputs
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
- User request and current repository path.
|
|
8
|
+
- `.agents/kyro/kyro.json` if present.
|
|
9
|
+
- `../helpers/analysis-guide.md` for analysis strategy.
|
|
10
|
+
- Templates only when writing their artifact.
|
|
8
11
|
|
|
9
|
-
|
|
10
|
-
|-----------|-----------|
|
|
11
|
-
| "analyze", "audit", "start project", "create roadmap", "analyze codebase" | "analiza", "audita", "inicia proyecto", "crea roadmap", "analiza el codebase" |
|
|
12
|
+
## Step 1 — Resolve scope
|
|
12
13
|
|
|
13
|
-
|
|
14
|
+
Determine:
|
|
14
15
|
|
|
15
|
-
|
|
16
|
+
| Field | Rule |
|
|
17
|
+
|-------|------|
|
|
18
|
+
| scope | Short kebab-case work topic, not the repo name. |
|
|
19
|
+
| codebasePath | Usually current working directory. |
|
|
20
|
+
| outputDir | Default `.agents/kyro/scopes/{scope}/`. |
|
|
16
21
|
|
|
17
|
-
|
|
18
|
-
- No previous kyro-ai work for this project (if resuming, use SPRINT or STATUS mode)
|
|
22
|
+
If scope or output directory is ambiguous, ask once. Then create the scoped directory structure.
|
|
19
23
|
|
|
20
|
-
|
|
24
|
+
## Step 2 — Detect work type
|
|
21
25
|
|
|
22
|
-
|
|
26
|
+
Classify the request as audit/refactor, feature, bugfix, new project, or tech debt. If unclear, ask before analysis.
|
|
23
27
|
|
|
24
|
-
|
|
28
|
+
## Step 3 — Analyze
|
|
25
29
|
|
|
26
|
-
|
|
30
|
+
Use project search/read tools to inspect only what the work type requires:
|
|
27
31
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
| New Project | "start from scratch", "new project", "create project" |
|
|
34
|
-
| Tech Debt | "clean up", "deprecated", "reduce debt", "missing tests" |
|
|
32
|
+
- Audit/refactor: broad architecture and quality scan.
|
|
33
|
+
- Feature: integration points and missing behavior.
|
|
34
|
+
- Bugfix: reproduce, root cause, blast radius.
|
|
35
|
+
- New project: requirements and comparable patterns.
|
|
36
|
+
- Tech debt: debt indicators and cleanup targets.
|
|
35
37
|
|
|
36
|
-
|
|
38
|
+
Let evidence determine findings. Do not force a fixed category list.
|
|
37
39
|
|
|
38
|
-
|
|
40
|
+
## Step 4 — Write findings
|
|
39
41
|
|
|
40
|
-
|
|
42
|
+
Write each distinct finding to `{outputDir}/findings/NN-descriptive-slug.md`.
|
|
41
43
|
|
|
42
|
-
|
|
44
|
+
Each finding needs summary, severity, affected files, details, and recommendations. Use `analysis-guide.md` for the detailed format.
|
|
43
45
|
|
|
44
|
-
|
|
46
|
+
## Step 5 — Write roadmap
|
|
45
47
|
|
|
46
|
-
|
|
47
|
-
|--------|---------------|
|
|
48
|
-
| **Scope** | Ask the user. A short kebab-case name for the work topic (e.g., `oauth-implementation`, `ui-redesign`, `q2-growth`). NOT the repo name — the repo is already `{cwd}`. |
|
|
49
|
-
| **Codebase Path** | The absolute path to the codebase. Usually the current working directory. |
|
|
50
|
-
| **Sprint Output Dir** | `{output_kyro_dir}/phases/` (automatic, resolved below) |
|
|
48
|
+
Load `../templates/ROADMAP.md` only now. Write `{outputDir}/ROADMAP.md` with:
|
|
51
49
|
|
|
52
|
-
|
|
50
|
+
- project paths
|
|
51
|
+
- finding-to-sprint map
|
|
52
|
+
- sprint dependencies
|
|
53
|
+
- sprint title/focus/type/version target
|
|
54
|
+
- suggested phases
|
|
55
|
+
- sprint summary table
|
|
53
56
|
|
|
54
|
-
|
|
55
|
-
>
|
|
56
|
-
> 1. **Default** (Recommended) — `.agents/kyro/scopes/{scope}/`
|
|
57
|
-
> 2. **Custom path** — provide your preferred directory"
|
|
57
|
+
## Step 6 — Scaffold human artifacts
|
|
58
58
|
|
|
59
|
-
|
|
59
|
+
Load templates only when writing:
|
|
60
60
|
|
|
61
|
-
|
|
61
|
+
- `../templates/PROJECT-README.md` → `{outputDir}/README.md`
|
|
62
|
+
- `../templates/REENTRY-PROMPTS.md` → `{outputDir}/RE-ENTRY-PROMPTS.md`
|
|
62
63
|
|
|
63
|
-
|
|
64
|
-
> **Codebase**: `{codebase_path}`
|
|
65
|
-
> **Output**: `{output_kyro_dir}`
|
|
66
|
-
>
|
|
67
|
-
> Proceed with this configuration?
|
|
64
|
+
Create `{outputDir}/phases/` empty. Sprints are generated later.
|
|
68
65
|
|
|
69
|
-
|
|
66
|
+
## Step 7 — Write structured routing files
|
|
70
67
|
|
|
71
|
-
|
|
68
|
+
Create:
|
|
72
69
|
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
3. Use **Grep** to search for specific patterns
|
|
77
|
-
4. Use **Read** to examine specific files in detail
|
|
70
|
+
- `{outputDir}/state.json` from `../templates/state.json`
|
|
71
|
+
- `{outputDir}/index.json` from `../templates/index.json`
|
|
72
|
+
- `{outputDir}/ROADMAP.summary.json` from `../templates/ROADMAP.summary.json`
|
|
78
73
|
|
|
79
|
-
|
|
80
|
-
- **Audit/Refactor**: Explore the entire codebase. Every directory, every major file. Identify all areas of concern.
|
|
81
|
-
- **New Feature**: Focus on the integration points. Understand what exists and what gaps need filling.
|
|
82
|
-
- **Bugfix**: Trace the bug path. Reproduce, identify root cause, assess blast radius.
|
|
83
|
-
- **New Project**: Research requirements, comparable solutions, stack decisions.
|
|
84
|
-
- **Tech Debt**: Scan for debt indicators across the codebase.
|
|
74
|
+
Initial values:
|
|
85
75
|
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
**Location**: `{output_kyro_dir}/findings/`
|
|
95
|
-
|
|
96
|
-
**Naming**: `NN-descriptive-slug.md` (e.g., `01-architecture-issues.md`)
|
|
97
|
-
|
|
98
|
-
**Content per file**: YAML frontmatter properties (following the template in analysis-guide.md) + Summary, severity, details with code examples, affected files, recommendations.
|
|
99
|
-
|
|
100
|
-
**Number of findings**: VARIABLE. Determined entirely by what the analysis reveals:
|
|
101
|
-
- Small project: 2-4 findings
|
|
102
|
-
- Medium refactor: 5-8 findings
|
|
103
|
-
- Major audit: 10-20+ findings
|
|
104
|
-
|
|
105
|
-
**Reference**: See [analysis-guide.md](../helpers/analysis-guide.md) → Step 3 for the finding file format.
|
|
106
|
-
|
|
107
|
-
### Step 5 — Create Roadmap
|
|
108
|
-
|
|
109
|
-
Using the [ROADMAP.md template](../templates/ROADMAP.md), create the adaptive roadmap:
|
|
110
|
-
|
|
111
|
-
1. Fill in project paths (codebase, output dir, findings, phases)
|
|
112
|
-
2. Map each finding to a suggested sprint:
|
|
113
|
-
- Finding 01 → Sprint 1 (usually, but not always)
|
|
114
|
-
- Related findings may be grouped into a single sprint
|
|
115
|
-
- Large findings may be split across multiple sprints
|
|
116
|
-
3. Define sprint dependencies (which sprints must complete before others)
|
|
117
|
-
4. For each sprint, define:
|
|
118
|
-
- Title and focus
|
|
119
|
-
- Source finding file(s)
|
|
120
|
-
- Version target (if applicable)
|
|
121
|
-
- Type (audit/refactor/feature/bugfix/debt)
|
|
122
|
-
- Suggested phases (2-5 phases per sprint)
|
|
123
|
-
5. Fill in the Sprint Summary table
|
|
124
|
-
6. Write the dependency map
|
|
125
|
-
|
|
126
|
-
**Location**: `{output_kyro_dir}/ROADMAP.md`
|
|
127
|
-
|
|
128
|
-
### Step 6 — Scaffold Working Directory
|
|
129
|
-
|
|
130
|
-
Create the full directory structure:
|
|
131
|
-
|
|
132
|
-
```
|
|
133
|
-
{output_kyro_dir}/
|
|
134
|
-
├── README.md ← From PROJECT-README.md template
|
|
135
|
-
├── ROADMAP.md ← Created in Step 5
|
|
136
|
-
├── RE-ENTRY-PROMPTS.md ← Created in Step 7
|
|
137
|
-
├── findings/ ← Created in Step 4
|
|
138
|
-
│ ├── 01-*.md
|
|
139
|
-
│ ├── 02-*.md
|
|
140
|
-
│ └── ...
|
|
141
|
-
└── phases/ ← Empty directory, sprints created later
|
|
142
|
-
```
|
|
143
|
-
|
|
144
|
-
**README.md**: Use the [PROJECT-README.md template](../templates/PROJECT-README.md). Fill in the frontmatter properties with actual values, then fill in:
|
|
145
|
-
- Project name, type, date
|
|
146
|
-
- Description of the work
|
|
147
|
-
- All absolute paths
|
|
148
|
-
- Baseline metrics (if applicable)
|
|
149
|
-
- Initial sprint map from the roadmap
|
|
150
|
-
|
|
151
|
-
### Step 7 — Generate Re-entry Prompts
|
|
152
|
-
|
|
153
|
-
Using the [reentry-generator.md](../helpers/reentry-generator.md) helper:
|
|
154
|
-
|
|
155
|
-
1. Use the [REENTRY-PROMPTS.md template](../templates/REENTRY-PROMPTS.md)
|
|
156
|
-
2. Fill in all template variables with actual values:
|
|
157
|
-
- `{scope}`, `{codebase_path}`, `{output_kyro_dir}`
|
|
158
|
-
- `{current_sprint}` = 1 (no sprints yet)
|
|
159
|
-
- Sprint 1 finding file path
|
|
160
|
-
3. Generate all 4 scenario prompts with real paths
|
|
161
|
-
4. Write to `{output_kyro_dir}/RE-ENTRY-PROMPTS.md`
|
|
162
|
-
|
|
163
|
-
## Output Summary
|
|
164
|
-
|
|
165
|
-
At the end of INIT, present a summary:
|
|
166
|
-
|
|
167
|
-
```
|
|
168
|
-
## INIT Complete
|
|
169
|
-
|
|
170
|
-
**Scope**: {scope}
|
|
171
|
-
**Type**: {work_type}
|
|
172
|
-
**Findings**: {N} files in findings/
|
|
173
|
-
**Sprints Planned**: {M} sprints in roadmap
|
|
174
|
-
**Files Created**:
|
|
175
|
-
- {output_kyro_dir}/README.md
|
|
176
|
-
- {output_kyro_dir}/ROADMAP.md
|
|
177
|
-
- {output_kyro_dir}/RE-ENTRY-PROMPTS.md
|
|
178
|
-
- {output_kyro_dir}/findings/01-{slug}.md
|
|
179
|
-
- {output_kyro_dir}/findings/02-{slug}.md
|
|
180
|
-
- ...
|
|
181
|
-
|
|
182
|
-
**Next Step**: Generate Sprint 1 using `/kyro:forge` or copy the re-entry prompt from RE-ENTRY-PROMPTS.md → Scenario 1.
|
|
76
|
+
```json
|
|
77
|
+
{
|
|
78
|
+
"status": "planning",
|
|
79
|
+
"activeSprint": null,
|
|
80
|
+
"currentPhase": "init",
|
|
81
|
+
"nextAction": "plan_sprint"
|
|
82
|
+
}
|
|
183
83
|
```
|
|
184
84
|
|
|
185
|
-
|
|
85
|
+
Update `.agents/kyro/kyro.json` so `scopes` includes this scope and `activeScope` points to it when appropriate.
|
|
186
86
|
|
|
187
|
-
##
|
|
87
|
+
## Output
|
|
188
88
|
|
|
189
|
-
|
|
190
|
-
|-------|--------|
|
|
191
|
-
| Codebase path not found | Ask user for the correct path |
|
|
192
|
-
| Output directory already exists | Ask user: overwrite, use different name, or resume |
|
|
193
|
-
| No meaningful findings | Inform user — the codebase may be in good shape. Generate a minimal roadmap with maintenance sprints. |
|
|
194
|
-
| Analysis scope too large | Break into phases. Analyze the most critical areas first, note others as "needs deeper analysis" finding. |
|
|
89
|
+
Report:
|
|
195
90
|
|
|
196
|
-
|
|
91
|
+
- scope
|
|
92
|
+
- work type
|
|
93
|
+
- number of findings
|
|
94
|
+
- planned sprint count
|
|
95
|
+
- files created
|
|
96
|
+
- next action: run `kyro-forge` to plan Sprint 1
|
|
197
97
|
|
|
198
|
-
##
|
|
98
|
+
## Rules
|
|
199
99
|
|
|
200
|
-
-
|
|
201
|
-
-
|
|
202
|
-
-
|
|
203
|
-
-
|
|
204
|
-
- [reentry-generator.md](../helpers/reentry-generator.md) — How to generate re-entry prompts
|
|
100
|
+
- `kyro install` never creates scoped `state.json`; INIT does.
|
|
101
|
+
- Markdown is durable evidence; JSON is the fast routing index.
|
|
102
|
+
- Do not load sprint templates, debt tracker, or execution modes during INIT.
|
|
103
|
+
- If the output directory already exists, ask whether to resume or choose a different scope.
|
|
@@ -1,253 +1,27 @@
|
|
|
1
|
-
# SPRINT Mode —
|
|
1
|
+
# SPRINT Mode — Router
|
|
2
2
|
|
|
3
|
-
This
|
|
3
|
+
This file is the lightweight index for sprint work. Do not load the full sprint protocol upfront.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
## Route
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
| Need | Load |
|
|
8
|
+
|------|------|
|
|
9
|
+
| Generate the next sprint | `plan-sprint.md` |
|
|
10
|
+
| Execute pending sprint tasks | `execute-task.md` |
|
|
11
|
+
| Validate task or phase quality | `review-task.md` |
|
|
12
|
+
| Close sprint, retro, debt, roadmap, re-entry | `close-sprint.md` |
|
|
13
|
+
| Resume interrupted or inconsistent state | `recover.md` |
|
|
8
14
|
|
|
9
|
-
|
|
10
|
-
|-----------|-----------|
|
|
11
|
-
| "generate sprint", "next sprint", "execute sprint", "run sprint", "continue sprint" | "genera sprint", "siguiente sprint", "ejecuta sprint", "corre sprint", "continúa sprint" |
|
|
15
|
+
## Required read order
|
|
12
16
|
|
|
13
|
-
|
|
17
|
+
1. `.agents/kyro/scopes/{scope}/state.json`
|
|
18
|
+
2. `.agents/kyro/scopes/{scope}/index.json`
|
|
19
|
+
3. The routed mode file above
|
|
20
|
+
4. Only the helpers/templates named by that routed mode
|
|
14
21
|
|
|
15
|
-
##
|
|
16
|
-
|
|
17
|
-
| Sub-Mode | Trigger | What Happens |
|
|
18
|
-
|----------|---------|--------------|
|
|
19
|
-
| **GENERATE** | "generate", "create", default when sprint file doesn't exist | Creates the sprint document only |
|
|
20
|
-
| **EXECUTE** | "execute", "run", "implement", sprint file already exists | Implements tasks from an existing sprint |
|
|
21
|
-
| **GENERATE+EXECUTE** | "generate and execute", "do the next sprint" | Generates then immediately executes |
|
|
22
|
-
|
|
23
|
-
If ambiguous, ask:
|
|
24
|
-
|
|
25
|
-
> "Should I **generate** the sprint document, **execute** an existing sprint, or **both**?"
|
|
26
|
-
|
|
27
|
-
---
|
|
28
|
-
|
|
29
|
-
## GENERATE Workflow
|
|
30
|
-
|
|
31
|
-
### Step 0 — Locate Output Directory
|
|
32
|
-
|
|
33
|
-
Determine `{output_kyro_dir}` before reading any sprint files:
|
|
34
|
-
|
|
35
|
-
1. **Re-entry prompt paths** — If the user's message contains absolute file paths (e.g. `/Users/.../ROADMAP.md`), extract `{output_kyro_dir}` from those paths. This is the most reliable source.
|
|
36
|
-
2. **Explicit path** — If the user mentions a path directly, use it.
|
|
37
|
-
3. **Auto-discover** — Scan `{cwd}/.agents/kyro/scopes/`:
|
|
38
|
-
- Single directory found → use it
|
|
39
|
-
- Multiple directories → ask: "Which project? Found: {list}"
|
|
40
|
-
4. **Ask** — If none of the above: "Where are your kyro-ai documents? (e.g. `.agents/kyro/scopes/my-project/`)"
|
|
41
|
-
|
|
42
|
-
Once resolved, all subsequent steps use `{output_kyro_dir}` as the base for all file paths.
|
|
43
|
-
|
|
44
|
-
### Step 1 — Determine Sprint Number
|
|
45
|
-
|
|
46
|
-
1. Read `ROADMAP.md` to understand the planned sprints
|
|
47
|
-
2. Scan `phases/` directory for existing sprint files
|
|
48
|
-
3. The next sprint number = highest existing sprint + 1
|
|
49
|
-
4. If no sprints exist, start with Sprint 1
|
|
50
|
-
|
|
51
|
-
### Step 2 — Gather Inputs
|
|
52
|
-
|
|
53
|
-
Read the required inputs as defined in [sprint-generator.md](../helpers/sprint-generator.md):
|
|
54
|
-
|
|
55
|
-
1. **Roadmap section**: Open `ROADMAP.md`, locate Sprint {N} definition
|
|
56
|
-
- Extract: title, focus, type, version target, suggested phases
|
|
57
|
-
2. **Previous sprint** (Sprint 2+): Open `phases/SPRINT-{N-1}-*.md`
|
|
58
|
-
- Extract: Retro, Recommendations, Accumulated Debt Table
|
|
59
|
-
3. **Finding file(s)**: Open the finding file(s) mapped to this sprint in the roadmap
|
|
60
|
-
- Extract: summary, details, affected files, recommendations
|
|
61
|
-
|
|
62
|
-
### Step 3 — Build Disposition Table (Sprint 2+)
|
|
63
|
-
|
|
64
|
-
For every recommendation from Sprint N-1, determine what happens to it:
|
|
65
|
-
|
|
66
|
-
| # | Recommendation | Action | Where | Justification |
|
|
67
|
-
|---|---------------|--------|-------|---------------|
|
|
68
|
-
| 1 | {text from sprint N-1} | Incorporated | Phase 2, T2.3 | Directly addresses API consistency |
|
|
69
|
-
| 2 | {text from sprint N-1} | Deferred | Sprint 5 | Requires schema migration first |
|
|
70
|
-
| 3 | {text from sprint N-1} | N/A | — | Fixed by Sprint 2 emergent phase |
|
|
71
|
-
| 4 | {text from sprint N-1} | Converted to Phase | Phase 4 | Significant enough to warrant its own phase |
|
|
72
|
-
|
|
73
|
-
**Every recommendation MUST appear in this table.** No exceptions.
|
|
74
|
-
|
|
75
|
-
**Action options**: Incorporated, Deferred, Resolved, N/A, **Converted to Phase** (when a recommendation becomes an entire phase, not just a task).
|
|
76
|
-
|
|
77
|
-
**Reference**: See [sprint-generator.md](../helpers/sprint-generator.md) → Step 4 for action options.
|
|
78
|
-
|
|
79
|
-
### Step 4 — Build Phases
|
|
80
|
-
|
|
81
|
-
Assemble phases from three sources:
|
|
82
|
-
|
|
83
|
-
1. **Roadmap-suggested phases**: Starting point from the roadmap
|
|
84
|
-
2. **Recommendation phases**: Incorporated recommendations that need their own phase
|
|
85
|
-
3. **Debt phases**: Debt items targeting this sprint
|
|
86
|
-
|
|
87
|
-
For each phase:
|
|
88
|
-
- **Objective**: Clear statement of what the phase accomplishes
|
|
89
|
-
- **Tasks**: List with checkboxes, task IDs (T{phase}.{task}), descriptions, file paths, verification criteria
|
|
90
|
-
|
|
91
|
-
**Reference**: See [sprint-generator.md](../helpers/sprint-generator.md) → Step 5 for phase assembly rules.
|
|
92
|
-
|
|
93
|
-
### Step 5 — Assemble Sprint Document
|
|
94
|
-
|
|
95
|
-
Use the [SPRINT.md template](../templates/SPRINT.md):
|
|
96
|
-
|
|
97
|
-
1. Fill frontmatter properties with actual values (title, date, project, sprint number, previous/next doc links, related findings)
|
|
98
|
-
2. Fill metadata: source finding, previous sprint, version target, type, carry-over count
|
|
99
|
-
3. Write sprint objective
|
|
100
|
-
4. Write Disposition table (Sprint 2+)
|
|
101
|
-
5. Write phases with tasks
|
|
102
|
-
6. Copy debt table from previous sprint + add new items
|
|
103
|
-
7. Write Definition of Done
|
|
104
|
-
8. Leave Retro and Recommendations sections EMPTY
|
|
105
|
-
|
|
106
|
-
**Reference**: See [debt-tracker.md](../helpers/debt-tracker.md) for debt table rules.
|
|
107
|
-
|
|
108
|
-
### Step 6 — Write Sprint File
|
|
109
|
-
|
|
110
|
-
Save to: `{sprints_dir}/SPRINT-{N}-{slug}.md`
|
|
111
|
-
|
|
112
|
-
The slug is derived from the sprint's focus area (e.g., `architecture-cleanup`, `api-consistency`).
|
|
113
|
-
|
|
114
|
-
---
|
|
115
|
-
|
|
116
|
-
## EXECUTE Workflow
|
|
117
|
-
|
|
118
|
-
### Step 7 — Read Sprint
|
|
119
|
-
|
|
120
|
-
Load the sprint file to execute. Verify it has:
|
|
121
|
-
- Phases with tasks
|
|
122
|
-
- Debt table
|
|
123
|
-
- Definition of Done
|
|
124
|
-
|
|
125
|
-
**Fill execution metadata**: Set `Execution Date` to today's date and `Executed By` to the executor's name in the sprint header. Also update the frontmatter `updated` field to today's date. These fields track who executed the sprint and when.
|
|
126
|
-
|
|
127
|
-
### Step 8 — Execute Task by Task
|
|
128
|
-
|
|
129
|
-
For each task in each phase:
|
|
130
|
-
|
|
131
|
-
1. **Mark in-progress**: Change `[ ]` to `[~]`
|
|
132
|
-
2. **Do the work**:
|
|
133
|
-
- Read relevant files
|
|
134
|
-
- Write/modify code as needed
|
|
135
|
-
- Run verification commands
|
|
136
|
-
- Test changes
|
|
137
|
-
3. **Mark done**: Change `[~]` to `[x]`
|
|
138
|
-
4. **Or mark blocked**: Change `[~]` to `[!]` with explanation
|
|
139
|
-
5. **Or mark carry-over**: Change `[~]` to `[>]` — when a task cannot be completed in this sprint but is not blocked. It will be carried over to the next sprint.
|
|
140
|
-
|
|
141
|
-
**Document evidence inline**: For each task, fill the `Evidence` field with concrete proof of work — trace logs, before/after snapshots, tables of affected items, verification marks. Evidence is not optional; it makes the sprint auditable.
|
|
142
|
-
|
|
143
|
-
**Execution order**: Process phases in order (Phase 1 → Phase 2 → ...). Within a phase, process tasks in order unless dependencies require different ordering.
|
|
144
|
-
|
|
145
|
-
**Persistence rule — checkpoint per phase**: After completing all tasks in a phase, write the sprint file to disk with all status updates (`[x]`, `[!]`, `[>]`) and evidence for that phase. This ensures progress survives unexpected interruptions (agent crash, session timeout, context overflow) without disrupting task-to-task flow within a phase. Do NOT write the file after every individual task — that fragments the agent's focus and wastes I/O. Do NOT defer all writes to sprint close — that risks losing all progress tracking on failure.
|
|
146
|
-
|
|
147
|
-
**Code quality**: Write production-quality code. Follow existing project patterns. Do not introduce new patterns without justification.
|
|
148
|
-
|
|
149
|
-
### Step 9 — Handle Emergent Work
|
|
150
|
-
|
|
151
|
-
During execution, you may discover work not covered by the plan. This is expected.
|
|
152
|
-
|
|
153
|
-
**When to add an Emergent Phase**:
|
|
154
|
-
- Found a bug that must be fixed before continuing
|
|
155
|
-
- Discovered a dependency that was not in the analysis
|
|
156
|
-
- A task reveals additional scope that cannot be deferred
|
|
157
|
-
|
|
158
|
-
**How to add**:
|
|
159
|
-
1. Add an "Emergent Phase" section in the sprint document (after planned phases)
|
|
160
|
-
2. Include: phase name, reason for emergence, tasks with IDs (TE.1, TE.2, ...)
|
|
161
|
-
3. Update Definition of Done to include emergent tasks
|
|
162
|
-
|
|
163
|
-
**Rule**: Do not add emergent phases for nice-to-haves. Only for work that is necessary to meet the sprint objective or that would create debt if deferred.
|
|
164
|
-
|
|
165
|
-
### Step 10 — Close Sprint
|
|
166
|
-
|
|
167
|
-
When all tasks are done (or explicitly skipped/blocked/carried-over):
|
|
168
|
-
|
|
169
|
-
**10a. Consolidate Findings**: Before filling the retro, complete the **Findings Consolidation** table. Review all phases (planned and emergent) and list every significant discovery with its origin, impact, and action taken. This creates an auditable trail of what was learned.
|
|
170
|
-
|
|
171
|
-
1. **Fill Retro section**:
|
|
172
|
-
- What Went Well: Things that worked as expected or better
|
|
173
|
-
- What Didn't Go Well: Challenges, blockers, things that took longer
|
|
174
|
-
- Surprises: Unexpected findings or outcomes
|
|
175
|
-
- **New Technical Debt Detected**: List new debt items discovered during execution, referencing their D{n} numbers from the Accumulated Debt table
|
|
176
|
-
|
|
177
|
-
2. **Fill Recommendations for Sprint N+1**:
|
|
178
|
-
- Numbered list of specific, actionable recommendations
|
|
179
|
-
- These become formal input for the next sprint's Disposition table
|
|
180
|
-
- Include both technical and process recommendations
|
|
181
|
-
|
|
182
|
-
3. **Update Debt Table**:
|
|
183
|
-
- Mark resolved items: Status → `resolved`, fill "Resolved In"
|
|
184
|
-
- Add new items discovered during execution
|
|
185
|
-
- Update deferred items if timelines changed
|
|
186
|
-
- Follow all rules from [debt-tracker.md](../helpers/debt-tracker.md)
|
|
187
|
-
|
|
188
|
-
4. **Update Frontmatter**:
|
|
189
|
-
- Set `updated` to today's date
|
|
190
|
-
- Set `status` to `"completed"` (or `"active"` if carry-overs exist)
|
|
191
|
-
- Set `progress` to final completion percentage (0-100)
|
|
192
|
-
- Append changelog entry: `{"version": "1.1", "date": "{today}", "changes": ["Sprint completed"]}`
|
|
193
|
-
|
|
194
|
-
5. **Verify Definition of Done**:
|
|
195
|
-
- Check every DoD item
|
|
196
|
-
- Mark as complete or document why it's not
|
|
197
|
-
|
|
198
|
-
### Step 11 — Update Re-entry Prompts
|
|
199
|
-
|
|
200
|
-
After sprint execution:
|
|
201
|
-
|
|
202
|
-
1. Open `{output_kyro_dir}/RE-ENTRY-PROMPTS.md`
|
|
203
|
-
2. Update current sprint number
|
|
204
|
-
3. Update file references (last sprint, next finding)
|
|
205
|
-
4. Update Quick Reference table with new sprint status
|
|
206
|
-
5. Update "Last updated" date
|
|
207
|
-
|
|
208
|
-
**Reference**: See [reentry-generator.md](../helpers/reentry-generator.md) for update rules.
|
|
209
|
-
|
|
210
|
-
### Step 12 — Update Roadmap (If Needed)
|
|
211
|
-
|
|
212
|
-
If execution revealed that the roadmap needs adjustment:
|
|
213
|
-
|
|
214
|
-
- A planned sprint no longer makes sense → remove or modify it
|
|
215
|
-
- A new sprint is needed → add it to the roadmap
|
|
216
|
-
- Sprint dependencies changed → update the dependency map
|
|
217
|
-
- Phase suggestions for future sprints should change → update them
|
|
218
|
-
|
|
219
|
-
**This is the ADAPTIVE principle**: The roadmap serves execution, not the reverse.
|
|
220
|
-
|
|
221
|
-
---
|
|
222
|
-
|
|
223
|
-
## Critical Rules for Sprint Mode
|
|
224
|
-
|
|
225
|
-
1. **One sprint at a time** — NEVER generate Sprint N+1 before Sprint N is complete
|
|
226
|
-
2. **Disposition is mandatory** — Every recommendation from Sprint N-1 must be in the Disposition table
|
|
227
|
-
3. **Emergent phases are welcome** — But only for necessary work, not nice-to-haves
|
|
228
|
-
4. **Debt table is inherited completely** — Never drop items, never reset the table
|
|
229
|
-
5. **Re-entry prompts must be updated** — Every sprint execution ends with a prompt update
|
|
230
|
-
6. **Retro is honest** — Don't sugarcoat. Document real challenges and surprises.
|
|
231
|
-
7. **Recommendations are specific** — "Improve tests" is not a recommendation. "Add unit tests for the auth middleware error paths in auth.ts:45-80" is.
|
|
232
|
-
|
|
233
|
-
---
|
|
234
|
-
|
|
235
|
-
## Error Handling
|
|
236
|
-
|
|
237
|
-
| Error | Action |
|
|
238
|
-
|-------|--------|
|
|
239
|
-
| No roadmap found | INIT mode must be run first. Inform user. |
|
|
240
|
-
| Previous sprint not found | Check if sprint numbering is correct. If Sprint 1, this is expected. |
|
|
241
|
-
| Finding file not found | Check roadmap mapping. The file may have been renamed or the mapping may be wrong. |
|
|
242
|
-
| All tasks blocked | Document blockers in retro, close sprint as incomplete, recommend resolution in Sprint N+1. |
|
|
243
|
-
| Sprint file already exists | Ask user: overwrite, resume execution, or skip to next sprint. |
|
|
244
|
-
|
|
245
|
-
---
|
|
246
|
-
|
|
247
|
-
## References
|
|
248
|
-
|
|
249
|
-
- [sprint-generator.md](../helpers/sprint-generator.md) — Sprint generation algorithm
|
|
250
|
-
- [debt-tracker.md](../helpers/debt-tracker.md) — Debt table rules
|
|
251
|
-
- [reentry-generator.md](../helpers/reentry-generator.md) — Re-entry prompt updates
|
|
252
|
-
- [SPRINT.md template](../templates/SPRINT.md) — Sprint document structure
|
|
22
|
+
## Invariants
|
|
253
23
|
|
|
24
|
+
- One sprint at a time.
|
|
25
|
+
- Previous retro, recommendations, and debt feed the next sprint.
|
|
26
|
+
- Checkpoint after each phase, not every task.
|
|
27
|
+
- Markdown remains evidence; JSON summaries are the routing index.
|