Skip to main content
command CX Codex

issue-triage · davepoon — Claude Code command: triage GitHub issues into Linear

issue-triage reads incoming GitHub issues, sets category, priority and owning team, checks for duplicates, then files a Linear task.

MIT ★ 3,785 updated 2026-10-25

Install into Claude Code · Plugin marketplace All methods and platforms ↓
/plugin marketplace add davepoon/buildwithclaude
/plugin install all-commands@buildwithclaude
Open on GitHub

What issue-triage does

The command turns the model into a triage specialist for GitHub issues. It reads tone and urgency, sorts the report into a category, estimates complexity, checks the reporter's history, pulls stack traces, notes which components break and whether the bug reproduces. Those signals then hit a rule table.

Security wording or a CVE reference sends an issue to the security team at priority 1. Bugs go to engineering, and a sharply negative tone lifts them a step. Feature requests reach product with a discussion flag, documentation reaches the docs team. A numeric score adds 40 for immediate urgency, 20 for words like urgent or critical, 20 when core components are hit, and subtracts 10 once an issue has sat past 30 days. Scores of 70 and above map to priority 1, 50 to 2, 30 to 3, the rest to 4.

Duplicates are checked first, by semantic similarity, fuzzy title and matching stack trace. What survives gets labels plus a Linear task, then the GitHub issue is updated and stakeholders are notified. The JavaScript blocks are logic the model should follow, not scripts that execute. Functions such as createTriagedTask and updateGitHubIssue are only described, so GitHub and Linear access has to come from somewhere else.

What it helps with

  • sort a backlog of new issues by priority without reading each one
  • catch duplicate reports by title or stack trace
  • route an issue to the team that owns the broken component
  • open a Linear task straight from a GitHub issue
  • label issues by category, component and urgency

Example prompts for the agent

  • Run /issue-triage over the open issues and rank them by priority
  • Check whether the latest bug report duplicates something already filed
  • Triage this batch and create the Linear tasks with labels

How to install issue-triage

1Plugin marketplace

/plugin marketplace add davepoon/buildwithclaude
/plugin install all-commands@buildwithclaude

2Manually: put the files in place

.claude/commands/issue-triage.md

Call it with /issue-triage. For all projects use ~/.claude/commands/

Questions about issue-triage

How do I install issue-triage in Claude Code?

Use the marketplace: /plugin marketplace add davepoon/buildwithclaude, then /plugin install all-commands@buildwithclaude. The command itself is the file .claude/commands/issue-triage.md.

What does issue-triage do?

It triages GitHub issues: picks a category and priority, assigns the team, looks for duplicates and creates a labelled Linear task.

Does issue-triage need Linear?

Routing ends with a Linear task, so without Linear the chain stops after analysis and labels. The duplicate search and the priority score still apply.

Source text

issue-triage.md · MIT
---
description: Triage and prioritize issues effectively
category: team-collaboration
---

# issue-triage

Triage and prioritize issues effectively

## System

You are an issue triage specialist that analyzes GitHub issues and intelligently routes them to Linear with appropriate categorization, prioritization, and team assignment. You use content analysis, patterns, and rules to make smart triage decisions.

## Instructions

When triaging GitHub issues:

1. **Issue Analysis**
   ```javascript
   async function analyzeIssue(issue) {
     const analysis = {
       // Content analysis
       sentiment: analyzeSentiment(issue.title, issue.body),
       urgency: detectUrgency(issue),
       category: categorizeIssue(issue),
       complexity: estimateComplexity(issue),
       
       // User analysis
       authorType: classifyAuthor(issue.author),
       authorHistory: await getAuthorHistory(issue.author),
       
       // Technical analysis
       stackTrace: extractStackTrace(issue.body),
       affectedComponents: detectComponents(issue),
       reproducibility: assessReproducibility(issue),
       
       // Business impact
       userImpact: estimateUserImpact(issue),
       businessPriority: calculateBusinessPriority(issue)
     };
     
     return analysis;
   }
   ```

2. **Categorization Rules**
   ```javascript
   const categorizationRules = [
     {
       name: 'Security Issue',
       patterns: [/security/i, /vulnerability/i, /CVE-/],
       labels: ['security'],
       priority: 1, // Urgent
       team: 'security',
       notify: ['security-lead']
     },
     {
       name: 'Bug Report',
       patterns: [/bug/i, /error/i, /crash/i, /broken/i],
       hasStackTrace: true,
       labels: ['bug'],
       priority: (issue) => issue.sentiment < -0.5 ? 2 : 3,
       team: 'engineering'
     },
     {
       name: 'Feature Request',
       patterns: [/feature/i, /enhancement/i, /add/i, /implement/i],
       labels: ['enhancement'],
       priority: 4,
       team: 'product',
       requiresDiscussion: true
     },
     {
       name: 'Documentation',
       patterns: [/docs/i, /documentation/i, /readme/i],
       labels: ['documentation'],
       priority: 4,
       team: 'docs'
     }
   ];
   ```

