implementation-approach
This Claude Code skill provides a structured meta-cognitive framework for selecting implementation strategies by analyzing current state, exploring reference patterns, and assessing risks. Use it when planning how to implement features, refactor existing code, handle legacy systems, or define the approach before development begins to ensure alignment between business goals and technical execution.
git clone --depth 1 https://github.com/shinpr/claude-code-workflows /tmp/implementation-approach && cp -r /tmp/implementation-approach/dev-workflows-fullstack/skills/implementation-approach ~/.claude/skills/implementation-approachSKILL.md
# Implementation Strategy Selection Framework (Meta-cognitive Approach) ## Meta-cognitive Strategy Selection Process ### Phase 1: Decision-Sufficient Current State Analysis **Core Question**: "What does the existing implementation look like?" #### Analysis Framework ```yaml Architecture Analysis: Responsibility separation, data flow, dependencies, technical debt Implementation Quality Assessment: Code quality, behavior-relevant test evidence, performance, security Historical Context Understanding: Current form rationale, past decision validity, constraint changes, requirement evolution ``` #### Meta-cognitive Question List - What is the true responsibility of this implementation? - Which parts are business essence and which derive from technical constraints? - What dependencies or implicit preconditions are unclear from the code? - What benefits and constraints does the current design bring? Stop when another current-state fact cannot change responsibility, reuse, option validity, total complexity, a contract, or verification. ### Phase 2: Design Convergence Complete these steps in order before selecting an implementation strategy: 1. **Existing-Surface Baseline**: Form the simplest end-to-end path that delivers the current outcome through existing responsibilities. Explicit requirements and accepted decisions are binding; suggested mechanisms remain candidates. 2. **Evidence Check**: Test that path against current requirements, verified constraints, observed in-scope problems, and evidence-backed material risks. Keep only the unmet conditions that can change the selected design. 3. **Targeted Comparison**: For each unmet condition, test reuse, derivation from existing data, on-demand computation, or responsibility at the current caller or boundary before adding design surface. Compare viable choices by total complexity across the dimensions that materially differ: user decisions, settings, modes, concepts, outputs, persistent state, implementation paths, UX, runtime, implementation, testing, documentation, and maintenance. Select the lowest-total-complexity choice that satisfies the condition. 4. **Subtraction Check**: Remove each proposed addition and re-test its governing condition. Retain it only when the confirmed outcome, a required boundary, or necessary proof becomes unmet. Classify supporting claims as observed, inferred, or unknown. Route an unknown that blocks the next step as an exact evidence prerequisite; the caller's value-boundary and irreversible-action gates determine whether user interaction is required. Candidate paths and rejected additions remain active analysis. The durable output is the **Selected Design**: the complete chosen path plus evidence for each added design surface and the condition that fails when it is removed. An accepted ADR may retain alternatives as decision history. An implementer uses the same convergence check without producing a separate artifact. ### Phase 3: Strategy Exploration and Creation **Core Question**: "When determining before → after, what implementation patterns or strategies should be referenced?" #### Strategy Discovery Process ```yaml Direct Strategy: Smallest repository-supported change that satisfies the accepted requirements and constraints Repository Alternatives: Existing patterns that materially differ in migration, dependency order, or verification boundary External Research: Official/current sources only when repository evidence cannot resolve a time-sensitive capability, compatibility, or dependency decision ``` #### Reference Strategy Patterns **Legacy Handling Strategies**: - Strangler Pattern: Gradual migration through phased replacement - Facade Pattern: Complexity hiding through unified interface - Adapter Pattern: Bridge with existing systems **New Development Strategies**: - Feature-driven Development: Vertical implementation prioritizing user value - Foundation-driven Development: Foundation-first construction prioritizing stability - Risk-driven Development: Prioritize addressing maximum risk elements **Integration/Migration Strategies**: - Proxy Pattern: Transparent feature extension - Decorator Pattern: Phased enhancement of existing features - Bridge Pattern: Flexibility through abstraction Use these patterns only when their named migration or dependency problem exists. Start with the direct strategy. Compare an alternative when it would materially change risk, rollout, compatibility, or the early verification point. Keep the option set limited to patterns that produce one of those material differences. ### Phase 4: Material Risk Assessment and Control **Core Question**: "What risks arise when applying this to existing implementation, and what's the best way to control them?" Evaluate only risk categories for which current evidence can change the strategy, public contract, rollout, rollback, or verification boundary. #### Conditional Risk Categories ```yaml Technical Risks: System impact, data consistency, performance degradation, integration complexity Operational Risks: Service availability, deployment downtime, process changes, rollback procedures Project Risks: Schedule delays, learning costs, quality achievement, team coordination ``` #### Risk Control Strategies ```yaml Preventive Measures: Phased migration, parallel operation verification, integration/regression tests, monitoring setup Incident Response: Rollback procedures, log/metrics preparation, communication system, service continuation procedures ``` ### Phase 5: Decision-Relevant Constraint Compatibility **Core Question**: "What are this project's constraints?" Check only constraints evidenced by the governing requirements, repository, external contracts, or current environment that can change the selected strategy or verification boundary. #### Conditional Constraint Categories ```yaml Technical Constraints: Library compatibility, resource capacity, mandatory requirements, numerical targets Temporal Constraints: Dea
Generates integration/E2E test skeletons from Design Doc ACs using ROI-based selection and journey-based E2E reservation. Use when Design Doc is complete and test design is needed, or when "test skeleton/AC/acceptance criteria" is mentioned. Behavior-first approach for minimal tests with maximum coverage.
Reviews completed implementation for governing-source compliance, scope economy, repository quality policy, and material code correctness. Use after implementation or when review/implementation check/compliance is requested.
Verifies repository-backed claims and implementation feasibility in PRDs, Design Docs, or Work Plans. Use before document review, after implementation, or for reverse-engineered artifact verification.
Collects compact repository evidence for scope confirmation, technical option selection, complete design, and verification. Use before Design Doc creation when repository facts can change scope, reuse, contracts, cost, or proof.
Detects conflicts across multiple Design Docs and provides structured reports. Use when multiple Design Docs exist, or when "consistency/conflict/sync/between documents" is mentioned. Focuses on detection and reporting only, no modifications.
Reviews one document or one ADR batch against governing requirements, repository evidence, and the needs of its next consumer. Use before user approval or when document consistency and completeness need verification.
Reviews changed integration and E2E tests against skeletons, proof obligations, or explicit prompt claims. Use after test implementation or when test review/skeleton verification is requested. Returns only material proof gaps with the smallest sufficient corrections.
Comprehensively collects problem-related information and creates evidence matrix. Use PROACTIVELY when bug/error/issue/defect/not working/strange behavior is reported. Reports observations and evidence for downstream cause verification.