skillfed

architecture-patterns

Master three foundational backend architecture approaches—Clean Architecture, Hexagonal Architecture, and Domain-Driven Design—to structure systems for testability, maintainability, and scalability. Each pattern teaches dependency management, separation of concerns, and technology-agnostic core logic through practical examples and directory structures.

Architecture Patterns teaches Clean, Hexagonal, and DDD approaches for building maintainable backend systems.

AI-generated summary based on this skill's SKILL.md

2,494 184 Apache-2.0 updated by foryourhealth111-pixel

Install

foryourhealth111-pixel/Vibe-Skills/architecture-patterns · repository language: Python

git clone https://github.com/foryourhealth111-pixel/Vibe-Skills
cp -r Vibe-Skills/bundled/skills/architecture-patterns ~/.claude/skills/architecture-patterns
npx skillfed install foryourhealth111-pixel/Vibe-Skills/architecture-patterns

Frequently asked questions

AI-generated answers based on this skill's SKILL.md and metadata

How do I structure backend code using clean architecture?

architecture-patterns teaches Clean Architecture by organizing code into concentric layers—entities, use cases, interface adapters, and frameworks—where dependencies point inward toward the domain core. This approach isolates business logic from infrastructure, making systems testable and maintainable. You'll learn practical directory structures and how to keep your backend independent of frameworks, databases, and UI concerns.

What are hexagonal architecture ports and adapters?

architecture-patterns explains Hexagonal Architecture as a pattern where your application core (domain logic) connects to the outside world through ports (interfaces) and adapters (implementations). Ports define contracts for external dependencies like databases or APIs; adapters implement those contracts. This design enables you to swap technologies without touching core logic, making your backend highly testable and loosely coupled.

How does domain-driven design structure backend systems?

architecture-patterns covers Domain-Driven Design (DDD) patterns including bounded contexts, aggregates, entities, and value objects. DDD aligns code structure with business domains, using rich domain models to encode business rules directly. You'll learn how to identify domain boundaries, model complex business logic, and organize microservices or monolithic systems around domain concepts rather than technical layers.

What's the difference between clean arch and hexagonal?

architecture-patterns clarifies that Clean Architecture and Hexagonal Architecture share the same core principle—isolating domain logic from external concerns—but emphasize different aspects. Clean Architecture focuses on layered dependency flow (inward-pointing); Hexagonal emphasizes symmetrical ports and adapters on all sides. Both achieve testability and maintainability; choose based on your team's mental model and system complexity.

How do I refactor a monolithic app using these patterns?

architecture-patterns guides refactoring by first identifying domain boundaries and separating business logic from infrastructure. Apply dependency inversion to decouple layers, introduce repository patterns for data access, and extract domain models. For microservices decomposition, use DDD bounded contexts to define service boundaries. Incremental refactoring—starting with high-value, loosely-coupled modules—reduces risk while improving testability.

What are value objects, entities, and aggregates in DDD?

architecture-patterns teaches that entities are domain objects with unique identities and lifecycles; value objects are immutable, identity-less objects representing domain concepts (like Money or Address); aggregates are clusters of entities and value objects treated as single units for consistency. These patterns help you build rich, expressive domain models that encode business rules directly, making backends more maintainable and aligned with domain language.

SKILL.md

rendered from the published skill — quoted content, verbatim

Architecture Patterns

Master proven backend architecture patterns including Clean Architecture, Hexagonal Architecture, and Domain-Driven Design to build maintainable, testable, and scalable systems.

When to Use This Skill

  • Designing new backend systems from scratch
  • Refactoring monolithic applications for better maintainability
  • Establishing architecture standards for your team
  • Migrating from tightly coupled to loosely coupled architectures
  • Implementing domain-driven design principles
  • Creating testable and mockable codebases
  • Planning microservices decomposition

Core Concepts

1. Clean Architecture (Uncle Bob)

Layers (dependency flows inward):

  • Entities: Core business models
  • Use Cases: Application business rules
  • Interface Adapters: Controllers, presenters, gateways
  • Frameworks & Drivers: UI, database, external services

Key Principles:

-

(truncated - see the full file via the links below)

Read as markdown · JSON record · Browse the source repository

File tree — 1 file
bundled/skills/architecture-patterns/SKILL.md

Related skills

Tags

layered-design separation-of-concerns testability-first domain-modeling adapter-pattern business-logic-isolation framework-agnostic consistency-boundaries inversion-of-control