3. **Priority Calculation**
   ```javascript
   function calculatePriority(issue, analysis) {
     let score = 0;
     
     // Urgency indicators
     if (analysis.urgency === 'immediate') score += 40;
     if (containsKeywords(issue, ['urgent', 'asap', 'critical'])) score += 20;
     if (issue.title.includes('🔥') || issue.title.includes('!!!')) score += 15;
     
     // Impact assessment
     score += analysis.userImpact * 10;
     if (analysis.affectedComponents.includes('core')) score += 20;
     if (analysis.reproducibility === 'always') score += 10;
     
     // Author influence
     if (analysis.authorType === 'enterprise') score += 15;
     if (analysis.authorHistory.issuesOpened > 10) score += 5;
     
     // Time decay
     const ageInDays = (Date.now() - new Date(issue.createdAt)) / (1000 * 60 * 60 * 24);
     if (ageInDays > 30) score -= 10;
     
     // Map score to priority
     if (score >= 70) return 1; // Urgent
     if (score >= 50) return 2; // High
     if (score >= 30) return 3; // Medium
     return 4; // Low
   }
   ```

4. **Team Assignment**
   ```javascript
   async function assignTeam(issue, analysis) {
     // Rule-based assignment
     for (const rule of categorizationRules) {
       if (matchesRule(issue, rule)) {
         return rule.team;
       }
     }
     
     // Component-based assignment
     const componentTeamMap = {
       'auth': 'identity-team',
       'api': 'platform-team',
       'ui': 'frontend-team',
       'database': 'data-team'
     };
     
     for (const component of analysis.affectedComponents) {
       if (componentTeamMap[component]) {
         return componentTeamMap[component];
       }
     }
     
     // ML-based assignment (if available)
     if (ML_ENABLED) {
       return await predictTeam(issue, analysis);
     }
     
     // Default assignment
     return 'triage-team';
   }
   ```

5. **Duplicate Detection**
   ```javascript
   async function findDuplicates(issue) {
     // Semantic similarity search
     const similar = await searchSimilarIssues(issue, {
       threshold: 0.85,
       limit: 5
     });
     
     // Title similarity
     const titleMatches = await searchByTitle(issue.title, {
       fuzzy: true,
       distance: 3
     });
     
     // Stack trace matching (for bugs)
     const stackTrace = extractStackTrace(issue.body);
     const stackMatches = stackTrace ? 
       await searchByStackTrace(stackTrace) : [];
     
     return {
       likely: similar.filter(s => s.score > 0.9),
       possible: [...similar, ...titleMatches, ...stackMatches]
         .filter(s => s.score > 0.7)
         .slice(0, 5)
     };
   }
   ```

6. **Auto-labeling**
   ```javascript
   function generateLabels(issue, analysis) {
     const labels = new Set();
     
     // Category labels
     labels.add(analysis.category.toLowerCase());
     
     // Priority labels
     labels.add(`priority/${getPriorityName(analysis.priority)}`);
     
     // Technical labels
     if (analysis.stackTrace) labels.add('has-stack-trace');
     if (analysis.reproducibility === 'always') labels.add('reproducible');
     
     // Component labels
     analysis.affectedComponents.forEach(c => 
       labels.add(`component/${c}`)
     );
     
     // Status labels
     if (analysis.needsMoreInfo) labels.add('needs-info');
     if (analysis.duplicate) labels.add('duplicate');
     
     return Array.from(labels);
   }
   ```

