---
name: agentify-doc
description: >
  Rewrite, compress, tighten, condense, shorten, or "agentify" an existing agent-facing
  doc (SKILL.md, CLAUDE.md, spec, standard, plan, system prompt) that is verbose or
  token-bloated. Triggers on "make this leaner for agents", "cut tokens from this doc",
  "rewrite this skill concisely", "tokenomics", "agentify".
---

# Agentify a Document — Tokenomics-Aware Rewrite

**Goal:** same behavior from the agent, fewer tokens. Compress **form, never content**. The win is tokens removed that do not change what the model does; removing a load-bearing example, decision rule, or scope qualifier is a regression, not a win.

The naming/structure law lives in the `agent-doc-authoring` skill — read it first; this skill is the *operation* that applies it to existing text.

**Register = caveman** (per `agent-doc-authoring` → "Register: caveman compression"). Beyond cutting filler, also drop articles (a/an/the) and write in fragments. HARD FLOOR is non-negotiable: normative keywords (MUST/MUST NOT/NEVER/ALWAYS/SHOULD), rule + invariant IDs and their exact statement, identifiers/paths/types/signatures, code + JSON blocks, contract clauses + gate conditions — all survive verbatim. Caveman touches connective prose only, never the normative/actionable surface.

## Procedure (ladder — do in order)

1. **Inventory the substance.** Before cutting, list what must survive: every technical fact, decision rule (`if X → do Y`), load-bearing before/after example, scope qualifier, normative keyword, rule/invariant ID, and security/hard-floor/data-loss item. This list is the floor; nothing on it is negotiable.
2. **Cut zero-activation tokens.** Filler (just/really/basically/simply), hedging, pleasantries, narrative connective tissue, throat-clearing intros, restated conclusions. These change no model behavior.
3. **Collapse prose → ladders/checklists.** Numbered steps and bullet rules are denser *and* more reliably followed than paragraphs.
4. **Replace codenames with recognized principle names** (per agent-doc-authoring). A 2-token recognized name (e.g. "idempotent", "memoize") can replace a sentence of description — high tokenomic yield *and* better activation. Run the add-vs-restrain test on each.
5. **De-duplicate — point, don't repeat.** Replace a re-stated rule with a reference to its one canonical location.
6. **BLUF each section.** Rule/result first; rationale after, trimmed to what an agent needs to apply the rule.
7. **Re-check the floor.** Diff against the step-1 inventory: every item still present and unambiguous. Concise ≠ cryptic — if a cut risks misread, restore it.

## Guardrails (reject these "compressions")

- **DO NOT invent private shorthand or codenames to save tokens** — fewer tokens but dead activation; that is the exact failure agent-doc-authoring exists to prevent.
- **DO NOT drop a before/after example** that anchors a rule. Examples are the 2nd-strongest lever; an unanchored rule is weaker even if shorter.
- **DO NOT compress into ambiguity.** If terseness forces the model to guess scope or intent, keep the longer form.
- **DO NOT caveman-compress the HARD FLOOR.** Dropping an article from prose is a win; dropping/softening a MUST, a rule ID, an identifier, or a contract clause inverts meaning — that is a regression, not compression.
- **DO NOT touch content on the substance floor** — security, data-loss, trust-boundary, and decision rules are preserved verbatim in meaning.
- **DO NOT silently delete.** Report what was cut (see Output).

## Output

- Write the rewritten doc in place (Edit/Write).
- Preserve the human-readable original as `<file>.original.md` if it has a human audience (mirrors the caveman `compress` convention).
- Report: **estimated token delta** (before → after, e.g. via `wc -w`/tokenizer estimate) and a short **cut-list** — what was removed and why. Never claim a clean compression without showing the delta and the cuts (no-ignored-signals).
