Skip to content

docs: add an agent playbook and keep agent docs in sync with action.yml - #27

Merged
atherdon merged 2 commits into
mainfrom
docs/agent-playbook
Oct 15, 2026
Merged

atherdon merged 2 commits into
mainfrom
docs/agent-playbook

Conversation

@atherdon

Copy link
Copy Markdown
Contributor

A better explanation of this Action for AI agents

AGENTS.md mixed two audiences (agents adding the Action to a repository, and agents changing this repository) and described the Action, but did not give an agent a procedure to follow. This PR adds one.

What's new

  • docs/agent-playbook.md: a four-step procedure (inspect the repository, choose a render mode, write the workflow, verify), a decision flowchart, eleven recipes (script, other flag styles, MJML/pandoc, tools not on the runner, catalog command, pnpm/yarn/bun, monorepo, matrix, private packages, fail-fast: false, two comments, scheduled run), a table that maps each log message to a fix, and a list of hard rules. It tells agents to read the failure annotation first, which now carries the first cause line (feat: include the failing command's cause in the error annotation #26).
  • AGENTS.md opens with a "Start here" section: where to go for each audience, and the five rules that matter most. The long reference sections are unchanged.
  • llms.txt and the README link to the playbook; CHANGELOG updated.

So the docs cannot drift

tests/check-action.py now also:

  • parses every ```yaml block in the README, AGENTS.md, llms.txt, CHANGELOG and docs/;
  • fails if a call to this Action in the docs or in examples/ uses an input that is not in action.yml, or is not pinned to @v1;
  • checks that relative links and #anchors point at files and headings that exist.

I checked the checks: injecting a bad input name, an @main pin, a missing file, a dead anchor and broken YAML into a scratch copy failed on each one. The metadata workflow now also runs when AGENTS.md, llms.txt or docs/ change.

Testing

All local suites pass (31 + 102 + 13 assertions, plus the static checks). No behavior of the Action changes in this PR.

🤖 Generated with Claude Code

https://claude.ai/code/session_01HxpS9r6qDihN2RKxQCwU2R


Generated by Claude Code

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HxpS9r6qDihN2RKxQCwU2R
- tests/check-action.py now parses every yaml block in the docs, fails when a
  call to this Action uses an input that is not in action.yml or is not pinned
  to @v1, and checks relative links and #anchors in the docs
- the metadata workflow runs when AGENTS.md, llms.txt or docs/ change
- the playbook tells agents to read the failure annotation first, which now
  carries the first cause line (#26)

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HxpS9r6qDihN2RKxQCwU2R
@github-actions

Copy link
Copy Markdown

Rendered emails

This PR rendered email templates.

Open the run → Artifacts → download → open index.html.

@atherdon
atherdon merged commit 1eb35b0 into main Oct 15, 2026
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants