domain-modeling

domain-modeling is a skill for Claude Code, Codex from devcxl/mattpocock-skills-zh. It costs 35 tokens per session (827 once invoked), scanned A, original, MIT.

A skill for building and maintaining a shared model of the important concepts in a software project. It records precise terms, relationships, and architectural decisions in files such as CONTEXT.md and architecture decision records.

In plain words
What is it for?
Use it when discussing project terminology, defining domain concepts, editing context documentation, recording decisions, or checking proposed relationships against the code.
Why use it?
It helps resolve ambiguous or conflicting language and keeps the documented model aligned with how the code actually works.

Skill for Claude CodeCodex

Written for Claude Code and Codex: shipped in a Claude Code plugin, but also agents/openai.yaml present.

Part of the mattpocock-skills plugin — 37 skills shipped together

Good fit Use it when discussing project terminology, defining domain concepts, editing context documentation, recording decisions, or checking proposed relationships against the code.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/devcxl/mattpocock-skills-zh/domain-modeling
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add devcxl/mattpocock-skills-zh --skill domain-modeling
Clone the repo
git clone --depth 1 https://github.com/devcxl/mattpocock-skills-zh

Made for: Claude Code, Codex.

Or install mattpocock-skills, the plugin that ships this one along with the rest of its 37 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for domain-modeling

README.md
[![agentmods](https://agentmods.dev/badge/skills/devcxl/mattpocock-skills-zh/domain-modeling/github.svg)](https://agentmods.dev/skills/devcxl/mattpocock-skills-zh/domain-modeling)
Your own site
<a href="https://agentmods.dev/skills/devcxl/mattpocock-skills-zh/domain-modeling"><img src="https://agentmods.dev/badge/skills/devcxl/mattpocock-skills-zh/domain-modeling/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for domain-modeling

Your own site · 80×15
<a href="https://agentmods.dev/skills/devcxl/mattpocock-skills-zh/domain-modeling"><img src="https://agentmods.dev/badge/skills/devcxl/mattpocock-skills-zh/domain-modeling.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 35 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 827 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00035 $0.00827
Opus 5 $0.00017 $0.00413
Sonnet 5 $0.00007 $0.00165
Haiku 4.5 $0.00003 $0.00083

Measured 11d ago against content hash 20bcb652ce2c, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade A, and why

domain-modeling scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/engineering/domain-modeling/SKILL.md · 75 lines

What it actually says

Domain Modeling(领域建模)

在设计过程中主动构建和完善项目的领域模型。这是一门主动的学科——质疑术语、创造边界场景、在术语和决策形成的瞬间将其记录在案。(仅仅阅读 CONTEXT.md 来获取词汇不是此 skill 的用途——那是任何 skill 都能做的单行习惯。此 skill 用于你在修改模型,而非仅仅消费它。)

文件结构

大多数 repo 只有一个 context:

/
├── CONTEXT.md
├── docs/
│   └── adr/
│       ├── 0001-event-sourced-orders.md
│       └── 0002-postgres-for-write-model.md
└── src/

如果根目录存在 CONTEXT-MAP.md,则该 repo 有多个 context。该 map 指向每个 context 的位置:

/
├── CONTEXT-MAP.md
├── docs/
│   └── adr/                          ← 系统级决策
├── src/
│   ├── ordering/
│   │   ├── CONTEXT.md
│   │   └── docs/adr/                 ← context 特定决策
│   └── billing/
│       ├── CONTEXT.md
│       └── docs/adr/

懒加载创建文件——仅当有内容需要写入时才创建。如果 CONTEXT.md 不存在,在第一个术语确定时创建。如果 docs/adr/ 不存在,在第一个 ADR 需要时创建。

在会话期间

对照 glossary 提出质疑

当用户使用与 CONTEXT.md 中已有语言冲突的术语时,立即指出。"你的 glossary 将 'cancellation' 定义为 X,但你似乎指的是 Y——到底是哪个?"

优化模糊语言

当用户使用模糊或过载的术语时,提出精确的标准术语。"你说 'account'——指的是 Customer 还是 User?它们是不同的东西。"

讨论具体场景

当领域关系被讨论时,用具体的场景进行压力测试。创造能够探测边界案例的场景,迫使用户精确描述概念之间的界限。

与代码交叉引用

当用户陈述某事物的工作方式时,检查代码是否一致。如果发现矛盾,指出:"你的代码取消了整个 Orders,但你刚才说部分取消是可能的——哪个是对的?"

内联更新 CONTEXT.md

当术语确定时,立即更新 CONTEXT.md。不要批量处理——在发生时即时捕获。使用 CONTEXT-FORMAT.md 中的格式。

CONTEXT.md 应完全不含实现细节。不要将 CONTEXT.md 视为 spec、草稿本或实现决策的仓库。它是 glossary,仅此而已。

谨慎提供 ADR

仅当以下三个条件同时满足时才提供创建 ADR:

  1. 难以逆转——事后改变想法的成本很高
  2. 脱离上下文会令人困惑——未来的读者会想"他们为什么这样做?"
  3. 是真实权衡的结果——存在真正的替代方案,你因特定原因选择了其中一个

如果缺少任何一条,跳过 ADR。使用 ADR-FORMAT.md 中的格式。

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 11d ago First seen · 75 lines · 35 tokens per session scan A 20bcb652ce2c

Subscribe to this mod's changes

domain-modeling is a skill published in the GitHub repository devcxl/mattpocock-skills-zh (340 stars, last pushed 6d ago), licensed MIT. It adds 35 tokens to every session and 827 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.