Loading source
Pulling the file list, source metadata, and syntax-aware rendering for this listing.
Source from bundle
Triage GitHub/Jira/backlog issues through Matt Pocock’s label-driven state machine.
Files
Skill
Size
Entrypoint
Format
Open file
Syntax-highlighted preview of this file as included in the skill package.
AGENT-BRIEF.md
1# Writing Agent Briefs23An agent brief is a structured comment posted on a GitHub issue when it moves to `ready-for-agent`. It is the authoritative specification that an AFK agent will work from. The original issue body and discussion are context — the agent brief is the contract.45## Principles67### Durability over precision89The issue may sit in `ready-for-agent` for days or weeks. The codebase will change in the meantime. Write the brief so it stays useful even as files are renamed, moved, or refactored.1011- **Do** describe interfaces, types, and behavioral contracts12- **Do** name specific types, function signatures, or config shapes that the agent should look for or modify13- **Don't** reference file paths — they go stale14- **Don't** reference line numbers15- **Don't** assume the current implementation structure will remain the same1617### Behavioral, not procedural1819Describe **what** the system should do, not **how** to implement it. The agent will explore the codebase fresh and make its own implementation decisions.2021- **Good:** "The `SkillConfig` type should accept an optional `schedule` field of type `CronExpression`"22- **Bad:** "Open src/types/skill.ts and add a schedule field on line 42"23- **Good:** "When a user runs `/triage` with no arguments, they should see a summary of issues needing attention"24- **Bad:** "Add a switch statement in the main handler function"2526### Complete acceptance criteria2728The agent needs to know when it's done. Every agent brief must have concrete, testable acceptance criteria. Each criterion should be independently verifiable.2930- **Good:** "Running `gh issue list --label needs-triage` returns issues that have been through initial classification"31- **Bad:** "Triage should work correctly"3233### Explicit scope boundaries3435State what is out of scope. This prevents the agent from gold-plating or making assumptions about adjacent features.3637## Template3839```markdown40## Agent Brief4142**Category:** bug / enhancement43**Summary:** one-line description of what needs to happen4445**Current behavior:**46Describe what happens now. For bugs, this is the broken behavior.47For enhancements, this is the status quo the feature builds on.4849**Desired behavior:**50Describe what should happen after the agent's work is complete.51Be specific about edge cases and error conditions.5253**Key interfaces:**54- `TypeName` — what needs to change and why55- `functionName()` return type — what it currently returns vs what it should return56- Config shape — any new configuration options needed5758**Acceptance criteria:**59- [ ] Specific, testable criterion 160- [ ] Specific, testable criterion 261- [ ] Specific, testable criterion 36263**Out of scope:**64- Thing that should NOT be changed or addressed in this issue65- Adjacent feature that might seem related but is separate66```6768## Examples6970### Good agent brief (bug)7172```markdown73## Agent Brief7475**Category:** bug76**Summary:** Skill description truncation drops mid-word, producing broken output7778**Current behavior:**79When a skill description exceeds 1024 characters, it is truncated at exactly801024 characters regardless of word boundaries. This produces descriptions81that end mid-word (e.g. "Use when the user wants to confi").8283**Desired behavior:**84Truncation should break at the last word boundary before 1024 characters85and append "..." to indicate truncation.8687**Key interfaces:**88- The `SkillMetadata` type's `description` field — no type change needed,89but the validation/processing logic that populates it needs to respect90word boundaries91- Any function that reads SKILL.md frontmatter and extracts the description9293**Acceptance criteria:**94- [ ] Descriptions under 1024 chars are unchanged95- [ ] Descriptions over 1024 chars are truncated at the last word boundary96before 1024 chars97- [ ] Truncated descriptions end with "..."98- [ ] The total length including "..." does not exceed 1024 chars99100**Out of scope:**101- Changing the 1024 char limit itself102- Multi-line description support103```104105### Good agent brief (enhancement)106107```markdown108## Agent Brief109110**Category:** enhancement111**Summary:** Add `.out-of-scope/` directory support for tracking rejected feature requests112113**Current behavior:**114When a feature request is rejected, the issue is closed with a `wontfix` label115and a comment. There is no persistent record of the decision or reasoning.116Future similar requests require the maintainer to recall or search for the117prior discussion.118119**Desired behavior:**120Rejected feature requests should be documented in `.out-of-scope/<concept>.md`121files that capture the decision, reasoning, and links to all issues that122requested the feature. When triaging new issues, these files should be123checked for matches.124125**Key interfaces:**126- Markdown file format in `.out-of-scope/` — each file should have a127`# Concept Name` heading, a `**Decision:**` line, a `**Reason:**` line,128and a `**Prior requests:**` list with issue links129- The triage workflow should read all `.out-of-scope/*.md` files early130and match incoming issues against them by concept similarity131132**Acceptance criteria:**133- [ ] Closing a feature as wontfix creates/updates a file in `.out-of-scope/`134- [ ] The file includes the decision, reasoning, and link to the closed issue135- [ ] If a matching `.out-of-scope/` file already exists, the new issue is136appended to its "Prior requests" list rather than creating a duplicate137- [ ] During triage, existing `.out-of-scope/` files are checked and surfaced138when a new issue matches a prior rejection139140**Out of scope:**141- Automated matching (human confirms the match)142- Reopening previously rejected features143- Bug reports (only enhancement rejections go to `.out-of-scope/`)144```145146### Bad agent brief147148```markdown149## Agent Brief150151**Summary:** Fix the triage bug152153**What to do:**154The triage thing is broken. Look at the main file and fix it.155The function around line 150 has the issue.156157**Files to change:**158- src/triage/handler.ts (line 150)159- src/types.ts (line 42)160```161162This is bad because:163- No category164- Vague description ("the triage thing is broken")165- References file paths and line numbers that will go stale166- No acceptance criteria167- No scope boundaries168- No description of current vs desired behavior169