Agent skill

Triage

by SethGammon in SethGammon/Citadel

GitHub issue and PR investigator. An agent skill from SethGammon/Citadel.

MITAuto-check passedDevelopment

Install Triage

skills CLI
$ npx skills add SethGammon/Citadel --skill triage -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install SethGammon/Citadel triage --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/SethGammon/Citadel.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/triage .claude/skills/triage && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
triage
GitHub stars
922
Token cost
~2.7k tokens
SKILL.md length
1,170 words
Files
3
Skills in repo
48
Repo updated
First seen
Licence
MIT

At a glance

GitHub issue and PR investigator. An agent skill from SethGammon/Citadel.

  • Works in 7 steps: Environment Setup → Issue Intake → Classification → …
  • Investigating GitHub issues and reviewing PRs
  • SKILL.md covers When to Use, Codex PR review integration, Inputs and Execution Protocol, plus 8 more sections
  • Calls node, git and gh

What it does

Triage is an agent skill from SethGammon/Citadel. GitHub issue and PR investigator. Pulls open issues/PRs, classifies them, searches the codebase for root cause or reviews contributed code, proposes fixes with file:line references, and optionally implements fixes. Use for investigating GitHub issues and reviewing PRs; do NOT use for general code review unrelated to GitHub issues.

Its SKILL.md is about 2.7k tokens, which your agent loads only when the skill is triggered. The skill folder holds 3 other files (for example `__benchmarks__/no-gh-cli.md` and `__benchmarks__/specific-issue.md`).

It sits in Development, covering Root cause analysis and Pull requests. It works with GitHub. The repository describes itself as: The operating layer for Claude Code + OpenAI Codex: persistent project memory, intent routing, safety hooks, cost telemetry, and parallel agent fleets. The licence is MIT.

When your agent uses it

  • Investigating GitHub issues and reviewing PRs
  • Do NOT use for general code review unrelated to GitHub issues

Example prompts

  • “/triage”

Workflow steps

7 steps, taken from the step headings in SKILL.md.

  1. Environment Setup
  2. Issue Intake
  3. Classification
  4. Investigation
  5. Resolution Plan
  6. Action
  7. Report

What it can do on your machine

Read from SKILL.md and the folder at commit e41ff1d. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • node
    • git
    • gh

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use git and gh, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Triage loads about 2.7k tokens when it runs. Until then it costs about 85 tokens; SKILL.md has 1,170 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~85
When it runs · the whole SKILL.md, loaded when a task matches
~2.7k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from SethGammon/Citadel at commit e41ff1d, republished under its MIT licence (© SethGammon). 1,170 words, ~2,716 tokens.

