Story Draft Workflow

PRD-first story creation — reads Confluence PRDs, traces ACs to requirements, and flags coverage gaps.

~6 phasesSTORIES_PUBLISHEDProduct Owner

Pipeline

Phase Summary

Hover over any phase name to see what it does in detail.

#PhasePurposeKey Output
1INTAKEAccept feature concept or Jira ID, extract Confluence linksINTAKE.md
2CONTEXTFetch PRD from Confluence, parse into structured requirementsCONTEXT.md + PRD_REQUIREMENTS.md
3SPECIFYWrite PRD-traced ACs, scope boundaries, edge casesSPECIFICATION.md
4DECOMPOSEBreak into stories with PRD coverage matrixDECOMPOSITION.md
5VALIDATE_DORRun DoR checklist, verify PRD was read if linkedDOR_VALIDATION.md
6PUBLISHCreate/update Jira tickets with PRD traceabilityPUBLISH.md

PRD-First Approach

When a Confluence PRD is linked to the ticket (or provided via --prd), the workflow switches from inference-based to requirements-driven:

PhaseWithout PRDWith PRD
CONTEXTReads ticket + codebase onlyFetches Confluence pages, parses into PRD_REQUIREMENTS.md with FR-N, NFR-N IDs
SPECIFYACs inferred from descriptionEach AC traces to a requirement ID. Untraced ACs flagged as [ASSUMED]
DECOMPOSESplits by size onlyPRD coverage matrix. Recommends additional stories for uncovered requirements
VALIDATE_DORStandard DoR checklistBlocks if PRD linked but never read. Checks coverage ≥50%
PUBLISHStandard PO SpecificationAdds PRD Traceability section with source link and coverage summary

Invocation Modes

Mode A: Enrich Existing

/story-draft DO-2902 — Takes an existing epic or story Jira ID, fetches current ticket data, auto-discovers linked Confluence PRD pages, and enriches with full PO specifications.

Mode B: Create from Scratch

/story-draft "Build a recommendation engine" — Takes a free-text feature concept, researches codebase context, and creates fully specified stories from scratch.

--prd flag

/story-draft DO-3255 --prd https://...atlassian.net/wiki/spaces/DH/pages/5408981093/Einstein+Recommendations

Explicitly provide a Confluence PRD URL. The page is fetched and used as the primary requirements source, even if the ticket description doesn't link to it. Works with both Mode A and Mode B.

What Gets Added to Jira

The PUBLISH phase appends a structured PO Specification section to each Jira ticket description:

--- PO Specification (auto-generated) ---

Acceptance Criteria:

AC1: [title] — Traces to: FR-1

Given [precondition]

When [action]

Then [expected result]

PRD Traceability:

Source PRD: [Confluence page title](url)

Requirements covered: FR-1, FR-3, NFR-1 (6 of 9 total)

Assumed ACs: AC4 (team convention), AC6 (codebase pattern)

Scope:

In scope: [explicit boundaries]

Out of scope: [explicit exclusions]

Dependencies:

Blocked by: [linked tickets]

Blocks: [downstream tickets]

Estimates:

Story points: [estimate]

Feature flag: [flag name if applicable]

Labels:

po-drafted

Signal Flow

SignalTypeMeaning
PHASE_COMPLETEAdvancePhase done, advance to next
BLOCKED_NEEDS_POBlockCannot proceed without Product Owner clarification
SCOPE_TOO_LARGEBlockStory exceeds size threshold, needs further decomposition
DOR_FAILEDLoopbackDefinition of Ready check failed, loop back to SPECIFY
DOR_FAILED_PRD_UNREADLoopbackPRD was linked in ticket but never fetched — loop back to CONTEXT to read Confluence pages
STORIES_PUBLISHEDTerminalAll stories created/updated in Jira, workflow complete