| name | kata-add-phase |
| description | Add planned work discovered during execution to the end of the current milestone in the roadmap. This skill appends sequential phases to the current milestone's phase list, automatically calculating the next phase number. Triggers include "add phase", "append phase", "new phase", and "create phase". This skill updates ROADMAP.md and STATE.md accordingly. |
| metadata | {"version":"0.1.0"} |
Add a new integer phase to the end of the current milestone in the roadmap.
This command appends sequential phases to the current milestone's phase list, automatically calculating the next phase number based on existing phases.
Purpose: Add planned work discovered during execution that belongs at the end of current milestone.
IMPORTANT: When showing examples to users, always use /kata-add-phase (the command), not the skill name.
<execution_context>
@.planning/ROADMAP.md
@.planning/STATE.md
</execution_context>
Parse the command arguments:
With --issue flag:
/kata-add-phase --issue .planning/issues/open/2026-02-06-phase-lookup.md
- Read the issue file to extract title, provenance, and context
description = issue title from frontmatter
ISSUE_FILE = the path argument
ISSUE_PROVENANCE = provenance field from frontmatter (e.g., github:owner/repo#102)
ISSUE_NUMBER = extracted from provenance if GitHub-linked (e.g., 102)
if | grep -q ;
ISSUE_FILE=$( | sed )
[ ! -f ];
1
description=$(grep | -d -f2- | xargs)
ISSUE_PROVENANCE=$(grep | -d -f2)
ISSUE_NUMBER=
| grep -q ;
ISSUE_NUMBER=$( | grep -oE | -d )
**Pre-flight: Check roadmap format (auto-migration)**
Load the roadmap file:
Parse the roadmap to find the current milestone section:
Find the highest integer phase number in the current milestone:
Convert the phase description to a kebab-case slug:
Validate that the new phase follows vertical slicing principles:
Create the phase directory structure:
Add the new phase entry to the roadmap:
Update STATE.md to reflect the new phase:
Present completion summary: