Skip to content

Add docs maintenance agent: AGENTS.md, skills, and rule files - #846

Draft
brandonjackson wants to merge 13 commits into
mainfrom
claude/docs-agent-skills-0e700j
Draft

Add docs maintenance agent: AGENTS.md, skills, and rule files#846
brandonjackson wants to merge 13 commits into
mainfrom
claude/docs-agent-skills-0e700j

Conversation

@brandonjackson

@brandonjackson brandonjackson commented Sep 4, 2026

Copy link
Copy Markdown

Short Description

Adds an AGENTS.md orchestrator and seven skill files under .agents/skills/ so an LLM agent can maintain the docs one section at a time. Seeds glossary.yml and adds empty style-exceptions.yml and translation-rules.yml with schema comments.

The skills

Each skill is a plain-language instruction file, 50 to 90 lines, that stands alone.

Skill What it does Why it's worth having
Lint Mechanical checks: terminology against the glossary, heading levels, broken links, orphan pages, missing front matter, untagged code blocks, missing alt text. Catches the cheap, common mistakes automatically so human review time goes on content, not formatting.
Accuracy check Lists every claim on a page (flags, defaults, labels, versions, limits) and verifies each one against the code in Lightning, kit, or adaptors. Docs drift silently as the product changes. This is the only skill that finds out-of-date facts before a user does.
Fresh-user evaluation Reads a page with no prior OpenFn knowledge and tries to complete the task. Records every point of confusion and scores readability and completeness. Authors can't see what they've assumed. This surfaces the missing prerequisite or undefined term that makes a newcomer give up.
Gap analysis Compares what a section covers against what exists in the product and what users ask about. Ranks gaps by users affected, severity, and evidence, with ease as a tiebreaker. Turns "we should write more docs" into a prioritised list with a home and an outline for each item. Tested end to end on the CLI section; found six real gaps traced to source.
Screenshot triage Scans all screenshots by default, dates each one, maps it to the UI code that draws that screen, and flags images older than the last UI change. Remembers classifications in screenshot-map.yml so repeat scans are cheap. Stale screenshots are the most visible sign of neglected docs. This tells you which ones to retake first, without anyone opening 350 images.
Translate Generates Spanish and French versions of English pages, with governance: content-hash source tracking, review status, never overwriting human-reviewed pages, honouring do-not-retranslate fences. Makes translation affordable while keeping humans in control of what they've reviewed. Translations stay current with the English automatically.
Release review Reads the changelogs for every release in the last month across Lightning, kit, and adaptors, works out what changed for users, and finds the docs pages that now need updating. Can be narrowed to one repo, tag, or PR. Closes the loop between shipping and documenting on a schedule, without anyone having to remember to ask per PR. Changelog-first keeps it cheap.

How they fit together

  • One section per run; the agent asks which section if none is named.
  • Order: lint → accuracy → fresh-user eval → gap analysis → translate. Screenshot triage and release review run on their own schedule (monthly is the intended cadence) rather than per section.
  • Every finding is a fix (applied), a suggestion (recorded in the PR for a human), or a question (asked, not guessed).
  • Stop and open a PR when the section is done or at 20 file changes. Translations get their own PR per locale and are exempt from the cap.

Boundaries the agent respects

  • Never edits pages marked translation_review_status: human-reviewed; offers a diff instead.
  • Never edits generated adaptor pages (adaptors/packages/**, adaptors/library/**); drafts issues for OpenFn/adaptors instead. Hand-written adaptors/*.md overviews stay editable.
  • Never edits versioned_docs/ (frozen v1).
  • Never changes build or deploy config without asking.
  • Never retakes screenshots.
  • Feature-flagged or deliberately hidden functionality is never a docs gap.

Translation source tracking

translation_source_hash is the content hash of the English file (git hash-object), not a commit SHA. The original spec said commit SHA, but the first trial run showed the problem: this repo squash-merges, so a hash pointing at a branch commit dangles the moment the PR lands. A content hash is the same wherever the file lives, and a reviewer can still recover the English they approved with git cat-file -p <hash> to see what changed since.

Rule files

glossary.yml (seeded with product terms that must never be translated), style-exceptions.yml, and translation-rules.yml are read by lint and translate and maintained by humans directly. Each explains its format in a header comment.

Things to look at carefully

  • .gitignore no longer ignores /i18n. The old rule contradicted committing translations in-repo. No i18n/ directory exists yet, so nothing changes until the translate skill runs.
  • docusaurus.config.js has no i18n block. I did not add one, since enabling locales changes what yarn build produces and deploys. The translate skill treats a missing locale as a blocking question.
  • The glossary seed goes slightly beyond the spec's list (adds dataclip, Canvas, Inspector, CLI, project, state, operation, collection, sandbox), based on terms already used across docs/. Easy to trim.
  • Release review and screenshot triage are designed for a monthly trigger. The trigger itself is not part of this PR.

No existing docs pages were modified.

AI Usage

  • I have used Claude Code
  • I have used another model
  • I have not used AI

You can read more details in our
Responsible AI Policy

🤖 Generated with Claude Code

https://claude.ai/code/session_01CntaKNYyBkumpWvm5mTJa7

Adds the orchestrator (AGENTS.md) and seven self-contained skill files under
.agents/skills/ for linting, accuracy verification, fresh-user evaluation,
gap analysis, translation, corrections capture, and screenshot triage.

Seeds glossary.yml with product terms that must never be translated and
spelling variants lint should flag. Adds empty style-exceptions.yml and
translation-rules.yml with schema comments.

Stops ignoring /i18n so machine translations can be committed alongside
the English source, per the translation architecture in AGENTS.md.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CntaKNYyBkumpWvm5mTJa7
Keeps every rule from the spec; drops long command snippets, exhaustive
path tables, and repeated output templates so the files are easier to read
and maintain.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CntaKNYyBkumpWvm5mTJa7
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CntaKNYyBkumpWvm5mTJa7
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CntaKNYyBkumpWvm5mTJa7
The three rule files stay and are maintained by humans directly.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CntaKNYyBkumpWvm5mTJa7
… glossary check, exempt from file cap

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CntaKNYyBkumpWvm5mTJa7
Starts from a product PR and finds the docs pages that need updating.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CntaKNYyBkumpWvm5mTJa7
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CntaKNYyBkumpWvm5mTJa7
Commit SHAs made on a branch dangle after a squash merge. A git blob hash
is the same wherever the file lives and still lets a reviewer recover the
English they approved.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CntaKNYyBkumpWvm5mTJa7
…cation map

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CntaKNYyBkumpWvm5mTJa7
…rch invocations, separate ease from impact

Based on a test run against the CLI section.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CntaKNYyBkumpWvm5mTJa7
@brandonjackson
brandonjackson marked this pull request as draft September 4, 2026 14:39
Defaults to every release in the last month across the product repos and
reads changelogs before diffs. A single PR remains an optional narrower
input.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CntaKNYyBkumpWvm5mTJa7
brandonjackson pushed a commit that referenced this pull request Sep 4, 2026
…ranslate skill

Brings AGENTS.md, the agent skills, and the rule files (glossary.yml,
translation-rules.yml, style-exceptions.yml) onto this branch so the Spanish
translations can be produced under the translate skill rather than audited
against it after the fact.

Merged rather than copied so the files keep one history: when #846 lands,
this branch's diff against main shows only the i18n work.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0191JhrXtWiHnUGwfwesiq7T
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

2 participants