/ddd-flow:3-decomposefrom ddd-flow
Draw or move bounded-context boundaries and author each context's model.yaml in the ddd-flow modelling loop. Use whenever a domain has confirmed discovery (events/rules) and needs cutting into bounded contexts, deciding what each context owns, or revising an existing context-map — invoked by ddd-flow:design or directly when decomposing a modelled domain. This is the ONLY step that draws a boundary; not for initial event discovery (that is 2-discover).
Ships in ddd-flow. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
You already know DDD boundary-finding, aggregate discovery, and context mapping. This skill does not re-teach that — it gives only what a strong model gets wrong by default here, plus the exact output contract the gate parses.
Read ../../references/RULES.md (the shared ddd-flow rules). The Grounding, Boundaries,
and Right-size sections govern this step. They are the rules, not the method — do not proceed
without them.
docs/domain/discovery/ (model.json = the confirmed/candidate event store — your
grounding source) and business-model.md.docs/domain/context-map.md and one docs/domain/<context>/model.yaml per grounded context.Author every model.yaml to the schema in ../../references/model.template.yaml. It is
single-sourced with ddd_check, so match it field-for-field (aggregates[].invariants; a notes:
line on an empty aggregates: []; valid YAML — no bare : inside a multi-line scalar). Artifact
shapes and line budgets: ../../references/artifact-shapes.md.
Boundaries come only from confirmed events. A noun cluster with 0 confirmed events and no
business invariant (ownership, audit, permissions) is a capability of another context — decline
it and record the escalation condition, never manufacture a context to fill the map. If the slice
has 0 confirmed events/rules or is below the grounding ratio, STOP and go back to 2-discover.
Run ddd_check (grounding + structure gate); resolve blocking gaps; keep open_questions
populated honestly. Never promote your own inference to a confirmed event — hand it to 2-discover;
only a human flips candidate → confirmed.
references/aggregate-design-canvas.md (opens in a new tab)references/bounded-context-canvas.md (opens in a new tab)references/brownfield-triangulation.md (opens in a new tab)references/ddd-methodology.md (opens in a new tab)references/output-template.md (opens in a new tab)references/worked-example.md (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub baodq97/govkit --plugin ddd-flow10 skills in this plugin
/1-understandCapture what the business sells, to whom, and what differentiates it — a Business Model Canvas, story map, and strategic-classification inputs — as the grounding step of the ddd-flow modelling loop. Use whenever a domain needs grounding before any boundary is drawn, or when the business model changed and downstream classification must be revisited — invoked by ddd-flow:design or directly. Writes docs/domain/business-model.md and supplies the inputs 3-decompose and 5-strategize need; it does NOT classify contexts itself./2-discoverSurface a domain's EventStorming timeline, ubiquitous language, and hotspots from what the people who do the work actually say — the discovery step of the ddd-flow modelling loop. Use whenever a domain needs its behaviour discovered before any boundary is drawn: mining PRDs/specs/schemas for candidate events, interviewing for the gaps, or merging a discovery delta — invoked by ddd-flow:design or directly. This is initial event discovery; drawing bounded-context boundaries is 3-decompose.
/4-connectTrace real business use cases as message flows across the bounded contexts to surface hidden coupling, in the ddd-flow modelling loop. Use whenever a domain has an initial cut (contexts + events) and you need to test whether concrete scenarios cross those boundaries cleanly, or to re-check flows after a boundary moved — invoked by ddd-flow:design or directly. Also use when one rule or invariant appears to span two contexts and the flow must be traced before anyone decides where it belongs — a distributed invariant is this step's finding to produce. Needs a cut to refute; not a discovery technique (that is 2-discover), and it never redraws a boundary itself (it hands 3-decompose the evidence).