Skip to main content
skill CX Codex

documentation-criteria — Claude Code skill: docs and setup

The documentation-criteria Claude Code skill selects the documents a change needs and determines where they belong. It activates for documentation planning and when creating or reviewing a technical document.

MIT ★ 720 updated 2026-11-11

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add shinpr/claude-code-workflows --skill documentation-criteria -a claude-code
Open on GitHub

What documentation-criteria does

The skill routes a change to the right set of documents and sets their order. It covers PRDs, ADRs, UI Specs, Design Docs, and Work Plans. A PRD records the intended outcome and acceptance criteria; an ADR captures a lasting technical choice, while a Work Plan lays out tasks and verification.

The route depends on structural scale. A small change goes straight to implementation; a medium one starts with a Design Doc and Work Plan, while a large one begins with a PRD. A UI Spec comes before the Design Doc when interface decisions are still open. ADRs go there too, but only for choices that need comparison and will shape future work. Existing ADRs are checked first, and local changes that follow an accepted design stay in the Design Doc.

What it helps with

  • select the documents a change requires
  • decide whether a technical choice needs an ADR
  • check whether open interface decisions call for a UI Spec
  • order PRD, Design Doc, and Work Plan preparation

Example prompts for the agent

  • Decide which documents this change needs.
  • Check whether the storage choice warrants an ADR.
  • Assess the change's scale and order the documentation work.

How to install documentation-criteria

1Skills CLI (Vercel)

npx skills add shinpr/claude-code-workflows --skill documentation-criteria -a claude-code

2Manually: put the files in place

~/.claude/skills/documentation-criteria/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/documentation-criteria/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about documentation-criteria

How do I install documentation-criteria in Claude Code?

Run npx skills add shinpr/claude-code-workflows --skill documentation-criteria -a claude-code. The skill file is at ~/.claude/skills/documentation-criteria/SKILL.md.

What does documentation-criteria do?

It decides whether a change needs a PRD, ADR, UI Spec, Design Doc, or Work Plan, and sets the preparation order. It also determines where each document belongs.

What makes a technical choice qualify for an ADR?

There must be at least two materially different options, and the choice must affect something future work needs to preserve or understand. Existing ADRs are checked first.

Source text

SKILL.md · MIT
---
name: documentation-criteria
description: Determines which of PRD, ADR, UI Spec, Design Doc, and Work Plan a change requires, and where each is stored. Use when deciding documentation scope, or when creating or reviewing a technical document.
---

# Documentation Creation Criteria

This file holds the routing decision: which documents a change requires and where they live. What to write inside one is defined by its template, linked from Storage Locations.

## What Each Document Fixes

Each document fixes one class of decision that the repository alone cannot supply. An unfilled section becomes a guess made later by the consumer named below, with no record of what was assumed.

- **PRD** — Fixes the business outcome and the acceptance criteria later work traces to. Its AC IDs are the traceability keys that the Design Doc, UI Spec, and test selection reuse; without them each consumer re-derives requirements from prose and the link between a test and the value it protects is lost. Implementation details belong to the Design Doc, selection rationale to an ADR, phases and task breakdown to the Work Plan. Later design, review, and test selection treat its content as governing, so a precondition held outside the repository change, such as release execution or organizational approval, appears in it only when the user's wording raises it.

- **ADR** — Records one durable technical choice and the options it beat, so later work can tell a deliberate decision from an accident. Without it a future change either re-runs the same comparison or silently reverses it. `Accepted` records the currently selected means, not an obligation to retain it: when later evidence supports a smaller sufficient choice, update or supersede the decision while the outcome, desired-future requirements, and non-goals remain true. End-to-end implementation design belongs to the Design Doc, schedule and repository tasks to the Work Plan.

- **UI Spec** — Records screen structure, transitions, component/state contracts, and visual acceptance before components exist, so decomposition is decided before implementation instead of per-component during it. Create one when those decisions remain open; reuse an approved UI Spec or go straight to the Design Doc when one evident repository-supported pattern already determines them. Technical implementation and API contracts belong to the Design Doc.

- **Design Doc** — Records the complete implementation design for the scope of the requirements: flows, contracts, change impact, and verification strategy. Task execution treats it as the primary technical baseline, so implementation does not silently invent missing How. The same baseline turns anything written in it into planned and implemented work, so release execution, production operation, and other work outside the repository change stay out of it; a requirement that describes such work is met by designing the capability it uses. When repository evidence invalidates technical How while the outcome, desired-future requirements, and non-goals remain true, correct the implementation and the affected technical artifact through their owning workflow without reopening product requirements. Technology selection rationale belongs to an ADR, schedule and assignments to the Work Plan.

- **Work Plan** — Fixes task order, dependencies, executable verification, and the earliest vertical proof point. Without it task order follows file layout rather than dependency, and integration risk moves to the end of the work. Design detail is referenced from the Design Doc rather than restated. Each task is repository work the executor completes and verifies during implementation using repository artifacts and its own output.

## Creation Decision Matrix

| Structural Scale | Base Documents | Creation Order |
|------------------|----------------|----------------|
| Small | None | Direct implementation |
| Medium | Design Doc → Work Plan | Start with Design Doc |
| Large | PRD → Design Doc → Work Plan | Continue after PRD approval |

Build one path in this order:

