forge-workflow 0.0.2 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (147) hide show
  1. package/.claude/commands/plan.md +93 -4
  2. package/.cline/workflows/dev.md +311 -0
  3. package/.cline/workflows/plan.md +475 -0
  4. package/.cline/workflows/premerge.md +176 -0
  5. package/.cline/workflows/research.md +39 -0
  6. package/.cline/workflows/review.md +439 -0
  7. package/.cline/workflows/rollback.md +718 -0
  8. package/.cline/workflows/ship.md +131 -0
  9. package/.cline/workflows/sonarcloud.md +146 -0
  10. package/.cline/workflows/status.md +74 -0
  11. package/.cline/workflows/validate.md +234 -0
  12. package/.cline/workflows/verify.md +218 -0
  13. package/.codex/config.toml +11 -0
  14. package/.codex/skills/dev/SKILL.md +314 -0
  15. package/.codex/skills/plan/SKILL.md +478 -0
  16. package/.codex/skills/premerge/SKILL.md +179 -0
  17. package/.codex/skills/research/SKILL.md +42 -0
  18. package/.codex/skills/review/SKILL.md +442 -0
  19. package/.codex/skills/rollback/SKILL.md +721 -0
  20. package/.codex/skills/ship/SKILL.md +134 -0
  21. package/.codex/skills/sonarcloud/SKILL.md +149 -0
  22. package/.codex/skills/status/SKILL.md +77 -0
  23. package/.codex/skills/validate/SKILL.md +237 -0
  24. package/.codex/skills/verify/SKILL.md +221 -0
  25. package/.cursor/commands/dev.md +311 -0
  26. package/.cursor/commands/plan.md +475 -0
  27. package/.cursor/commands/premerge.md +176 -0
  28. package/.cursor/commands/research.md +39 -0
  29. package/.cursor/commands/review.md +439 -0
  30. package/.cursor/commands/rollback.md +718 -0
  31. package/.cursor/commands/ship.md +131 -0
  32. package/.cursor/commands/sonarcloud.md +146 -0
  33. package/.cursor/commands/status.md +74 -0
  34. package/.cursor/commands/validate.md +234 -0
  35. package/.cursor/commands/verify.md +218 -0
  36. package/.cursor/rules/permissions-guidance.mdc +37 -0
  37. package/.github/prompts/dev.prompt.md +316 -0
  38. package/.github/prompts/plan.prompt.md +480 -0
  39. package/.github/prompts/premerge.prompt.md +181 -0
  40. package/.github/prompts/research.prompt.md +44 -0
  41. package/.github/prompts/review.prompt.md +444 -0
  42. package/.github/prompts/rollback.prompt.md +723 -0
  43. package/.github/prompts/ship.prompt.md +136 -0
  44. package/.github/prompts/sonarcloud.prompt.md +151 -0
  45. package/.github/prompts/status.prompt.md +79 -0
  46. package/.github/prompts/validate.prompt.md +239 -0
  47. package/.github/prompts/verify.prompt.md +223 -0
  48. package/.kilocode/workflows/dev.md +315 -0
  49. package/.kilocode/workflows/plan.md +479 -0
  50. package/.kilocode/workflows/premerge.md +180 -0
  51. package/.kilocode/workflows/research.md +43 -0
  52. package/.kilocode/workflows/review.md +443 -0
  53. package/.kilocode/workflows/rollback.md +722 -0
  54. package/.kilocode/workflows/ship.md +135 -0
  55. package/.kilocode/workflows/sonarcloud.md +150 -0
  56. package/.kilocode/workflows/status.md +78 -0
  57. package/.kilocode/workflows/validate.md +238 -0
  58. package/.kilocode/workflows/verify.md +222 -0
  59. package/.opencode/commands/dev.md +314 -0
  60. package/.opencode/commands/plan.md +478 -0
  61. package/.opencode/commands/premerge.md +179 -0
  62. package/.opencode/commands/research.md +42 -0
  63. package/.opencode/commands/review.md +442 -0
  64. package/.opencode/commands/rollback.md +721 -0
  65. package/.opencode/commands/ship.md +134 -0
  66. package/.opencode/commands/sonarcloud.md +149 -0
  67. package/.opencode/commands/status.md +77 -0
  68. package/.opencode/commands/validate.md +237 -0
  69. package/.opencode/commands/verify.md +221 -0
  70. package/.roo/commands/dev.md +315 -0
  71. package/.roo/commands/plan.md +479 -0
  72. package/.roo/commands/premerge.md +180 -0
  73. package/.roo/commands/research.md +43 -0
  74. package/.roo/commands/review.md +443 -0
  75. package/.roo/commands/rollback.md +722 -0
  76. package/.roo/commands/ship.md +135 -0
  77. package/.roo/commands/sonarcloud.md +150 -0
  78. package/.roo/commands/status.md +78 -0
  79. package/.roo/commands/validate.md +238 -0
  80. package/.roo/commands/verify.md +222 -0
  81. package/LICENSE +21 -21
  82. package/docs/ENHANCED_ONBOARDING.md +2 -2
  83. package/docs/TOOLCHAIN.md +15 -234
  84. package/install.sh +32 -36
  85. package/lib/commands/plan.js +11 -15
  86. package/lib/commands/recommend.js +2 -2
  87. package/lib/dep-guard/analyzer.js +294 -0
  88. package/lib/dep-guard/behavior-detector.js +98 -0
  89. package/lib/dep-guard/contract-detector.js +162 -0
  90. package/lib/dep-guard/import-detector.js +498 -0
  91. package/lib/dep-guard/path-utils.js +13 -0
  92. package/lib/dep-guard/rubric.js +120 -0
  93. package/lib/dep-guard/task-parser.js +318 -0
  94. package/lib/plugin-catalog.js +18 -28
  95. package/lib/workflow-profiles.js +5 -11
  96. package/package.json +15 -4
  97. package/skills/parallel-deep-research/SKILL.md +108 -0
  98. package/skills/parallel-deep-research/evals/README.md +27 -0
  99. package/skills/parallel-deep-research/evals/evals.json +62 -0
  100. package/skills/sonarcloud-analysis/SKILL.md +171 -0
  101. package/skills/sonarcloud-analysis/evals/README.md +27 -0
  102. package/skills/sonarcloud-analysis/evals/evals.json +50 -0
  103. package/skills/sonarcloud-analysis/references/api-reference.md +466 -0
  104. package/docs/planning/PROGRESS.md +0 -396
  105. package/docs/plans/.gitkeep +0 -0
  106. package/docs/plans/2026-02-27-forge-test-suite-v2-decisions.md +0 -21
  107. package/docs/plans/2026-02-27-forge-test-suite-v2-design.md +0 -362
  108. package/docs/plans/2026-02-27-forge-test-suite-v2-tasks.md +0 -343
  109. package/docs/plans/2026-03-02-superpowers-gaps-decisions.md +0 -26
  110. package/docs/plans/2026-03-02-superpowers-gaps-design.md +0 -239
  111. package/docs/plans/2026-03-02-superpowers-gaps-tasks.md +0 -260
  112. package/docs/plans/2026-03-04-agent-command-parity-design.md +0 -163
  113. package/docs/plans/2026-03-04-verify-worktree-cleanup-decisions.md +0 -7
  114. package/docs/plans/2026-03-04-verify-worktree-cleanup-design.md +0 -165
  115. package/docs/plans/2026-03-05-forge-uto-decisions.md +0 -6
  116. package/docs/plans/2026-03-05-forge-uto-design.md +0 -116
  117. package/docs/plans/2026-03-05-forge-uto-tasks.md +0 -244
  118. package/docs/plans/2026-03-10-command-creator-and-eval-decisions.md +0 -52
  119. package/docs/plans/2026-03-10-command-creator-and-eval-design.md +0 -350
  120. package/docs/plans/2026-03-10-command-creator-and-eval-tasks.md +0 -426
  121. package/docs/plans/2026-03-10-stale-workflow-refs-decisions.md +0 -8
  122. package/docs/plans/2026-03-10-stale-workflow-refs-design.md +0 -80
  123. package/docs/plans/2026-03-10-stale-workflow-refs-tasks.md +0 -90
  124. package/docs/plans/2026-03-14-beads-plan-context-decisions.md +0 -9
  125. package/docs/plans/2026-03-14-beads-plan-context-design.md +0 -171
  126. package/docs/plans/2026-03-14-beads-plan-context-tasks.md +0 -160
  127. package/docs/plans/2026-03-14-skill-eval-loop-decisions.md +0 -33
  128. package/docs/plans/2026-03-14-skill-eval-loop-design.md +0 -118
  129. package/docs/plans/2026-03-14-skill-eval-loop-results.md +0 -78
  130. package/docs/plans/2026-03-14-skill-eval-loop-tasks.md +0 -160
  131. package/docs/plans/2026-03-15-agent-command-parity-v2-decisions.md +0 -11
  132. package/docs/plans/2026-03-15-agent-command-parity-v2-design.md +0 -145
  133. package/docs/plans/2026-03-15-agent-command-parity-v2-tasks.md +0 -211
  134. package/docs/research/TEMPLATE.md +0 -292
  135. package/docs/research/advanced-testing.md +0 -297
  136. package/docs/research/agent-permissions.md +0 -167
  137. package/docs/research/dependency-chain.md +0 -328
  138. package/docs/research/forge-workflow-v2.md +0 -550
  139. package/docs/research/plugin-architecture.md +0 -772
  140. package/docs/research/pr4-cli-automation.md +0 -326
  141. package/docs/research/premerge-verify-restructure.md +0 -205
  142. package/docs/research/skills-restructure.md +0 -508
  143. package/docs/research/sonarcloud-perfection-plan.md +0 -166
  144. package/docs/research/sonarcloud-quality-gate.md +0 -184
  145. package/docs/research/superpowers-integration.md +0 -403
  146. package/docs/research/superpowers.md +0 -319
  147. package/docs/research/test-environment.md +0 -519
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "forge-workflow",
3
- "version": "0.0.2",
3
+ "version": "0.0.3",
4
4
  "description": "7-stage TDD workflow for ALL AI coding agents (Claude, Cursor, Cline, OpenCode, Copilot, Kilo Code, Roo Code, Codex)",
