evolutionary-modular-architecture

Designs evolutionary modular monoliths with DDD bounded contexts, ACLs, and resilience patterns.

Updated Sep 15, 2026
One-click install
npx skills add https://github.com/Peterson-Benhame/agent-skills --skill evolutionary-modular-architecture-peterson-benhame
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: evolutionary-modular-architecture
Source: https://github.com/Peterson-Benhame/agent-skills/tree/main/packages/skills-catalog/skills/%28architecture%29/evolutionary-modular-architecture
Command: npx skills add https://github.com/Peterson-Benhame/agent-skills --skill evolutionary-modular-architecture-peterson-benhame

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve? Teams often over-engineer new backends with premature microservices or under-engineer them with tangled layer-folder structures, leading to vendor lock-in, fragile integrations, and costly rewrites. This Skill guides the design of a modular monolith with strong logical boundaries from day one while keeping physical separation as a later, optional step. ## Core Features & Use Cases - Strategic and tactical DDD guidance: Classify subdomains as Core, Supporting, or Generic, draw context maps, and apply rich aggregates only where invariants justify them. - Flat-by-aggregate module organization: Co-locate each business concept in one folder with technical layers expressed as file suffixes, validated by deterministic Node scripts. - Vendor independence and resilience: Wrap every external system (ERP, storage, AI, identity) behind a port and Anti-Corruption Layer, with transactional outbox events, backoff with jitter, circuit breakers, and idempotency keys. - Architecture documentation: Produce a self-contained HTML architecture document with hand-drawn-style SVG diagrams from a provided template. - Use Case: When designing a payables platform that posts to a client's ERP, use this Skill to define bounded contexts, place the ERP behind an ErpLedgerPort adapter, wire events through an outbox, and generate the full architecture document. ## Quick Start Ask the agent to design the architecture for your new platform or backend, describing your domain and any external systems it must integrate with.

Frequently Asked Questions about evolutionary-modular-architecture

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

FAQPage Schema
How do I design a modular monolith architecture?

Start with DDD strategic design: classify subdomains as Core, Supporting, or Generic, then draw a context map. Keep one deploy with strong logical boundaries, organize modules flat-by-aggregate, and put every external system behind a port and adapter.

When should I choose a modular monolith vs microservices?

Default to a modular monolith with one deploy and one database, where each module solely owns its tables. Promote a module to its own app or database only when its own scaling, failure-isolation, or deployment metrics justify it.

How do I avoid vendor lock-in with an ERP or external API?

Define a port in your domain's language, such as ErpLedgerPort, and implement it with an adapter that translates the vendor model at the boundary. Swapping vendors then means writing a new adapter while the domain never imports vendor types.

What is flat-by-aggregate folder organization?

Each business concept gets one folder containing its entity, service, repository, and controller files distinguished by suffixes, with depth limited to two or three levels. Technical-layer folders like controllers/ or services/ are forbidden and enforced by a validation script.

When should I use SSE instead of WebSocket?

Use SSE for server-to-client push such as live queues, notifications, and dashboards since it works over plain HTTP with automatic reconnection. Reserve WebSocket for genuinely bidirectional, low-latency needs like collaborative editing.

When is this architecture skill not appropriate?

Skip it for simple CRUD apps with a handful of endpoints where framework defaults suffice. For NestJS-specific deep implementation use nestjs-modular-monolith, and for single domain-model reviews use tactical-ddd instead.