7. **Triage Workflow**
   ```javascript
   async function triageIssue(issue) {
     const workflow = {
       analyzed: false,
       triaged: false,
       actions: []
     };
     
     try {
       // Step 1: Analyze
       const analysis = await analyzeIssue(issue);
       workflow.analyzed = true;
       
       // Step 2: Check duplicates
       const duplicates = await findDuplicates(issue);
       if (duplicates.likely.length > 0) {
         return handleDuplicate(issue, duplicates.likely[0]);
       }
       
       // Step 3: Determine routing
       const triage = {
         team: await assignTeam(issue, analysis),
         priority: calculatePriority(issue, analysis),
         labels: generateLabels(issue, analysis),
         assignee: await suggestAssignee(issue, analysis)
       };
       
       // Step 4: Create Linear task
       const task = await createTriagedTask(issue, triage, analysis);
       workflow.triaged = true;
       
       // Step 5: Update GitHub
       await updateGitHubIssue(issue, triage, task);
       
       // Step 6: Notify stakeholders
       await notifyStakeholders(issue, triage, analysis);
       
       return workflow;
     } catch (error) {
       workflow.error = error;
       return workflow;
     }
   }
   ```

8. **Batch Triage**
   ```javascript
   async function batchTriage(filters) {
     const issues = await fetchUntriaged(filters);
     const results = {
       total: issues.length,
       triaged: [],
       skipped: [],
       failed: []
     };
     
     console.log(`Found ${issues.length} issues to triage`);
     
     for (const issue of issues) {
       try {
         // Skip if already triaged
         if (hasTriageLabel(issue)) {
           results.skipped.push(issue);
           continue;
         }
         
         // Triage issue
         const result = await triageIssue(issue);
         if (result.triaged) {
           results.triaged.push({ issue, result });
         } else {
           results.failed.push({ issue, error: result.error });
         }
         
         // Progress update
         updateProgress(results);
         
       } catch (error) {
         results.failed.push({ issue, error });
       }
     }
     
     return results;
   }
   ```

9. **Triage Templates**
   ```javascript
   const triageTemplates = {
     bug: {
       linearTemplate: `
   ## Bug Report
   
   **Reported by:** {author}
   **Severity:** {severity}
   **Reproducibility:** {reproducibility}
   
   ### Description
   {description}
   
   ### Stack Trace
   \`\`\`
   {stackTrace}
   \`\`\`
   
   ### Environment
   {environment}
   
   ### Steps to Reproduce
   {reproSteps}
       `,
       requiredInfo: ['description', 'environment', 'reproSteps']
     },
     
     feature: {
       linearTemplate: `
   ## Feature Request
   
   **Requested by:** {author}
   **Business Value:** {businessValue}
   
   ### Description
   {description}
   
   ### Use Cases
   {useCases}
   
   ### Acceptance Criteria
   {acceptanceCriteria}
       `,
       requiresApproval: true
     }
   };
   ```

10. **Triage Metrics**
    ```javascript
    function generateTriageMetrics(period = '7d') {
      return {
        volume: {
          total: countIssues(period),
          byCategory: groupByCategory(period),
          byPriority: groupByPriority(period),
          byTeam: groupByTeam(period)
        },
        
        performance: {
          avgTriageTime: calculateAvgTriageTime(period),
          autoTriageRate: calculateAutoTriageRate(period),
          accuracyRate: calculateAccuracy(period)
        },
        
        patterns: {
          commonIssues: findCommonPatterns(period),
          peakTimes: analyzePeakTimes(period),
          teamLoad: analyzeTeamLoad(period)
        }
      };
    }
    ```

## Examples

### Manual Triage
```bash
# Triage single issue
claude issue-triage 123

# Triage with options
claude issue-triage 123 --team="backend" --priority="high"

# Interactive triage
claude issue-triage 123 --interactive
```

### Automated Triage
```bash
# Triage all untriaged issues
claude issue-triage --auto

# Triage with filters
claude issue-triage --auto --label="needs-triage"

# Scheduled triage
claude issue-triage --auto --schedule="*/15 * * * *"
```

### Triage Configuration
```bash
# Set up triage rules
claude issue-triage --setup-rules

# Test triage rules
claude issue-triage --test-rules --dry-run

# Export triage config
claude issue-triage --export-config > triage-config.json
```

## Output Format

```
Issue Triage Report
===================
Processed: 2025-01-16 11:00:00
Mode: Automatic

Triage Summary:
───────────────────────────────────
Total Issues      : 47
Successfully Triaged : 44 (93.6%)
Duplicates Found  : 3
Manual Review     : 3
Failed           : 0

By Category:
- Bug Reports     : 28 (63.6%)
- Feature Requests: 12 (27.3%)
- Documentation   : 4 (9.1%)

By Priority:
- Urgent (P1)     : 3  ████
- High (P2)       : 12 ████████████
- Medium (P3)     : 24 ████████████████████████
- Low (P4)        : 5  █████

Team Assignments:
- Backend         : 18
- Frontend        : 15
- Security        : 3
- Documentation   : 4
- Triage Team     : 4

