Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
thienanblog avatar

Documentation Guidelines

  • 47 installs
  • 62 repo stars
  • Updated August 5, 2026
  • thienanblog/awesome-ai-agent-skills

Helps with documentation tasks.

About

documentation-guidelines is a Claude Code skill for documentation. It helps solo builders move faster with AI-assisted development.

  • documentation-guidelines
  • Documentation
  • AI-coding skill

Documentation Guidelines by the numbers

  • 47 all-time installs (skills.sh)
  • +3 installs in the week ending Aug 5, 2026 (Skillselion tracking)
  • Ranked #823 of 1,879 Documentation skills by installs in the Skillselion catalog
  • Data as of Aug 5, 2026 (Skillselion catalog sync)
npx skills add https://github.com/thienanblog/awesome-ai-agent-skills --skill documentation-guidelines

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs47
repo stars62
Last updatedAugust 5, 2026
Repositorythienanblog/awesome-ai-agent-skills

What it does

Helps with documentation tasks.

Files

SKILL.mdMarkdownGitHub ↗

Documentation Guidelines

Overview

Produce documentation that is easy to locate, owned by the correct repo/module/feature, and safe to use as a source of truth. Use this skill for monorepos and single-project repos when creating, reorganizing, or updating architecture docs, module docs, feature docs, API contracts, workflows, runbooks, testing notes, or debugging guidance. Prefer searchable filenames with explicit suffixes over repeated README.md files for detailed module docs.

Apply the workflow directly unless the repository has newer explicit agent instructions or a newer docs index that conflicts.

For detailed templates, read references/documentation-guidelines.md.

Non-Negotiable Reading Rule

Before summarizing, moving, deleting, or editing documentation:

1. Read the complete target file, not just search hits. 2. If root docs/README.md exists, read it first. It is the project routing index. 3. Read the owning repo README.md, local agent guide, and repo docs/README.md when they exist. 4. Read repo-level modules.md and features.md when resolving a module or feature. 5. Read the owning module doc at docs/modules/<module-id>/<module-id>-module.md when it exists. If a project still uses legacy docs/modules/<module-id>/README.md, read it and consider migrating it when editing. 6. Read all relationship docs marked Required. 7. Do not infer business logic from filenames, folder names, translated labels, role display names, or stale references. 8. If two docs appear duplicated, read both completely and identify the source-of-truth owner before deleting or merging.

Project Shape

Monorepo

