ddd-practice
Skill4 starsChanged 5 months agoApache-2.0View on GitHub
Applies domain-driven design with bounded contexts, aggregates, and ubiquitous language. Use when modelling complex business domains, defining boundaries, or protecting invariants.
In this repository114 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- accessibility-wcagSkill
- agentic-ux-patternsSkill
- ai-model-governanceSkill
- api-design-and-lifecycleSkill
- apply-laws-of-aiSkill
- bdd-practiceSkill
- browser-testing-with-devtoolsSkill
- business-capability-modelingSkill
- business-information-concept-modelingSkill
- capability-maturity-assessmentSkill
- cdc-and-source-to-stream-ingestionSkill
- ci-cd-and-automationSkill
- cloud-platform-architectureSkill
- code-review-and-qualitySkill
- cognitive-bias-reviewSkill
- conceptual-data-modelingSkill
- context-engineeringSkill
- data-contract-designSkill
- data-governance-and-qualitySkill
- data-integration-and-interoperabilitySkill
- data-lifecycle-and-retention-managementSkill
- data-lineage-and-provenanceSkill
- data-product-dashboard-designSkill
- data-product-designSkill
- data-security-and-privacy-architectureSkill
- deprecation-and-migrationSkill
- design-system-practiceSkill
- documentation-and-adrsSkill
- dora-four-keysSkill
- dry-principleSkill
- eip-integration-validationSkill
- evaluation-and-monitoringSkill
- event-driven-architectureSkill
- event-governance-and-lineageSkill
- event-modelingSkill
- event-streaming-platform-designSkill
- exception-handling-and-recoverySkill
- finops-practiceSkill
- frontend-state-and-interaction-designSkill
- git-workflow-and-versioningSkill
- goal-setting-and-monitoringSkill
- guardrails-safety-patternsSkill
- human-in-the-loopSkill
- idea-refinementSkill
- incident-response-and-postmortemsSkill
- incremental-implementationSkill
- infrastructure-as-codeSkill
- integration-message-constructionSkill
- inter-agent-communication-a2aSkill
- kiss-principleSkill
- knowledge-graph-ragSkill
- knowledge-retrieval-ragSkill
- krag-evaluation-governanceSkill
- krag-ingestion-graph-constructionSkill
- krag-retrieval-answeringSkill
- krag-system-designSkill
- lakehouse-and-medallion-architectureSkill
- learning-and-adaptationSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
9 rules. About 0 are common, 8 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈8
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 13
Use this skill when modelling complex business behaviour, designing service boundaries, refactoring an anemic domain model, defining …
- Distinctive: line 17
Create a maintainable domain model that reflects the business language, protects invariants, isolates bounded contexts and separates domain …
- Distinctive: line 26
Keep domain logic in the domain layer.
- Distinctive: line 27
Use domain events for important state changes that other components need to react to.
- Distinctive: line 42
Do not create elaborate DDD structure for CRUD-only or simple scripting problems.
- Distinctive: line 43
Do not let database schemas dictate aggregate boundaries by default.
- Distinctive: line 44
Do not allow controllers, API handlers, ORM models or LLM prompts to become the only place where business rules live.
- Very specific: line 45
Prefer explicit domain terms over generic technical names such as Manager, Processor, Handler or Data.
- Distinctive: line 46
Keep bounded contexts independent.
≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Domain-Driven Design (DDD)
When to use
Use this skill when modelling complex business behaviour, designing service boundaries, refactoring an anemic domain model, defining aggregates, separating subdomains, aligning code with business language, or implementing domain rules that should not leak into infrastructure code.
Objective
Create a maintainable domain model that reflects the business language, protects invariants, isolates bounded contexts and separates domain logic from technical plumbing.
Procedure
- Identify the business capability, subdomain and stakeholders.
- Capture the ubiquitous language: key terms, events, commands, policies, invariants and ambiguous words.
- Define bounded contexts and context boundaries before designing classes or services.
- Classify domain concepts as entities, value objects, aggregates, domain services, repositories, domain events or application services.
- Define aggregate boundaries around consistency rules, not database tables.
- Keep domain logic in the domain layer; keep persistence, messaging, UI and external integrations in adapters or infrastructure.
- Use domain events for important state changes that other components need to react to.
- Validate the model with examples, tests and, where useful, BDD scenarios.
Tactical modelling guidance
- Entity: has identity and lifecycle.
- Value object: immutable description with equality by value.
- Aggregate: consistency boundary with a root that protects invariants.
- Repository: persistence abstraction for aggregate roots.
- Domain service: domain operation that does not naturally belong to one entity or value object.
- Application service: orchestration layer; it coordinates use cases but should not contain core domain rules.
- Domain event: fact that something meaningful happened in the domain.
Rules
- Do not create elaborate DDD structure for CRUD-only or simple scripting problems.
- Do not let database schemas dictate aggregate boundaries by default.
- Do not allow controllers, API handlers, ORM models or LLM prompts to become the only place where business rules live.
- Prefer explicit domain terms over generic technical names such as
Manager,Processor,HandlerorData. - Keep bounded contexts independent; integration between contexts should use explicit contracts, events or anti-corruption layers.
Related skills
bdd-practice— scenarios using ubiquitous languagespec-driven-development— bounded context in specsconceptual-data-modeling— link domain concepts to data models
References
Verification
- Bounded context and key domain terms stated.
- Aggregate or boundary decisions documented.
- Invariants protected identified.
- Modelling assumptions requiring business validation noted.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

