ddd-refactor

Produce phased DDD refactoring plans with aggregate guardrails and invariants.

Updated Mar 18, 2026
One-click install
npx skills add https://github.com/mikecubed/agent-orchestration --skill ddd-refactor-mikecubed
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ddd-refactor
Source: https://github.com/mikecubed/agent-orchestration/tree/main/plugins/patterns/skills/ddd-refactor
Command: npx skills add https://github.com/mikecubed/agent-orchestration --skill ddd-refactor-mikecubed

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This skill produces phased, safe refactoring plans toward DDD patterns. It guides plan-only changes and does not write code, helping teams evolve architecture without breaking existing behavior.

Core Features & Use Cases

  • Phased refactoring plans aligned with DDD patterns (Aggregate boundaries, Repository + Specification, Layered Architecture).
  • Checks for Ubiquitous Language changes alongside structural changes; warns about aggregate boundary changes; provides independent, safe phases (minimum 3).
  • Guidance on applying DDD refactorings such as moving behavior, introducing domain layers, and aligning ubiquitous language with code.

Quick Start

Describe a phased, safe migration plan toward a DDD pattern for the given codebase.

Frequently Asked Questions about ddd-refactor

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I safely refactor an existing codebase toward Domain-Driven Design patterns?

Refactoring toward Domain-Driven Design requires phased, safe migration plans that establish aggregate boundaries and repositories without breaking existing behavior. This skill generates those structured, multi-phase evolution plans with guardrails to ensure safe transitions.

What is a phased DDD refactoring plan and why do I need one?

A phased DDD refactoring plan structures architecture evolution into a minimum of three independent, safe phases. You need one to evolve domain models and update ubiquitous language systematically without disrupting current system functionality during structural changes.

How do I align ubiquitous language with code while changing aggregate boundaries?

Aligning ubiquitous language with code during aggregate boundary changes requires checking for language updates alongside structural shifts. The plan warns about boundary modifications and documents phase invariants to keep behavior consistent throughout the migration.

Can this skill introduce a domain layer and move behavior within a layered architecture?

Introducing a domain layer and moving behavior within a layered architecture are supported DDD refactorings. The skill provides guidance on applying these structural changes safely across its required minimum of three independent phases.

Does this DDD refactor skill write code or modify my project files directly?

This DDD refactor skill does not write code or modify project files directly. It guides plan-only changes, producing documentation of phase invariants and structural evolution strategies to help teams evolve architecture manually and safely.

What are the limitations of using phased planning for DDD pattern migration?

The limitation of this phased planning approach is that it strictly produces plans rather than executable code. Teams must manually implement the structural changes, ubiquitous language updates, and aggregate guardrails outlined in the generated refactoring phases.