ALWAYS invoke this skill before using any decomposition skill or when understanding outcome levels. NEVER decompose outcomes without loading this foundation first.
From spx-legacynpx claudepluginhub outcomeeng/claude --plugin spx-legacyThis skill is limited to using the following tools:
references/level-decision-tree.mdreferences/outcome-types.mdreferences/what-goes-where.mdGuides Next.js Cache Components and Partial Prerendering (PPR) with cacheComponents enabled. Implements 'use cache', cacheLife(), cacheTag(), revalidateTag(), static/dynamic optimization, and cache debugging.
Migrates code, prompts, and API calls from Claude Sonnet 4.0/4.5 or Opus 4.1 to Opus 4.5, updating model strings on Anthropic, AWS, GCP, Azure platforms.
Details PluginEval's skill quality evaluation: 3 layers (static, LLM judge), 10 dimensions, rubrics, formulas, anti-patterns, badges. Use to interpret scores, improve triggering, calibrate thresholds.
<essential_principles>
OUTCOMES, NOT TASKS.
This is the most fundamental principle. The Product Tree contains OUTCOMES—states of the world that should exist—not tasks to be done.
| WRONG (Task) | RIGHT (Outcome) |
|---|---|
| "Refactor to comply with ADR" | "System produces correct output" |
| "Fix bug in X" | "Edge case Y handled correctly" |
| "Add error handling" | "Invalid input returns clear error" |
| "Write tests" | Tests are PROOF of outcomes, not outcomes |
ADRs and PDRs GOVERN, they don't implement.
STORIES REQUIRED FOR IMPLEMENTATION.
A feature without stories is NOT ready for implementation—regardless of whether code already exists.
WRONG: "Implementation exists and passes tests, so flat structure is fine"
RIGHT: "Feature needs stories before any implementation can be verified"
WRONG: "Feature-level tests are comprehensive enough"
RIGHT: "Only story-level tests enable atomic verification and property-based testing"
If you encounter a feature with implementation but no stories: recommend decomposition, not acceptance.
SHARED NEED → ENABLER:
When 2+ containers share a need, factor it into an ENABLER at the lowest convergence point:
54-component-library.capability/
├── 54-fixed-point-format.adr.md # GOVERNS (no tests here)
├── 21-dsp-foundation.feature/ # ENABLER for shared need
│ └── 21-fixed-point-helpers.story/ # Implements shared helpers
│ └── tests/ # Tests for the enabler
├── 54-dsp-cordic.feature/ # DEPENDS ON enabler
├── 76-dsp-nco.feature/ # DEPENDS ON enabler
└── 87-dsp-cic.feature/ # DEPENDS ON enabler
The ADR (and PDR) doesn't get tests. The ENABLER that satisfies the shared need gets tests.
The Product Tree replaces the backlog.
Structured Outcome Requirement:
Every outcome must be expressed as a typed, structured outcome (Scenario, Mapping, Conformance, or Property), have referenced test files, and pass agentic review. This is the quality gate — not syntactic constraints, but verified coherence between specs, tests, and passing tests.
Note: ADRs and PDRs don't have outcomes—they GOVERN. The requirement applies to outcomes in specs. See references/outcome-types.md for the four outcome types and their notations.
Principle 11:
Higher levels unaware of lower level breakdown. Features don't list story outcomes. Capabilities don't list feature outcomes. Completion bubbles up through test results, not spec references.
</essential_principles>
<quick_start> This skill provides mental models for Outcome Engineering decomposition. Read it BEFORE using:
/decomposing-prd-to-capabilities/decomposing-capability-to-features/decomposing-feature-to-storiesKey questions for each level:
| Level | Question | Constraint |
|---|---|---|
| Capability | "What can the product DO?" | Cross-cutting vertical slice |
| Feature | "What significant slice can be done in ≤7 stories?" | At most 7 atomic stories |
| Story | "What's the atomic unit?" | Structured outcomes |
</quick_start>
<level_semantics>
<capability_level>
A capability is a large, cross-cutting vertical slice of the product. It represents something the product is capable of doing, providing, or accomplishing.
Examples:
Key characteristics:
NOT a capability:
</capability_level>
<feature_level>
A feature is a significant and valuable vertical slice that can be implemented in at most 7 atomic stories.
Examples:
The 7-story limit is critical:
IF feature needs > 7 stories
THEN split into multiple features
IF feature has only 1-2 stories
THEN it may be too small (or that's fine for now—it can grow)
Key characteristics:
NOT a feature:
</feature_level>
<story_level>
A story is the atomic unit of implementation—something that can be understood and implemented as a single coherent piece.
Examples:
The level of abstraction depends on context:
Key characteristics:
NOT a story:
</story_level>
</level_semantics>
<organic_growth>
Starting small is normal:
21-auth.capability/
└── 21-login.feature/
└── 21-basic-login.story/
This is a valid structure. One capability, one feature, one story.
Growth happens at any level:
21-auth.capability/
├── 21-login.feature/
│ ├── 21-basic-login.story/
│ ├── 37-remember-me.story/ ← Story added
│ └── 54-login-throttling.story/ ← Story added
├── 37-registration.feature/ ← Feature added
│ └── 21-email-registration.story/
└── 54-password-reset.feature/ ← Feature added
├── 21-request-reset.story/
└── 37-complete-reset.story/
BSP numbering enables insertion:
</organic_growth>
<decomposition_principles>
Capability → Features:
Ask: "What significant vertical slices make up this capability?"
Each slice should be:
Feature → Stories:
Ask: "What atomic pieces make up this feature?"
Each piece should be:
The key question at every level:
Can this be expressed as a structured outcome (Scenario, Mapping, Conformance, or Property)? If not, decompose further or clarify requirements.
</decomposition_principles>
<common_mistakes>
Wrong (the SPI example):
# Feature: Serial SPI
## Outcomes
### 1. SPI master transmits in mode 0 ← Should be a story
### 2. SPI modes 1-3 verified ← Should be a story
### 3. SPI slave responds ← Should be a story
### 4. Master-slave loopback works ← Feature-level OK
### 5. Lint-clean HDL ← Feature-level OK
Correct structure:
22-serial-spi.feature/
├── serial-spi.feature.md # Outcomes 4 & 5 only (if needed)
├── 10-spi-master.story/ # Outcomes 1 & 2 become stories
├── 20-spi-slave.story/ # Outcome 3 becomes a story
└── ...
Why? Principle 11—features don't list story outcomes. Stories prove themselves through passing tests.
If you need 12 stories, you have 2 features, not 1.
Test levels (1, 2, 3) are about infrastructure needed:
Container levels (Story, Feature, Capability) are about scope of concern:
These are orthogonal. A story can have Level 2 tests. A capability can have Level 1 tests.
WRONG: Agents removing ALL outcomes from features because "features don't list story outcomes."
Features MUST have their own outcomes. Principle 11 means features don't list outcomes that ARE stories (atomic implementation units). Features still have:
# Feature: Serial SPI
## Outcomes
### 1. Master-slave loopback works ← KEEP (integration)
### 2. Generated HDL passes lint ← KEEP (quality gate)
What to MOVE to stories:
### 3. SPI master mode 0 works ← MOVE TO STORY (atomic)
WRONG: "Where do we test the ADR?" or "ADR compliance story"
ADRs and PDRs GOVERN, they don't implement:
The ENABLER pattern for shared needs:
WRONG:
54-component-library.capability/
├── 54-fixed-point-format.adr.md
└── tests/
└── test_adr_compliance.py ← ADRs don't get tests!
RIGHT:
54-component-library.capability/
├── 54-fixed-point-format.adr.md # GOVERNS (no tests)
├── 21-dsp-foundation.feature/ # ENABLER (has the NEED)
│ └── 21-fixed-point-helpers.story/ # Satisfies shared need
│ └── tests/ # Tests verify outcomes
├── 54-dsp-cordic.feature/ # Uses enabler
└── 76-dsp-nco.feature/ # Uses enabler
WRONG reasoning:
"Implementation exists and is functional"
"Tests are comprehensive"
"Structure is flat - all tests at feature level"
"This may be intentional for a completed feature"
Why this is wrong:
RIGHT response when finding implementation without stories:
"Feature has implementation but no stories. This violates Outcome Engineering framework.
Recommend decomposing into stories to enable:
- Atomic verification of each behavior
- Property-based testing at story level
- Clear specification of edge cases
- Independent verification of each unit"
The test: If a feature has tests/ but no *.story/ directories, it needs decomposition—regardless of whether tests pass.
</common_mistakes>
<what_goes_where>
| Type | Purpose | Contains | Verified by |
|---|---|---|---|
| ADR | GOVERNS how (arch) | Constraints, rationale | /reviewing-{language}-architecture |
| PDR | GOVERNS what (product) | Product invariants | Product/UX review |
| Spec | DESCRIBES outcomes | Structured outcomes, test refs | /reviewing-{language} |
| Test | PROVES existence | Executable verification | /reviewing-{language}-tests |
The Flow:
ADR/PDR constrains → Spec defines WHAT → Test PROVES → Ledger RECORDS
See references/what-goes-where.md for detailed taxonomy.
</what_goes_where>
<reference_index>
| File | Purpose |
|---|---|
references/what-goes-where.md | What content belongs in ADRs, PDRs, Specs, Tests |
references/level-decision-tree.md | Decision flowchart for container levels |
references/outcome-types.md | Four outcome types: Scenario, Mapping, Conformance, Property |
</reference_index>
<success_criteria>
Skill mastery demonstrated when:
</success_criteria>