domain-driven-design
它能做什么
帮助规划和组织领域驱动设计(DDD)的工作,从最初的策略到实际落地实现,尤其适用于复杂系统。
适用场景
- ✓业务复杂且变化迅速时。
- ✓多个团队需要协同工作、避免冲突时。
- ✓想把规划决策与代码的编写方式联系起来时。
技能链接
https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/domain-driven-design/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“评估一下我们的支付平台是否应该采用领域驱动设计,以及下一步该做什么。”
每周 5 个新技能,1 分钟读完。
工作原理
这个工具会先判断 DDD 是否适合你的问题。然后,它会帮你定义业务的各个部分以及它们之间如何通信,并在每个阶段为你指引合适的工具。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Domain-Driven Design
Use this skill when
- You need to model a complex business domain with explicit boundaries.
- You want to decide whether full DDD is worth the added complexity.
- You need to connect strategic design decisions to implementation patterns.
- You are planning CQRS, event sourcing, sagas, or projections from domain needs.
Do not use this skill when
- The problem is simple CRUD with low business complexity.
- You only need localized bug fixes.
- There is no access to domain knowledge and no proxy product expert.
Instructions
- Run a viability check before committing to full DDD.
- Produce strategic artifacts first: subdomains, bounded contexts, language glossary.
- Route to specialized skills based on current task.
- Define success criteria and evidence for each stage.
Viability check
Use full DDD only when at least two of these are true:
- Business rules are complex or fast-changing.
- Multiple teams are causing model collisions.
- Integration contracts are unstable.
- Auditability and explicit invariants are critical.
Routing map
- Strategic model and boundaries:
@ddd-strategic-design - Cross-context integrations and translation:
@ddd-context-mapping - Tactical code modeling:
@ddd-tactical-patterns - Read/write separation:
@cqrs-implementation - Event history as source of truth:
@event-sourcing-architectand@event-store-design - Long-running workflows:
@saga-orchestration - Read models:
@projection-patterns - Decision log:
@architecture-decision-records
If templates are needed, open references/ddd-deliverables.md.
Output requirements
Always return:
- Scope and assumptions
- Current stage (strategic, tactical, or evented)
- Explicit artifacts produced
- Open risks and next step recommendation
Examples
Use @domain-driven-design to assess if this billing platform should adopt full DDD.
Then route to the right next skill and list artifacts we must produce this week.
Limitations
- This skill does not replace direct workshops with domain experts.
- It does not provide framework-specific code generation.
- It should not be used as a justification to over-engineer simple systems.
常见问题
什么是领域驱动设计(DDD)?
它是一种组织软件开发的方法,重点在于深入理解“领域”(也就是业务问题)及其运作方式,在复杂系统中尤其有用。
什么时候真正需要 DDD?
当业务规则复杂、频繁变化,或者多个团队需要在一个庞大且高度集成的系统上协作时,它最有用。
这个工具会帮我写代码吗?
不会。它帮助规划和组织工作,但不会直接生成代码,也无法替代与领域专家的沟通。
详情
作者的原始描述
Plan and route Domain-Driven Design work from strategic modeling to tactical implementation and evented architecture patterns.
热度
- GitHub 星标
- 48k
- 排名
- #4488
- 许可证
- MIT
- 更新时间
- 2026/10/15
评论
- …
同一仓库的更多技能
00-andruia-consultant
48k帮你的智能体启动或改进 AI 项目。它可以分析代码、推荐工具,并用西班牙语制定行动计划。
007
48k让你的智能体执行安全审计和威胁建模。它有助于保护项目免受攻击和漏洞的威胁。
10-andruia-skill-smith
48k帮你的智能体创建或改进 AI 工具。它可以定义工具的工作方式、编写文档,并验证其结构。
20-andruia-niche-intelligence
48k让你的智能体创建某个特定行业的摘要。它有助于借助可靠的信息来源,了解项目的背景、规则、使用模式和风险。