1. Select the base path from Structural Scale.
2. Insert an applicable UI Spec immediately before the Design Doc.
3. One or more qualifying ADR decision points insert an ADR batch immediately before the Design Doc. A qualifying decision point sets the scale floor to Medium.

## Structural Scale

Classify the decision burden, not repository layout. File count is supporting evidence only.

| Scale | Structural condition |
|-------|----------------------|
| Small | One coherent outcome has one evident repository-supported implementation within one responsibility boundary and no unresolved durable choice |
| Medium | One coherent outcome coordinates across a boundary or requires investigation of a potentially durable choice |
| Large | Multiple independently valuable outcomes require separate design decisions |

A qualifying ADR decision point sets the floor at Medium because it creates a durable decision. One coherent outcome remains Medium when it crosses multiple layers; Large requires independently valuable outcomes with separate design decisions.

## ADR Decision Filters

Apply the Choice filter, then the Durability filter, to each technical topic inside the implementation scope. Apply them independently from Structural Scale, and check existing ADRs first.

1. **Choice requires judgment** — current requirements, accepted decisions, and representative repository evidence support at least two credible, materially distinct options whose selection requires comparison.
2. **Decision is durable** — choosing among those options materially changes responsibility, dependency direction, a shared contract, persistence, a technology dependency, reversibility, or lifecycle cost that future work must preserve or understand.

Create one ADR for each topic that passes both filters, and review the complete batch together. Treat choices as one decision point when they must be selected or reconsidered together; separate independently revisitable choices.

Qualifying durable choices include:

- introducing or replacing a technology, library, platform, storage model, or external dependency;
- changing ownership, dependency direction, a trust boundary, or a shared public contract when credible alternatives exist;
- replacing an accepted architecture decision with a different durable choice that passes both filters;
- choosing an irreversible or high-cost-to-reverse data or compatibility strategy.

A local contract, data-flow, state, or component change belongs in the Design Doc when it follows an accepted design, has one evident repository-supported implementation, or remains cheaply reversible. Counts of files, consumers, nesting levels, states, steps, and asynchronous operations are supporting evidence rather than ADR criteria. Only the qualifying decisions above create ADRs; generic technical concerns, operational possibilities, and rejected activities can only support that determination.

## Storage Locations

| Document | Path | Naming Convention | Template |
|----------|------|------------------|----------|
| PRD | `docs/prd/` | `[feature-name]-prd.md` | [prd-template.md](references/prd-template.md) |
| ADR | `docs/adr/` | `ADR-[4-digits]-[title].md` | [adr-template.md](references/adr-template.md) |
| UI Spec | `docs/ui-spec/` | `[feature-name]-ui-spec.md` | [ui-spec-template.md](references/ui-spec-template.md) |
| UI Spec Assets | `docs/ui-spec/assets/{feature-name}/` | Prototype code files | - |
| Design Doc | `docs/design/` | `[feature-name]-design.md` | [design-template.md](references/design-template.md) |
| Work Plan | `docs/plans/` | `YYYYMMDD-{type}-{description}.md` | [plan-template.md](references/plan-template.md) |
| Task File | `docs/plans/tasks/` | `{plan-name}-task-{number}.md` | [task-template.md](references/task-template.md) |

*Note: Work plans are excluded by `.gitignore`

## References

Each template defines the content, structural elements, and diagram criteria for its document: [prd-template.md](references/prd-template.md), [adr-template.md](references/adr-template.md), [ui-spec-template.md](references/ui-spec-template.md), [design-template.md](references/design-template.md), [plan-template.md](references/plan-template.md), [task-template.md](references/task-template.md)

© shinpr · MIT · shinpr/claude-code-workflows

Similar skills

All skills for Writing and docs →

From the same set43

The whole set →
llm-friendly-context llm-friendly-context rewrites prompts, handoffs and generated docs so the next agent can see the inputs, the steps and what counts as done. Useful whenever text goes to another model. CX Codex +1 ★ 720repo stars requirement-convergence requirement-convergence — a Claude Code skill that isolates a project outcome from proposed requirements and records user-stated exclusions. Runs at requirement intake before any system design begins. CX Codex +1 ★ 720repo stars work-planner The work-planner Claude Code subagent turns approved Design Docs into implementation plans with tasks, dependencies, and checks. It activates for work-plan or task-planning requests. CX Codex ★ 720repo stars typescript-rules Enforces React and TypeScript rules for frontend work: type safety, component structure, state ownership and error handling. CX Codex +1 ★ 720repo stars codebase-analyzer codebase-analyzer — a Claude Code subagent that inspects repository facts before creating a Design Doc. Runs on an approved PRD path or verbatim requirements to surface reuse, contract impacts, and risks. CX Codex ★ 720repo stars code-verifier The code-verifier Claude Code subagent checks claims in PRDs, design docs, and work plans against repository evidence. Run it before document review, after implementation, or to verify a description of an existing system. CX Codex ★ 720repo stars scope-discoverer scope-discoverer discovers functional scope across existing codebases for reverse documentation. Groups features into PRD-ready units. CX Codex ★ 720repo stars ui-spec-designer The ui-spec-designer Claude Code subagent turns interface requirements into a specification of screens, states, and components. It activates for frontend design work or requests to break a UI into components. CX Codex ★ 720repo stars

Project sponsors

Companies that keep this analytics open