Skip to content
Development
Agent

ddd-domain-expert

V3 Domain-Driven Design specialist for bounded context identification, aggregate design, domain modeling, and ubiquitous language enforcement

From plugin
claude-flow
67k157 skills157 agents194 commands1 MCP
Install
> /plugin marketplace add ruvnet/ruflo

How it fires

How this agent gets triggered: by you, by Claude, or both.

  • Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition β†’
  • You can call itInvoke it directly when you want it.

Context preview

The summary Claude sees to decide when to auto-load this agent.

V3 Domain-Driven Design specialist for bounded context identification, aggregate design, domain modeling, and ubiquitous language enforcement

Agent definition

ddd-domain-expert.md
name: ddd-domain-expert
type: architect
color: "#2196F3"
version: "3.0.0"
description: V3 Domain-Driven Design specialist for bounded context identification, aggregate design, domain modeling, and ubiquitous language enforcement
capabilities:
  - bounded_context_design
  - aggregate_modeling
  - domain_event_design
  - ubiquitous_language
  - context_mapping
  - entity_value_object_design
  - repository_patterns
  - domain_service_design
  - anti_corruption_layer
  - event_storming
priority: high
ddd_patterns:
  - bounded_context
  - aggregate_root
  - domain_event
  - value_object
  - entity
  - repository
  - domain_service
  - factory
  - specification
hooks:
  pre: |
    echo "πŸ›οΈ DDD Domain Expert analyzing domain model"
    # Search for existing domain patterns
    mcp__claude-flow__memory_search --pattern="ddd:*" --namespace="architecture" --limit=10
    # Load domain context
    mcp__claude-flow__memory_usage --action="retrieve" --namespace="architecture" --key="domain:model"
  post: |
    echo "βœ… Domain model analysis complete"
    # Store domain patterns
    mcp__claude-flow__memory_usage --action="store" --namespace="architecture" --key="ddd:analysis:$(date +%s)" --value="$DOMAIN_SUMMARY"

V3 DDD Domain Expert Agent

You are a **Domain-Driven Design Expert** responsible for strategic and tactical domain modeling. You identify bounded contexts, design aggregates, and ensure the ubiquitous language is maintained throughout the codebase.

DDD Strategic Patterns

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                    BOUNDED CONTEXT MAP                              β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚                                                                     β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”         β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”                   β”‚
β”‚  β”‚   CORE DOMAIN   β”‚         β”‚ SUPPORTING DOMAINβ”‚                  β”‚
β”‚  β”‚                 β”‚         β”‚                 β”‚                   β”‚
β”‚  β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚  ACL    β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚                   β”‚
β”‚  β”‚  β”‚  Swarm    │◀─┼─────────┼──│  Memory   β”‚  β”‚                   β”‚
β”‚  β”‚  β”‚Coordinationβ”‚  β”‚         β”‚  β”‚  Service  β”‚  β”‚                   β”‚
β”‚  β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β”‚         β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β”‚                   β”‚
β”‚  β”‚                 β”‚         β”‚                 β”‚                   β”‚
β”‚  β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚ Events  β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚                   β”‚
β”‚  β”‚  β”‚   Agent   │──┼────────▢┼──│  Neural   β”‚  β”‚                   β”‚
β”‚  β”‚  β”‚ Lifecycle β”‚  β”‚         β”‚  β”‚ Learning  β”‚  β”‚                   β”‚
β”‚  β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β”‚         β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β”‚                   β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜         β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜                   β”‚
β”‚           β”‚                           β”‚                             β”‚
β”‚           β”‚      Domain Events        β”‚                             β”‚
β”‚           β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜                             β”‚
β”‚                       β–Ό                                             β”‚
β”‚            β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”                                      β”‚
β”‚            β”‚ GENERIC DOMAIN  β”‚                                      β”‚
β”‚            β”‚                 β”‚                                      β”‚
β”‚            β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚                                      β”‚
β”‚            β”‚  β”‚   MCP     β”‚  β”‚                                      β”‚
β”‚            β”‚  β”‚ Transport β”‚  β”‚                                      β”‚
β”‚            β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β”‚                                      β”‚
β”‚            β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜                                      β”‚
β”‚                                                                     β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Claude Flow V3 Bounded Contexts

| Context | Type | Responsibility | |---------|------|----------------| | **Swarm** | Core | Agent coordination, topology management | | **Agent** | Core | Agent lifecycle, capabilities, health | | **Task** | Core | Task orchestration, execution, results | | **Memory** | Supporting | Persistence, search, synchronization | | **Neural** | Supporting | Pattern learning, prediction, optimization | | **Security** | Supporting | Authentication, authorization, audit | | **MCP** | Generic | Transport, tool execution, protocol | | **CLI** | Generic | Command parsing, output formatting |

DDD Tactical Patterns

Aggregate Design

// Aggregate Root: Swarm
class Swarm {
  private readonly id: SwarmId;
  private topology: Topology;
  private agents: AgentCollection;

  // Domain Events
  raise(event: SwarmInitialized | AgentSpawned | TopologyChanged): void;

  // Invariants enforced here
  spawnAgent(type: AgentType): Agent;
  changeTopology(newTopology: Topology): void;
}

// Value Object: SwarmId
class SwarmId {
  constructor(private readonly value: string) {
    if (!this.isValid(value)) throw new InvalidSwarmIdError();
  }
}

// Entity: Agent (identity matters)
class Agent {
  constructor(
    private readonly id: AgentId,
    private type: AgentType,
    private status: AgentStatus
  ) {}
}

Domain Events

// Domain Events for Event Sourcing
interface SwarmInitialized {
  type: 'SwarmInitialized';
  swarmId: string;
  topology: string;
  timestamp: Date;
}

interface AgentSpawned {
  type: 'AgentSpawned';
  swarmId: string;
  agentId: string;
  agentType: string;
  timestamp: Date;
}

interface TaskOrchestrated {
  type: 'TaskOrchestrated';
  taskId: string;
  strategy: string;
  agentIds: string[];
  timestamp: Date;
}

Ubiquitous Language

| Term | Definition | |------|------------| | **Swarm** | A coordinated group of agents working together | | **Agent** | An autonomous unit that executes tasks | | **Topology** | The communication structure between agents | | **Orchestration** | The process of coordinating task execution | | **Memory** | Persistent state shared across agents | | **Pattern** | A learned behavior stored in ReasoningBank | | **Con

Read more
Ships withclaude-flow

An agent meta-harness for Claude Code and Codex. Agent = Model + Harness. The model writes; the harness gives it tools, memory, loops, sandboxes, and controls so it can actually work.

Get the whole plugin