Download SKILL.mdSave it as .claude/skills/triage/SKILL.md (or your agent's skills folder). This skill also uses 2 other files; get the full folder from GitHub.
name
triage
description
GitHub issue and PR investigator. Pulls open issues/PRs, classifies them, searches the codebase for root cause or reviews contributed code, proposes fixes with file:line references, and optionally implements fixes. Use for investigating GitHub issues and reviewing PRs; do NOT use for general code review unrelated to GitHub issues.
license
MIT
user-invocable
true
auto-trigger
false
trigger_keywords
triage, open issues, unlabeled issues, review pr, review prs, investigate issue
effort
high
last-updated
2026-03-24

Triage — GitHub Issue & PR Investigator

When to Use

Don't use when: fixing a specific already-diagnosed issue (use /marshal); monitoring a single PR's CI (use /pr-watch); reviewing code quality outside of GitHub issues (use /review).

  • /triage — triage all open, unlabeled issues
  • /triage 10 — investigate issue #10 specifically
  • /triage pr 13 — review PR #13
  • /triage prs — review all open PRs
  • /triage --batch — pull all open issues, classify, investigate, report
  • /triage --stale — find issues older than 14 days with no activity
  • After the issue-monitor SessionStart hook reports new issues

Codex PR review integration

For Codex-visible PRs, decide whether to use native @codex review, local Citadel triage, or both:

bash
node scripts/codex-pr-review.js plan --repo <owner/repo> --pr <number> --risk <low|medium|high|local-only> --write

Use native @codex review when the diff is GitHub-visible and the main need is a focused P0/P1 review. Use local Citadel triage when the answer depends on unpushed files, local generated artifacts, or hands-on edits. Use both for large or risky PRs.

After Codex posts a GitHub review, fetch and ingest the review comments before deciding merge readiness:

bash
node scripts/codex-review-fetch.js --repo <owner/repo> --pr <number> --write

Use --file <review-comments.json> with the same script when working from exported/offline review data.

Treat ingested P0/P1 findings as blockers until local verification confirms they are fixed or not applicable.

Inputs

InputSourceRequired
Issue/PR numberArgument (e.g., /triage 10, /triage pr 13)No — omit to triage all open
Modepr prefix for PRsNo — defaults to issues
RepoAuto-detected from git remoteYes (auto)
gh CLI"/c/Program Files/GitHub CLI/gh.exe" on Windows, gh elsewhereYes (auto)

Execution Protocol

Phase 0 — Environment Setup
  1. Detect repo from git remote get-url origin, extract owner/repo
  2. Verify gh auth status
  3. Set $GH: Windows → "/c/Program Files/GitHub CLI/gh.exe", other → gh
Phase 1 — Issue Intake

Single issue (/triage 10):

$GH issue view <number> --repo <owner/repo> --json number,title,body,labels,state,comments,createdAt,updatedAt,author,assignees

Batch (/triage or --batch):

$GH issue list --repo <owner/repo> --state open --json number,title,labels,createdAt,updatedAt --limit 50

Filter to untriaged: issues with no labels, or missing priority/type label.

Stale (--stale):

$GH issue list --repo <owner/repo> --state open --json number,title,labels,createdAt,updatedAt --limit 100

Filter to issues with no activity in 14+ days.

Single PR (/triage pr 13):

$GH pr view <number> --repo <owner/repo> --json number,title,body,author,state,files,commits,comments,createdAt,headRefName,baseRefName,mergeable,reviewDecision
$GH pr diff <number> --repo <owner/repo>

All PRs (/triage prs):

$GH pr list --repo <owner/repo> --state open --json number,title,author,createdAt,labels --limit 50
Phase 1b — PR Review Protocol
PR Classification
TypeSignal
bugfixFixes a reported issue, closes #N
featureAdds new functionality
refactorRestructures without changing behavior
docsDocumentation only
infraCI/CD, build, packaging, installer
PR Review Checklist
  1. Read the full diff — not just the PR description.
  2. Check for regressions against closed issues and recent commits.
  3. Check for conflicts with in-flight work (same files as open PRs).
  4. Verify the approach: correct solution, not overly complex.
  5. Check cross-platform: Unix assumptions, Windows path handling.
  6. Check conventions against existing project patterns.
  7. Check for scope creep beyond the PR title.
PR Resolution

Write a per-PR resolution block (full template: docs/TRIAGE.md#pr-resolution-template) with:

  • Author, type, files changed count, mergeable status
  • What it does (1-3 sentences)
  • Review findings, each with a file:line reference
  • Issues found, split into Critical (blocks merge) and Non-critical (nice to fix, not blocking)
  • Recommendation checkbox: Approve / Request changes (with the specific changes needed) / Close (with reason)
PR Actions

IMPORTANT: All PR actions are external. Show the user the exact comment text and get approval before posting.

Phase 2 — Classification

Type (exactly one):

TypeSignal
bugError messages, "doesn't work", stack traces, regression
feature"Would be nice", "add support for"
question"How do I", "is it possible"
docsREADME/documentation issues
infraCI/CD, build, packaging, dependencies

Severity (bugs only):

SeverityCriteria
criticalBlocks installation or core functionality for all users
highBreaks a major feature or affects many users
mediumBreaks a minor feature or has a workaround
lowCosmetic, edge case, or easy workaround

Affected Component:

  • Citadel hooks / skills / agents
  • .claude/harness.json — shared Citadel project configuration for all runtimes, including Codex
  • .planning/ — planning/campaign system
  • docs/ — documentation
  • Root files — project setup
Phase 3 — Investigation
3a. Parse the Report

Extract: error messages, environment, reproduction steps, expected vs actual behavior, workarounds.

3b. Search the Codebase
  1. Grep for exact error messages / error codes
  2. Read files named in the issue
  3. Find functions named in stack traces
  4. Search for the bug class or anti-pattern
  5. git log --oneline -20 -- <affected-files> for recent changes
  6. Cross-reference similar issues
3c. Root Cause Analysis

For bugs:

  1. What breaks — the specific code path
  2. Why it breaks — root cause, not symptom
  3. When introduced — git blame / log
  4. Who is affected — scope
  5. The fix — file:line references

For features/questions:

  1. Already possible? Search existing functionality.
  2. Where would it go? Which component/layer.
  3. Effort: trivial / small / medium / large
  4. Blockers: dependencies, architecture constraints
Show full SKILL.md (451 more words)Show less
3d. Reproduce (when possible)

Set up conditions, run the failing command, confirm error matches, verify proposed fix resolves it.

Phase 4 — Resolution Plan

Write a per-issue resolution plan (full template: docs/TRIAGE.md#issue-resolution-plan-template) with:

  • Type, severity, component, reproducible (yes / no / not-attempted)
  • Root cause: 1-3 sentences explaining WHY
  • Affected code: <file>:<line> entries with what is wrong at each
  • Proposed fix: specific code changes with file:line references
  • Impact: who is affected, whether a workaround exists, whether it is a breaking change
  • Recommended action checkbox: Fix in next release / Needs more info from reporter / Won't fix (with reason) / Duplicate of #N
Phase 5 — Action

Auto-fix when: root cause clear and verified, fix contained to 1-3 files, no breaking changes, no architectural decisions needed.

Steps:

  1. Branch: fix/issue-<number>-<slug>
  2. Implement fix
  3. Run typecheck/build
  4. Commit: fix: <description> (closes #<number>)
  5. Push and open PR linking the issue
  6. Comment on the issue with the PR link

Comment with findings when fix needs discussion or user input: post root cause analysis, proposed fix, and questions.

Label only for questions/docs/features: add type + priority labels, optionally point to existing docs.

Phase 6 — Report

Output a Triage Summary table with columns # | Title | Type | Severity | Action | Status, one row per triaged item (example: docs/TRIAGE.md#triage-summary-example).

Label Taxonomy

Apply via $GH issue edit <number> --add-label "<label>":

Type: bug, feature, question, docs, infra Severity (bugs): critical, high, medium, low Status: needs-info, confirmed, wont-fix, duplicate

Auto-fix Handoff

---PR READY---
PR #<N>: <url>

To watch this PR automatically:
  Local  →  /pr-watch <N>
  Cloud  →  open in Claude Code web or mobile, toggle "Auto fix" ON
---

Contextual Gates

Disclosure: "Triaging GitHub issues and PRs. Read-only — no changes made without showing you first." Reversibility: green — investigation is read-only; any GitHub actions (labels, comments, PRs) shown to user for approval before posting Trust gates:

  • Any: view triage report; all external actions require explicit approval

Quality Gates

  • Every issue has a classification (type + severity for bugs)
  • Every bug has root cause with file:line references
  • Every auto-fix passes typecheck and build
  • Every PR links to the issue it fixes
  • Every issue has at least a label or comment
  • No issue comment is generic or substanceless

Fringe Cases

gh not available or not authenticated: Stop and instruct: "Run gh auth login before using /triage."

No open issues or PRs: Report "No open issues found." and exit cleanly.

Empty/unparseable issue body: Classify as needs-info, comment requesting reproduction steps.

.planning/ missing: /triage reads from GitHub, not local state. Skip .planning/ writes if missing.

Anti-Patterns — Do NOT

  • Post generic comments without substance
  • Propose fixes without reading the actual code
  • Label without investigating
  • Auto-fix when root cause is unclear
  • Close issues without explanation
  • Guess at fixes — verify by reading code and running checks

gh CLI Notes

  • Windows: "/c/Program Files/GitHub CLI/gh.exe" — always pass --repo <owner/repo>
  • Comments: $GH issue comment <number> --repo <owner/repo> --body "..."
  • Labels: $GH issue edit <number> --repo <owner/repo> --add-label "bug,high"

Exit Protocol

---HANDOFF---
- Triaged N issues: X bugs, Y features, Z questions
- Auto-fixed: <list of issue numbers with PR links>
- Needs attention: <list of issues requiring human decision>
- New labels applied: <count>
- Reversibility: green — investigation read-only; auto-fix PRs can be closed/reverted if unwanted
---

© SethGammon, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 2 other files in skills/triage of SethGammon/Citadel.

  • SKILL.md
  • __benchmarks__/no-gh-cli.md
  • __benchmarks__/specific-issue.md

Open the folder on GitHubat commit e41ff1d

Compare with similar skills

Triage next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Triage compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Triage this skillSethGammon/Citadel922—~2.7kAutomated safety check: PassMIT
Reviewing Pull RequestsShopify/shopify-app-js543—~1.9kAutomated safety check: PassMIT
Issue BriefVasiHemanth/tokentelemetry376—~1.5kAutomated safety check: PassMIT
Issue TracerZaxbyHub/opencode-swarm490—~4.4kAutomated safety check: PassMIT
CodeScope Codebase Graph AnalysisQwenLM/qwen-code28k1 repos~9.3kAutomated safety check: PassApache-2.0
Bugfix PRTanStack/ai3.2k—~4.8kAutomated safety check: PassMIT

Similar skills

  • Reviewing Pull Requests

    Shopify/shopify-app-js

    Official

    Reviews pull requests for Shopify/shopify-app-js with comprehensive analysis including semver compliance (MAJOR/MINOR/PATCH classification), single responsibility validation, pattern consistency…

    543 GitHub stars~1.9k tokensUpdated today
    DevelopmentAuto-check passed
  • Issue Brief

    VasiHemanth/tokentelemetry

    Explain a GitHub issue, discussion, or feature request in plain language before deciding whether to build it.

    376 GitHub stars~1.5k tokensUpdated 2 days ago
    DevelopmentAuto-check passed
  • Issue Tracer

    ZaxbyHub/opencode-swarm

    Drives a bug report from validation and root-cause tracing through a critic-reviewed plan, an approved minimal fix and a PR-ready closure, never merging without recorded human approval.

    490 GitHub stars~4.4k tokensUpdated today
    DevelopmentAuto-check passed
  • Answers questions about code structure, history, bugs and PR risk using a CodeScope knowledge graph and semantic index built from the repository.

    28k GitHub starsUsed in 1 repo~9.3k tokens
    DevelopmentAuto-check passed
  • Bugfix PR

    TanStack/ai

    Treats bug-fix pull requests as invasive and untrusted. An agent skill from TanStack/ai.

    3.2k GitHub stars~4.8k tokensUpdated today
    DevelopmentAuto-check passed
  • Quickly triages a contributor pull request or reported issue against repository policy and lightweight evidence without full review or root-cause analysis.

    2.3k GitHub stars~431 tokensUpdated 6 days ago
    DevelopmentAuto-check passed

More from SethGammon/Citadel

All 48 skills in this repo
  • Create Skill

    SethGammon/Citadel

    Creates new skills from the user's repeating patterns. An agent skill from SethGammon/Citadel.

    922 GitHub stars~1.9k tokensUpdated 7 days ago
    Auto-check passed
  • Houseclean

    SethGammon/Citadel

    Cross-drive storage audit and cleanup. An agent skill from SethGammon/Citadel.

    922 GitHub stars~2.2k tokensUpdated 7 days ago
    Auto-check passed
  • Loop

    SethGammon/Citadel

    Bounded foreground repetition for the current session. An agent skill from SethGammon/Citadel.

    922 GitHub stars~1.4k tokensUpdated 7 days ago
    Auto-check passed
  • Watch

    SethGammon/Citadel

    File sentinel that monitors the working directory for changes and marker comments, then auto-triggers appropriate skills.

    922 GitHub stars~2.9k tokensUpdated 7 days ago
    Auto-check passed
  • Archon

    SethGammon/Citadel

    Autonomous multi-session campaign agent. An agent skill from SethGammon/Citadel.

    922 GitHub stars~5.4k tokensUpdated 7 days ago
    Auto-check passed
  • Fleet

    SethGammon/Citadel

    Parallel campaign orchestrator. An agent skill from SethGammon/Citadel.

    922 GitHub stars~6.3k tokensUpdated 7 days ago
    Auto-check passed

Works with

Categories

Questions about Triage

What does Triage do?

GitHub issue and PR investigator. An agent skill from SethGammon/Citadel. Triage is an agent skill from SethGammon/Citadel. GitHub issue and PR investigator.

When should I use Triage?

Triage fits situations like: investigating GitHub issues and reviewing PRs; do NOT use for general code review unrelated to GitHub issues.

How do I install Triage in Claude Code?

Run `npx skills add SethGammon/Citadel --skill triage -a claude-code`. Or copy the skill folder (skills/triage in SethGammon/Citadel) into .claude/skills/triage in your project. Claude Code loads it when a task matches its description.

How do I install Triage in Codex?

Run `npx skills add SethGammon/Citadel --skill triage -a codex`. Or copy the skill folder (skills/triage in SethGammon/Citadel) into .agents/skills/triage in your project. Codex loads it when a task matches its description.

Can I use Triage in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add SethGammon/Citadel --skill triage -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/triage, .gemini/skills/triage, .github/skills/triage and .opencode/skills/triage in your project.

What does Triage need to run?

Going by SKILL.md and its folder, Triage needs the command-line tools its instructions call (node, git and gh).

Does Triage access the network?

SKILL.md contains no URLs. Its commands use git and gh, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Triage safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Triage use?

Triage is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Triage use?

About 2.7k tokens (SKILL.md is roughly 11k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Triage?

Skills that share tags, products or a category with Triage: Reviewing Pull Requests (Shopify/shopify-app-js, 543 stars), Issue Brief (VasiHemanth/tokentelemetry, 376 stars), Issue Tracer (ZaxbyHub/opencode-swarm, 490 stars) and CodeScope Codebase Graph Analysis (QwenLM/qwen-code, 28k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Triage?

SethGammon (a GitHub user) maintains it in SethGammon/Citadel, which has 922 GitHub stars. The repository holds 48 skills in this directory. The repository was last updated on October 1, 2026.

Source: SethGammon/Citadel on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.