跳到正文
cccskills
免费在 GitHub 公开

domain-modeling

Clarify project terminology and the relationships between business concepts. Check definitions against concrete scenarios and code, update GLOSSARY.md as terms are agreed, and record significant design decisions with their trade-offs when the stated criteria are met.

中文简介正在准备中。当前显示英语简介。

原文查看原文说明

构建并打磨项目的领域模型。适用于讨论 codebase 术语、编写或编辑 GLOSSARY.md,或记录或编辑 ADR。

实测评分 未实测

查看安装方法

适用场景

  • Clarifying ambiguous project terminology
  • Creating or updating GLOSSARY.md
  • Checking concept boundaries against code and edge cases
  • Recording significant design decisions and their trade-offs

包含的文件(4)

  • SKILL.md2.8 KB
  • ADR-FORMAT.md2.6 KB
  • agents/openai.yaml96 B
  • GLOSSARY-FORMAT.md2.2 KB

SKILL.md(原文)

安装前可以查看交给 AI 代理的指令内容。

领域建模

在设计过程中主动构建并打磨项目的 domain model。这是 active discipline:挑战术语、发明 edge-case scenarios,并在概念成形的当下写入 glossary 和 decisions。

文件结构

多数 repos 只有一个 context:

/
|- GLOSSARY.md
|- docs/
|  `- adr/
|     |- 0001-event-sourced-orders.md
|     `- 0002-postgres-for-write-model.md
`- src/

如果 root 有 GLOSSARY-MAP.md,说明 repo 有多个 contexts。map 指向每个 context 的位置:

/
|- GLOSSARY-MAP.md
|- docs/
|  `- adr/                          -> system-wide decisions
`- src/
   |- ordering/
   |  |- GLOSSARY.md
   |  `- docs/adr/                  -> context-specific decisions
   `- billing/
      |- GLOSSARY.md
      `- docs/adr/

按需懒创建文件:只有在有内容要写时才创建。如果没有 GLOSSARY.md,当第一个 term 被解决时创建它。如果没有 docs/adr/,当第一个 ADR 需要出现时创建它。

Session 期间

对照术语表质询

当用户使用的术语与 GLOSSARY.md 中既有语言冲突时,立即指出。"Your glossary defines 'cancellation' as X, but you seem to mean Y - which is it?"

打磨模糊用语

当用户使用模糊或过载术语时,提出一个精确的 canonical term。"You're saying 'account' - do you mean the Customer or the User? Those are different things."

讨论具体场景

讨论 domain relationships 时,用具体场景做压力测试。发明能探测 edge cases 的场景,迫使用户精确定义概念之间的 boundaries。

与代码交叉对照

当用户描述某事如何工作时,检查代码是否同意。如果发现矛盾,要指出:"Your code cancels entire Orders, but you just said partial cancellation is possible - which is right?"

就地更新 GLOSSARY.md

当一个 term 被解决时,立刻更新 GLOSSARY.md。不要批量攒到最后;随着概念出现就捕获。使用 GLOSSARY-FORMAT.md 中的格式。

GLOSSARY.md 必须完全不包含 implementation details。不要把 GLOSSARY.md 当 spec、scratch pad 或 implementation decisions 的仓库。它只是一份 glossary。

谨慎提议 ADR

只有以下三项都成立时,才提出创建 ADR:

  1. Hard to reverse - 之后改变主意的成本有意义
  2. Surprising without context - 未来读者会疑惑 "why did they do it this way?"
  3. The result of a real trade-off - 确实存在替代方案,而你基于具体理由选择了其中一个

缺少任一项就跳过 ADR。使用 ADR-FORMAT.md 中的格式。

评价

还没有评价。欢迎分享你的使用感受。

评论

无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。

还没有评论。来写第一条吧。

提交后会立即公开。请勿填写邮箱、电话等个人信息。URL 最多 2 个。

0 / 1000 字

此表单受 reCAPTCHA 保护,适用 Google 的隐私权政策和服务条款。

同一仓库的技能

ask-matt

免费

Find the right skill and sequence for your current development task, from shaping an idea to implementation, debugging, and review. The guide also explains when to prototype, prepare specifications, or move work into a fresh session.

中文简介正在准备中。当前显示英语简介。

  • Choose a workflow for turning an idea into working software
  • Find the starting point for a difficult bug investigation
  • Plan specifications and tickets for work across multiple sessions
vinvcn/mattpocock-skills-zh-CN52372026年10月20日 更新

Summarize the current conversation and launch a fresh background agent to continue the work. The handoff includes references to existing artifacts and suggested skills, removes sensitive information, and can emphasize the next session’s intended focus.

中文简介正在准备中。当前显示英语简介。

  • Continue ongoing work with a fresh agent
  • Focus the next session on a specific task
  • Hand off work using references to existing documents
vinvcn/mattpocock-skills-zh-CN52372026年10月20日 更新

Review changes from a chosen Git reference against both project coding standards and issue or specification requirements. Separate parallel reviews report rule violations, possible design problems, missing requirements, and changes beyond the intended scope.

中文简介正在准备中。当前显示英语简介。

  • Review a branch or pull request
  • Check changes since a specific commit
  • Find missing requirements or unintended scope
vinvcn/mattpocock-skills-zh-CN52372026年10月20日 更新

Design modules that expose simple interfaces while hiding substantial behavior. Use shared terms and principles to assess interface complexity, decide where behavior can be swapped, and organize code so callers and tests use the same interface.

中文简介正在准备中。当前显示英语简介。

  • Simplify a module interface
  • Review module structure during refactoring
  • Decide where behavior should be swappable
vinvcn/mattpocock-skills-zh-CN52372026年10月20日 更新

Diagnose difficult bugs and performance regressions by first building a repeatable check for the exact symptom. Minimize the reproduction, test ranked hypotheses, apply a fix, and verify the original scenario with regression tests where suitable.

中文简介正在准备中。当前显示英语简介。

  • Investigating persistent errors or incorrect output
  • Increasing reproduction rates for intermittent bugs
  • Measuring and diagnosing performance regressions
vinvcn/mattpocock-skills-zh-CN52372026年10月20日 更新

Set up Claude Code hooks that block specified Git commands before they run, including push and destructive cleanup operations. Choose project or global installation, adjust the blocked commands, and test that the hook rejects a sample command.

中文简介正在准备中。当前显示英语简介。

  • Blocking git push from Claude Code
  • Preventing commands that discard local changes
  • Installing Git guardrails across projects
vinvcn/mattpocock-skills-zh-CN52372026年10月20日 更新

查看 vinvcn 的全部技能

报告此技能的问题