@c0x12c/ai-toolkit 1.15.0

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 (255) hide show
  1. package/.claude-plugin/marketplace.json +16 -0
  2. package/.claude-plugin/plugin.json +12 -0
  3. package/README.md +439 -0
  4. package/VERSION +1 -0
  5. package/agents/design-critic.md +127 -0
  6. package/agents/idea-killer.md +72 -0
  7. package/agents/infrastructure-expert.md +49 -0
  8. package/agents/micronaut-backend-expert.md +45 -0
  9. package/agents/phase-reviewer.md +150 -0
  10. package/agents/research-planner.md +70 -0
  11. package/agents/solution-architect-cto.md +49 -0
  12. package/agents/sre-architect.md +49 -0
  13. package/agents/team-coordinator.md +111 -0
  14. package/bin/cli.js +780 -0
  15. package/claude-md/00-header.md +39 -0
  16. package/claude-md/01-core.md +105 -0
  17. package/claude-md/05-database.md +20 -0
  18. package/claude-md/11-backend-micronaut.md +19 -0
  19. package/claude-md/20-frontend-react.md +44 -0
  20. package/claude-md/25-ux-design.md +56 -0
  21. package/claude-md/30-infrastructure.md +24 -0
  22. package/claude-md/30-project-mgmt.md +119 -0
  23. package/claude-md/40-product.md +39 -0
  24. package/claude-md/50-ops.md +34 -0
  25. package/claude-md/60-research.md +27 -0
  26. package/claude-md/90-footer.md +21 -0
  27. package/commands/spartan/brainstorm.md +134 -0
  28. package/commands/spartan/brownfield.md +157 -0
  29. package/commands/spartan/build.md +435 -0
  30. package/commands/spartan/careful.md +94 -0
  31. package/commands/spartan/commit-message.md +112 -0
  32. package/commands/spartan/content.md +17 -0
  33. package/commands/spartan/context-save.md +161 -0
  34. package/commands/spartan/contribute.md +140 -0
  35. package/commands/spartan/daily.md +42 -0
  36. package/commands/spartan/debug.md +308 -0
  37. package/commands/spartan/deep-dive.md +55 -0
  38. package/commands/spartan/deploy.md +207 -0
  39. package/commands/spartan/e2e.md +264 -0
  40. package/commands/spartan/env-setup.md +166 -0
  41. package/commands/spartan/epic.md +199 -0
  42. package/commands/spartan/fe-review.md +181 -0
  43. package/commands/spartan/figma-to-code.md +260 -0
  44. package/commands/spartan/forensics.md +46 -0
  45. package/commands/spartan/freeze.md +84 -0
  46. package/commands/spartan/fundraise.md +53 -0
  47. package/commands/spartan/gate-review.md +229 -0
  48. package/commands/spartan/gsd-upgrade.md +376 -0
  49. package/commands/spartan/guard.md +42 -0
  50. package/commands/spartan/init-project.md +178 -0
  51. package/commands/spartan/init-rules.md +298 -0
  52. package/commands/spartan/interview.md +154 -0
  53. package/commands/spartan/kickoff.md +73 -0
  54. package/commands/spartan/kotlin-service.md +109 -0
  55. package/commands/spartan/lean-canvas.md +222 -0
  56. package/commands/spartan/lint-rules.md +122 -0
  57. package/commands/spartan/map-codebase.md +124 -0
  58. package/commands/spartan/migration.md +82 -0
  59. package/commands/spartan/next-app.md +317 -0
  60. package/commands/spartan/next-feature.md +212 -0
  61. package/commands/spartan/onboard.md +326 -0
  62. package/commands/spartan/outreach.md +16 -0
  63. package/commands/spartan/phase.md +142 -0
  64. package/commands/spartan/pitch.md +18 -0
  65. package/commands/spartan/plan.md +210 -0
  66. package/commands/spartan/pr-ready.md +202 -0
  67. package/commands/spartan/project.md +106 -0
  68. package/commands/spartan/qa.md +222 -0
  69. package/commands/spartan/research.md +254 -0
  70. package/commands/spartan/review.md +132 -0
  71. package/commands/spartan/scan-rules.md +173 -0
  72. package/commands/spartan/sessions.md +143 -0
  73. package/commands/spartan/spec.md +131 -0
  74. package/commands/spartan/startup.md +257 -0
  75. package/commands/spartan/team.md +570 -0
  76. package/commands/spartan/teardown.md +161 -0
  77. package/commands/spartan/testcontainer.md +97 -0
  78. package/commands/spartan/tf-cost.md +123 -0
  79. package/commands/spartan/tf-deploy.md +116 -0
  80. package/commands/spartan/tf-drift.md +100 -0
  81. package/commands/spartan/tf-import.md +107 -0
  82. package/commands/spartan/tf-module.md +121 -0
  83. package/commands/spartan/tf-plan.md +100 -0
  84. package/commands/spartan/tf-review.md +106 -0
  85. package/commands/spartan/tf-scaffold.md +109 -0
  86. package/commands/spartan/tf-security.md +147 -0
  87. package/commands/spartan/think.md +221 -0
  88. package/commands/spartan/unfreeze.md +13 -0
  89. package/commands/spartan/update.md +134 -0
  90. package/commands/spartan/ux.md +1233 -0
  91. package/commands/spartan/validate.md +193 -0
  92. package/commands/spartan/web-to-prd.md +706 -0
  93. package/commands/spartan/workstreams.md +109 -0
  94. package/commands/spartan/write.md +16 -0
  95. package/commands/spartan.md +386 -0
  96. package/frameworks/00-framework-comparison-guide.md +317 -0
  97. package/frameworks/01-lean-canvas.md +196 -0
  98. package/frameworks/02-design-sprint.md +304 -0
  99. package/frameworks/03-foundation-sprint.md +337 -0
  100. package/frameworks/04-business-model-canvas.md +391 -0
  101. package/frameworks/05-customer-development.md +426 -0
  102. package/frameworks/06-jobs-to-be-done.md +358 -0
  103. package/frameworks/07-mom-test.md +392 -0
  104. package/frameworks/08-value-proposition-canvas.md +488 -0
  105. package/frameworks/09-javelin-board.md +428 -0
  106. package/frameworks/10-build-measure-learn.md +467 -0
  107. package/frameworks/11-mvp-approaches.md +533 -0
  108. package/frameworks/think-before-build.md +593 -0
  109. package/lib/assembler.js +197 -0
  110. package/lib/assembler.test.js +159 -0
  111. package/lib/detector.js +166 -0
  112. package/lib/detector.test.js +221 -0
  113. package/lib/packs.js +16 -0
  114. package/lib/resolver.js +272 -0
  115. package/lib/resolver.test.js +298 -0
  116. package/lib/worktree.sh +104 -0
  117. package/package.json +50 -0
  118. package/packs/backend-micronaut.yaml +35 -0
  119. package/packs/backend-nodejs.yaml +15 -0
  120. package/packs/backend-python.yaml +15 -0
  121. package/packs/core.yaml +37 -0
  122. package/packs/database.yaml +21 -0
  123. package/packs/frontend-react.yaml +24 -0
  124. package/packs/infrastructure.yaml +40 -0
  125. package/packs/ops.yaml +16 -0
  126. package/packs/packs.compiled.json +371 -0
  127. package/packs/product.yaml +22 -0
  128. package/packs/project-mgmt.yaml +24 -0
  129. package/packs/research.yaml +39 -0
  130. package/packs/shared-backend.yaml +14 -0
  131. package/packs/ux-design.yaml +21 -0
  132. package/rules/backend-micronaut/API_DESIGN.md +313 -0
  133. package/rules/backend-micronaut/BATCH_PROCESSING.md +92 -0
  134. package/rules/backend-micronaut/CONTROLLERS.md +388 -0
  135. package/rules/backend-micronaut/KOTLIN.md +414 -0
  136. package/rules/backend-micronaut/RETROFIT_PLACEMENT.md +290 -0
  137. package/rules/backend-micronaut/SERVICES_AND_BEANS.md +325 -0
  138. package/rules/core/NAMING_CONVENTIONS.md +208 -0
  139. package/rules/core/SKILL_AUTHORING.md +174 -0
  140. package/rules/core/TIMEZONE.md +316 -0
  141. package/rules/database/ORM_AND_REPO.md +289 -0
  142. package/rules/database/SCHEMA.md +146 -0
  143. package/rules/database/TRANSACTIONS.md +311 -0
  144. package/rules/frontend-react/FRONTEND.md +344 -0
  145. package/rules/infrastructure/MODULES.md +260 -0
  146. package/rules/infrastructure/NAMING.md +196 -0
  147. package/rules/infrastructure/PROVIDERS.md +309 -0
  148. package/rules/infrastructure/SECURITY.md +310 -0
  149. package/rules/infrastructure/STATE_AND_BACKEND.md +237 -0
  150. package/rules/infrastructure/STRUCTURE.md +234 -0
  151. package/rules/infrastructure/VARIABLES.md +285 -0
  152. package/rules/shared-backend/ARCHITECTURE.md +46 -0
  153. package/rules/ux-design/DESIGN_PROCESS.md +176 -0
  154. package/skills/api-endpoint-creator/SKILL.md +455 -0
  155. package/skills/api-endpoint-creator/error-handling-guide.md +244 -0
  156. package/skills/api-endpoint-creator/examples.md +522 -0
  157. package/skills/api-endpoint-creator/testing-patterns.md +302 -0
  158. package/skills/article-writing/SKILL.md +109 -0
  159. package/skills/article-writing/examples.md +59 -0
  160. package/skills/backend-api-design/SKILL.md +84 -0
  161. package/skills/backend-api-design/code-patterns.md +138 -0
  162. package/skills/brainstorm/SKILL.md +95 -0
  163. package/skills/browser-qa/SKILL.md +87 -0
  164. package/skills/browser-qa/playwright-snippets.md +110 -0
  165. package/skills/ci-cd-patterns/SKILL.md +108 -0
  166. package/skills/ci-cd-patterns/workflows.md +149 -0
  167. package/skills/competitive-teardown/SKILL.md +93 -0
  168. package/skills/competitive-teardown/example-analysis.md +50 -0
  169. package/skills/content-engine/SKILL.md +131 -0
  170. package/skills/content-engine/examples.md +72 -0
  171. package/skills/database-patterns/SKILL.md +72 -0
  172. package/skills/database-patterns/code-templates.md +114 -0
  173. package/skills/database-table-creator/SKILL.md +141 -0
  174. package/skills/database-table-creator/examples.md +552 -0
  175. package/skills/database-table-creator/kotlin-templates.md +400 -0
  176. package/skills/database-table-creator/migration-template.sql +68 -0
  177. package/skills/database-table-creator/validation-checklist.md +337 -0
  178. package/skills/deep-research/SKILL.md +80 -0
  179. package/skills/design-intelligence/SKILL.md +268 -0
  180. package/skills/design-workflow/SKILL.md +127 -0
  181. package/skills/design-workflow/checklists.md +45 -0
  182. package/skills/idea-validation/SKILL.md +129 -0
  183. package/skills/idea-validation/example-report.md +50 -0
  184. package/skills/investor-materials/SKILL.md +122 -0
  185. package/skills/investor-materials/example-outline.md +70 -0
  186. package/skills/investor-outreach/SKILL.md +112 -0
  187. package/skills/investor-outreach/examples.md +76 -0
  188. package/skills/kotlin-best-practices/SKILL.md +58 -0
  189. package/skills/kotlin-best-practices/code-patterns.md +132 -0
  190. package/skills/market-research/SKILL.md +99 -0
  191. package/skills/security-checklist/SKILL.md +65 -0
  192. package/skills/security-checklist/audit-reference.md +95 -0
  193. package/skills/service-debugging/SKILL.md +116 -0
  194. package/skills/service-debugging/common-issues.md +65 -0
  195. package/skills/startup-pipeline/SKILL.md +152 -0
  196. package/skills/terraform-best-practices/SKILL.md +244 -0
  197. package/skills/terraform-module-creator/SKILL.md +284 -0
  198. package/skills/terraform-review/SKILL.md +222 -0
  199. package/skills/terraform-security-audit/SKILL.md +280 -0
  200. package/skills/terraform-service-scaffold/SKILL.md +574 -0
  201. package/skills/testing-strategies/SKILL.md +116 -0
  202. package/skills/testing-strategies/examples.md +103 -0
  203. package/skills/testing-strategies/integration-test-setup.md +71 -0
  204. package/skills/ui-ux-pro-max/SKILL.md +238 -0
  205. package/skills/ui-ux-pro-max/data/charts.csv +26 -0
  206. package/skills/ui-ux-pro-max/data/colors.csv +97 -0
  207. package/skills/ui-ux-pro-max/data/icons.csv +101 -0
  208. package/skills/ui-ux-pro-max/data/landing.csv +31 -0
  209. package/skills/ui-ux-pro-max/data/products.csv +97 -0
  210. package/skills/ui-ux-pro-max/data/react-performance.csv +45 -0
  211. package/skills/ui-ux-pro-max/data/stacks/astro.csv +54 -0
  212. package/skills/ui-ux-pro-max/data/stacks/flutter.csv +53 -0
  213. package/skills/ui-ux-pro-max/data/stacks/html-tailwind.csv +56 -0
  214. package/skills/ui-ux-pro-max/data/stacks/jetpack-compose.csv +53 -0
  215. package/skills/ui-ux-pro-max/data/stacks/nextjs.csv +53 -0
  216. package/skills/ui-ux-pro-max/data/stacks/nuxt-ui.csv +51 -0
  217. package/skills/ui-ux-pro-max/data/stacks/nuxtjs.csv +59 -0
  218. package/skills/ui-ux-pro-max/data/stacks/react-native.csv +52 -0
  219. package/skills/ui-ux-pro-max/data/stacks/react.csv +54 -0
  220. package/skills/ui-ux-pro-max/data/stacks/shadcn.csv +61 -0
  221. package/skills/ui-ux-pro-max/data/stacks/svelte.csv +54 -0
  222. package/skills/ui-ux-pro-max/data/stacks/swiftui.csv +51 -0
  223. package/skills/ui-ux-pro-max/data/stacks/vue.csv +50 -0
  224. package/skills/ui-ux-pro-max/data/styles.csv +68 -0
  225. package/skills/ui-ux-pro-max/data/typography.csv +58 -0
  226. package/skills/ui-ux-pro-max/data/ui-reasoning.csv +101 -0
  227. package/skills/ui-ux-pro-max/data/ux-guidelines.csv +100 -0
  228. package/skills/ui-ux-pro-max/data/web-interface.csv +31 -0
  229. package/skills/ui-ux-pro-max/python-setup.md +146 -0
  230. package/skills/ui-ux-pro-max/scripts/core.py +253 -0
  231. package/skills/ui-ux-pro-max/scripts/design_system.py +1067 -0
  232. package/skills/ui-ux-pro-max/scripts/search.py +114 -0
  233. package/skills/web-to-prd/SKILL.md +478 -0
  234. package/templates/build-config.yaml +44 -0
  235. package/templates/commands-config.yaml +55 -0
  236. package/templates/competitor-analysis.md +60 -0
  237. package/templates/content/AGENT_TEMPLATE.md +47 -0
  238. package/templates/content/COMMAND_TEMPLATE.md +27 -0
  239. package/templates/content/RULE_TEMPLATE.md +40 -0
  240. package/templates/content/SKILL_TEMPLATE.md +41 -0
  241. package/templates/design-config.md +105 -0
  242. package/templates/design-doc.md +207 -0
  243. package/templates/epic.md +100 -0
  244. package/templates/feature-spec.md +181 -0
  245. package/templates/idea-canvas.md +47 -0
  246. package/templates/implementation-plan.md +159 -0
  247. package/templates/prd-template.md +86 -0
  248. package/templates/preamble.md +89 -0
  249. package/templates/project-readme.md +35 -0
  250. package/templates/quality-gates.md +230 -0
  251. package/templates/spartan-config.yaml +164 -0
  252. package/templates/user-interview.md +69 -0
  253. package/templates/validation-checklist.md +108 -0
  254. package/templates/workflow-backend-micronaut.md +409 -0
  255. package/templates/workflow-frontend-react.md +233 -0