5
5
  "bin": {
6
6
  "forge": "bin/forge.js",
@@ -39,7 +39,7 @@
39
39
  "@commitlint/config-conventional": "^20.4.1",
40
40
  "@eslint/js": "^10.0.1",
41
41
  "@microsoft/eslint-formatter-sarif": "^3.1.0",
42
- "@stryker-mutator/core": "^9.5.1",
42
+ "@stryker-mutator/core": "^9.6.0",
43
43
  "c8": "^11.0.0",
44
44
  "eslint": "^10.0.2",
45
45
  "globals": "^17.3.0",
@@ -76,12 +76,21 @@
76
76
  "files": [
77
77
  "bin/",
78
78
  "lib/",
79
+ "skills/",
79
80
  ".claude/commands/",
80
81
  ".claude/rules/",
81
82
  ".claude/scripts/",
82
- ".forge/hooks/",
83
+ ".claude/skills/",
84
+ ".cursor/",
85
+ ".cline/",
86
+ ".roo/",
87
+ ".codex/",
88
+ ".kilocode/",
89
+ ".opencode/",
90
+ ".github/prompts/",
83
91
  ".github/PLUGIN_TEMPLATE.json",
84
- "docs/",
92
+ ".forge/hooks/",
93
+ "docs/*.md",
85
94
  "install.sh",
86
95
  "lefthook.yml",
87
96
  "AGENTS.md",
@@ -89,10 +98,12 @@
89
98
  ".mcp.json.example"
90
99
  ],
91
100
  "dependencies": {
101
+ "@babel/parser": "^7.29.2",
92
102
  "fastest-levenshtein": "^1.0.16"
93
103
  },
94
104
  "overrides": {
95
105
  "eslint": "^10.0.2",
106
+ "flatted": "3.4.2",
96
107
  "minimatch": "10.2.4"
97
108
  },
98
109
  "c8": {
@@ -0,0 +1,108 @@
1
+ ---
2
+ name: parallel-deep-research
3
+ description: >
4
+ Produces comprehensive research reports that go far beyond what built-in web
5
+ search can achieve. Sends research tasks to Parallel AI's pro/ultra processors
6
+ which spend 3-25 minutes autonomously crawling, reading, and synthesizing dozens
7
+ of sources — returning structured reports with citations. Built-in WebSearch
8
+ can only run a few queries; this skill runs an entire research pipeline externally.
9
+ No binary install — requires PARALLEL_API_KEY in .env.local. ALWAYS use this
10
+ skill instead of doing multiple WebSearch calls when the user needs a comprehensive
11
+ report, market analysis, competitive landscape, industry deep-dive, strategic
12
+ recommendations, or multi-source synthesis. This is the RIGHT tool for any
13
+ research task that would require more than 3-4 web searches to answer properly.
14
+ Also trigger during /plan Phase 2 research and /research workflows.
15
+ compatibility: Requires PARALLEL_API_KEY in .env.local. Uses curl. Takes 3-25 minutes.
16
+ metadata:
17
+ author: harshanandak
18
+ version: "1.0.0"
19
+ ---
20
+
21
+ # Parallel Deep Research
22
+
23
+ Comprehensive research reports with multi-source synthesis. Use `pro` (3-9 min, $0.10) or `ultra` (5-25 min, $0.30) for deep analysis.
24
+
25
+ > **CLI alternative (recommended)**: Install `parallel-cli` for official skill:
26
+ > `npx skills add parallel-web/parallel-agent-skills --skill parallel-deep-research`
27
+
28
+ ## Setup
29
+
30
+ ```bash
31
+ API_KEY=$(grep "^PARALLEL_API_KEY=" .env.local | cut -d= -f2)
32
+ ```
33
+
34
+ ## Create Research Task
35
+
36
+ ```bash
37
+ curl -s -X POST "https://api.parallel.ai/v1/tasks/runs" \
38
+ -H "x-api-key: $API_KEY" \
39
+ -H "Content-Type: application/json" \
40
+ -d '{
41
+ "input": "Analyze the AI chatbot market. Include: size, growth, key players, trends, competitive threats",
42
+ "processor": "pro"
43
+ }'
44
+ ```
45
+
46
+ Response: `{"run_id": "trun_abc123...", "status": "queued"}`
47
+
48
+ ## Get Result (polling)
49
+
50
+ The result endpoint returns both status and output in one call. Poll until `status` is `completed`.
51
+
52
+ ```bash
53
+ RUN_ID="trun_abc123..."
54
+ MAX_POLLS=180 # 30 min max (180 × 10s)
55
+
56
+ for i in $(seq 1 $MAX_POLLS); do
57
+ RESULT=$(curl -s "https://api.parallel.ai/v1/tasks/runs/$RUN_ID/result" \
58
+ -H "x-api-key: $API_KEY")
59
+
60
+ STATUS=$(echo "$RESULT" | grep -o '"status":"[^"]*"' | head -1 | cut -d'"' -f4)
61
+
62
+ if [ "$STATUS" = "completed" ]; then
63
+ echo "$RESULT"
64
+ break
65
+ elif [ "$STATUS" = "failed" ]; then
66
+ echo "Task failed: $RESULT"
67
+ break
68
+ fi
69
+
70
+ echo "Poll $i/$MAX_POLLS — Status: $STATUS"
71
+ sleep 10
72
+ done
73
+
74
+ if [ "$i" = "$MAX_POLLS" ] && [ "$STATUS" != "completed" ] && [ "$STATUS" != "failed" ]; then
75
+ echo "Timeout: task did not complete within 30 minutes"
76
+ fi
77
+ ```
78
+
79
+ ## Processors
80
+
81
+ | Processor | Speed | Cost | Use For |
82
+ |-----------|-------|------|---------|
83
+ | pro | 3-9 min | $0.10/task | Market analysis, strategic reports |
84
+ | ultra | 5-25 min | $0.30/task | Comprehensive deep research |
85
+
86
+ ## Example: Market Analysis
87
+
88
+ ```json
89
+ {
90
+ "input": "Analyze the AI chip market in 2024. Include market size, growth rate, key players (NVIDIA, AMD, Intel), emerging competitors, and 2025 outlook.",
91
+ "processor": "pro"
92
+ }
93
+ ```
94
+
95
+ Result: Markdown report with citations.
96
+
97
+ ## When to Use
98
+
99
+ - Market research and competitive analysis
100
+ - Strategic reports requiring multiple sources
101
+ - Research that needs synthesis across many documents
102
+ - Any task that would need more than 3-4 web searches to answer properly
103
+
104
+ For quick facts or single-source lookups, use built-in WebSearch instead.
105
+
106
+ ## Timeout
107
+
108
+ Set polling timeout to 1800s (30 min) for ultra tasks. Pro tasks typically complete in 3-9 min.
@@ -0,0 +1,27 @@
1
+ # Eval Sets
2
+
3
+ These eval files use a flat JSON array format targeting `scripts/eval_win.py`:
4
+
5
+ ```json
6
+ [{"query": "...", "should_trigger": true}]
7
+ ```
8
+
9
+ This is **not** compatible with the skill-creator plugin's `run_loop.py` which expects:
10
+
11
+ ```json
12
+ {"skill_name": "...", "evals": [{"id": "...", "prompt": "...", "should_trigger": true}]}
13
+ ```
14
+
15
+ To convert for `run_loop.py`:
16
+
17
+ ```bash
18
+ python3 -c "
19
+ import json, pathlib, uuid
20
+ data = json.loads(pathlib.Path('evals.json').read_text())
21
+ out = {'skill_name': 'SKILL-NAME-HERE', 'evals': [
22
+ {'id': str(uuid.uuid4()), 'prompt': item['query'], 'should_trigger': item['should_trigger']}
23
+ for item in data
24
+ ]}
25
+ print(json.dumps(out, indent=2))
26
+ " > evals_skill_creator.json
27
+ ```
@@ -0,0 +1,62 @@
1
+ [
2
+ {
3
+ "query": "I need a comprehensive market analysis of the developer tools space — cover the top 20 players, their funding, market positioning, and where the industry is heading over the next 3-5 years. Include data from Gartner, Forrester, and any recent VC investment reports",
4
+ "should_trigger": true
5
+ },
6
+ {
7
+ "query": "Write a deep research report on the state of WebAssembly adoption in production — synthesize case studies from companies using WASM, performance benchmarks vs native code, ecosystem maturity analysis, and strategic recommendations for when to adopt it",
8
+ "should_trigger": true
9
+ },
10
+ {
11
+ "query": "Our CTO wants a competitive landscape analysis comparing Convex, Supabase, Firebase, and PlanetScale for our backend rewrite. Need comprehensive feature comparison, pricing analysis at our scale (50K DAU), community health metrics, and risk assessment for each",
12
+ "should_trigger": true
13
+ },
14
+ {
15
+ "query": "Create a strategic report on the AI code generation market — analyze GitHub Copilot, Cursor, Claude Code, and emerging competitors. Cover adoption rates, developer satisfaction surveys, enterprise pricing trends, and predictions for 2027",
16
+ "should_trigger": true
17
+ },
18
+ {
19
+ "query": "I'm doing /plan Phase 2 research — produce a comprehensive analysis of event-driven architecture patterns in microservices, covering Kafka vs RabbitMQ vs NATS, with production case studies, failure mode analysis, and recommendations for our 100K events/sec throughput requirement",
20
+ "should_trigger": true
21
+ },
22
+ {
23
+ "query": "Write an industry deep-dive into the observability market — compare Datadog, Grafana Cloud, and New Relic across features, pricing, scalability, and OpenTelemetry support. Include customer migration stories and TCO analysis for a 500-node cluster",
24
+ "should_trigger": true
25
+ },
26
+ {
27
+ "query": "Research and synthesize the current state of edge computing for real-time AI inference — cover hardware options, cloud provider edge offerings, latency benchmarks, and case studies from autonomous vehicles and IoT deployments",
28
+ "should_trigger": true
29
+ },
30
+ {
31
+ "query": "Quick search: what's the current price of Bitcoin and what were Anthropic's latest announcements?",
32
+ "should_trigger": false
33
+ },
34
+ {
35
+ "query": "Find the official migration guide URL for ESLint's new flat config format",
36
+ "should_trigger": false
37
+ },
38
+ {
39
+ "query": "Search for recent blog posts about Bun 2.0 features and release date",
40
+ "should_trigger": false
41
+ },
42
+ {
43
+ "query": "Go to https://stripe.com/docs/api and extract the authentication section with all the code examples",
44
+ "should_trigger": false
45
+ },
46
+ {
47
+ "query": "Scrape https://openai.com/pricing and extract the per-token costs for each model tier",
48
+ "should_trigger": false
49
+ },
50
+ {
51
+ "query": "Build a structured company profile for Databricks — return JSON with founding year, funding rounds, valuation, employee count, and tech stack",
52
+ "should_trigger": false
53
+ },
54
+ {
55
+ "query": "Fix the TypeScript compilation error in src/services/auth.ts — it's complaining about missing type for the session token",
56
+ "should_trigger": false
57
+ },
58
+ {
59
+ "query": "Add unit tests for the rate limiter middleware in src/middleware/rateLimit.ts",
60
+ "should_trigger": false
61
+ }
62
+ ]
@@ -0,0 +1,171 @@
1
+ ---
2
+ name: sonarcloud-analysis
3
+ description: >
4
+ Pull issues, metrics, quality gates, and analysis data from SonarCloud. ALWAYS
5
+ use this skill when the user mentions SonarCloud, asks about code quality metrics,
6
+ wants to check PR quality gates, or needs to review security vulnerabilities and
7
+ technical debt from static analysis. Also trigger during /review workflow when
8
+ SonarCloud issues need addressing. Trigger on phrases like "SonarCloud",
9
+ "quality gate", "code quality metrics", "technical debt", "coverage report",
10
+ "static analysis issues", "security vulnerabilities from scan".
11
+ category: Code Quality
12
+ tags: [sonarcloud, code-quality, issues, metrics, security]
13
+ context: fork
14
+ tools: [Bash, WebFetch, Read, Grep, Glob]
15
+ model: sonnet
16
+ ---
17
+
18
+ <role>
19
+ You are a SonarCloud code quality analyst with expertise in static analysis, security vulnerability assessment, and technical debt management. You operate with your own isolated context to perform comprehensive code quality analysis without polluting the main conversation.
20
+ </role>
21
+
22
+ <capabilities>
23
+ - Query SonarCloud API for issues, metrics, and quality gates
24
+ - Analyze code quality across branches and pull requests
25
+ - Identify security vulnerabilities and hotspots
26
+ - Track coverage, duplication, and technical debt
27
+ - Generate health reports and trend analysis
28
+ - Correlate SonarCloud findings with local codebase
29
+ </capabilities>
30
+
31
+ <constraints>
32
+ - Always use environment variables: $SONARCLOUD_TOKEN, $SONARCLOUD_ORG, $SONARCLOUD_PROJECT
33
+ - Load credentials from .env.local if environment variables are not set
34
+ - Never expose tokens in output
35
+ - Validate API responses before processing
36
+ - Handle pagination for large result sets
37
+ </constraints>
38
+
39
+ <workflow>
40
+ 1. Load environment variables (check .env.local if needed: `source .env.local 2>/dev/null || true`)
41
+ 2. Verify credentials are available
42
+ 3. Determine the analysis scope (project, branch, PR)
43
+ 4. Query relevant endpoints
44
+ 5. Process and correlate results
45
+ 6. Return actionable summary to main context
46
+ </workflow>
47
+
48
+ # SonarCloud Integration
49
+
50
+ **Base**: `https://sonarcloud.io/api` | **Auth**: `Bearer $SONARCLOUD_TOKEN`
51
+
52
+ ## Configuration
53
+
54
+ **Environment Variables**: Required for authentication
55
+ - `SONARCLOUD_TOKEN` - Generate at sonarcloud.io/account/security
56
+ - `SONARCLOUD_ORG` - Your SonarCloud organization key
57
+ - `SONARCLOUD_PROJECT` - Your project key
58
+
59
+ **Option 1: Use .env.local** (Recommended)
60
+ Add to your project's `.env.local`:
61
+ ```bash
62
+ SONARCLOUD_TOKEN=your_token_here
63
+ SONARCLOUD_ORG=your-org
64
+ SONARCLOUD_PROJECT=your-project
65
+ ```
66
+
67
+ Before querying, load environment variables:
68
+ ```bash
69
+ # Load .env.local into current environment
70
+ export $(grep -v '^#' .env.local | xargs)
71
+ ```
72
+
73
+ **Option 2: Export directly**
74
+ ```bash
75
+ export SONARCLOUD_TOKEN="your_token"
76
+ export SONARCLOUD_ORG="your-org"
77
+ export SONARCLOUD_PROJECT="your-project"
78
+
79
+ # Common queries
80
+ curl -H "Authorization: Bearer $TOKEN" \
81
+ "https://sonarcloud.io/api/issues/search?organization=$ORG&componentKeys=$PROJECT&resolved=false"
82
+ curl -H "Authorization: Bearer $TOKEN" \
83
+ "https://sonarcloud.io/api/measures/component?component=$PROJECT&metricKeys=bugs,coverage"
84
+ curl -H "Authorization: Bearer $TOKEN" \
85
+ "https://sonarcloud.io/api/qualitygates/project_status?projectKey=$PROJECT"
86
+ ```
87
+
88
+ ## Endpoints
89
+
90
+ | Endpoint | Purpose | Key Params |
91
+ | ------------------------------- | ------------------------ | ---------------------------------------- |
92
+ | `/api/issues/search` | Bugs, vulnerabilities | `types`, `severities`, `branch`, `pullRequest` |
93
+ | `/api/measures/component` | Coverage, complexity | `metricKeys`, `branch`, `pullRequest` |
94
+ | `/api/qualitygates/project_status` | Pass/fail status | `projectKey`, `branch`, `pullRequest` |
95
+ | `/api/hotspots/search` | Security hotspots | `projectKey`, `status` |
96
+ | `/api/projects/search` | List projects | `organization`, `q` |
97
+ | `/api/project_analyses/search` | Analysis history | `project`, `from`, `to` |
98
+ | `/api/measures/search_history` | Metrics over time | `component`, `metrics`, `from` |
99
+ | `/api/components/tree` | Files with metrics | `qualifiers=FIL`, `metricKeys` |
100
+ | `/api/duplications/show` | Duplicate code blocks | `key` (file key), `branch` |
101
+ | `/api/sources/raw` | Raw source code | `key` (file key), `branch` |
102
+ | `/api/sources/scm` | SCM blame info | `key`, `from`, `to` |
103
+ | `/api/ce/activity` | Background tasks | `component`, `status`, `type` |
104
+ | `/api/qualityprofiles/search` | Quality profiles | `language`, `project` |
105
+ | `/api/languages/list` | Supported languages | - |
106
+ | `/api/project_branches/list` | Project branches | `project` |
107
+ | `/api/project_badges/measure` | SVG badge | `project`, `metric`, `branch` |
108
+ | `/api/rules/search` | Coding rules | `languages`, `severities`, `types` |
109
+
110
+ ## Common Filters
111
+
112
+ **Issues**: `types=BUG,VULNERABILITY,CODE_SMELL` | `severities=BLOCKER,CRITICAL,MAJOR` | `resolved=false` | `inNewCodePeriod=true`
113
+
114
+ **Metrics**: `bugs,vulnerabilities,code_smells,coverage,duplicated_lines_density,sqale_rating,reliability_rating,security_rating`
115
+
116
+ **New Code**: `new_bugs,new_vulnerabilities,new_coverage,new_duplicated_lines_density`
117
+
118
+ ## Workflows
119
+
120
+ ### Health Check
121
+
122
+ ```bash
123
+ curl ... "/api/qualitygates/project_status?projectKey=$PROJECT"
124
+ curl ... "/api/measures/component?component=$PROJECT&metricKeys=bugs,vulnerabilities,coverage,sqale_rating"
125
+ curl ... "/api/issues/search?organization=$ORG&componentKeys=$PROJECT&resolved=false&facets=severities,types&ps=1"
126
+ ```
127
+
128
+ ### PR Analysis
129
+
130
+ ```bash
131
+ curl ... "/api/qualitygates/project_status?projectKey=$PROJECT&pullRequest=123"
132
+ curl ... "/api/issues/search?organization=$ORG&componentKeys=$PROJECT&pullRequest=123&resolved=false"
133
+ curl ... "/api/measures/component?component=$PROJECT&pullRequest=123&metricKeys=new_bugs,new_coverage"
134
+ ```
135
+
136
+ ### Security Audit
137
+
138
+ ```bash
139
+ curl ... "/api/issues/search?organization=$ORG&componentKeys=$PROJECT&types=VULNERABILITY&resolved=false"
140
+ curl ... "/api/hotspots/search?projectKey=$PROJECT&status=TO_REVIEW"
141
+ ```
142
+
143
+ ### Duplication Analysis
144
+
145
+ ```bash
146
+ # Get duplication metrics
147
+ curl ... "/api/measures/component?component=$PROJECT&metricKeys=duplicated_lines,duplicated_lines_density,duplicated_blocks,duplicated_files"
148
+
149
+ # Get files with most duplication
150
+ curl ... "/api/components/tree?component=$PROJECT&qualifiers=FIL&metricKeys=duplicated_lines_density&s=metric&metricSort=duplicated_lines_density&asc=false&ps=20"
151
+
152
+ # Get duplicate blocks for a specific file (requires file key from above)
153
+ curl ... "/api/duplications/show?key=my-project:src/utils/helpers.ts"
154
+ ```
155
+
156
+ ## Response Processing
157
+
158
+ ```bash
159
+ # Count by severity
160
+ curl ... | jq '.issues | group_by(.severity) | map({severity: .[0].severity, count: length})'
161
+
162
+ # Failed quality gate conditions
163
+ curl ... | jq '.projectStatus.conditions | map(select(.status == "ERROR"))'
164
+
165
+ # Metrics as key-value
166
+ curl ... | jq '.component.measures | map({(.metric): .value}) | add'
167
+ ```
168
+
169
+ ## Detailed Reference
170
+
171
+ For complete API parameters and response schemas, see [references/api-reference.md](references/api-reference.md).
@@ -0,0 +1,27 @@
1
+ # Eval Sets
2
+
3
+ These eval files use a flat JSON array format targeting `scripts/eval_win.py`:
4
+
5
+ ```json
6
+ [{"query": "...", "should_trigger": true}]
7
+ ```
8
+
9
+ This is **not** compatible with the skill-creator plugin's `run_loop.py` which expects:
10
+
11
+ ```json
12
+ {"skill_name": "...", "evals": [{"id": "...", "prompt": "...", "should_trigger": true}]}
13
+ ```
14
+
15
+ To convert for `run_loop.py`:
16
+
17
+ ```bash
18
+ python3 -c "
19
+ import json, pathlib, uuid
20
+ data = json.loads(pathlib.Path('evals.json').read_text())
21
+ out = {'skill_name': 'SKILL-NAME-HERE', 'evals': [
22
+ {'id': str(uuid.uuid4()), 'prompt': item['query'], 'should_trigger': item['should_trigger']}
23
+ for item in data
24
+ ]}
25
+ print(json.dumps(out, indent=2))
26
+ " > evals_skill_creator.json
27
+ ```
@@ -0,0 +1,50 @@
1
+ [
2
+ {
3
+ "query": "Check the SonarCloud quality gate status for our latest PR — I want to see if there are any blockers before we can merge, especially around security vulnerabilities and code coverage",
4
+ "should_trigger": true
5
+ },
6
+ {
7
+ "query": "Pull the SonarCloud analysis results for our project — show me all the critical and major security vulnerabilities found in the last scan, with file locations and remediation guidance",
8
+ "should_trigger": true
9
+ },
10
+ {
11
+ "query": "We're in /review and SonarCloud flagged some issues — get the full list of code smells, bugs, and vulnerabilities from the latest analysis so I can address them before the quality gate passes",
12
+ "should_trigger": true
13
+ },
14
+ {
15
+ "query": "What's our current technical debt ratio in SonarCloud? Show me the metrics dashboard — maintainability rating, reliability rating, security rating, and coverage percentage",
16
+ "should_trigger": true
17
+ },
18
+ {
19
+ "query": "The SonarCloud quality gate is failing on our PR — pull the specific issues that are blocking it and show me what needs to be fixed, sorted by severity",
20
+ "should_trigger": true
21
+ },
22
+ {
23
+ "query": "Get the SonarCloud code coverage report for our project — I want to see which modules have low coverage and identify the files that need more tests before our next release",
24
+ "should_trigger": true
25
+ },
26
+ {
27
+ "query": "Implement a new REST API endpoint for user profile management with CRUD operations, input validation, and proper error handling",
28
+ "should_trigger": false
29
+ },
30
+ {
31
+ "query": "Search for best practices around implementing OAuth2 PKCE flow in a Node.js application",
32
+ "should_trigger": false
33
+ },
34
+ {
35
+ "query": "Write a comprehensive market analysis of the DevSecOps tools landscape covering SAST, DAST, and SCA vendors",
36
+ "should_trigger": false
37
+ },
38
+ {
39
+ "query": "Scrape https://docs.sonarcloud.io and extract the full list of supported languages and analysis rules",
40
+ "should_trigger": false
41
+ },
42
+ {
43
+ "query": "Build a structured company profile for SonarSource — return JSON with founding year, funding, products, and competitive positioning",
44
+ "should_trigger": false
45
+ },
46
+ {
47
+ "query": "Add proper citations to docs/research/security-audit-findings.md following our project's citation standards",
48
+ "should_trigger": false
49
+ }
50
+ ]