agentleFS
nfeuernfeuer/project-foundation-kit/.claude/skills/doc-sync/SKILL.md

doc-sync

Skill0 starsChanged 4 months agoMITView on GitHub

Keep docs, spec, and code in lockstep in the same PR — update affected narrative docs, cite/update the canonical spec, and log any accepted drift as a follow-up

34 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use api-endpoint, improve and 5 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • tadoEngSkill

    api-endpoint

    Add or change a backend API endpoint on this product, keeping Pydantic as the single contract authority and regenerating the TypeScript client. Use when asked to add an endpoint, expose data to the frontend, change a request or response shape, or wire a new backend capability into a page.

    Also in 4 projects that use this

  • AnasX7Skill

    improve

    Survey any codebase as a senior advisor and produce prioritized, self-contained implementation plans for OTHER models/agents to execute. Strictly read-only on source code — never implements, fixes, or refactors anything itself. Use when asked to audit a codebase, find improvement opportunities (bugs, security, performance, test coverage, tech debt, migrations, DX), suggest features or where to take the project next (roadmap, product direction), or generate handoff plans for another agent to implement.

    Also in 3 projects that use this

  • dillonluiSkill

    design-review

    Review a view or flow for UX and UI issues. Provides severity-ranked, actionable findings grounded in established design heuristics. Use when the user asks for design feedback, UX review, or UI critique.

    Also in 3 projects that use this

  • Microsoft AzureSkill

    design

    Design rules and conventions for the API Center Portal. Use when editing detail pages, card components, badges, layout, navigation, sidebars, or headers. Covers badge styling, metadata placement, page navigation patterns, and layout alignment.

    Also in 3 projects that use this

  • NVIDIASkill

    research

    Before designing a feature, research how comparable libraries solve the problem, check best practices, known pitfalls, and upstream changes. Use when starting a new feature, investigating an unfamiliar area, or the user asks to research something.

    Also in 3 projects that use this

  • GoogleSkill

    code-review

    Adversarial systems, concurrency, memory-model, and architecture code review protocol. Use this skill whenever asked to review code, PRs, diffs, or branches in Filament.

    Also in 4 projects that use this

The file

We split this skill into the rules it gives an agent

7 rules. 0 are common, 2 are distinctive, and 5 are very specific to this project.

  • 0

    Common

    Most of the 27 edited versions we read keep these.

  • 2

    Distinctive

    This author's own choices. Worth a look.

  • 5

    Very specific

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

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

    follow-ups log: Read docs/DOCS_STANDARD.md for the taxonomy before you start.

    line 18
  2. Very specific:

    Always pass --exclude-dir={.git,.venv,node_modules,__pycache__,.claude/worktrees,dist,build} (or the find -prune equivalent).

    line 24
  3. Distinctive:

    Keep updates proportional to the change — amend the relevant paragraph or bullet, not a rewritten page.

    line 48
  4. Very specific:

    In scope: update the affected § in this same PR.

    line 62
  5. Very specific:

    Out of scope: call it out explicitly in the PR body and log a follow-up (next step) with status spec-update-pending.

    line 63
  6. Very specific:

    Use the spec-check skill (or the spec-drift-checker agent) for the detailed file→section audit.

    line 66
  7. Distinctive:

    Check that internal doc links you touched still resolve.

    line 75

“Common” is measured: kept by at least 6 in 10 of the 27 edited versions of this file we could read. “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

Doc Sync

Profile-driven. Narrative doc paths use capabilities.docs.dir from .claude/kit.yaml (default: docs/). Spec checks reference capabilities.spec.file — if that key is empty, steps 3 (cite/sync spec) and the citation gate are skipped.

Documentation drifts the moment code changes and the docs don't. This skill runs at the end of a change (it's step 6–8 of the pre-pr gate) and closes the gap across three surfaces: narrative docs, the canonical spec, and the follow-ups log. Read docs/DOCS_STANDARD.md for the taxonomy before you start.

Search hygiene

  • Broad grep and find must prune stale and generated trees to avoid false positives.
  • Always pass --exclude-dir={.git,.venv,node_modules,__pycache__,.claude/worktrees,dist,build} (or the find -prune equivalent).
grep -r ... --exclude-dir={.git,.venv,node_modules,__pycache__,.claude/worktrees,dist,build}

Workflow

1. Diff the branch

git diff main...HEAD --name-only

This is the universal starting point — map each changed source file to the docs it affects.

2. Update narrative docs (hand-written)

For each changed area, update the relevant hand-written pages under capabilities.docs.dir (default: docs/):

  • <docs.dir>/domain/<subsystem>.md — if behavior or data model changed.
  • <docs.dir>/workflows/<flow>.md — if a user-facing flow changed.
  • <docs.dir>/operations/* — if deployment, migrations, or monitoring changed.
  • <docs.dir>/changelog.md — always, for a user-visible change.
  • <docs.dir>/troubleshooting.md / glossary.md — if you introduced a new failure mode or domain term.

Keep updates proportional to the change — amend the relevant paragraph or bullet, not a rewritten page.

Never hand-edit generated pages (docs/reference/, docs/config/, docs/schemas/) — those regenerate from docstrings/config on build. Instead, fix the docstring or config that generates them.

Each domain page opens with a one-line summary and a > Realizes: <spec> §X.Y citation.

3. Cite and sync the spec

Skipped when capabilities.spec.file is empty in kit.yaml. Otherwise, every design change cites the spec section it implements (capabilities.spec.file). If behavior now diverges from what the spec says:

  • In scope: update the affected § in this same PR.
  • Out of scope: call it out explicitly in the PR body and log a follow-up (next step) with status spec-update-pending. Never let it drift silently.

Use the spec-check skill (or the spec-drift-checker agent) for the detailed file→section audit.

4. Log follow-ups

Scan the diff for TODOs, deferred decisions, and accepted drift. Append them to docs/followups.md (see the followup-tracking skill for the entry format). Close any follow-up this PR resolves by moving it to the archive.

5. Verify links

Check that internal doc links you touched still resolve. A moved or renamed page breaks references silently.

Output

## Doc Sync
- Narrative pages updated: <list / none affected>
- Generated pages: <regenerate on build / N/A>
- Spec: <cited §X.Y / updated §X.Y / follow-up logged for §X.Y>
- Follow-ups: <added N / closed N / none>
- Links: <clean / fixed N>

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.