/rc:rc-writing-for-agentsfrom rc
Writes and audits agent-facing artifacts: skills, AGENTS.md, hooks. Audits context cost. Use when authoring or trimming these files. Not for READMEs.
Ships in rc. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
Every artifact an agent reads — a skill, a resident instruction file, a hook, a pointer doc — is the same object under different loading rules. They shared four skills and one doctrine; now they share one skill, because the doctrine is the part that matters and it was written four times.
The goal is predictability: the agent taking the same process every run, not producing the same output. Every lever below serves it.
Bold terms are defined in references/glossary.md.
| The artifact | Read |
|---|---|
| A skill — new, bloated, or with triggers that don't fire | references/authoring-procedure.md, then audit with references/checklist.md |
A skill whose references/ the agent ignores | references/loading-diagnosis.md in full, before proposing a fix |
AGENTS.md / CLAUDE.md — resident context | references/resident-files.md |
| A hook — a rule that must hold every time | references/hooks.md |
| "Where is my context window going?" | references/context-audit.md |
Every branch ends in a written audit, item by item — fix each Fail and re-audit. A document that reads well but fails its audit is not done. The doctrine below governs every line you write in any branch, not just the ones a procedure file mentions.
Every authoring decision trades these against each other:
description, every
line of a resident file, an MCP tool schema. Paid every turn, on every task, whether or not it
applies.Neither is free, so "just add it" is never the answer. A rule bearing on 5% of sessions taxes the other 95%, and rules dilute each other — instruction-following is a budget, so a bloated file enforces less, with the critical rule drowning in the noise.
And the reader is a frontier model. It knows git, testing, the language's idioms and general best practice, and it can read the codebase. It needs decisions, not knowledge, and it parses a crisp rule without an example. What survives is the delta: the difference between stock behavior and what this project needs.
The central method, and the reason this doctrine shortens documents rather than improving them:
Delete the line. Ask whether the agent's behaviour changed. If it didn't, the line was waste.
Run it sentence by sentence, not line by line. When a sentence fails, delete the whole sentence — do not trim words from it. Be aggressive: most prose that fails should go, not be rewritten. A weak directive is a no-op (be thorough, when the agent is already thorough-ish); the fix is a stronger word (relentless), not a longer explanation.
Content sits on a ladder ranked by how immediately the agent needs it:
Progressive disclosure is the move down that ladder. Branching is its cleanest test: inline what every branch needs, push behind a pointer what only some branches reach. A pointer's wording, not its target, decides whether the agent actually reaches the material. Where the ladder decides how far down a piece sits, co-location decides what sits beside it: keep a concept's definition, rules and caveats under one heading, so reading one part brings its neighbours along.
Push too little down and the top bloats; push too much and you hide what the agent needs. That tension is the whole decision.
A leading word is a compact concept already in the model's pretraining that the agent thinks with while running — seam, tracer bullet, red, tight, lesson. Repeated across a document it accumulates a distributed definition and anchors a whole region of behaviour in the fewest tokens, by recruiting priors the model already holds.
It pays twice. In the body it anchors execution — the agent reaches for the same behaviour every time the word appears. In a description it anchors invocation — when the same word lives in your prompts, docs and code, the agent links that shared language to the skill and fires it more reliably.
Hunt for the collapse. A triad spelled out at three sites, a description spending a sentence to gesture at one idea — each is begging to become one token:
Assume every document you touch is carrying restatements that a leading word retires.
Keep each meaning in a single source of truth — one authoritative place, so changing the behaviour is a one-place edit. Then check every line for relevance (does it still bear on what this does?) and run the no-op test on what remains. Nothing should appear twice in any form; duplication is the reliable sign of a document nobody tested.
When you abstract from a specific run, strip what belonged to that repo and write for the class of task. A document improves by getting shorter.
Use these to diagnose a document that isn't working:
Two choices with different costs:
disable-model-invocation: true) strips the description from the agent's reach:
only a human typing its name invokes it. Zero context load, paid in cognitive load.Choose model-invocation only when the agent or another skill must reach it on its own. When user-invoked skills multiply past what you can remember, the cure is a router: one user-invoked skill that names the others and when to reach for each.
Each cut spends one of the two budgets, so split only when the cut earns it:
Neither justifies a split whose only argument is that the topics feel separate. Two artifacts that need each other's vocabulary to explain themselves — where each description spends words saying what it is not — are one artifact that was cut in the wrong place.
references/glossary.md — full definition of every bold term.references/authoring-procedure.md — spec mechanics for a new skill: metadata rules, directory
layout, script conventions, validation.references/checklist.md — the exit audit: doctrine (Part A) plus spec compliance (Part B).references/loading-diagnosis.md — ignored references: symptoms, the pointer-strength ladder,
fixes in order.references/resident-files.md — AGENTS.md/CLAUDE.md: the rent test, the scope ladder, form.references/hooks.md — authoring a RC hook in the house style, wiring and verifying it.references/hook-events.md — the per-event I/O contract (which events reach the model, which can
block).references/context-audit.md — inventory and rank what consumes the window.scripts/validate-metadata.py — read-only; validates a name/description pair against the spec:
python3 <skill-dir>/scripts/validate-metadata.py --name "[name]" --description "[description]".assets/SKILL.template.md — skeleton for a new SKILL.md.assets/SKILL.template.md (opens in a new tab)references/authoring-procedure.md (opens in a new tab)references/checklist.md (opens in a new tab)references/context-audit.md (opens in a new tab)references/glossary.md (opens in a new tab)references/hook-events.md (opens in a new tab)references/hooks.md (opens in a new tab)references/loading-diagnosis.md (opens in a new tab)references/resident-files.md (opens in a new tab)scripts/validate-metadata.py (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
sonnetmediumThree short reads, in order
npx claudepluginhub rodolfochicone/rc-project --plugin rc32 skills in this plugin
/rcExplains RC — its skills, agents, hooks and artifacts. Use to learn what RC offers. Do not use to run a workflow step./rc-a11yGuias de acessibilidade (a11y) para web seguindo WCAG 2.2 AA — semântica HTML, ARIA, navegação por teclado, gestão de foco, contraste e leitores de tela. Use ao construir ou revisar UI (componentes, formulários, modais, navegação, tabelas). Não use para acessibilidade de PDF, auditoria jurídica de conformidade, ou design visual sem relação com a11y./rc-axumImplements and reviews Axum 0.8+ APIs in Rust — routing, State, extractors, Tower middleware, typed errors, WebSockets, CORS, timeouts, hardening. Use when building or changing Axum backends, handlers, middleware, or WS endpoints. Do not use for SvelteKit (rc-sveltekit), the SQLx data layer alone (rc-sqlx), or Rust language idioms (rc-rust)./rc-boardDrives a Linear or Jira board through its MCP server as a Product Manager — create, update, or search issues, refine one into a PRD/TechSpec with native child issues, or execute its children with test evidence. Use when working a tracker. Do not use for GitHub Issues, bulk imports, or when no board MCP is configured./rc-codebase-designVocabulary for deep modules — interface, depth, seam, adapter. Use when deciding where an interface goes. Do not use for UI (rc-interface-design)./rc-codemapBuilds and refreshes per-directory codemap.md as a cheap structure map. Use before exploring a large repo. Do not use to trace one bug.Other plugins' skills for the same job