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 agentmods add skills/yibie/spec-agents.md/capturenpx skills add yibie/SPEC-AGENTS.md --skill capturegit clone --depth 1 https://github.com/yibie/SPEC-AGENTS.mdWrote 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/yibie/spec-agents.md/capture)<a href="https://agentmods.dev/skills/yibie/spec-agents.md/capture"><img src="https://agentmods.dev/badge/skills/yibie/spec-agents.md/capture.svg" alt="Measured on agentmods" 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.00051 | $0.00917 |
| Opus 5 | $0.00026 | $0.00458 |
| Sonnet 5 | $0.00010 | $0.00183 |
| Haiku 4.5 | $0.00005 | $0.00092 |
Grade A, and why
capture 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 today.
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.
How it starts
The opening of the file, as written. The whole thing — 82 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Capture
把已确认的共识写成一个活的设计契约。
前置条件
plan已结束并得到approve、compatible revise、breaking,或明确的plan-only执行授权。breaking时,SPEC 必须包含迁移方案;ADR 不在这里写, 由learn收尾时写。- 设计需要跨多个上下文,或必须交给之后的 agent 继续。
.spec-agents/doctrine/docs/WORKFLOW.md、CONTEXT.md、项目.spec-agents/state/KERNEL.md(若存在)、 相关 ADR、Protocol、Runbook 和 Lesson 已被读取;冲突回到plan。
写入位置
创建或更新:
.spec-agents/specs/<feature>/SPEC.md
不要在根目录再创建第二份 SPEC。目录不存在时按需创建;不要预建未来 feature 的文件。
SPEC 最小结构
# <feature>
status: draft | confirmed | in-progress | revised | verified | superseded
revision: <number>
# 或使用下面的列表形式(示例取自本 SPEC):
kernel_delta: none
# kernel_delta:
# - revise: Model delta (SPEC section gains normative meaning)
# - revise: capture Action Contract (kernel_delta field, mandatory on new SPECs)
# - revise: learn Action Contract (promotion must match the declaration)
context_refs:
## Problem and goal
## Unchanged contracts
## Decision and boundaries
## Model delta
## Action Contracts
## Seams and verification
## Compatibility and migration
## Out of scope
## Issue map
## Revision notes
verified 是完成工作的终态,由 learn 在收尾时写入;capture 不写它。
superseded 是另一条出口——被另一份 SPEC 取代——两者不是同义词。
每个由 capture 创建的 SPEC 都必须显式带有 kernel_delta:;none 是合法的明确答案。
关于 ## Model delta 的含义、缺失字段的读取方式以及 Kernel 条目的范围,见
.spec-agents/doctrine/docs/WORKFLOW.md 的 SPEC 定义。列表的动词限于
add | revise | supersede | retire,每个 <entry> 命名 Kernel 条目,不命名文件。
记录“已经决定的 what/why/where”,不要把新的取舍藏进 SPEC。实现细节只写到能让后续切片保持一致的程度。
当 SPEC 是 Kernel Bootstrap 时,记录 K1 已确认的概念、关系、动作契约和
不变量,以及待确认的扩展;不要把 K1 复制成第二份长期真相。验证通过后由
learn 更新项目 .spec-agents/state/KERNEL.md。
修订
- 文字澄清、链接和验证补充可以直接修订。
- 改变目标、边界、身份、关系、不变量、接口或验收标准,必须重新经过
plan。 - 修订时保留 revision、原因、受影响的 CONTEXT/Protocol、兼容性、迁移和验证。
- 受影响的 Slice 标为
stale;不要让旧 Slice 继续执行。
完成条件
SPEC 状态、未改变的契约、边界、Action Contracts、验证入口和 out-of-scope 齐全,并能让一个新上下文不依赖本次对话继续工作。
若已确认的 plan 结果记录了 kernel_promotion 且不为 none,而 kernel_delta 为空或为 none,capture 必须停下、报告并不得完成,以防止重现 upstream SPEC-AGENTS Evidence E-20260821-006 记录的决定丢失。
What ships with it
1 file 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.
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.
- today Changed · +15 lines 6da831bc6bbf
- 6d ago First seen · 67 lines · 51 tokens per session scan A e629b381296a
capture is a skill published in the GitHub repository yibie/SPEC-AGENTS.md (126 stars, last pushed 4d ago), licensed MIT. It adds 51 tokens to every session and 917 once invoked, about $0.0003 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.
Other skills, from other repositories
systematic-debugging
Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.
local-ai-agents
Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…
next-cache-components-adoption
Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…
next-cache-components-optimizer
Drive a Next.js route to instant navigation by setting up an agentic loop, under Cache Components / PPR, on initial load (hard navigation) and client-side navigation (soft navigation). Encode the goal as a failing @next/playwright instant() e2e and work it to green, one verified route at a time; the shipped test then…
next-partial-prefetching-adoption
Turn on Partial Prefetching in a Next.js app and work through the insights it surfaces. Use when the user wants to enable or adopt Partial Prefetching, flip the partialPrefetching flag, opt routes in with export const prefetch = 'partial', audit Link prefetch={true} behavior, preserve existing prefetched UI with…
chronicle
Analyze Copilot session history for standup reports, usage tips, session search, and session reindexing. Use when the user asks for a standup, daily summary, usage tips, workflow recommendations, wants to search or find past sessions by keyword/file/PR, wants to reindex their session store, or asks about deleting…