Skip to content

Commit 64122e7

Browse files
authored
docs(config): add bug capture skill (#1818)
1 parent 2d079b9 commit 64122e7

2 files changed

Lines changed: 139 additions & 0 deletions

File tree

Lines changed: 135 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,135 @@
1+
---
2+
name: bug-capture
3+
description: Capture a reported bug as a high-context GitHub issue after targeted diagnosis. Use when a user reports a bug, shares reproduction steps or screenshots, and wants the issue tracker to contain enough context for a later agent to fix it quickly.
4+
---
5+
6+
# Bug Capture
7+
8+
Capture a real bug as a GitHub issue with enough evidence for a later agent to
9+
fix it quickly: workflow, screenshot evidence, diagnosis, likely fix, and
10+
verification path.
11+
12+
## Rules
13+
14+
- Investigate, but do not fix: no product-code edits, branches, commits, or
15+
leftover temporary files.
16+
- Do not overstate certainty. Say when a bug was reproduced, when it was not
17+
reproduced, and how confident you are in the diagnosis.
18+
- Spend tokens on evidence that changes the issue. Summarize long logs, files,
19+
and screenshots instead of pasting them.
20+
21+
## Process
22+
23+
### 1. Gather
24+
25+
Use existing context first: reporter description, screen/route/feature,
26+
workflow, actual result, expected result, environment/account state, screenshot,
27+
logs, and issue links.
28+
29+
For screenshots:
30+
31+
- Inspect attached screenshots and summarize what matters.
32+
- Use `[screenshot]` in the issue unless the reporter provides a real URL or
33+
safe path to reference.
34+
- Keep image observations in the summary or diagnosis, not in a long screenshot
35+
section.
36+
37+
### 2. Investigate
38+
39+
Inspect before asking questions.
40+
41+
- Read only relevant domain docs (`CONTEXT.md`, feature docs, ADRs).
42+
- Search for the reported screen, route, component, API, event, or error text.
43+
- Check nearby tests and recent local patterns.
44+
- Reproduce or run the narrowest practical UI/API/test flow when available.
45+
- Use sub-agents only for independent questions; ask each for concise findings.
46+
47+
Record concrete evidence: whether you reproduced it, commands/run results,
48+
browser observations, likely affected files/modules, and confidence.
49+
50+
### 3. Clarify
51+
52+
Ask questions only after investigation, only for facts you cannot infer.
53+
54+
- Ask one question at a time.
55+
- Ask at most 3 questions total.
56+
- Include your recommended/default answer.
57+
- Focus on missing screen/step, reproducibility, expected behavior, or relevant
58+
account/auth/Google/self-hosted state.
59+
60+
If key facts are still missing, publish a useful issue with an information-needed
61+
label.
62+
63+
### 4. Prepare GitHub
64+
65+
- Use GitHub Issues through `gh`, inferred from the current repo remote.
66+
- Ensure a `bug` label exists; create it if missing.
67+
- Normal capture: apply `bug` and `needs-triage`.
68+
- Incomplete capture: apply `bug` and `needs-info`. If an obvious equivalent
69+
already exists, such as `needs more info`, use it instead of creating a
70+
duplicate.
71+
- Never apply `ready-for-agent` automatically.
72+
73+
### 5. Dedupe
74+
75+
Search open issues with screen, route, workflow, error, and symptom keywords.
76+
77+
- Strong duplicate: comment on it with the new workflow, screenshot placeholder,
78+
diagnosis, likely fix, and verification path.
79+
- Weak match: create a new issue and mention the possible relation.
80+
- No match: create a new issue.
81+
82+
### 6. Publish
83+
84+
Use title format:
85+
86+
```text
87+
<area>: <observable broken behavior>
88+
```
89+
90+
Use this body:
91+
92+
```md
93+
## Bug report
94+
95+
Short summary of what is broken and who is affected.
96+
97+
## Where it happened
98+
99+
Route, screen, feature, environment, or account state.
100+
101+
## Workflow
102+
103+
1. Reporter step.
104+
2. Reporter step.
105+
3. What happened.
106+
107+
## Expected outcome
108+
109+
What should have happened.
110+
111+
## Screenshot
112+
113+
[screenshot]
114+
115+
## Diagnosis
116+
117+
Reproduction status, strongest evidence, likely affected files/modules,
118+
confidence, and related issue if any.
119+
120+
## Likely fix
121+
122+
Concrete handoff prompt for the fixing agent: where to start and what behavior
123+
to preserve.
124+
125+
## Verification
126+
127+
Shortest practical flow, test, or command proving the fix.
128+
```
129+
130+
If publishing fails, report the failure and provide the draft body.
131+
132+
### 7. Report
133+
134+
Return the issue URL, whether it was new or a duplicate comment, any missing
135+
information, and a short plain-English diagnosis/likely-fix summary.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
interface:
2+
display_name: "Bug Capture"
3+
short_description: "Capture bugs as rich GitHub issues"
4+
default_prompt: "Use $bug-capture to investigate this bug report and create a GitHub issue."

0 commit comments

Comments
 (0)