You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: sprint planning with skills (/refine-story, /plan-tasks, /write-issue).
Story Statement
As a product engineer planning sprint work with AI assistance I want to invoke /refine-story and /plan-tasks which compose /write-issue for PM tool integration, with how-to-08 and how-to-09 thinned to orchestrators So that story refinement and task breakdown follow a structured process that produces properly formatted issues in the adopted PM tool
Given a user story in Todo state When/refine-story is invoked in Claude Code Then the skill follows the refinement process: story selection → requirements analysis (Given-When-Then) → technical analysis → sprint readiness → documentation, producing a refined story in the adopted PM tool format
Given/refine-story is invoked on a story that is already partially refined (e.g. Given-When-Then written but technical analysis missing) When the skill evaluates each refinement step Then it detects already-completed sections, skips them, and resumes from the first missing section (idempotent execution)
Given/refine-story is invoked on a story already in Refined state When the skill detects the story is already refined Then it offers to update specific sections rather than re-doing the entire refinement
Given a refined user story When/plan-tasks is invoked Then the skill follows the task breakdown process: story analysis → task identification → task definition → documentation using the task template, creating tasks via /write-issue
Given/plan-tasks is invoked on a story where some tasks already exist When the skill evaluates the task list Then it detects existing tasks, skips them, and creates only missing tasks (idempotent execution)
Given/write-issue is invoked with $type: story and story content, without $id When the skill executes Then it reads user-story-template.md, formats the issue body following that template structure, and creates a new issue in the adopted PM tool with proper labels, hierarchy linking (epic → story), and project field configuration
Given/write-issue is invoked with $type: story, story content, and $id: 42 When the skill executes Then it reads user-story-template.md, formats the issue body following that template structure, and updates the existing issue chore(test): manual tag smoke #42 in the adopted PM tool
Given/write-issue is invoked with $type: task and task content, without $id When the skill executes Then it reads task-template.md, formats the issue body following that template structure, and creates a new issue in the adopted PM tool with proper labels, hierarchy linking (story → task), and project field configuration
Given/write-issue is invoked with $type: task, task content, and $id: 55 When the skill executes Then it reads task-template.md, formats the issue body following that template structure, and updates the existing issue chore: release v0.1.0 #55 in the adopted PM tool
Given how-to-08 and how-to-09 are thinned When a non-skill assistant reads either file Then both remain readable with phase flows, HALT conditions, and selection criteria — just without procedural details
Given/write-issue is invoked independently (not via /refine-story or /plan-tasks) When called with $type, $content, and optionally $id and $parent Then it reads the corresponding template, formats the issue body accordingly, and creates (no $id) or updates ($id provided) the issue in the adopted PM tool
Business Rules
Idempotent execution (cross-cutting, applies to ALL skills): every step in a skill MUST check current state before acting, and only execute missing actions. Re-invoking a skill on a partially completed workflow resumes from where it left off — never re-does already completed work.
Template-driven formatting: /write-issue MUST read and apply the type-specific template for every issue it creates or updates:
$type: story → reads collaboration/templates/user-story-template.md
The template defines the issue body structure — /write-issue fills it with the provided content
Create vs Update via $id: /write-issue behavior is determined by the $id argument:
$id absent → create new issue in PM tool
$id present → update existing issue identified by $id
Skills that compose /write-issue (e.g. /refine-story, /plan-tasks) are responsible for passing $id when updating an existing issue
PM tool agnostic: /write-issue uses ONLY the PM tool specified in adoption (adoption/tech/way-of-working.md). There is NO fallback to a different tool. If the adopted PM tool is unavailable or encounters errors, /write-issue HALTs with an error and reports the issue to the developer — it does NOT silently switch to an alternative tool.
Extensible by design: in this story /write-issue supports story and task types. Support for epic and initiative types (with their own templates) is added in #103 when the strategic planning skills need them.
/write-issue is a single skill handling multiple issue types — target type passed as argument
Adoption binding: /write-issue reads adoption/tech/way-of-working.md for PM tool choice
Templates (user-story-template.md, task-template.md) are consumed BY skills, not modified
Edge Cases and Error Handling
PM tool not configured: /write-issue HALTs and asks developer to configure via /setup-pm or manually set way-of-working.md
Story not refined: /plan-tasks HALTs — requires refined story as input
PM tool error: /write-issue HALTs with an error describing the problem (e.g. API unavailable, authentication failure, rate limit). No fallback to a different tool — the developer must resolve the issue with the adopted PM tool.
Story already refined: /refine-story detects Refined state, offers selective update
dataset/.skills/process/refine-story/SKILL.md created with idempotent section-level checks
dataset/.skills/process/plan-tasks/SKILL.md created with idempotent task-level checks
dataset/.skills/capability/write-issue/SKILL.md created with PM tool abstraction, template-driven formatting, $id for create/update, extensible type system, no tool fallback
/write-issue reads and applies user-story-template.md for story issues
/write-issue reads and applies task-template.md for task issues
/write-issue creates (no $id) or updates ($id provided) correctly
/write-issue HALTs on PM tool errors with descriptive message (no fallback)
/write-issue returns issue identifier after create (for compose chains)
Final Story Points: L(5) Confidence Level: High Sizing Justification: 3 SKILL.md + 2 how-to thinnings + idempotency (section-level, task-level, issue-level). /write-issue is the most complex atomic skill (PM tool abstraction + template-driven formatting + create/update via $id + no fallback error handling) but content is well-defined in existing PM tool implementation guides and templates.
/write-issue template-driven: reads the template, parses its structure, fills with content. Template = the source of truth for issue body format.
Create vs Update: determined by $id argument — absent = create, present = update. No ambiguous title matching. Callers (e.g. /refine-story, /plan-tasks) pass $id when updating.
/refine-story transition: skill handles template switching from Initial Breakdown to Refined format
Idempotency: /refine-story checks sections, /plan-tasks checks existing tasks, /write-issue uses explicit $id for updates. All follow check→skip→act→verify pattern.
No PM tool fallback: /write-issue uses ONLY the adopted PM tool. On error, it HALTs with a descriptive message — the developer resolves the issue, then re-invokes (idempotent).
Completes Circle 1 (sprint cycle). After #98-#101, daily development workflow fully covered by skills.
Write 3 SKILL.md files. Thin 2 how-to files. /write-issue introduces PM tool abstraction — reads adoption for tool choice, reads type-specific template for formatting. No fallback between tools. Designed for extensibility: adding new types (epic, initiative in #103) means adding template references, not restructuring. All skills follow check→skip→act→verify idempotency pattern from #99.
/write-issue Flow
Read $type argument → validate supported type → select template
Summary: Create /refine-story process skill with section-level idempotency and template reordering.
Type: Documentation
Description: Section-level idempotency: selection → requirements (Given-When-Then) → technical analysis → sprint readiness → documentation. Detects partial refinement, resumes from missing section. Already-refined → offers selective update (passes $id to /write-issue). Composes /write-issue ($type: story). Template reordering: user story body has functional sections first (Story Statement → Epic Context → AC → DoD → Sizing → Dependencies → Validation → Notes), then technical sections last (Technical Analysis → Task Breakdown). Update collaboration/templates/user-story-template.md to reflect functional-first/technical-last ordering. Update collaboration/templates/task-template.md to formalize Dependency Graph and AC Coverage in the Task Breakdown Format for Story Body section.
Acceptance Criteria:
Primary deliverable: SKILL.md with valid frontmatter; section-level idempotency
packages/knowledge-hub/dataset/.pair/knowledge/guidelines/collaboration/templates/task-template.md — add Dependency Graph + AC Coverage to Task Breakdown Format
Summary: Create /plan-tasks process skill with task-level idempotency and integrated technical section format.
Type: Documentation
Description: Task-level idempotency: story analysis → task identification → task definition → documentation via /write-issue. Detects existing tasks, creates only missing ones ($type: task, no $id). Updates existing via $id. Coverage validation: all ACs mapped to tasks. Composes /write-issue. Integrated Technical Analysis + Task Breakdown format: Technical Analysis and Task Breakdown are the last content sections in the story body (after Notes, before footer). When appending, condenses Technical Analysis (keeps strategy summary, data flow/pipeline order, risks), then appends: task checklist → Dependency Graph (ASCII block showing task dependencies) → AC Coverage table (maps each AC to covering tasks) → detailed tasks.
Acceptance Criteria:
Primary deliverable: SKILL.md with valid frontmatter; task-level idempotency
Technical Design: Task checklist with check→skip→act→verify, /write-issue composition, TA condensation
Bounded Context & Modules: Knowledge Base Management — dataset/.skills/process/
Files to Modify/Create:
dataset/.skills/process/plan-tasks/SKILL.md — new process skill
packages/knowledge-hub/dataset/.pair/knowledge/guidelines/collaboration/templates/task-template.md — formalize Dependency Graph + AC Coverage in Task Breakdown Format
Summary: End-to-end validation of all skills and thinned how-to-08/how-to-09 in Claude Code.
Type: Testing
Description: Validate: /refine-story on Todo story (full refinement); re-invoke partial (resumes); already-refined (offers update); /plan-tasks on refined story (creates tasks); re-invoke with existing tasks (creates only missing); /write-issue independently (create + update for both story and task types); PM tool error → HALT; thinned how-to-08 and how-to-09 standalone readability.
Acceptance Criteria:
Primary deliverable: All skills invocable and producing correct output
Resolution
Delivered by PR #110 (merged). Board: Done.
feat: sprint planning with skills (/refine-story, /plan-tasks, /write-issue).
Story Statement
As a product engineer planning sprint work with AI assistance
I want to invoke
/refine-storyand/plan-taskswhich compose/write-issuefor PM tool integration, withhow-to-08andhow-to-09thinned to orchestratorsSo that story refinement and task breakdown follow a structured process that produces properly formatted issues in the adopted PM tool
Where:
dataset/.skills/process/refine-story/,dataset/.skills/process/plan-tasks/,dataset/.skills/capability/write-issue/,.pair/knowledge/how-to/08-how-to-refine-a-user-story.md,.pair/knowledge/how-to/09-how-to-create-tasks.mdEpic Context
Parent Epic: Agent Skills in Knowledge Base #97
Status: Refined
Priority: P0 (Must-Have)
Acceptance Criteria
Functional Requirements
Given a user story in Todo state
When
/refine-storyis invoked in Claude CodeThen the skill follows the refinement process: story selection → requirements analysis (Given-When-Then) → technical analysis → sprint readiness → documentation, producing a refined story in the adopted PM tool format
Given
/refine-storyis invoked on a story that is already partially refined (e.g. Given-When-Then written but technical analysis missing)When the skill evaluates each refinement step
Then it detects already-completed sections, skips them, and resumes from the first missing section (idempotent execution)
Given
/refine-storyis invoked on a story already in Refined stateWhen the skill detects the story is already refined
Then it offers to update specific sections rather than re-doing the entire refinement
Given a refined user story
When
/plan-tasksis invokedThen the skill follows the task breakdown process: story analysis → task identification → task definition → documentation using the task template, creating tasks via
/write-issueGiven
/plan-tasksis invoked on a story where some tasks already existWhen the skill evaluates the task list
Then it detects existing tasks, skips them, and creates only missing tasks (idempotent execution)
Given
/write-issueis invoked with$type: storyand story content, without$idWhen the skill executes
Then it reads
user-story-template.md, formats the issue body following that template structure, and creates a new issue in the adopted PM tool with proper labels, hierarchy linking (epic → story), and project field configurationGiven
/write-issueis invoked with$type: story, story content, and$id: 42When the skill executes
Then it reads
user-story-template.md, formats the issue body following that template structure, and updates the existing issue chore(test): manual tag smoke #42 in the adopted PM toolGiven
/write-issueis invoked with$type: taskand task content, without$idWhen the skill executes
Then it reads
task-template.md, formats the issue body following that template structure, and creates a new issue in the adopted PM tool with proper labels, hierarchy linking (story → task), and project field configurationGiven
/write-issueis invoked with$type: task, task content, and$id: 55When the skill executes
Then it reads
task-template.md, formats the issue body following that template structure, and updates the existing issue chore: release v0.1.0 #55 in the adopted PM toolGiven how-to-08 and how-to-09 are thinned
When a non-skill assistant reads either file
Then both remain readable with phase flows, HALT conditions, and selection criteria — just without procedural details
Given
/write-issueis invoked independently (not via /refine-story or /plan-tasks)When called with
$type,$content, and optionally$idand$parentThen it reads the corresponding template, formats the issue body accordingly, and creates (no
$id) or updates ($idprovided) the issue in the adopted PM toolBusiness Rules
$type: story→ readscollaboration/templates/user-story-template.md$type: task→ readscollaboration/templates/task-template.md$id: /write-issue behavior is determined by the$idargument:$idabsent → create new issue in PM tool$idpresent → update existing issue identified by$id$idwhen updating an existing issueadoption/tech/way-of-working.md). There is NO fallback to a different tool. If the adopted PM tool is unavailable or encounters errors, /write-issue HALTs with an error and reports the issue to the developer — it does NOT silently switch to an alternative tool.storyandtasktypes. Support forepicandinitiativetypes (with their own templates) is added in #103 when the strategic planning skills need them.adoption/tech/way-of-working.mdfor PM tool choiceuser-story-template.md,task-template.md) are consumed BY skills, not modifiedEdge Cases and Error Handling
/setup-pmor manually setway-of-working.md$idprovided but issue not found: /write-issue HALTs with error "issue #N not found"$type: /write-issue HALTs with error listing currently supported types (story/task in this story; epic/initiative added in Strategic planning process skills (/plan-initiatives through /plan-stories) #103)Definition of Done Checklist
Development Completion
dataset/.skills/process/refine-story/SKILL.mdcreated with idempotent section-level checksdataset/.skills/process/plan-tasks/SKILL.mdcreated with idempotent task-level checksdataset/.skills/capability/write-issue/SKILL.mdcreated with PM tool abstraction, template-driven formatting,$idfor create/update, extensible type system, no tool fallbackuser-story-template.mdfor story issuestask-template.mdfor task issues$id) or updates ($idprovided) correctlyhow-to-08thinned to ~120 lines (orchestration only)how-to-09thinned to ~140 lines (orchestration only)Quality Assurance
/refine-storyinvocable in Claude Code — produces refined story/refine-storyre-invoked on partially refined story — completes only missing sections/refine-storyon already-refined story — offers selective update (passes$idto /write-issue)/plan-tasksinvocable in Claude Code — produces task breakdown/plan-tasksre-invoked with some tasks existing — creates only missing tasks/write-issuecreate mode (no$id) — creates issue, body follows template structure/write-issueupdate mode ($idprovided) — updates existing issue, body follows template structure/write-issuewith$idfor non-existent issue — HALTs with clear error/write-issueon PM tool error — HALTs with descriptive error, no fallback/write-issueinvocable independently — creates or updates issue in adopted PM toolStory Sizing and Sprint Readiness
Refined Story Points
Final Story Points: L(5)
Confidence Level: High
Sizing Justification: 3 SKILL.md + 2 how-to thinnings + idempotency (section-level, task-level, issue-level). /write-issue is the most complex atomic skill (PM tool abstraction + template-driven formatting + create/update via
$id+ no fallback error handling) but content is well-defined in existing PM tool implementation guides and templates.Sprint Fit Assessment
Sprint Fit: Yes — single sprint
Development Estimate: 3 days (3 skills + 2 how-to thinnings)
Testing Estimate: 1 day (Claude Code + PM tool modes + template validation + create/update tests + error handling tests + re-invocation tests + standalone readability)
Dependencies and Coordination
Story Dependencies
Prerequisite Stories: #98 (skill infrastructure)
Dependent Stories: #103 (extends /write-issue with epic + initiative types)
Validation and Testing Strategy
Acceptance Testing
/refine-storywith a sample Todo story → verify refinement process/refine-storyon partially refined story → verify resumes from missing section/refine-storyon already-refined story → verify offers update, passes$id/plan-taskswith a refined story → verify task breakdown, new tasks via /write-issue (no$id)/plan-taskswith some tasks existing → verify creates only missing tasks/write-issuewith$type: story, no$id→ verify creates issue, body matches user-story-template.md/write-issuewith$type: story,$id: 42→ verify updates issue chore(test): manual tag smoke #42, body matches template/write-issuewith$type: task, no$id→ verify creates issue, body matches task-template.md/write-issuewith$type: task,$id: 55→ verify updates issue chore: release v0.1.0 #55/write-issuewith$idfor non-existent issue → verify HALT with errorNotes
Open questions resolved:
$typeargument, reads the type-specific template file$idargument — absent = create, present = update. No ambiguous title matching. Callers (e.g. /refine-story, /plan-tasks) pass$idwhen updating.$idfor updates. All follow check→skip→act→verify pattern.Completes Circle 1 (sprint cycle). After #98-#101, daily development workflow fully covered by skills.
Design reference:
docs/design/skills-in-knowledge-base.mdsections 1, 2, 3, composition patternTechnical Analysis
Strategy
Write 3 SKILL.md files. Thin 2 how-to files. /write-issue introduces PM tool abstraction — reads adoption for tool choice, reads type-specific template for formatting. No fallback between tools. Designed for extensibility: adding new types (epic, initiative in #103) means adding template references, not restructuring. All skills follow check→skip→act→verify idempotency pattern from #99.
/write-issue Flow
$typeargument → validate supported type → select template$contentdata$idprovided → update existing issue; if absent → create new issueIdempotency per Skill
$idto /write-issue.$id). Updates existing via$id.$idabsent = create,$idpresent = update.Technical Risks
Task Breakdown
Dependency Graph
AC Coverage
T-1: Create /write-issue SKILL.md (capability skill)
Priority: P0 | Estimated Hours: 5h | Bounded Context: Knowledge Base Management
Summary: Create
/write-issueatomic capability skill with PM tool abstraction and template-driven formatting.Type: Documentation
Description: PM tool abstraction: reads
adoption/tech/way-of-working.mdfor tool choice, reads type-specific template ($type: story→user-story-template.md,$type: task→task-template.md), formats body, creates (no$id) or updates ($idprovided). No PM tool fallback — HALT on error. Extensible: epic/initiative types added in #103. Arguments:$type(required),$content(required),$id(optional),$parent(optional). Returns issue identifier for compose chains. Referencescollaboration/project-management-tool/github-implementation.mdorfilesystem-implementation.mdfor tool-specific behavior.Acceptance Criteria:
Technical Requirements:
$id, HALT on errorImplementation Approach:
dataset/.skills/capability/dataset/.skills/capability/write-issue/SKILL.md— new capability skillDependencies:
Implementation Steps:
dataset/.skills/capability/write-issue/Testing Strategy:
Notes: Most complex atomic skill. Designed for extensibility — epic/initiative added in #103 by adding template references.
T-2: Create /refine-story SKILL.md (process skill)
Priority: P0 | Estimated Hours: 4h | Bounded Context: Knowledge Base Management
Summary: Create
/refine-storyprocess skill with section-level idempotency and template reordering.Type: Documentation
Description: Section-level idempotency: selection → requirements (Given-When-Then) → technical analysis → sprint readiness → documentation. Detects partial refinement, resumes from missing section. Already-refined → offers selective update (passes
$idto /write-issue). Composes /write-issue ($type: story). Template reordering: user story body has functional sections first (Story Statement → Epic Context → AC → DoD → Sizing → Dependencies → Validation → Notes), then technical sections last (Technical Analysis → Task Breakdown). Updatecollaboration/templates/user-story-template.mdto reflect functional-first/technical-last ordering. Updatecollaboration/templates/task-template.mdto formalize Dependency Graph and AC Coverage in the Task Breakdown Format for Story Body section.Acceptance Criteria:
Technical Requirements:
Implementation Approach:
dataset/.skills/process/dataset/.skills/process/refine-story/SKILL.md— new process skillpackages/knowledge-hub/dataset/.pair/knowledge/guidelines/collaboration/templates/user-story-template.md— functional-first/technical-last orderingpackages/knowledge-hub/dataset/.pair/knowledge/guidelines/collaboration/templates/task-template.md— add Dependency Graph + AC Coverage to Task Breakdown FormatDependencies:
Implementation Steps:
dataset/.skills/process/refine-story/Testing Strategy:
Notes: Template reordering positions Technical Analysis as bridge to Task Breakdown.
T-3: Create /plan-tasks SKILL.md (process skill)
Priority: P0 | Estimated Hours: 4h | Bounded Context: Knowledge Base Management
Summary: Create
/plan-tasksprocess skill with task-level idempotency and integrated technical section format.Type: Documentation
Description: Task-level idempotency: story analysis → task identification → task definition → documentation via /write-issue. Detects existing tasks, creates only missing ones (
$type: task, no$id). Updates existing via$id. Coverage validation: all ACs mapped to tasks. Composes /write-issue. Integrated Technical Analysis + Task Breakdown format: Technical Analysis and Task Breakdown are the last content sections in the story body (after Notes, before footer). When appending, condenses Technical Analysis (keeps strategy summary, data flow/pipeline order, risks), then appends: task checklist → Dependency Graph (ASCII block showing task dependencies) → AC Coverage table (maps each AC to covering tasks) → detailed tasks.Acceptance Criteria:
Technical Requirements:
Implementation Approach:
dataset/.skills/process/dataset/.skills/process/plan-tasks/SKILL.md— new process skillpackages/knowledge-hub/dataset/.pair/knowledge/guidelines/collaboration/templates/task-template.md— formalize Dependency Graph + AC Coverage in Task Breakdown FormatDependencies:
Implementation Steps:
dataset/.skills/process/plan-tasks/Testing Strategy:
Notes: Integrated Technical Analysis + Task Breakdown format is the same pattern used manually for this epic's task breakdown.
T-4: Thin how-to-08 from ~308 to ~120 lines
Priority: P0 | Estimated Hours: 2h | Bounded Context: Knowledge Base Management
Summary: Remove operational content from how-to-08, keeping orchestration structure.
Type: Documentation
Description: Keep: phase flow (selection → analysis → requirements → validation → documentation → completion), HALT conditions, INVEST validation framework, selection criteria. Remove (now in skills): requirements gathering procedures, Given-When-Then generation, technical analysis execution, template filling. Standalone readable for non-skill assistants.
Acceptance Criteria:
Technical Requirements:
Implementation Approach:
.pair/knowledge/how-to/.pair/knowledge/how-to/08-how-to-refine-a-user-story.md— thin to ~120 linesDependencies:
Implementation Steps:
Testing Strategy:
Notes: Second how-to thinning (after #99's how-to-10). Pattern well-established.
T-5: Thin how-to-09 from ~358 to ~140 lines
Priority: P0 | Estimated Hours: 2h | Bounded Context: Knowledge Base Management
Summary: Remove operational content from how-to-09, keeping orchestration structure.
Type: Documentation
Description: Keep: 7-phase flow, HALT conditions, task decomposition criteria, bounded context mapping requirement. Remove (now in skills): task identification patterns, template filling, dependency identification procedures. Standalone readable for non-skill assistants.
Acceptance Criteria:
Technical Requirements:
Implementation Approach:
.pair/knowledge/how-to/.pair/knowledge/how-to/09-how-to-create-tasks.md— thin to ~140 linesDependencies:
Implementation Steps:
Testing Strategy:
Notes: Thins in parallel with T-4 (how-to-08).
T-6: Validate skills and thinned how-to files in Claude Code
Priority: P0 | Estimated Hours: 2h | Bounded Context: Knowledge Base Management
Summary: End-to-end validation of all skills and thinned how-to-08/how-to-09 in Claude Code.
Type: Testing
Description: Validate: /refine-story on Todo story (full refinement); re-invoke partial (resumes); already-refined (offers update); /plan-tasks on refined story (creates tasks); re-invoke with existing tasks (creates only missing); /write-issue independently (create + update for both story and task types); PM tool error → HALT; thinned how-to-08 and how-to-09 standalone readability.
Acceptance Criteria:
Technical Requirements:
Implementation Approach:
Dependencies:
Implementation Steps:
Testing Strategy:
Notes: Final validation before story completion.
Refinement Date: 2026-02-08
Review and Approval: Approved (2026-02-09)