agentleFS
junhjangjunhjang/claude-harness/.claude/skills/doc-pattern/SKILL.md

doc-pattern

Skill0 starsChanged 6 months agoMITView on GitHub

Creating a new doc file under docs/ — PRD, RFC, ADR, SPEC, TDD, AUDIT, POSTMORTEM, README. Selects the right doc type based on trigger rules, applies frontmatter, decides single-file vs folder layout.

The file

We split this skill into the rules it gives an agent

2 rules. About 0 are common, 1 is distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Single file → folder promotion: when 2nd ADR is needed or RFC accumulates more than one screen.

    line 31
  2. Distinctive:

    If unsure which type, ask before writing.

    line 35

≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Apply when creating a new doc under docs/. Full rationale: docs/harness/doc-pattern.md.

  1. 8 doc types, each answers one question.
    • PRD: why exists / who uses
    • RFC: alternatives explored
    • ADR: what was committed
    • SPEC: input/output contract
    • TDD: internal mechanics (only if non-trivial)
    • AUDIT: does it still work (output of automation)
    • POSTMORTEM: post-incident only, never speculative
    • README: how to run / observe / stop
  2. Triggers — write only when fired. PRD + README always. RFC: irreversible decision OR multiple credible alternatives. ADR: per RFC conclusion or small committed decision. SPEC: output consumed by another system. TDD: code unreadable in <30min. AUDIT: output is automation input. POSTMORTEM: actual incident only. Empty docs are worse than missing docs.
  3. Frontmatter required:
    type: PRD | RFC | ADR | SPEC | TDD | AUDIT | POSTMORTEM | README
    status: draft | accepted | superseded | retired
    owner: <author>
    last-reviewed: YYYY-MM-DD
    ADRs may add supersedes / superseded-by.
  4. Single file → folder promotion when 2nd ADR is needed or RFC accumulates more than one screen. git mv components/X.md components/X/SPEC.md. Update CLAUDE.md to point at the folder.
  5. Status discipline. ADR never edited — supersede with new ADR + superseded-by link. PRD answers "why", SPEC answers "what" — don't mix in one doc. README is operator-facing and links to SPEC, never paraphrases it.

If unsure which type, ask before writing.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.