@@ -0,0 +1,95 @@
1
+ ---
2
+ name: brainstorm
3
+ description: Run a structured brainstorm session for startup ideas. Takes a theme or problem and generates ideas with quick gut-checks. Use when the user wants to explore a space or generate new ideas.
4
+ allowed_tools:
5
+ - WebSearch
6
+ ---
7
+
8
+ # Brainstorm
9
+
10
+ Turn a vague direction into a list of concrete ideas worth testing.
11
+
12
+ ## When to Use
13
+
14
+ - User has a theme, problem, or space they want to explore
15
+ - Generating new project ideas
16
+ - Expanding on a half-baked idea
17
+ - Looking for adjacent opportunities
18
+
19
+ ## Process
20
+
21
+ ### 1. Set the Frame
22
+ Ask or confirm:
23
+ - What space? (health, finance, dev tools, etc.)
24
+ - Who's the user? (founders, students, parents, etc.)
25
+ - Any limits? (no hardware, must be B2B, etc.)
26
+ - What's the goal? (side project, VC-backed, bootstrap)
27
+
28
+ ### 2. Generate Ideas (Go Wide)
29
+ Produce 8-15 ideas. For each:
30
+ - **Name** - Working title
31
+ - **One-liner** - What it does in 10 words
32
+ - **Who** - Target user
33
+ - **Problem** - What pain it fixes
34
+ - **Why now** - Why this didn't work before
35
+ - **Quick risk** - Biggest thing that could kill it
36
+
37
+ ### 3. Gut-Check Filter
38
+ Rate each idea on:
39
+ - Demand signal (0-5): Are people searching for this? Paying for alternatives?
40
+ - Buildability (0-5): Can you build an MVP in 2 weeks?
41
+ - Moat potential (0-5): Can you defend this?
42
+
43
+ ### 4. Pick Top 3
44
+ Pick the 3 best ideas. For each, write:
45
+ - The key bet (what must be true for this to work)
46
+ - First validation step (cheapest way to test)
47
+ - Existing competitors (who's doing something close)
48
+
49
+ ## Interaction Style
50
+
51
+ **No BS. Honest feedback only.**
52
+
53
+ This is a two-way talk:
54
+ - I ask you questions → you answer
55
+ - You ask me questions → I think hard, give you options, then answer
56
+
57
+ **When I ask you a question, I always:**
58
+ 1. Think about it first
59
+ 2. Give you 2-3 options with my honest take on each
60
+ 3. Tell you which one I'd pick and why
61
+ 4. Then ask what you think
62
+
63
+ **When you ask me something:**
64
+ - I give you a straight answer
65
+ - I tell you what's wrong with your thinking if I see it
66
+ - I push back if your idea is weak
67
+
68
+ **Never:**
69
+ - Ask a question without giving options
70
+ - Sugarcoat bad ideas
71
+ - Say "it depends" without picking a side
72
+ - Give soft answers to hard questions
73
+ - Skip the tough feedback to be nice
74
+
75
+ ## Rules
76
+
77
+ - No idea is too dumb during generation
78
+ - But be brutal during filtering
79
+ - "Interesting" is not enough. Need a real pain point.
80
+ - If the user already has a direction, skip to expanding that
81
+ - Don't fall in love with clever solutions to fake problems
82
+
83
+ ## Gotchas
84
+
85
+ - **Don't brainstorm solutions — brainstorm problems.** Founders jump to features too fast. Force "what pain?" before "what product?"
86
+ - **"Interesting" ≠ real demand.** If you can't find anyone searching for it, paying for alternatives, or complaining online, the problem might be fake.
87
+ - **Avoid clever-founder bias.** Technical founders fall in love with clever solutions to problems nobody has. Test the problem first.
88
+ - **Don't skip "Why now?"** Every good idea needs a timing argument. If this could've been built 5 years ago and nobody did, ask why.
89
+ - **Too many ideas = no decision.** If you generate 15 ideas and can't pick 3, the frame is too broad. Narrow the space.
90
+
91
+ ## Output
92
+
93
+ Save to the project's `01-brainstorm/` folder.
94
+
95
+ After delivering, suggest: "Want me to run /validate on any of these?"
@@ -0,0 +1,87 @@
1
+ ---
2
+ name: browser-qa
3
+ description: "Run real browser QA with Playwright. Use when testing a frontend feature, verifying UI before PR, smoke testing after deploy, or investigating reported visual bugs."
4
+ allowed_tools:
5
+ - Read
6
+ - Write
7
+ - Edit
8
+ - Glob
9
+ - Grep
10
+ - Bash
11
+ ---
12
+
13
+ # Browser QA Skill
14
+
15
+ Test web apps with a real browser. Find bugs users would find.
16
+
17
+ ## When to Use
18
+
19
+ - After building a frontend feature
20
+ - Before creating a PR for UI changes
21
+ - When user reports "something looks broken"
22
+ - Smoke testing after deploy
23
+
24
+ ## What This Skill Does
25
+
26
+ 1. Launches Playwright with real Chromium
27
+ 2. Hits every discoverable page in the app
28
+ 3. Checks for console errors, network failures, broken assets
29
+ 4. Tests interactive elements (forms, buttons, links)
30
+ 5. Verifies mobile responsiveness
31
+ 6. Produces a structured QA report
32
+
33
+ ## QA Check Categories
34
+
35
+ ### 1. Page Health
36
+ Every page gets these checks:
37
+ - HTTP status is 2xx
38
+ - No JavaScript console errors
39
+ - No failed network requests (4xx/5xx)
40
+ - No missing images or assets
41
+ - Page loads in under 3 seconds
42
+
43
+ ### 2. Layout & Responsive
44
+ - Desktop (1280px): no horizontal scroll, no overlapping elements
45
+ - Mobile (375px): no horizontal scroll, text is readable, buttons are tappable
46
+ - No content clipped or hidden unintentionally
47
+
48
+ ### 3. Interactive Elements
49
+ - Buttons: click → something happens (no dead buttons)
50
+ - Links: click → navigates to valid page (no 404s)
51
+ - Forms: submit empty → validation shows. Submit valid → success feedback.
52
+ - Dropdowns/modals: open → content visible. Close → content hidden.
53
+
54
+ ### 4. Navigation Flow
55
+ - Every link in nav goes somewhere valid
56
+ - Back button works as expected
57
+ - Breadcrumbs (if present) are accurate
58
+ - Auth redirects work (protected page → login → redirect back)
59
+
60
+ ### 5. Data Display
61
+ - Lists show data (not empty state when data exists)
62
+ - Pagination works (if present)
63
+ - Search/filter updates results
64
+ - Loading states show during data fetch
65
+ - Error states show when API fails
66
+
67
+ ## Playwright Patterns & Report Template
68
+
69
+ > See playwright-snippets.md for ready-to-use Playwright code (page tests, mobile viewport, form testing, screenshot on failure) and the QA report template.
70
+
71
+ ## Gotchas
72
+
73
+ - **`networkidle` waits forever on apps with websockets or polling.** Use `domcontentloaded` or a specific element selector instead if the app has live connections.
74
+ - **`page.click()` on invisible elements passes silently.** Always verify the element is visible before interacting. Use `await expect(locator).toBeVisible()` first.
75
+ - **Mobile viewport test without touch simulation misses real bugs.** Set `hasTouch: true` in the browser context, not just the viewport size.
76
+ - **Console warnings are not console errors.** Don't report React hydration warnings or deprecation notices as bugs. Only `console.error` and failed network requests are bugs.
77
+ - **Screenshots on CI look different than local.** Font rendering, antialiasing, and DPI differ between macOS and Linux. Use visual comparison thresholds, not pixel-perfect matching.
78
+
79
+ ## Rules
80
+
81
+ - **Real browser only.** Playwright + Chromium. No HTTP-only testing.
82
+ - **Headless by default.** Don't open visible windows unless asked.
83
+ - **Test both viewports.** Desktop (1280px) and mobile (375px).
84
+ - **Console errors = bugs.** Always report them.
85
+ - **One-shot mode.** Launch browser, test, close. No daemon.
86
+ - **Screenshot failures.** Take a screenshot when something breaks.
87
+ - **Don't fix without asking.** Report first, then offer fixes.
@@ -0,0 +1,110 @@
1
+ # Playwright QA — Code Snippets
2
+
3
+ > This file is referenced by SKILL.md. Read it when writing QA scripts or generating reports.
4
+
5
+ ## Basic Page Test
6
+
7
+ ```typescript
8
+ import { chromium } from 'playwright'
9
+
10
+ const browser = await chromium.launch({ headless: true })
11
+ const page = await browser.newPage()
12
+
13
+ // Collect errors
14
+ const errors: string[] = []
15
+ page.on('console', msg => {
16
+ if (msg.type() === 'error') errors.push(msg.text())
17
+ })
18
+ page.on('requestfailed', req => {
19
+ errors.push(`NETWORK: ${req.url()} — ${req.failure()?.errorText}`)
20
+ })
21
+
22
+ await page.goto('http://localhost:3000')
23
+ await page.waitForLoadState('networkidle')
24
+
25
+ // Check for errors
26
+ if (errors.length > 0) {
27
+ console.log('BUGS FOUND:', errors)
28
+ }
29
+
30
+ await browser.close()
31
+ ```
32
+
33
+ ## Mobile Viewport Test
34
+
35
+ ```typescript
36
+ const context = await browser.newContext({
37
+ viewport: { width: 375, height: 812 },
38
+ userAgent: 'Mozilla/5.0 (iPhone 14)',
39
+ })
40
+ const page = await context.newPage()
41
+ await page.goto('http://localhost:3000')
42
+
43
+ // Check for horizontal scroll (layout bug)
44
+ const hasHScroll = await page.evaluate(() =>
45
+ document.documentElement.scrollWidth > document.documentElement.clientWidth
46
+ )
47
+ if (hasHScroll) {
48
+ console.log('BUG: Horizontal scroll on mobile')
49
+ }
50
+ ```
51
+
52
+ ## Form Test
53
+
54
+ ```typescript
55
+ // Test empty submit (should show validation)
56
+ await page.click('button[type="submit"]')
57
+ const validationVisible = await page.locator('.error, [role="alert"]').count()
58
+
59
+ // Test valid submit
60
+ await page.fill('input[name="email"]', 'test@example.com')
61
+ await page.fill('input[name="password"]', 'password123')
62
+ await page.click('button[type="submit"]')
63
+ await page.waitForURL('**/dashboard')
64
+ ```
65
+
66
+ ## Screenshot on Failure
67
+
68
+ ```typescript
69
+ try {
70
+ await page.goto(url)
71
+ // ... checks ...
72
+ } catch (e) {
73
+ await page.screenshot({ path: `qa-failure-${Date.now()}.png`, fullPage: true })
74
+ throw e
75
+ }
76
+ ```
77
+
78
+ ## QA Report Template
79
+
80
+ ```markdown
81
+ ## QA Report
82
+ Date: YYYY-MM-DD
83
+ Target: http://localhost:3000
84
+
85
+ ### Summary
86
+ | Metric | Count |
87
+ |--------|-------|
88
+ | Pages tested | N |
89
+ | Bugs found | N |
90
+ | Warnings | N |
91
+ | Passed | N |
92
+
93
+ ### Bugs
94
+ BUG-1: [title]
95
+ - Page: [URL]
96
+ - Steps: [reproduce]
97
+ - Expected: [what should happen]
98
+ - Actual: [what happened]
99
+ - Severity: blocker / major / minor
100
+ - Auto-fixable: yes / no
101
+
102
+ ### Warnings
103
+ WARN-1: [title]
104
+ - Page: [URL]
105
+ - Issue: [description]
106
+
107
+ ### Passed
108
+ - /page-a — all checks clear
109
+ - /page-b — all checks clear
110
+ ```
@@ -0,0 +1,108 @@
1
+ ---
2
+ name: ci-cd-patterns
3
+ description: "CI/CD pipeline patterns for GitHub Actions, PR automation, and deployment workflows. Use when setting up CI, fixing broken pipelines, automating PR checks, or configuring deployment."
4
+ allowed_tools:
5
+ - Read
6
+ - Write
7
+ - Edit
8
+ - Glob
9
+ - Grep
10
+ - Bash
11
+ ---
12
+
13
+ # CI/CD Patterns
14
+
15
+ Patterns for GitHub Actions, PR automation, and deployment workflows.
16
+
17
+ ## When to Use
18
+
19
+ - Setting up or fixing GitHub Actions workflows
20
+ - Automating PR checks (lint, test, build)
21
+ - Configuring deployment pipelines
22
+ - Monitoring PR status and retrying flaky CI
23
+ - Setting up multi-environment deployment (dev, staging, prod)
24
+
25
+ ## GitHub Actions --- Common Patterns
26
+
27
+ ### Basic CI Workflow
28
+ ```yaml
29
+ name: CI
30
+ on:
31
+ push:
32
+ branches: [main, develop]
33
+ pull_request:
34
+ branches: [main, develop]
35
+
36
+ jobs:
37
+ test:
38
+ runs-on: ubuntu-latest
39
+ steps:
40
+ - uses: actions/checkout@v4
41
+ - name: Run tests
42
+ run: ./gradlew test
43
+ ```
44
+
45
+ ### PR Check Workflow
46
+ ```yaml
47
+ name: PR Check
48
+ on: pull_request
49
+
50
+ jobs:
51
+ lint:
52
+ runs-on: ubuntu-latest
53
+ steps:
54
+ - uses: actions/checkout@v4
55
+ - run: ./gradlew ktlintCheck
56
+
57
+ test:
58
+ runs-on: ubuntu-latest
59
+ steps:
60
+ - uses: actions/checkout@v4
61
+ - run: ./gradlew test
62
+
63
+ build:
64
+ runs-on: ubuntu-latest
65
+ needs: [lint, test]
66
+ steps:
67
+ - uses: actions/checkout@v4
68
+ - run: ./gradlew build
69
+ ```
70
+
71
+ ## PR Babysitting Pattern
72
+
73
+ Monitor a PR through CI, handle common failures:
74
+
75
+ 1. **Check CI status** --- `gh pr checks <number>`
76
+ 2. **Identify failure type** --- flaky test, lint error, build failure
77
+ 3. **Fix and push** --- for lint/build errors, fix locally and push
78
+ 4. **Retry flaky tests** --- re-run the workflow: `gh run rerun <run-id> --failed`
79
+ 5. **Resolve merge conflicts** --- rebase onto target branch
80
+ 6. **Enable auto-merge** --- `gh pr merge <number> --auto --squash`
81
+
82
+ > See `workflows.md` for ready-to-use GitHub Actions YAML templates.
83
+
84
+ ## Deployment Checklist
85
+
86
+ Before deploying:
87
+ - [ ] All CI checks pass
88
+ - [ ] No merge conflicts
89
+ - [ ] Database migrations reviewed (if any)
90
+ - [ ] Environment variables set in target environment
91
+ - [ ] Rollback plan identified
92
+
93
+ ## Gotchas
94
+
95
+ - **Caching saves minutes per run.** Always cache dependencies (`actions/cache` or `actions/setup-java` with cache). A cold Gradle build takes 3-5 minutes, cached takes 30 seconds.
96
+ - **`needs:` creates sequential dependencies.** Without it, all jobs run in parallel. Use `needs: [lint, test]` to make build wait for checks.
97
+ - **Secret names are case-sensitive.** `secrets.DB_PASSWORD` and `secrets.db_password` are different. Match the exact name from Settings > Secrets.
98
+ - **Don't use `actions/checkout@v3` --- use `v4`.** v3 uses Node 16 which is deprecated. v4 uses Node 20.
99
+ - **Flaky tests need investigation, not just retry.** If you re-run a workflow more than twice for the same test, fix the test. Common causes: race conditions, time-dependent assertions, shared test state.
100
+ - **Force-pushing during CI review resets the check suite.** Wait for CI to finish before force-pushing, or you'll waste runner minutes.
101
+
102
+ ## Rules
103
+
104
+ - Every PR must pass CI before merge
105
+ - Don't skip CI checks (`[skip ci]`) unless it's docs-only
106
+ - Keep workflows under 10 minutes total
107
+ - Use matrix builds for multi-version testing
108
+ - Store secrets in GitHub Secrets, never in code
@@ -0,0 +1,149 @@
1
+ # CI/CD --- Workflow Templates
2
+
3
+ > This file is referenced by SKILL.md. Read it when setting up specific GitHub Actions workflows.
4
+
5
+ ## Kotlin/Micronaut --- Full CI
6
+
7
+ ```yaml
8
+ name: CI
9
+ on:
10
+ push:
11
+ branches: [main, develop]
12
+ pull_request:
13
+ branches: [main, develop]
14
+
15
+ env:
16
+ JAVA_VERSION: '17'
17
+ GRADLE_OPTS: '-Dorg.gradle.daemon=false'
18
+
19
+ jobs:
20
+ lint:
21
+ runs-on: ubuntu-latest
22
+ steps:
23
+ - uses: actions/checkout@v4
24
+ - uses: actions/setup-java@v4
25
+ with:
26
+ distribution: temurin
27
+ java-version: ${{ env.JAVA_VERSION }}
28
+ cache: gradle
29
+ - run: ./gradlew ktlintCheck
30
+
31
+ test:
32
+ runs-on: ubuntu-latest
33
+ services:
34
+ postgres:
35
+ image: postgres:15
36
+ env:
37
+ POSTGRES_DB: test_db
38
+ POSTGRES_USER: test
39
+ POSTGRES_PASSWORD: test
40
+ ports: ['5432:5432']
41
+ options: >-
42
+ --health-cmd pg_isready
43
+ --health-interval 10s
44
+ --health-timeout 5s
45
+ --health-retries 5
46
+ steps:
47
+ - uses: actions/checkout@v4
48
+ - uses: actions/setup-java@v4
49
+ with:
50
+ distribution: temurin
51
+ java-version: ${{ env.JAVA_VERSION }}
52
+ cache: gradle
53
+ - run: ./gradlew test
54
+ env:
55
+ DB_HOST: localhost
56
+ DB_PORT: 5432
57
+ DB_NAME: test_db
58
+ DB_USER: test
59
+ DB_PASSWORD: test
60
+
61
+ build:
62
+ runs-on: ubuntu-latest
63
+ needs: [lint, test]
64
+ steps:
65
+ - uses: actions/checkout@v4
66
+ - uses: actions/setup-java@v4
67
+ with:
68
+ distribution: temurin
69
+ java-version: ${{ env.JAVA_VERSION }}
70
+ cache: gradle
71
+ - run: ./gradlew build -x test
72
+ ```
73
+
74
+ ## Next.js --- Full CI
75
+
76
+ ```yaml
77
+ name: Frontend CI
78
+ on:
79
+ push:
80
+ branches: [main, develop]
81
+ pull_request:
82
+
83
+ jobs:
84
+ check:
85
+ runs-on: ubuntu-latest
86
+ steps:
87
+ - uses: actions/checkout@v4
88
+ - uses: actions/setup-node@v4
89
+ with:
90
+ node-version: 20
91
+ cache: yarn
92
+ - run: yarn install --frozen-lockfile
93
+ - run: yarn lint
94
+ - run: yarn type-check
95
+ - run: yarn build
96
+ - run: yarn test --ci
97
+ ```
98
+
99
+ ## Docker Build + Push
100
+
101
+ ```yaml
102
+ name: Docker
103
+ on:
104
+ push:
105
+ branches: [main]
106
+
107
+ jobs:
108
+ build-push:
109
+ runs-on: ubuntu-latest
110
+ steps:
111
+ - uses: actions/checkout@v4
112
+ - uses: docker/setup-buildx-action@v3
113
+ - uses: docker/login-action@v3
114
+ with:
115
+ registry: ghcr.io
116
+ username: ${{ github.actor }}
117
+ password: ${{ secrets.GITHUB_TOKEN }}
118
+ - uses: docker/build-push-action@v5
119
+ with:
120
+ context: .
121
+ push: true
122
+ tags: ghcr.io/${{ github.repository }}:${{ github.sha }}
123
+ cache-from: type=gha
124
+ cache-to: type=gha,mode=max
125
+ ```
126
+
127
+ ## Auto-merge Dependabot PRs
128
+
129
+ ```yaml
130
+ name: Auto-merge Dependabot
131
+ on: pull_request
132
+
133
+ permissions:
134
+ contents: write
135
+ pull-requests: write
136
+
137
+ jobs:
138
+ auto-merge:
139
+ if: github.actor == 'dependabot[bot]'
140
+ runs-on: ubuntu-latest
141
+ steps:
142
+ - uses: dependabot/fetch-metadata@v2
143
+ id: metadata
144
+ - if: steps.metadata.outputs.update-type == 'version-update:semver-patch'
145
+ run: gh pr merge --auto --squash "$PR_URL"
146
+ env:
147
+ PR_URL: ${{ github.event.pull_request.html_url }}
148
+ GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
149
+ ```
@@ -0,0 +1,93 @@
1
+ ---
2
+ name: competitive-teardown
3
+ description: Deep competitor analysis. Tear apart a specific competitor or compare multiple competitors. Use when the user names a competitor or asks "who else is doing this?"
4
+ allowed_tools:
5
+ - WebSearch
6
+ - WebFetch
7
+ - Read
8
+ ---
9
+
10
+ # Competitive Teardown
11
+
12
+ Study competitors like you're planning to beat them.
13
+
14
+ ## When to Use
15
+
16
+ - User names a specific competitor
17
+ - "Who else is doing this?"
18
+ - Before building, to find gaps
19
+ - Preparing for investor "competition slide"
20
+
21
+ > See `example-analysis.md` for a filled-in competitor teardown showing the format and depth expected.
22
+
23
+ ## Single Competitor Teardown
24
+
25
+ ### Product
26
+ - What do they actually do? (use the product, not just the landing page)
27
+ - Key features
28
+ - What's good about it
29
+ - What sucks (check 1-star reviews on App Store, G2, Reddit)
30
+ - Pricing tiers
31
+
32
+ ### Business
33
+ - Funding (Crunchbase, PitchBook)
34
+ - Revenue if known (press, SimilarWeb traffic guesses)
35
+ - Team size (LinkedIn)
36
+ - Founded when
37
+ - Growth signals (hiring? launching new features? going quiet?)
38
+
39
+ ### Users
40
+ - Who uses it? (check case studies, reviews, social mentions)
41
+ - How do they get users? (SEO, ads, viral, sales team)
42
+ - Community size (Discord, Reddit, Twitter followers)
43
+ - NPS or satisfaction signals
44
+
45
+ ### Weaknesses
46
+ - Negative reviews (patterns, not one-offs)
47
+ - Missing features users ask for
48
+ - Pricing complaints
49
+ - Technical limitations
50
+ - Support complaints
51
+
52
+ ## Multi-Competitor Comparison
53
+
54
+ Create a table:
55
+
56
+ | | Competitor A | Competitor B | Competitor C | Us (planned) |
57
+ |---|---|---|---|---|
58
+ | One-liner | | | | |
59
+ | Target user | | | | |
60
+ | Key feature | | | | |
61
+ | Pricing | | | | |
62
+ | Funding | | | | |
63
+ | Weakness | | | | |
64
+ | Our advantage | | | | |
65
+
66
+ ## Find the Gap
67
+
68
+ After analysis, answer:
69
+ - Where are ALL competitors weak?
70
+ - What do users want that nobody does well?
71
+ - Is there an underserved segment?
72
+ - What positioning would make us different?
73
+
74
+ ## Rules
75
+
76
+ - Use the product. Don't just read the landing page.
77
+ - Check reviews on multiple platforms
78
+ - Look for patterns in complaints, not single reviews
79
+ - Be fair. Give credit where it's due.
80
+ - If a competitor is way ahead, say so. Don't hide it.
81
+
82
+ ## Gotchas
83
+
84
+ - **Don't just read the landing page.** Sign up for free trials. Watch demo videos. Read user forums. The landing page is marketing, not the product.
85
+ - **One-star reviews are gold, but look for patterns.** A single angry review means nothing. Ten people saying the same thing is a signal.
86
+ - **Funding ≠ success.** A competitor with $50M raised and no revenue is weaker than one with $2M raised and growing 20% monthly.
87
+ - **Don't confuse features with moat.** A feature can be copied in a sprint. Distribution, data, and network effects can't.
88
+ - **Check if they're growing or coasting.** Recent job postings, new features, blog activity — these signal momentum. Silence signals trouble.
89
+
90
+ ## Output
91
+
92
+ Save to the project's `02-research/` folder.
93
+ Use the template from `templates/competitor-analysis.md` if it fits.
@@ -0,0 +1,50 @@
1
+ # Competitive Teardown — Example Analysis
2
+
3
+ > This file is referenced by SKILL.md. Use this format when producing a competitor teardown.
4
+
5
+ ## Example: Project Management Tool Teardown
6
+
7
+ ### Linear
8
+
9
+ **Product**
10
+ - Task tracking with keyboard-first UX, built for dev teams
11
+ - Key features: cycles, roadmaps, triage, GitHub/GitLab integration
12
+ - Strengths: incredibly fast UI, opinionated workflow, developer-loved
13
+ - Weaknesses: no time tracking, limited reporting, no resource management
14
+ - Pricing: $8/user/mo (Standard), $14/user/mo (Plus)
15
+
16
+ **Business**
17
+ - Founded: 2019, San Francisco
18
+ - Funding: $52M Series B (2021), valued ~$400M
19
+ - Team: ~80 employees (LinkedIn estimate)
20
+ - Growth signals: active hiring (8 open roles), weekly changelog updates, active Discord (15K+ members)
21
+
22
+ **Users**
23
+ - Primary: engineering teams at startups and mid-size companies
24
+ - Acquisition: word-of-mouth, developer communities, Twitter/X
25
+ - Community: Discord (15K), Twitter (50K followers)
26
+ - Sentiment: very positive on Reddit/HN, main complaint is "too opinionated"
27
+
28
+ **Weaknesses (from 1-star reviews)**
29
+ - "Can't customize workflow beyond their model" (repeated 12x on G2)
30
+ - "No time tracking means we need a second tool" (repeated 8x)
31
+ - "Reporting is basic — can't build custom dashboards"
32
+ - "Mobile app is an afterthought"
33
+
34
+ ---
35
+
36
+ ### Comparison Table
37
+
38
+ | | Linear | Jira | Shortcut | Our Product |
39
+ |---|---|---|---|---|
40
+ | One-liner | Fast PM for devs | Enterprise PM | Balanced PM for teams | [TBD] |
41
+ | Target user | Dev teams 10-200 | Enterprise 500+ | Teams 20-500 | [TBD] |
42
+ | Key strength | Speed + UX | Customization | Balance | [TBD] |
43
+ | Pricing | $8-14/user | $0-15/user | $8.50/user | [TBD] |
44
+ | Funding | $52M | Public (Atlassian) | $62M | [TBD] |
45
+ | Main weakness | Too opinionated | Too complex | No standout feature | [TBD] |
46
+ | Our advantage | [what we'd do better] | [what we'd do better] | [what we'd do better] | — |
47
+
48
+ ### The Gap
49
+
50
+ All three competitors are weak on: **real-time collaboration during planning sessions.** Nobody does live sprint planning well. Linear is closest but it's still turn-based. This is our angle.