From 26655cee369012be09b873a38c7ccc1169275083 Mon Sep 17 00:00:00 2001 From: Gilbert Sanchez Date: Sun, 21 Jun 2026 11:59:22 -0700 Subject: [PATCH] Add agent docs --- .claude/settings.local.json | 65 ------------------------------ .frontmatter/database/mediaDb.json | 1 + AGENTS.md | 17 ++++++++ docs/agents/domain.md | 51 +++++++++++++++++++++++ docs/agents/issue-tracker.md | 22 ++++++++++ docs/agents/triage-labels.md | 15 +++++++ 6 files changed, 106 insertions(+), 65 deletions(-) delete mode 100644 .claude/settings.local.json create mode 100644 .frontmatter/database/mediaDb.json create mode 100644 AGENTS.md create mode 100644 docs/agents/domain.md create mode 100644 docs/agents/issue-tracker.md create mode 100644 docs/agents/triage-labels.md diff --git a/.claude/settings.local.json b/.claude/settings.local.json deleted file mode 100644 index 6286e60d9..000000000 --- a/.claude/settings.local.json +++ /dev/null @@ -1,65 +0,0 @@ -{ - "permissions": { - "allow": [ - "Bash(npx hugo:*)", - "Bash(hugo version:*)", - "Bash(where hugo:*)", - "Bash(hugo --gc --minify)", - "Bash(hugo --gc --minify -d docs)", - "Bash(ls -la /home/*/Downloads/)", - "Read(//root/**)", - "Bash(grep -h \"^ - \" ~/Downloads/oldsite/posts/*.md)", - "Bash(grep -v \"^ - $\")", - "Bash(grep -h ^categories: -A 50 ~/Downloads/oldsite/posts/*.md)", - "Bash(grep -v \"^--$\")", - "Bash(grep -h \"^author:\" ~/Downloads/oldsite/posts/*.md)", - "Bash(for dir:*)", - "Bash(do echo:*)", - "Read(//c/Users/James/Downloads/oldsite/$dir/**)", - "Bash(done)", - "Bash(grep -l \"podcast\" ~/Downloads/oldsite/posts/*.md)", - "Bash(xargs head:*)", - "Bash(grep -h \"^date:\" ~/Downloads/oldsite/posts/*.md)", - "Bash(grep -l \"^categories:\" -A 20 ~/Downloads/oldsite/posts/*.md)", - "Bash(xargs grep:*)", - "Bash(head -60 ~/Downloads/oldsite/posts/2013-06-20-*.md)", - "Bash(find ~/Downloads/oldsite -type f -exec ls -lh {})", - "Bash(sort -k5 -hr)", - "Read(//c//**)", - "Bash(find /mnt/ -maxdepth 3 -name \"oldsite\" -type d)", - "Bash(powershell.exe -Command \"Test-Path 'C:\\\\downloads\\\\oldsite'\" 2>/dev/null)", - "Bash(powershell.exe -Command \"Get-ChildItem 'C:\\\\downloads' -ErrorAction SilentlyContinue | Select-Object -ExpandProperty Name\" 2>/dev/null)", - "Bash(powershell.exe -Command \"Test-Path 'C:\\\\downloads'; Get-ChildItem 'C:\\\\' -Directory | Where-Object { \\\\$_.Name -match 'download' } | Select-Object -ExpandProperty FullName\")", - "Bash(powershell.exe -Command \"Get-ChildItem 'C:\\\\Users\\\\James\\\\Downloads' -Directory -ErrorAction SilentlyContinue | Where-Object { \\\\$_.Name -match 'old' } | Select-Object -ExpandProperty FullName; Test-Path 'C:\\\\Users\\\\James\\\\Downloads\\\\oldsite'\")", - "Bash(ls /c/Users/James/Downloads/oldsite/posts/2025-01-*)", - "Bash(grep -l \"categories:\" /c/Users/James/Downloads/oldsite/posts/2024-*)", - "Bash(while read:*)", - "Bash(do grep:*)", - "Bash(grep -h '^ - ' /c/Users/James/Downloads/oldsite/posts/*.md)", - "Bash(grep -v \"post_views\\\\|swp_cache\\\\|default\\\\|Right\\\\|Yes\\\\|inactive\\\\|http\\\\|themnific\\\\|wp-content\\\\|secondline\\\\|audio\\\\|enclosure\\\\|0$\")", - "Bash(do head:*)", - "Bash(node:*)", - "Bash(ls /c/scripts/PowerShellOrgWebsite/content/articles/*.md)", - "Bash(ls /c/scripts/PowerShellOrgWebsite/content/podcast/*.md)", - "Bash(grep \"Install-Module\\\\`\" /c/scripts/PowerShellOrgWebsite/content/articles/2023-09-15-microsoft-graph-powershell-module-getting-started-guide.md)", - "WebFetch(domain:leanpub.com)", - "Bash(magick --version)", - "Bash(pwsh -Command \"Get-Command pwsh\")", - "Bash(npx --version)", - "Bash(npx --yes sharp-cli -- -i \"C:/Users/James/Creative Cloud Files jamesp@powershell.org 988C53795B1EA2570A495C3F@AdobeID/Logos/New Website Logo/logo_400x300.png\" -o \"C:/scripts/PowerShellOrgWebsite/static/favicon-32x32.png\" resize 32 32 --fit contain --background \"rgba\\(255,255,255,0\\)\")", - "Bash(npx:*)", - "Bash(\"C:/scripts/PowerShellOrgWebsite/static/favicon.ico\")", - "Bash(wc -l /Users/jamespetty/git/PowerShellOrgWebsite/content/articles/*.md)", - "Bash(git -C /Users/jamespetty/git/PowerShellOrgWebsite log --oneline)", - "Bash(hugo --gc --minify --destination /tmp/hugo-test-build)", - "Bash(cat /c/scripts/PowerShellOrgWebsite/config/*)", - "Bash(hugo --quiet)", - "Bash(head -5 /c/scripts/PowerShellOrgWebsite/content/articles/*.md)", - "Bash(head -5 /c/scripts/PowerShellOrgWebsite/content/podcast/*.md)", - "Bash(grep:*)", - "Bash(hugo --printPathWarnings)", - "Bash(hugo --templateMetrics)", - "Bash(hugo)" - ] - } -} diff --git a/.frontmatter/database/mediaDb.json b/.frontmatter/database/mediaDb.json new file mode 100644 index 000000000..9e26dfeeb --- /dev/null +++ b/.frontmatter/database/mediaDb.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/AGENTS.md b/AGENTS.md new file mode 100644 index 000000000..e29031a6b --- /dev/null +++ b/AGENTS.md @@ -0,0 +1,17 @@ +# AGENTS.md + +Instructions for AI agents working in this repository. + +## Agent skills + +### Issue tracker + +Issues and PRDs are tracked in GitHub Issues (`PowerShellOrg/PowerShellOrgWebsite`) via the `gh` CLI. See `docs/agents/issue-tracker.md`. + +### Triage labels + +Canonical triage roles map 1:1 to their default label strings (`needs-triage`, `needs-info`, `ready-for-agent`, `ready-for-human`, `wontfix`). See `docs/agents/triage-labels.md`. + +### Domain docs + +Single-context: one `CONTEXT.md` + `docs/adr/` at the repo root. See `docs/agents/domain.md`. diff --git a/docs/agents/domain.md b/docs/agents/domain.md new file mode 100644 index 000000000..c97d6a6db --- /dev/null +++ b/docs/agents/domain.md @@ -0,0 +1,51 @@ +# Domain Docs + +How the engineering skills should consume this repo's domain documentation when exploring the codebase. + +## Before exploring, read these + +- **`CONTEXT.md`** at the repo root, or +- **`CONTEXT-MAP.md`** at the repo root if it exists — it points at one `CONTEXT.md` per context. Read each one relevant to the topic. +- **`docs/adr/`** — read ADRs that touch the area you're about to work in. In multi-context repos, also check `src//docs/adr/` for context-scoped decisions. + +If any of these files don't exist, **proceed silently**. Don't flag their absence; don't suggest creating them upfront. The producer skill (`/grill-with-docs`) creates them lazily when terms or decisions actually get resolved. + +## File structure + +Single-context repo (most repos): + +``` +/ +├── CONTEXT.md +├── docs/adr/ +│ ├── 0001-event-sourced-orders.md +│ └── 0002-postgres-for-write-model.md +└── src/ +``` + +Multi-context repo (presence of `CONTEXT-MAP.md` at the root): + +``` +/ +├── CONTEXT-MAP.md +├── docs/adr/ ← system-wide decisions +└── src/ + ├── ordering/ + │ ├── CONTEXT.md + │ └── docs/adr/ ← context-specific decisions + └── billing/ + ├── CONTEXT.md + └── docs/adr/ +``` + +## Use the glossary's vocabulary + +When your output names a domain concept (in an issue title, a refactor proposal, a hypothesis, a test name), use the term as defined in `CONTEXT.md`. Don't drift to synonyms the glossary explicitly avoids. + +If the concept you need isn't in the glossary yet, that's a signal — either you're inventing language the project doesn't use (reconsider) or there's a real gap (note it for `/grill-with-docs`). + +## Flag ADR conflicts + +If your output contradicts an existing ADR, surface it explicitly rather than silently overriding: + +> _Contradicts ADR-0007 (event-sourced orders) — but worth reopening because…_ diff --git a/docs/agents/issue-tracker.md b/docs/agents/issue-tracker.md new file mode 100644 index 000000000..cce77ecbb --- /dev/null +++ b/docs/agents/issue-tracker.md @@ -0,0 +1,22 @@ +# Issue tracker: GitHub + +Issues and PRDs for this repo live as GitHub issues. Use the `gh` CLI for all operations. + +## Conventions + +- **Create an issue**: `gh issue create --title "..." --body "..."`. Use a heredoc for multi-line bodies. +- **Read an issue**: `gh issue view --comments`, filtering comments by `jq` and also fetching labels. +- **List issues**: `gh issue list --state open --json number,title,body,labels,comments --jq '[.[] | {number, title, body, labels: [.labels[].name], comments: [.comments[].body]}]'` with appropriate `--label` and `--state` filters. +- **Comment on an issue**: `gh issue comment --body "..."` +- **Apply / remove labels**: `gh issue edit --add-label "..."` / `--remove-label "..."` +- **Close**: `gh issue close --comment "..."` + +Infer the repo from `git remote -v` — `gh` does this automatically when run inside a clone. + +## When a skill says "publish to the issue tracker" + +Create a GitHub issue. + +## When a skill says "fetch the relevant ticket" + +Run `gh issue view --comments`. diff --git a/docs/agents/triage-labels.md b/docs/agents/triage-labels.md new file mode 100644 index 000000000..b716855d4 --- /dev/null +++ b/docs/agents/triage-labels.md @@ -0,0 +1,15 @@ +# Triage Labels + +The skills speak in terms of five canonical triage roles. This file maps those roles to the actual label strings used in this repo's issue tracker. + +| Label in mattpocock/skills | Label in our tracker | Meaning | +| -------------------------- | -------------------- | ---------------------------------------- | +| `needs-triage` | `needs-triage` | Maintainer needs to evaluate this issue | +| `needs-info` | `needs-info` | Waiting on reporter for more information | +| `ready-for-agent` | `ready-for-agent` | Fully specified, ready for an AFK agent | +| `ready-for-human` | `ready-for-human` | Requires human implementation | +| `wontfix` | `wontfix` | Will not be actioned | + +When a skill mentions a role (e.g. "apply the AFK-ready triage label"), use the corresponding label string from this table. + +Edit the right-hand column to match whatever vocabulary you actually use.