Notable Issues:
🔴 #456: Security vulnerability in auth system → Security Team (P1)
🟠 #789: Database connection pooling errors → Backend Team (P2)
🟡 #234: Add dark mode support → Frontend Team (P3)

Actions Taken:
✓ Created 44 Linear tasks
✓ Applied 156 labels
✓ Assigned to 12 team members
✓ Linked 3 duplicates
✓ Sent 8 notifications

Triage Metrics:
- Avg time per issue: 2.3s
- Auto-triage accuracy: 94.2%
- Manual intervention: 6.8%
```

## Best Practices

1. **Rule Refinement**
   - Regularly review triage accuracy
   - Update patterns based on feedback
   - Test rules before deployment

2. **Quality Control**
   - Sample triaged issues for review
   - Track false positives/negatives
   - Implement feedback loops

3. **Stakeholder Communication**
   - Notify teams of new assignments
   - Provide triage summaries
   - Escalate critical issues

4. **Continuous Improvement**
   - Analyze triage patterns
   - Optimize assignment rules
   - Implement ML when appropriate

© BuildWithClaude Community · MIT · davepoon/buildwithclaude

Similar slash commands

All slash commands for Git and GitHub →

issue-triage by other authors comes first.

issue-triage davila7 issue-triage triages incoming GitHub and Linear tasks, computes priority scores, and routes issues to matching teams. CX Codex +1 276installs om-auto-issue-triage open-mercato om-auto-issue-triage — a Claude Code skill ranks open issues suitable for automated fixes and prepares queue labels. It generates a shortlist and pauses for explicit human confirmation before updating the tracker. CX Codex +1 455installs triage-issues dyoshikawa triage-issues walks open GitHub issues that carry no labels, reads each one, and applies fitting labels from your repository's own set. Handy once the backlog gets noisy and nobody knows where to start. CX Codex +1 ★ 1,636repo stars oss-issue-triage Samuel Berthe oss-issue-triage designs an issue and pull-request triage system sized to what a maintainer team can actually sustain: labels, intake, response targets, duty rotation. CX Codex +1 13,400installs issue-create terrylica issue-create turns a rough description into a formatted GitHub issue: detects the type, picks labels that exist in the repo, and warns about duplicates before you post. CX Codex +1 129installs linear-task-to-issue davila7 linear-task-to-issue — a slash command that turns a Linear task into a GitHub issue, carrying over fields, links, attachments and comments. Useful when planning lives in Linear and code lives in GitHub. CX Codex +1 129installs github-project-triage steipete The github-project-triage Claude Code skill reviews open GitHub issues and pull requests when prompted with “triage.” It surfaces blockers, checks, risks, and a next action for each item. CX Codex +1 105installs

From the same set235

The whole set →
freshdesk-automation freshdesk-automation is a Claude Code skill for managing Freshdesk tickets, contacts, and companies through Rube MCP. It searches cases, sends replies, and adds notes from an AI coding workflow. CX Codex +1 ★ 3,785repo stars ops-yolo ops-yolo is a Claude Code skill that launches four parallel agents to assess a company from executive perspectives. It surfaces critical project problems. CX Codex +1 ★ 3,785repo stars exploits-search exploits-search searches for vulnerabilities with public exploits across your repository ecosystems and tracks them in local memory. CX Codex +1 ★ 3,785repo stars clickup-automation clickup-automation — a skill for Claude Code and Cursor that automates ClickUp project management through Rube MCP: create and update tasks, browse workspace hierarchy, add comments, and manage team members. CX Codex +1 ★ 3,785repo stars todoist-automation todoist-automation is a Claude Code skill for managing Todoist tasks, projects, sections, and search filters through Rube MCP. CX Codex +1 ★ 3,785repo stars monday-automation monday-automation is a Claude Code skill that manages Monday.com boards and their contents through Rube MCP. It creates tasks, edits column values, and sorts items into groups. CX Codex +1 ★ 3,785repo stars bitbucket-automation bitbucket-automation walks an agent through Bitbucket work — repositories, pull requests, branches, issues — over the Rube MCP server from Composio. Handy when repo chores happen from a chat prompt. CX Codex +1 ★ 3,785repo stars pipedrive-automation pipedrive-automation — a skill for Claude Code and Cursor that handles deals, contacts, organizations, activities, and notes in Pipedrive through Rube MCP (Composio). CX Codex +1 ★ 3,785repo stars

Project sponsors

Companies that keep this analytics open