maintain-agent-docs
GitHub维护仓库 Agent 文档,处理 AGENTS.md 兼容性、技能漂移及重复指令。通过更新源指针、移除过时指南和运行工作区检查来优化上下文预算,确保文档与可执行源码一致。
触发场景
安装
npx skills add videojs/video.js --skill maintain-agent-docs -g -y
SKILL.md
Frontmatter
{
"name": "maintain-agent-docs",
"description": "Maintain repository agent guidance. Use for AGENTS.md, CLAUDE.md compatibility, skill drift, duplicated instructions, or context budgets."
}
Agent documentation
Keep agent guidance as a routing and correction layer over project sources, not a second documentation system.
Placement
- Put durable, broadly applicable repository facts in the nearest
AGENTS.md. - Keep each
CLAUDE.mdas@AGENTS.mdunless Claude-only behavior is genuinely required. - Put an explicit, repeatable vertical workflow in a skill.
- Keep checked-in skills as direct children of
.agents/skills/; treat.claude/skills/and.opencode/skills/as generated directory aliases. - Put conditional detail in a directly linked skill reference.
- Put rules that can be mechanically checked in code, tests, lint, hooks, or
build/scripts/check-workspace.mjs. - When the user explicitly requests a durable record, put architecture rationale in
internal/design/,internal/decisions/, orrfc/; never create one as a default by-product of other work.
Process
- Identify the repeated failure or new fact and the executable source that proves it.
- Search existing agent docs and skills for overlap or contradiction.
- Prefer updating a source pointer or validator over copying code, schemas, commands, or examples.
- Remove obsolete guidance in the same change.
- Keep skill frontmatter portable:
nameand a precisedescriptiononly. - Run
pnpm check:workspaceand review the reported context budgets.
Do not add generic software advice the model already knows. Add a rule only when an agent would plausibly get this repository wrong without it.
Example
Input: “Remove duplicated setup instructions from agent guidance.”
Output: Smaller routing docs that point to executable sources, corrected aliases, passing validators, and an updated context-budget report.
版本历史
- 8a0a3d8 当前 2026-10-20 08:03


