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.
npx skills add YangFan-Code-Star/context-dev --skill record-decisiongit clone --depth 1 https://github.com/YangFan-Code-Star/context-devWrote 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.
[](https://agentmods.dev/skills/yangfan-code-star/context-dev/record-decision)<a href="https://agentmods.dev/skills/yangfan-code-star/context-dev/record-decision"><img src="https://agentmods.dev/badge/skills/yangfan-code-star/context-dev/record-decision/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.
<a href="https://agentmods.dev/skills/yangfan-code-star/context-dev/record-decision"><img src="https://agentmods.dev/badge/skills/yangfan-code-star/context-dev/record-decision.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00068 | $0.00580 |
| Opus 5.5 | $0.00027 | $0.00232 |
| Sonnet 5.5 | $0.00014 | $0.00116 |
| Haiku 4.5 | $0.00007 | $0.00058 |
Grade A, and why
record-decision 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 1mo 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.
What it actually says
记录架构决策
代码能表达"做了什么",表达不了"为什么不用另一个方案"。缺了这部分,agent 会反复提议已经被否决过的东西,而你要一遍遍重新解释。
什么时候该写
- 在两个及以上方案之间做了选择,且另一个方案也说得通
- 引入或换掉一个核心依赖、框架、存储
- 定下一个会扩散到很多文件的约定(金额怎么存、时间怎么表示、错误怎么传)
- 明确否决了一个看起来很自然的做法
不该写的:没有取舍的选择("用项目已有的 logger")、随时可以改的局部实现、纯风格问题。
怎么写
- 找到
docs/decisions/里最大的编号,加一。文件名NNNN-用短横线连接的标题.md,标题是结论不是议题——写「金额用整数最小单位存储」,不要写「关于金额存储的讨论」。 - 复制
docs/decisions/template.md,填写。 - 关键在**「其他方案」一节:把认真考虑过的方案写下来,以及放弃它的具体原因**。这一节是 ADR 全部价值所在,只写一句"性能不好"等于没写。
- 如果这个决策会影响日常写代码的方式,在
AGENTS.md加一行指针,正文留在 ADR 里。
只增不改
决策变了不要改旧文件,写一份新的,然后在旧的顶部加一行:
> 已被 [ADR 0007](0007-xxx.md) 取代。
保留被推翻的记录,是为了让后来者知道"这条路走过了",而不是重新走一遍。
写完检查
- 标题是结论,不是议题
- 「其他方案」里每个被放弃的选项都有具体理由
- 没有写进真实密钥、生产数据或个人信息
- 如果影响日常写法,
AGENTS.md里留了指针
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.
- 1mo ago First seen · 42 lines · 68 tokens per session scan A a0085accfe53
record-decision is a skill published in the GitHub repository YangFan-Code-Star/context-dev (2 stars, last pushed 2mo ago), licensed MIT. It adds 68 tokens to every session and 580 once invoked, about $0.0003 per session on Opus 5.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-31.
Other skills, from other repositories
openspec-bulk-archive-change
Archive multiple completed OpenSpec changes at once. Use when archiving several parallel changes. Also use for a plural archive request - "openspec bulk-archive", "opsx bulk-archive", "openspec archive all", or "openspec archive these changes".
acceptance-test-authoring
Use when creating or modifying acceptance tests, configuring cucumber-js or behave runners, writing or refactoring step definitions, linting executable Gherkin specs, choosing an acceptance stack, or implementing OpenSpec tasks that involve acceptance tests.
openspec-bulk-apply-change
Use when multiple active OpenSpec changes should be applied concurrently in isolated worktrees with delegated verification and no merge.
gherkin-authoring
Use when drafting, reviewing, or improving Gherkin, Cucumber scenarios, BDD acceptance criteria, feature examples, Scenario Outlines, Backgrounds, Rules, Doc Strings, Data Tables, tags, or Gherkin embedded in Markdown.
architectural-decision-records
Use when documenting, drafting, reviewing, or updating architectural decisions, ADRs, decision logs, tradeoffs, rationale, consequences, alternatives, or architecture decision history.
adversarial-authoring
Use when rules or instructions mention "adversarial-authoring", "adversarial authoring", "must use adversarial-authoring skill", "model council", "cross-model review", or "mixture of models"; coordinates adversarial authoring and review subagents and records council notes.