issue-discover
25
总安装量
2
周安装量
#14707
全站排名
安装命令
npx skills add https://github.com/catlog22/claude-code-workflow --skill issue-discover
Agent 安装分布
amp
2
opencode
2
kimi-cli
2
codex
2
github-copilot
2
gemini-cli
2
Skill 文档
Issue Discover
Unified issue discovery and creation skill covering three entry points: manual issue creation, perspective-based discovery, and prompt-driven exploration.
Architecture Overview
âââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââ
â Issue Discover Orchestrator (SKILL.md) â
â â Action selection â Route to phase â Execute â Summary â
âââââââââââââââââ¬ââââââââââââââââââââââââââââââââââââââââââââââââââ
â
ââ AskUserQuestion: Select action
â
âââââââââââââ¼ââââââââââââ¬ââââââââââââ
â â â â
âââââââââââ âââââââââââ âââââââââââ â
â Phase 1 â â Phase 2 â â Phase 3 â â
â Create â âDiscover â âDiscover â â
â New â â Multi â âby Promptâ â
âââââââââââ âââââââââââ âââââââââââ â
â â â â
Issue Discoveries Discoveries â
(registered) (export) (export) â
â â â â
âââââââââââââ´ââââââââââââ â
â â
issue-resolve (plan/queue) â
â â
/issue:execute â
Key Design Principles
- Action-Driven Routing: AskUserQuestion selects action, then load single phase
- Progressive Phase Loading: Only read the selected phase document
- CLI-First Data Access: All issue CRUD via
ccw issueCLI commands - Auto Mode Support:
-yflag skips action selection with auto-detection
Auto Mode
When --yes or -y: Skip action selection, auto-detect action from input type.
Usage
Skill(skill="issue-discover", args="<input>")
Skill(skill="issue-discover", args="[FLAGS] \"<input>\"")
# Flags
-y, --yes Skip all confirmations (auto mode)
--action <type> Pre-select action: new|discover|discover-by-prompt
# Phase-specific flags
--priority <1-5> Issue priority (new mode)
--perspectives <list> Comma-separated perspectives (discover mode)
--external Enable Exa research (discover mode)
--scope <pattern> File scope (discover/discover-by-prompt mode)
--depth <level> standard|deep (discover-by-prompt mode)
--max-iterations <n> Max exploration iterations (discover-by-prompt mode)
# Examples
Skill(skill="issue-discover", args="https://github.com/org/repo/issues/42") # Create from GitHub
Skill(skill="issue-discover", args="\"Login fails with special chars\"") # Create from text
Skill(skill="issue-discover", args="--action discover src/auth/**") # Multi-perspective discovery
Skill(skill="issue-discover", args="--action discover src/api/** --perspectives=security,bug") # Focused discovery
Skill(skill="issue-discover", args="--action discover-by-prompt \"Check API contracts\"") # Prompt-driven discovery
Skill(skill="issue-discover", args="-y \"auth broken\"") # Auto mode create
Execution Flow
Input Parsing:
ââ Parse flags (--action, -y, --perspectives, etc.) and positional args
Action Selection:
ââ --action flag provided â Route directly
ââ Auto-detect from input:
â ââ GitHub URL or #number â Create New (Phase 1)
â ââ Path pattern (src/**, *.ts) â Discover (Phase 2)
â ââ Short text (< 80 chars) â Create New (Phase 1)
â ââ Long descriptive text (⥠80 chars) â Discover by Prompt (Phase 3)
ââ Otherwise â AskUserQuestion to select action
Phase Execution (load one phase):
ââ Phase 1: Create New â phases/01-issue-new.md
ââ Phase 2: Discover â phases/02-discover.md
ââ Phase 3: Discover by Prompt â phases/03-discover-by-prompt.md
Post-Phase:
ââ Summary + Next steps recommendation
Phase Reference Documents
| Phase | Document | Load When | Purpose |
|---|---|---|---|
| Phase 1 | phases/01-issue-new.md | Action = Create New | Create issue from GitHub URL or text description |
| Phase 2 | phases/02-discover.md | Action = Discover | Multi-perspective issue discovery (bug, security, test, etc.) |
| Phase 3 | phases/03-discover-by-prompt.md | Action = Discover by Prompt | Prompt-driven iterative exploration with Gemini planning |
Core Rules
- Action Selection First: Always determine action before loading any phase
- Single Phase Load: Only read the selected phase document, never load all phases
- CLI Data Access: Use
ccw issueCLI for all issue operations, NEVER read files directly - Content Preservation: Each phase contains complete execution logic from original commands
- Auto-Detect Input: Smart input parsing reduces need for explicit –action flag
Input Processing
Auto-Detection Logic
function detectAction(input, flags) {
// 1. Explicit --action flag
if (flags.action) return flags.action;
const trimmed = input.trim();
// 2. GitHub URL â new
if (trimmed.match(/github\.com\/[\w-]+\/[\w-]+\/issues\/\d+/) || trimmed.match(/^#\d+$/)) {
return 'new';
}
// 3. Path pattern (contains **, /, or --perspectives) â discover
if (trimmed.match(/\*\*/) || trimmed.match(/^src\//) || flags.perspectives) {
return 'discover';
}
// 4. Short text (< 80 chars, no special patterns) â new
if (trimmed.length > 0 && trimmed.length < 80 && !trimmed.includes('--')) {
return 'new';
}
// 5. Long descriptive text â discover-by-prompt
if (trimmed.length >= 80) {
return 'discover-by-prompt';
}
// Cannot auto-detect â ask user
return null;
}
Action Selection (AskUserQuestion)
// When action cannot be auto-detected
const answer = AskUserQuestion({
questions: [{
question: "What would you like to do?",
header: "Action",
multiSelect: false,
options: [
{
label: "Create New Issue (Recommended)",
description: "Create issue from GitHub URL, text description, or structured input"
},
{
label: "Discover Issues",
description: "Multi-perspective discovery: bug, security, test, quality, performance, etc."
},
{
label: "Discover by Prompt",
description: "Describe what to find â Gemini plans the exploration strategy iteratively"
}
]
}]
});
// Route based on selection
const actionMap = {
"Create New Issue": "new",
"Discover Issues": "discover",
"Discover by Prompt": "discover-by-prompt"
};
Data Flow
User Input (URL / text / path pattern / descriptive prompt)
â
[Parse Flags + Auto-Detect Action]
â
[Action Selection] â AskUserQuestion (if needed)
â
[Read Selected Phase Document]
â
[Execute Phase Logic]
â
[Summary + Next Steps]
ââ After Create â Suggest issue-resolve (plan solution)
ââ After Discover â Suggest export to issues, then issue-resolve
TodoWrite Pattern
[
{"content": "Select action", "status": "completed"},
{"content": "Execute: [selected phase name]", "status": "in_progress"},
{"content": "Summary & next steps", "status": "pending"}
]
Phase-specific sub-tasks are attached when the phase executes (see individual phase docs for details).
Core Guidelines
Data Access Principle: Issues files can grow very large. To avoid context overflow:
| Operation | Correct | Incorrect |
|---|---|---|
| List issues (brief) | ccw issue list --status pending --brief |
Read('issues.jsonl') |
| Read issue details | ccw issue status <id> --json |
Read('issues.jsonl') |
| Create issue | echo '...' | ccw issue create |
Direct file write |
| Update status | ccw issue update <id> --status ... |
Direct file edit |
ALWAYS use CLI commands for CRUD operations. NEVER read entire issues.jsonl directly.
Error Handling
| Error | Resolution |
|---|---|
| No action detected | Show AskUserQuestion with all 3 options |
| Invalid action type | Show available actions, re-prompt |
| Phase execution fails | Report error, suggest manual intervention |
| No files matched (discover) | Check target pattern, verify path exists |
| Gemini planning failed (discover-by-prompt) | Retry with qwen fallback |
Post-Phase Next Steps
After successful phase execution, recommend next action:
// After Create New (issue created)
AskUserQuestion({
questions: [{
question: "Issue created. What next?",
header: "Next",
multiSelect: false,
options: [
{ label: "Plan Solution", description: "Generate solution via issue-resolve" },
{ label: "Create Another", description: "Create more issues" },
{ label: "View Issues", description: "Review all issues" },
{ label: "Done", description: "Exit workflow" }
]
}]
});
// After Discover / Discover by Prompt (discoveries generated)
AskUserQuestion({
questions: [{
question: "Discovery complete. What next?",
header: "Next",
multiSelect: false,
options: [
{ label: "Export to Issues", description: "Convert discoveries to issues" },
{ label: "Plan Solutions", description: "Plan solutions for exported issues via issue-resolve" },
{ label: "Done", description: "Exit workflow" }
]
}]
});
Related Skills & Commands
issue-resolve– Plan solutions, convert artifacts, form queues, from brainstormissue-manage– Interactive issue CRUD operations/issue:execute– Execute queue with DAG-based parallel orchestrationccw issue list– List all issuesccw issue status <id>– View issue details