A repo is a monorepo when it has multiple independent apps/services/packages or deployable runtimes, such as apps/*, services/*, or packages/*.

Use this documentation shape:

docs/
  README.md
  naming-and-structure.md
  relationship-map.md
  runbooks/
  decisions/

apps/<repo>/
  README.md
  docs/
    README.md
    modules.md
    features.md
    architecture/
    modules/
      order/
        order-module.md
        features/
          approve-order-api-feature.md
        workflows/
          order-approval-workflow.md
        runbooks/
          debug-order-approval-runbook.md
        order-testing.md
    reference/
    runbooks/
    memories/
    archives/

Root docs/ is a routing and coordination area. Detailed monorepo docs always live inside the owning repository, such as apps/api/docs/..., not under root docs/<repo-id>/....

Root docs/README.md must link to each repo docs index, repo-level modules.md, and repo-level features.md. It must not copy every feature into a full global feature list.

Single Project

A single-project repo may keep all docs under root docs/, but still uses the same index model:

docs/
  README.md
  naming-and-structure.md
  modules.md
  features.md
  architecture/
  modules/
    order/
      order-module.md
      features/
        approve-order-api-feature.md
      workflows/
        order-approval-workflow.md
      runbooks/
        debug-order-approval-runbook.md
      order-testing.md
  reference/
  runbooks/
  memories/
  archives/

Use one repo prompt name for routing, such as Main Repo, API Repo, or a domain-specific project name.

Routing Index Requirements

Root docs/README.md is the first file an AI agent should use to resolve natural-language prompts. It must include:

  • Project shape: monorepo or single-project.
  • Repo prompt names and repo IDs.
  • Links to each repo docs index, modules.md, and features.md.
  • A root Module Locator for quick module resolution.
  • Cross-repo Relationship Map.
  • Independent/tooling areas.
  • AI reading workflow and update rules.

Repo-level modules.md lists modules owned by that repo. Repo-level features.md lists features owned by that repo. Detailed module docs should use searchable suffix filenames such as docs/modules/<module-id>/<module-id>-module.md, not repeated module README.md files, unless a project explicitly requires folder landing pages.

File Naming Rules

Use explicit suffixes for detailed docs so developers can find files quickly by name:

SuffixUse ForExample
-module.mdModule overview, ownership boundary, source paths, feature indexorder-module.md
-feature.mdOne feature, workflow surface, or API contractapprove-order-api-feature.md
-workflow.mdMulti-step business or UI flow larger than one feature docorder-approval-workflow.md
-runbook.mdDebugging, operations, maintenance, incident responsedebug-order-approval-runbook.md
-reference.mdCatalogs, legacy references, external mappingsapi-errors-reference.md
-testing.mdTest matrix, verification commands, test data rulesorder-testing.md
-roadmap.mdPlans, phases, milestones, rollout sequencingorder-roadmap.md

Reserve README.md for root/repo entrypoints and intentional index folders. Do not create docs/modules/<module-id>/README.md for new module docs when the project follows suffix naming.

Global Uniqueness Rules

These identifiers must be unique across the whole project:

IdentifierExamplePurpose
Repo prompt nameAPI RepoNatural-language routing
Repo IDapiStable machine-readable repo key
Canonical module nameOrder ModuleNatural-language module routing
Module IDorderStable machine-readable module key
Canonical feature nameApprove Order APINatural-language feature routing
Feature IDapprove-order-apiStable machine-readable feature key

When the same business concept appears in multiple repos, include owner or surface in the canonical name, such as Approve Order API and Approve Order Office UI.

Aliases are allowed only when each alias maps to exactly one canonical repo, module, or feature. Remove or narrow ambiguous aliases.

Relationship Levels

Use only these values in relationship maps:

LevelMeaningAI Behavior
RequiredChange may break another repo, contract, workflow, or test surfaceRead before proposing or editing
RecommendedRelated context may affect UX, rollout, tests, or integration qualityRead for design, contract, workflow, or user-facing work
OptionalUseful background only; not blockingMention as context and read only if the task needs it
NoneNo expected coordinationDo not broaden scope unless the prompt explicitly asks

Independent/tooling repos must be marked None when they have no product runtime or contract dependency.

Ownership Rules

Place documentation by enforcement owner:

Information TypeSource of Truth
API payloads, responses, errors, permissions, validation, database rulesOwning backend/API module feature docs
UI routes, client state, rendering behavior, form flowOwning client module feature docs
Background jobs, queues, schedules, retriesOwning worker/service module docs
Shared package public APIsOwning package docs
Cross-repo dependencyRoot relationship map plus owner docs
Local scripts and developer toolingTooling repo docs

Consumer docs may summarize how they consume a contract, but must link to the owner doc instead of copying the full business rule.

Workflow

When creating or updating docs:

1. Read root docs/README.md when present. 2. Resolve the repo prompt name, module name, and feature name from the user prompt. 3. If only a feature is named, use repo-level feature indexes linked from root docs/README.md to find its owner. 4. Read the owning repo docs index, repo modules.md, repo features.md, owning module *-module.md, and existing feature docs. 5. Read relationship docs marked Required; read Recommended docs for design, contract, workflow, and user-facing changes. 6. Decide whether the work is an index update, module doc, feature doc, API contract, workflow, runbook, memory/convention, archive/move, or cross-repo relationship update. 7. Create or update docs in the owning docs folder. Remove obsolete content instead of appending contradictory sections. 8. Update root and repo indexes when adding, renaming, moving, or archiving repos/modules/features. 9. Search for stale paths, old names, old IDs, and removed terms. 10. Verify links resolve relative to the file location.

If routing remains ambiguous after reading indexes, ask one targeted question instead of guessing.

Frontmatter

Every new or materially rewritten Markdown doc must start with YAML frontmatter:

---
name: Human Readable Title
description: One sentence describing scope and owner.
version: 1.0.0
last_updated: YYYY-MM-DD
maintained_by: Team Or Owner
---

Module docs must also include routing fields:

repo_prompt_name: API Repo
repo_id: api
module_name: Order Module
module_id: order
module_aliases:
  - Orders
related_docs:
  - ../../features.md

Feature docs must also include feature routing fields:

repo_prompt_name: API Repo
repo_id: api
module_name: Order Module
module_id: order
feature_name: Approve Order API
feature_id: approve-order-api
feature_aliases:
  - Order Approval API
related_docs:
  - ../order-module.md
  - ../../../features.md

Preserve existing version/history when migrating docs. Update last_updated and version when content changes materially.

Required Content

For backend/API contract docs, include when applicable:

  • Purpose, scope, consumers, and ownership boundary.
  • Controllers/routes, requests, resources, models, services, jobs, providers, constants, and config.
  • Endpoint table, headers, payload examples, response examples, and error dictionary.
  • Permissions, token abilities, feature flags, rate limits, audit rules, and client consumption rules.
  • Data model, state transitions, events, queues, cache behavior, side effects, and external dependencies.
  • Local development, seed data, migrations, verification commands, troubleshooting hints, and test commands.

For client/workflow docs, include when applicable:

  • Entry points, routes, screens, and workflow ownership.
  • API or realtime contracts consumed, linked to owner docs.
  • Local state/storage behavior and client-only constraints.
  • UX/rendering rules without duplicating backend business rules.
  • Compatibility, rollout, verification commands, and debugging notes.

Style Rules

  • Use frontmatter plus Markdown consistently.
  • Use tables for repo names, module indexes, feature indexes, relationships, endpoints, business rules, route maps, error dictionaries, testing matrices, and debugging symptom maps.
  • Use Mermaid for actor flows, system flows, state machines, and ERDs when helpful.
  • Keep Mermaid labels short. Wrap labels with punctuation in quotes.
  • Keep docs concise but complete enough for a future engineer to avoid guessing.
  • Delete obsolete text and stale references.
  • Link to source-of-truth docs instead of duplicating rules across consumers.

Verification

Before finishing:

  • Confirm new or moved docs are discoverable from root docs/README.md and the owning repo indexes.
  • Confirm detailed docs use the project's required suffix naming, such as *-module.md, *-feature.md, *-workflow.md, *-runbook.md, *-reference.md, *-testing.md, and *-roadmap.md.
  • Confirm root docs do not contain detailed app/service contracts in a monorepo.
  • Confirm repo/module/feature names and IDs are unique.
  • Confirm independent/tooling areas have None relationship scope when appropriate.
  • Confirm new docs have required frontmatter.
  • Confirm links resolve relative to the file location.
  • Search for stale paths, renamed files, old prompt names, old module names, and old feature names.

Resources

  • references/documentation-guidelines.md: Detailed templates for root indexes, repo-level module/feature indexes, module docs, feature docs, API contracts, client workflows, testing, debugging, and cross-repo relationship maps.

Related skills

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.