Bug Triage Squad
Triages incoming bug reports — severity, reproducibility, likely component, and routing — into a structured, machine-readable record.
Bug Triage Squad is a Claude-powered agent (@anthropic/bug-triage-squad) that sits on your bug-intake line and turns raw reports into clean triage decisions your tracker can act on automatically.
What it does
Given a bug report (from a form, an email, a Slack message, or a GitHub issue), the agent returns a single strict-JSON record containing:
- Severity (
critical → trivial) and priority (p0–p3), calibrated on real user/system impact rather than how the report is worded.
- Reproducibility assessment:
reproducible, intermittent, needs-info, or cannot-reproduce.
- Likely component plus a routing target (team/queue), with a
0.0–1.0 confidence score.
- Possible-duplicate flag, the missing information that would most change the assessment, and concrete next steps for the assignee.
It runs on Claude Sonnet 4.6 with adaptive thinking — fast enough for high-volume intake, calibrated enough to keep critical/p0 meaningful.
Setup
export ANTHROPIC_API_KEY="sk-ant-..."
npm install @anthropic-ai/sdk # or: pip install anthropic
The agent is a single messages.create call: the system prompt defines the triage policy, the bug report is the user message, and output_config.format constrains the response to the triage schema. Copy any of the configs in this listing — they all instantiate the same agent (same model, same system prompt, same JSON schema).
Example
Input (user message):
App keeps crashing when I tap "Export to PDF" on the reports page.
Happens every time on my iPhone. Latest version I think. Lost my work twice.
Output (triage record):
{
"summary": "iOS app crashes reliably on 'Export to PDF' from the reports page, with unsaved work lost.",
"severity": "high",
"severity_rationale": "Deterministic crash on a core action causing data loss for the user, with no stated workaround.",
"priority": "p1",
"reproducibility": "reproducible",
"likely_component": "mobile-ios",
"component_confidence": 0.7,
"routing_target": "mobile-team",
"possible_duplicate": false,
"missing_information": ["exact app version", "iOS version", "device model", "crash log"],
"next_steps": ["Reproduce export-to-PDF on a test iPhone", "Pull the crash report and check for unsaved-state loss"],
"tags": ["crash", "ios", "pdf-export", "data-loss"]
}
Notes
- Triage only. The agent assigns and routes; it does not diagnose root cause or propose fixes. Pair it with a separate diagnosis/fix agent downstream.
- JSON only. Responses are constrained with structured outputs, so the result is always schema-valid and safe to write straight into your tracker. Note that structured outputs are incompatible with citations.
- Calibration over alarm. Severity is derived from impact, not from urgent or emotional wording — keep your
critical/p0 lanes trustworthy.
- Thin reports are fine. Incomplete reports are triaged as
needs-info with the missing fields enumerated, never refused.
- Determinism. The prompt steers toward consistent, repeatable triage; sampling parameters are intentionally omitted (and are unsupported on this model family).