@agents-inc/cli 0.32.1
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.
- package/CHANGELOG.md +462 -0
- package/LICENSE +21 -0
- package/README.md +179 -0
- package/config/skills-matrix.yaml +926 -0
- package/config/stacks.yaml +2186 -0
- package/dist/chunk-3ZOIOVKT.js +365 -0
- package/dist/chunk-3ZOIOVKT.js.map +1 -0
- package/dist/chunk-4RAY5AOI.js +78 -0
- package/dist/chunk-4RAY5AOI.js.map +1 -0
- package/dist/chunk-5PIKNCZX.js +234 -0
- package/dist/chunk-5PIKNCZX.js.map +1 -0
- package/dist/chunk-66UDJBF6.js +96 -0
- package/dist/chunk-66UDJBF6.js.map +1 -0
- package/dist/chunk-7SOPVGDV.js +24 -0
- package/dist/chunk-7SOPVGDV.js.map +1 -0
- package/dist/chunk-A27LOC4Z.js +95 -0
- package/dist/chunk-A27LOC4Z.js.map +1 -0
- package/dist/chunk-B2UBHA66.js +301 -0
- package/dist/chunk-B2UBHA66.js.map +1 -0
- package/dist/chunk-BZN2Z5P7.js +882 -0
- package/dist/chunk-BZN2Z5P7.js.map +1 -0
- package/dist/chunk-BZQBJP34.js +186 -0
- package/dist/chunk-BZQBJP34.js.map +1 -0
- package/dist/chunk-DC5AK3LW.js +105 -0
- package/dist/chunk-DC5AK3LW.js.map +1 -0
- package/dist/chunk-DHET7RCE.js +50 -0
- package/dist/chunk-DHET7RCE.js.map +1 -0
- package/dist/chunk-EMJ2ZKS7.js +346 -0
- package/dist/chunk-EMJ2ZKS7.js.map +1 -0
- package/dist/chunk-FJQRVFMB.js +48 -0
- package/dist/chunk-FJQRVFMB.js.map +1 -0
- package/dist/chunk-FZGYSLJL.js +85 -0
- package/dist/chunk-FZGYSLJL.js.map +1 -0
- package/dist/chunk-H566H3MQ.js +87 -0
- package/dist/chunk-H566H3MQ.js.map +1 -0
- package/dist/chunk-IYG2LAIM.js +90 -0
- package/dist/chunk-IYG2LAIM.js.map +1 -0
- package/dist/chunk-IZZ4IIEG.js +29 -0
- package/dist/chunk-IZZ4IIEG.js.map +1 -0
- package/dist/chunk-JMVWYAHT.js +63 -0
- package/dist/chunk-JMVWYAHT.js.map +1 -0
- package/dist/chunk-LAPCUV4D.js +191 -0
- package/dist/chunk-LAPCUV4D.js.map +1 -0
- package/dist/chunk-LGUI3PMO.js +109 -0
- package/dist/chunk-LGUI3PMO.js.map +1 -0
- package/dist/chunk-MM7NK5N2.js +4542 -0
- package/dist/chunk-MM7NK5N2.js.map +1 -0
- package/dist/chunk-N6S7ZRIL.js +31 -0
- package/dist/chunk-N6S7ZRIL.js.map +1 -0
- package/dist/chunk-O4D67NN7.js +24 -0
- package/dist/chunk-O4D67NN7.js.map +1 -0
- package/dist/chunk-ODUOU55D.js +56 -0
- package/dist/chunk-ODUOU55D.js.map +1 -0
- package/dist/chunk-OGJIZ6QH.js +497 -0
- package/dist/chunk-OGJIZ6QH.js.map +1 -0
- package/dist/chunk-OMV7TLWD.js +340 -0
- package/dist/chunk-OMV7TLWD.js.map +1 -0
- package/dist/chunk-PBEHPQLK.js +146 -0
- package/dist/chunk-PBEHPQLK.js.map +1 -0
- package/dist/chunk-QPTOIZAT.js +32 -0
- package/dist/chunk-QPTOIZAT.js.map +1 -0
- package/dist/chunk-R3XFQKPG.js +111 -0
- package/dist/chunk-R3XFQKPG.js.map +1 -0
- package/dist/chunk-R74PZWQS.js +69 -0
- package/dist/chunk-R74PZWQS.js.map +1 -0
- package/dist/chunk-SO22IQPY.js +45 -0
- package/dist/chunk-SO22IQPY.js.map +1 -0
- package/dist/chunk-T4EXUIBY.js +19 -0
- package/dist/chunk-T4EXUIBY.js.map +1 -0
- package/dist/chunk-U3IGFMCY.js +31 -0
- package/dist/chunk-U3IGFMCY.js.map +1 -0
- package/dist/chunk-UICL22RT.js +318 -0
- package/dist/chunk-UICL22RT.js.map +1 -0
- package/dist/chunk-UX2H2K2G.js +183 -0
- package/dist/chunk-UX2H2K2G.js.map +1 -0
- package/dist/chunk-W2ZSCZ2U.js +93 -0
- package/dist/chunk-W2ZSCZ2U.js.map +1 -0
- package/dist/chunk-WEUVWHMA.js +189 -0
- package/dist/chunk-WEUVWHMA.js.map +1 -0
- package/dist/chunk-XY3XDVMI.js +15599 -0
- package/dist/chunk-XY3XDVMI.js.map +1 -0
- package/dist/chunk-YND42IXK.js +233 -0
- package/dist/chunk-YND42IXK.js.map +1 -0
- package/dist/chunk-YZTWZVGX.js +41 -0
- package/dist/chunk-YZTWZVGX.js.map +1 -0
- package/dist/chunk-Z4TWOP3H.js +81 -0
- package/dist/chunk-Z4TWOP3H.js.map +1 -0
- package/dist/cli/defaults/agent-mappings.yaml +271 -0
- package/dist/commands/build/marketplace.js +252 -0
- package/dist/commands/build/marketplace.js.map +1 -0
- package/dist/commands/build/plugins.js +114 -0
- package/dist/commands/build/plugins.js.map +1 -0
- package/dist/commands/build/stack.js +153 -0
- package/dist/commands/build/stack.js.map +1 -0
- package/dist/commands/compile.js +354 -0
- package/dist/commands/compile.js.map +1 -0
- package/dist/commands/config/get.js +61 -0
- package/dist/commands/config/get.js.map +1 -0
- package/dist/commands/config/index.js +23 -0
- package/dist/commands/config/index.js.map +1 -0
- package/dist/commands/config/path.js +34 -0
- package/dist/commands/config/path.js.map +1 -0
- package/dist/commands/config/set-project.js +61 -0
- package/dist/commands/config/set-project.js.map +1 -0
- package/dist/commands/config/show.js +14 -0
- package/dist/commands/config/show.js.map +1 -0
- package/dist/commands/config/unset-project.js +57 -0
- package/dist/commands/config/unset-project.js.map +1 -0
- package/dist/commands/diff.js +742 -0
- package/dist/commands/diff.js.map +1 -0
- package/dist/commands/doctor.js +370 -0
- package/dist/commands/doctor.js.map +1 -0
- package/dist/commands/edit.js +301 -0
- package/dist/commands/edit.js.map +1 -0
- package/dist/commands/eject.js +262 -0
- package/dist/commands/eject.js.map +1 -0
- package/dist/commands/import/skill.js +361 -0
- package/dist/commands/import/skill.js.map +1 -0
- package/dist/commands/info.js +217 -0
- package/dist/commands/info.js.map +1 -0
- package/dist/commands/init.js +443 -0
- package/dist/commands/init.js.map +1 -0
- package/dist/commands/list.js +49 -0
- package/dist/commands/list.js.map +1 -0
- package/dist/commands/new/agent.js +224 -0
- package/dist/commands/new/agent.js.map +1 -0
- package/dist/commands/new/skill.js +199 -0
- package/dist/commands/new/skill.js.map +1 -0
- package/dist/commands/outdated.js +176 -0
- package/dist/commands/outdated.js.map +1 -0
- package/dist/commands/search.js +288 -0
- package/dist/commands/search.js.map +1 -0
- package/dist/commands/uninstall.js +302 -0
- package/dist/commands/uninstall.js.map +1 -0
- package/dist/commands/update.js +304 -0
- package/dist/commands/update.js.map +1 -0
- package/dist/commands/validate.js +389 -0
- package/dist/commands/validate.js.map +1 -0
- package/dist/commands/version/bump.js +79 -0
- package/dist/commands/version/bump.js.map +1 -0
- package/dist/commands/version/index.js +54 -0
- package/dist/commands/version/index.js.map +1 -0
- package/dist/commands/version/set.js +86 -0
- package/dist/commands/version/set.js.map +1 -0
- package/dist/commands/version/show.js +54 -0
- package/dist/commands/version/show.js.map +1 -0
- package/dist/components/common/confirm.js +9 -0
- package/dist/components/common/confirm.js.map +1 -0
- package/dist/components/common/confirm.test.js +203 -0
- package/dist/components/common/confirm.test.js.map +1 -0
- package/dist/components/common/message.js +20 -0
- package/dist/components/common/message.js.map +1 -0
- package/dist/components/common/spinner.js +14 -0
- package/dist/components/common/spinner.js.map +1 -0
- package/dist/components/skill-search/skill-search.js +12 -0
- package/dist/components/skill-search/skill-search.js.map +1 -0
- package/dist/components/wizard/category-grid.js +11 -0
- package/dist/components/wizard/category-grid.js.map +1 -0
- package/dist/components/wizard/category-grid.test.js +997 -0
- package/dist/components/wizard/category-grid.test.js.map +1 -0
- package/dist/components/wizard/domain-selection.js +14 -0
- package/dist/components/wizard/domain-selection.js.map +1 -0
- package/dist/components/wizard/help-modal.js +10 -0
- package/dist/components/wizard/help-modal.js.map +1 -0
- package/dist/components/wizard/menu-item.js +10 -0
- package/dist/components/wizard/menu-item.js.map +1 -0
- package/dist/components/wizard/search-modal.js +11 -0
- package/dist/components/wizard/search-modal.js.map +1 -0
- package/dist/components/wizard/search-modal.test.js +218 -0
- package/dist/components/wizard/search-modal.test.js.map +1 -0
- package/dist/components/wizard/section-progress.js +10 -0
- package/dist/components/wizard/section-progress.js.map +1 -0
- package/dist/components/wizard/section-progress.test.js +192 -0
- package/dist/components/wizard/section-progress.test.js.map +1 -0
- package/dist/components/wizard/source-grid.js +14 -0
- package/dist/components/wizard/source-grid.js.map +1 -0
- package/dist/components/wizard/source-grid.test.js +504 -0
- package/dist/components/wizard/source-grid.test.js.map +1 -0
- package/dist/components/wizard/stack-selection.js +17 -0
- package/dist/components/wizard/stack-selection.js.map +1 -0
- package/dist/components/wizard/step-build.js +17 -0
- package/dist/components/wizard/step-build.js.map +1 -0
- package/dist/components/wizard/step-build.test.js +600 -0
- package/dist/components/wizard/step-build.test.js.map +1 -0
- package/dist/components/wizard/step-confirm.js +12 -0
- package/dist/components/wizard/step-confirm.js.map +1 -0
- package/dist/components/wizard/step-confirm.test.js +366 -0
- package/dist/components/wizard/step-confirm.test.js.map +1 -0
- package/dist/components/wizard/step-refine.js +10 -0
- package/dist/components/wizard/step-refine.js.map +1 -0
- package/dist/components/wizard/step-refine.test.js +237 -0
- package/dist/components/wizard/step-refine.test.js.map +1 -0
- package/dist/components/wizard/step-settings.js +17 -0
- package/dist/components/wizard/step-settings.js.map +1 -0
- package/dist/components/wizard/step-settings.test.js +243 -0
- package/dist/components/wizard/step-settings.test.js.map +1 -0
- package/dist/components/wizard/step-sources.js +20 -0
- package/dist/components/wizard/step-sources.js.map +1 -0
- package/dist/components/wizard/step-sources.test.js +294 -0
- package/dist/components/wizard/step-sources.test.js.map +1 -0
- package/dist/components/wizard/step-stack.js +19 -0
- package/dist/components/wizard/step-stack.js.map +1 -0
- package/dist/components/wizard/step-stack.test.js +357 -0
- package/dist/components/wizard/step-stack.test.js.map +1 -0
- package/dist/components/wizard/view-title.js +10 -0
- package/dist/components/wizard/view-title.js.map +1 -0
- package/dist/components/wizard/wizard-layout.js +16 -0
- package/dist/components/wizard/wizard-layout.js.map +1 -0
- package/dist/components/wizard/wizard-tabs.js +14 -0
- package/dist/components/wizard/wizard-tabs.js.map +1 -0
- package/dist/components/wizard/wizard-tabs.test.js +294 -0
- package/dist/components/wizard/wizard-tabs.test.js.map +1 -0
- package/dist/components/wizard/wizard.js +35 -0
- package/dist/components/wizard/wizard.js.map +1 -0
- package/dist/config/skills-matrix.yaml +926 -0
- package/dist/config/stacks.yaml +2186 -0
- package/dist/hooks/init.js +40 -0
- package/dist/hooks/init.js.map +1 -0
- package/dist/index.js +10 -0
- package/dist/index.js.map +1 -0
- package/dist/magic-string.es-RGXYGAW3.js +1316 -0
- package/dist/magic-string.es-RGXYGAW3.js.map +1 -0
- package/dist/source-manager-SBPPLOQQ.js +16 -0
- package/dist/source-manager-SBPPLOQQ.js.map +1 -0
- package/dist/src/agents/_templates/agent.liquid +140 -0
- package/dist/src/agents/developer/api-developer/agent.yaml +12 -0
- package/dist/src/agents/developer/api-developer/critical-reminders.md +23 -0
- package/dist/src/agents/developer/api-developer/critical-requirements.md +11 -0
- package/dist/src/agents/developer/api-developer/examples.md +72 -0
- package/dist/src/agents/developer/api-developer/intro.md +22 -0
- package/dist/src/agents/developer/api-developer/output-format.md +359 -0
- package/dist/src/agents/developer/api-developer/workflow.md +471 -0
- package/dist/src/agents/developer/cli-developer/agent.yaml +12 -0
- package/dist/src/agents/developer/cli-developer/critical-reminders.md +28 -0
- package/dist/src/agents/developer/cli-developer/critical-requirements.md +15 -0
- package/dist/src/agents/developer/cli-developer/examples.md +68 -0
- package/dist/src/agents/developer/cli-developer/intro.md +23 -0
- package/dist/src/agents/developer/cli-developer/output-format.md +216 -0
- package/dist/src/agents/developer/cli-developer/workflow.md +509 -0
- package/dist/src/agents/developer/web-architecture/agent.yaml +12 -0
- package/dist/src/agents/developer/web-architecture/critical-reminders.md +27 -0
- package/dist/src/agents/developer/web-architecture/critical-requirements.md +35 -0
- package/dist/src/agents/developer/web-architecture/examples.md +187 -0
- package/dist/src/agents/developer/web-architecture/intro.md +35 -0
- package/dist/src/agents/developer/web-architecture/output-format.md +261 -0
- package/dist/src/agents/developer/web-architecture/workflow.md +599 -0
- package/dist/src/agents/developer/web-developer/agent.yaml +12 -0
- package/dist/src/agents/developer/web-developer/critical-reminders.md +17 -0
- package/dist/src/agents/developer/web-developer/critical-requirements.md +15 -0
- package/dist/src/agents/developer/web-developer/examples.md +109 -0
- package/dist/src/agents/developer/web-developer/intro.md +5 -0
- package/dist/src/agents/developer/web-developer/output-format.md +213 -0
- package/dist/src/agents/developer/web-developer/workflow.md +459 -0
- package/dist/src/agents/meta/agent-summoner/agent.yaml +12 -0
- package/dist/src/agents/meta/agent-summoner/critical-reminders.md +31 -0
- package/dist/src/agents/meta/agent-summoner/critical-requirements.md +27 -0
- package/dist/src/agents/meta/agent-summoner/examples.md +176 -0
- package/dist/src/agents/meta/agent-summoner/intro.md +9 -0
- package/dist/src/agents/meta/agent-summoner/output-format.md +115 -0
- package/dist/src/agents/meta/agent-summoner/workflow.md +1540 -0
- package/dist/src/agents/meta/documentor/agent.yaml +11 -0
- package/dist/src/agents/meta/documentor/critical-reminders.md +23 -0
- package/dist/src/agents/meta/documentor/critical-requirements.md +13 -0
- package/dist/src/agents/meta/documentor/examples.md +147 -0
- package/dist/src/agents/meta/documentor/intro.md +11 -0
- package/dist/src/agents/meta/documentor/output-format.md +237 -0
- package/dist/src/agents/meta/documentor/workflow.md +1271 -0
- package/dist/src/agents/meta/skill-summoner/agent.yaml +13 -0
- package/dist/src/agents/meta/skill-summoner/critical-reminders.md +73 -0
- package/dist/src/agents/meta/skill-summoner/critical-requirements.md +62 -0
- package/dist/src/agents/meta/skill-summoner/examples.md +116 -0
- package/dist/src/agents/meta/skill-summoner/intro.md +5 -0
- package/dist/src/agents/meta/skill-summoner/output-format.md +279 -0
- package/dist/src/agents/meta/skill-summoner/workflow.md +1485 -0
- package/dist/src/agents/migration/cli-migrator/agent.yaml +12 -0
- package/dist/src/agents/migration/cli-migrator/anti-patterns.md +158 -0
- package/dist/src/agents/migration/cli-migrator/conversion-mappings.md +63 -0
- package/dist/src/agents/migration/cli-migrator/critical-reminders.md +17 -0
- package/dist/src/agents/migration/cli-migrator/critical-requirements.md +13 -0
- package/dist/src/agents/migration/cli-migrator/intro.md +15 -0
- package/dist/src/agents/migration/cli-migrator/output-format.md +164 -0
- package/dist/src/agents/migration/cli-migrator/workflow.md +230 -0
- package/dist/src/agents/pattern/pattern-scout/agent.yaml +10 -0
- package/dist/src/agents/pattern/pattern-scout/critical-reminders.md +58 -0
- package/dist/src/agents/pattern/pattern-scout/critical-requirements.md +17 -0
- package/dist/src/agents/pattern/pattern-scout/examples.md +93 -0
- package/dist/src/agents/pattern/pattern-scout/intro.md +3 -0
- package/dist/src/agents/pattern/pattern-scout/output-format.md +196 -0
- package/dist/src/agents/pattern/pattern-scout/workflow.md +1901 -0
- package/dist/src/agents/pattern/web-pattern-critique/agent.yaml +12 -0
- package/dist/src/agents/pattern/web-pattern-critique/critical-reminders.md +13 -0
- package/dist/src/agents/pattern/web-pattern-critique/critical-requirements.md +11 -0
- package/dist/src/agents/pattern/web-pattern-critique/examples.md +56 -0
- package/dist/src/agents/pattern/web-pattern-critique/intro.md +5 -0
- package/dist/src/agents/pattern/web-pattern-critique/output-format.md +257 -0
- package/dist/src/agents/pattern/web-pattern-critique/workflow.md +674 -0
- package/dist/src/agents/planning/web-pm/agent.yaml +12 -0
- package/dist/src/agents/planning/web-pm/critical-reminders.md +21 -0
- package/dist/src/agents/planning/web-pm/critical-requirements.md +17 -0
- package/dist/src/agents/planning/web-pm/examples.md +85 -0
- package/dist/src/agents/planning/web-pm/intro.md +3 -0
- package/dist/src/agents/planning/web-pm/output-format.md +228 -0
- package/dist/src/agents/planning/web-pm/workflow.md +393 -0
- package/dist/src/agents/researcher/api-researcher/agent.yaml +10 -0
- package/dist/src/agents/researcher/api-researcher/critical-reminders.md +27 -0
- package/dist/src/agents/researcher/api-researcher/critical-requirements.md +13 -0
- package/dist/src/agents/researcher/api-researcher/examples.md +116 -0
- package/dist/src/agents/researcher/api-researcher/intro.md +32 -0
- package/dist/src/agents/researcher/api-researcher/output-format.md +135 -0
- package/dist/src/agents/researcher/api-researcher/workflow.md +261 -0
- package/dist/src/agents/researcher/web-researcher/agent.yaml +10 -0
- package/dist/src/agents/researcher/web-researcher/critical-reminders.md +23 -0
- package/dist/src/agents/researcher/web-researcher/critical-requirements.md +11 -0
- package/dist/src/agents/researcher/web-researcher/examples.md +126 -0
- package/dist/src/agents/researcher/web-researcher/intro.md +31 -0
- package/dist/src/agents/researcher/web-researcher/output-format.md +112 -0
- package/dist/src/agents/researcher/web-researcher/workflow.md +322 -0
- package/dist/src/agents/reviewer/api-reviewer/agent.yaml +12 -0
- package/dist/src/agents/reviewer/api-reviewer/critical-reminders.md +16 -0
- package/dist/src/agents/reviewer/api-reviewer/critical-requirements.md +13 -0
- package/dist/src/agents/reviewer/api-reviewer/examples.md +54 -0
- package/dist/src/agents/reviewer/api-reviewer/intro.md +22 -0
- package/dist/src/agents/reviewer/api-reviewer/output-format.md +288 -0
- package/dist/src/agents/reviewer/api-reviewer/workflow.md +369 -0
- package/dist/src/agents/reviewer/cli-reviewer/agent.yaml +12 -0
- package/dist/src/agents/reviewer/cli-reviewer/critical-reminders.md +17 -0
- package/dist/src/agents/reviewer/cli-reviewer/critical-requirements.md +13 -0
- package/dist/src/agents/reviewer/cli-reviewer/examples.md +83 -0
- package/dist/src/agents/reviewer/cli-reviewer/intro.md +21 -0
- package/dist/src/agents/reviewer/cli-reviewer/output-format.md +330 -0
- package/dist/src/agents/reviewer/cli-reviewer/workflow.md +294 -0
- package/dist/src/agents/reviewer/web-reviewer/agent.yaml +12 -0
- package/dist/src/agents/reviewer/web-reviewer/critical-reminders.md +17 -0
- package/dist/src/agents/reviewer/web-reviewer/critical-requirements.md +11 -0
- package/dist/src/agents/reviewer/web-reviewer/examples.md +79 -0
- package/dist/src/agents/reviewer/web-reviewer/intro.md +20 -0
- package/dist/src/agents/reviewer/web-reviewer/output-format.md +253 -0
- package/dist/src/agents/reviewer/web-reviewer/workflow.md +228 -0
- package/dist/src/agents/tester/cli-tester/agent.yaml +12 -0
- package/dist/src/agents/tester/cli-tester/critical-reminders.md +19 -0
- package/dist/src/agents/tester/cli-tester/critical-requirements.md +17 -0
- package/dist/src/agents/tester/cli-tester/examples.md +80 -0
- package/dist/src/agents/tester/cli-tester/intro.md +19 -0
- package/dist/src/agents/tester/cli-tester/output-format.md +232 -0
- package/dist/src/agents/tester/cli-tester/workflow.md +304 -0
- package/dist/src/agents/tester/web-tester/agent.yaml +12 -0
- package/dist/src/agents/tester/web-tester/critical-reminders.md +15 -0
- package/dist/src/agents/tester/web-tester/critical-requirements.md +11 -0
- package/dist/src/agents/tester/web-tester/examples.md +68 -0
- package/dist/src/agents/tester/web-tester/intro.md +18 -0
- package/dist/src/agents/tester/web-tester/output-format.md +252 -0
- package/dist/src/agents/tester/web-tester/workflow.md +507 -0
- package/dist/stores/wizard-store.js +13 -0
- package/dist/stores/wizard-store.js.map +1 -0
- package/dist/stores/wizard-store.test.js +689 -0
- package/dist/stores/wizard-store.test.js.map +1 -0
- package/package.json +134 -0
- package/src/agents/_templates/agent.liquid +140 -0
- package/src/agents/developer/api-developer/agent.yaml +12 -0
- package/src/agents/developer/api-developer/critical-reminders.md +23 -0
- package/src/agents/developer/api-developer/critical-requirements.md +11 -0
- package/src/agents/developer/api-developer/examples.md +72 -0
- package/src/agents/developer/api-developer/intro.md +22 -0
- package/src/agents/developer/api-developer/output-format.md +359 -0
- package/src/agents/developer/api-developer/workflow.md +471 -0
- package/src/agents/developer/cli-developer/agent.yaml +12 -0
- package/src/agents/developer/cli-developer/critical-reminders.md +28 -0
- package/src/agents/developer/cli-developer/critical-requirements.md +15 -0
- package/src/agents/developer/cli-developer/examples.md +68 -0
- package/src/agents/developer/cli-developer/intro.md +23 -0
- package/src/agents/developer/cli-developer/output-format.md +216 -0
- package/src/agents/developer/cli-developer/workflow.md +509 -0
- package/src/agents/developer/web-architecture/agent.yaml +12 -0
- package/src/agents/developer/web-architecture/critical-reminders.md +27 -0
- package/src/agents/developer/web-architecture/critical-requirements.md +35 -0
- package/src/agents/developer/web-architecture/examples.md +187 -0
- package/src/agents/developer/web-architecture/intro.md +35 -0
- package/src/agents/developer/web-architecture/output-format.md +261 -0
- package/src/agents/developer/web-architecture/workflow.md +599 -0
- package/src/agents/developer/web-developer/agent.yaml +12 -0
- package/src/agents/developer/web-developer/critical-reminders.md +17 -0
- package/src/agents/developer/web-developer/critical-requirements.md +15 -0
- package/src/agents/developer/web-developer/examples.md +109 -0
- package/src/agents/developer/web-developer/intro.md +5 -0
- package/src/agents/developer/web-developer/output-format.md +213 -0
- package/src/agents/developer/web-developer/workflow.md +459 -0
- package/src/agents/meta/agent-summoner/agent.yaml +12 -0
- package/src/agents/meta/agent-summoner/critical-reminders.md +31 -0
- package/src/agents/meta/agent-summoner/critical-requirements.md +27 -0
- package/src/agents/meta/agent-summoner/examples.md +176 -0
- package/src/agents/meta/agent-summoner/intro.md +9 -0
- package/src/agents/meta/agent-summoner/output-format.md +115 -0
- package/src/agents/meta/agent-summoner/workflow.md +1540 -0
- package/src/agents/meta/documentor/agent.yaml +11 -0
- package/src/agents/meta/documentor/critical-reminders.md +23 -0
- package/src/agents/meta/documentor/critical-requirements.md +13 -0
- package/src/agents/meta/documentor/examples.md +147 -0
- package/src/agents/meta/documentor/intro.md +11 -0
- package/src/agents/meta/documentor/output-format.md +237 -0
- package/src/agents/meta/documentor/workflow.md +1271 -0
- package/src/agents/meta/skill-summoner/agent.yaml +13 -0
- package/src/agents/meta/skill-summoner/critical-reminders.md +73 -0
- package/src/agents/meta/skill-summoner/critical-requirements.md +62 -0
- package/src/agents/meta/skill-summoner/examples.md +116 -0
- package/src/agents/meta/skill-summoner/intro.md +5 -0
- package/src/agents/meta/skill-summoner/output-format.md +279 -0
- package/src/agents/meta/skill-summoner/workflow.md +1485 -0
- package/src/agents/migration/cli-migrator/agent.yaml +12 -0
- package/src/agents/migration/cli-migrator/anti-patterns.md +158 -0
- package/src/agents/migration/cli-migrator/conversion-mappings.md +63 -0
- package/src/agents/migration/cli-migrator/critical-reminders.md +17 -0
- package/src/agents/migration/cli-migrator/critical-requirements.md +13 -0
- package/src/agents/migration/cli-migrator/intro.md +15 -0
- package/src/agents/migration/cli-migrator/output-format.md +164 -0
- package/src/agents/migration/cli-migrator/workflow.md +230 -0
- package/src/agents/pattern/pattern-scout/agent.yaml +10 -0
- package/src/agents/pattern/pattern-scout/critical-reminders.md +58 -0
- package/src/agents/pattern/pattern-scout/critical-requirements.md +17 -0
- package/src/agents/pattern/pattern-scout/examples.md +93 -0
- package/src/agents/pattern/pattern-scout/intro.md +3 -0
- package/src/agents/pattern/pattern-scout/output-format.md +196 -0
- package/src/agents/pattern/pattern-scout/workflow.md +1901 -0
- package/src/agents/pattern/web-pattern-critique/agent.yaml +12 -0
- package/src/agents/pattern/web-pattern-critique/critical-reminders.md +13 -0
- package/src/agents/pattern/web-pattern-critique/critical-requirements.md +11 -0
- package/src/agents/pattern/web-pattern-critique/examples.md +56 -0
- package/src/agents/pattern/web-pattern-critique/intro.md +5 -0
- package/src/agents/pattern/web-pattern-critique/output-format.md +257 -0
- package/src/agents/pattern/web-pattern-critique/workflow.md +674 -0
- package/src/agents/planning/web-pm/agent.yaml +12 -0
- package/src/agents/planning/web-pm/critical-reminders.md +21 -0
- package/src/agents/planning/web-pm/critical-requirements.md +17 -0
- package/src/agents/planning/web-pm/examples.md +85 -0
- package/src/agents/planning/web-pm/intro.md +3 -0
- package/src/agents/planning/web-pm/output-format.md +228 -0
- package/src/agents/planning/web-pm/workflow.md +393 -0
- package/src/agents/researcher/api-researcher/agent.yaml +10 -0
- package/src/agents/researcher/api-researcher/critical-reminders.md +27 -0
- package/src/agents/researcher/api-researcher/critical-requirements.md +13 -0
- package/src/agents/researcher/api-researcher/examples.md +116 -0
- package/src/agents/researcher/api-researcher/intro.md +32 -0
- package/src/agents/researcher/api-researcher/output-format.md +135 -0
- package/src/agents/researcher/api-researcher/workflow.md +261 -0
- package/src/agents/researcher/web-researcher/agent.yaml +10 -0
- package/src/agents/researcher/web-researcher/critical-reminders.md +23 -0
- package/src/agents/researcher/web-researcher/critical-requirements.md +11 -0
- package/src/agents/researcher/web-researcher/examples.md +126 -0
- package/src/agents/researcher/web-researcher/intro.md +31 -0
- package/src/agents/researcher/web-researcher/output-format.md +112 -0
- package/src/agents/researcher/web-researcher/workflow.md +322 -0
- package/src/agents/reviewer/api-reviewer/agent.yaml +12 -0
- package/src/agents/reviewer/api-reviewer/critical-reminders.md +16 -0
- package/src/agents/reviewer/api-reviewer/critical-requirements.md +13 -0
- package/src/agents/reviewer/api-reviewer/examples.md +54 -0
- package/src/agents/reviewer/api-reviewer/intro.md +22 -0
- package/src/agents/reviewer/api-reviewer/output-format.md +288 -0
- package/src/agents/reviewer/api-reviewer/workflow.md +369 -0
- package/src/agents/reviewer/cli-reviewer/agent.yaml +12 -0
- package/src/agents/reviewer/cli-reviewer/critical-reminders.md +17 -0
- package/src/agents/reviewer/cli-reviewer/critical-requirements.md +13 -0
- package/src/agents/reviewer/cli-reviewer/examples.md +83 -0
- package/src/agents/reviewer/cli-reviewer/intro.md +21 -0
- package/src/agents/reviewer/cli-reviewer/output-format.md +330 -0
- package/src/agents/reviewer/cli-reviewer/workflow.md +294 -0
- package/src/agents/reviewer/web-reviewer/agent.yaml +12 -0
- package/src/agents/reviewer/web-reviewer/critical-reminders.md +17 -0
- package/src/agents/reviewer/web-reviewer/critical-requirements.md +11 -0
- package/src/agents/reviewer/web-reviewer/examples.md +79 -0
- package/src/agents/reviewer/web-reviewer/intro.md +20 -0
- package/src/agents/reviewer/web-reviewer/output-format.md +253 -0
- package/src/agents/reviewer/web-reviewer/workflow.md +228 -0
- package/src/agents/tester/cli-tester/agent.yaml +12 -0
- package/src/agents/tester/cli-tester/critical-reminders.md +19 -0
- package/src/agents/tester/cli-tester/critical-requirements.md +17 -0
- package/src/agents/tester/cli-tester/examples.md +80 -0
- package/src/agents/tester/cli-tester/intro.md +19 -0
- package/src/agents/tester/cli-tester/output-format.md +232 -0
- package/src/agents/tester/cli-tester/workflow.md +304 -0
- package/src/agents/tester/web-tester/agent.yaml +12 -0
- package/src/agents/tester/web-tester/critical-reminders.md +15 -0
- package/src/agents/tester/web-tester/critical-requirements.md +11 -0
- package/src/agents/tester/web-tester/examples.md +68 -0
- package/src/agents/tester/web-tester/intro.md +18 -0
- package/src/agents/tester/web-tester/output-format.md +252 -0
- package/src/agents/tester/web-tester/workflow.md +507 -0
- package/src/schemas/agent-frontmatter.schema.json +84 -0
- package/src/schemas/agent.schema.json +93 -0
- package/src/schemas/hooks.schema.json +47 -0
- package/src/schemas/marketplace.schema.json +119 -0
- package/src/schemas/metadata.schema.json +113 -0
- package/src/schemas/plugin.schema.json +130 -0
- package/src/schemas/project-config.schema.json +125 -0
- package/src/schemas/project-source-config.schema.json +81 -0
- package/src/schemas/skill-frontmatter.schema.json +42 -0
- package/src/schemas/skills-matrix.schema.json +467 -0
- package/src/schemas/stack.schema.json +191 -0
- package/src/schemas/stacks.schema.json +111 -0
|
@@ -0,0 +1,674 @@
|
|
|
1
|
+
<self_correction_triggers>
|
|
2
|
+
|
|
3
|
+
## Self-Correction Checkpoints
|
|
4
|
+
|
|
5
|
+
**If you notice yourself:**
|
|
6
|
+
|
|
7
|
+
- **Critiquing without reading the full patterns file** → Stop. Read the entire file first.
|
|
8
|
+
- **Making generic statements like "this is bad practice"** → Stop. Cite specific industry sources.
|
|
9
|
+
- **Providing critique without code examples** → Stop. Add concrete good/bad examples.
|
|
10
|
+
- **Mixing severity levels (calling everything CRITICAL)** → Stop. Recalibrate severity objectively.
|
|
11
|
+
- **Skipping skill invocation for domain patterns** → Stop. Load the relevant skill for comparison.
|
|
12
|
+
- **Being dogmatic instead of pragmatic** → Stop. Consider team context and trade-offs.
|
|
13
|
+
- **Forgetting to provide migration strategy** → Stop. Add step-by-step refactoring guidance.
|
|
14
|
+
|
|
15
|
+
These checkpoints prevent critique drift during extended sessions.
|
|
16
|
+
</self_correction_triggers>
|
|
17
|
+
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
<mandatory_investigation>
|
|
21
|
+
|
|
22
|
+
## Pattern Critique Investigation Process
|
|
23
|
+
|
|
24
|
+
**Before critiquing ANY patterns:**
|
|
25
|
+
|
|
26
|
+
1. **Read the entire patterns file**
|
|
27
|
+
- Understand all patterns documented
|
|
28
|
+
- Note what categories are present
|
|
29
|
+
- Identify what's missing vs documented
|
|
30
|
+
|
|
31
|
+
2. **Categorize patterns by domain**
|
|
32
|
+
- State Management patterns
|
|
33
|
+
- Component Architecture patterns
|
|
34
|
+
- Testing patterns
|
|
35
|
+
- Styling patterns
|
|
36
|
+
- Build/Tooling patterns
|
|
37
|
+
- API Integration patterns
|
|
38
|
+
|
|
39
|
+
3. **Load relevant skills for comparison**
|
|
40
|
+
- For each domain category, invoke the corresponding skill
|
|
41
|
+
- Use skill patterns as the baseline for critique
|
|
42
|
+
|
|
43
|
+
4. **Assess against industry standards**
|
|
44
|
+
- Reference Airbnb, Stripe, Meta, Vercel patterns
|
|
45
|
+
- Consider 2025 best practices
|
|
46
|
+
- Evaluate production scalability
|
|
47
|
+
</mandatory_investigation>
|
|
48
|
+
|
|
49
|
+
---
|
|
50
|
+
|
|
51
|
+
<post_action_reflection>
|
|
52
|
+
|
|
53
|
+
## Post-Critique Reflection
|
|
54
|
+
|
|
55
|
+
**After completing each critique section, evaluate:**
|
|
56
|
+
|
|
57
|
+
1. Did I read the full patterns file before critiquing?
|
|
58
|
+
2. Did I invoke relevant skills for domain comparison?
|
|
59
|
+
3. Did I provide concrete code examples for each issue?
|
|
60
|
+
4. Did I cite specific industry sources?
|
|
61
|
+
5. Did I categorize severity correctly (not everything is CRITICAL)?
|
|
62
|
+
6. Did I provide actionable migration strategies?
|
|
63
|
+
7. Was I pragmatic or dogmatic in my assessment?
|
|
64
|
+
|
|
65
|
+
Only proceed when you have verified all requirements are met.
|
|
66
|
+
</post_action_reflection>
|
|
67
|
+
|
|
68
|
+
---
|
|
69
|
+
|
|
70
|
+
<progress_tracking>
|
|
71
|
+
|
|
72
|
+
## Critique Progress Tracking
|
|
73
|
+
|
|
74
|
+
**Track your progress through the critique:**
|
|
75
|
+
|
|
76
|
+
1. **Patterns Reviewed:** [list categories covered]
|
|
77
|
+
2. **Skills Invoked:** [list skills loaded for comparison]
|
|
78
|
+
3. **Issues Found:**
|
|
79
|
+
- Critical: [count]
|
|
80
|
+
- Important: [count]
|
|
81
|
+
- Nice-to-have: [count]
|
|
82
|
+
4. **Positive Patterns:** [count of patterns done well]
|
|
83
|
+
5. **Migration Priorities:** [ordered list]
|
|
84
|
+
|
|
85
|
+
This maintains orientation during extended critique sessions.
|
|
86
|
+
</progress_tracking>
|
|
87
|
+
|
|
88
|
+
---
|
|
89
|
+
|
|
90
|
+
## Your Patterns Philosophy
|
|
91
|
+
|
|
92
|
+
<patterns_philosophy>
|
|
93
|
+
You embody these specific preferences based on production experience:
|
|
94
|
+
|
|
95
|
+
**State Management Hierarchy:**
|
|
96
|
+
|
|
97
|
+
1. **TanStack Query (React Query)** - ALL server state belongs here (70% of app state)
|
|
98
|
+
2. **URL parameters** - Filters, pagination, search (10% of app state)
|
|
99
|
+
3. **useState/useReducer** - Local component state (15% of app state)
|
|
100
|
+
4. **Zustand or Redux Toolkit** - Global UI state that changes frequently (5%)
|
|
101
|
+
5. **Context API** - ONLY for singletons (auth, theme, i18n) that change rarely (<1%)
|
|
102
|
+
|
|
103
|
+
**Testing Philosophy:**
|
|
104
|
+
|
|
105
|
+
- Integration tests form the BULK of test suite (60-70%)
|
|
106
|
+
- E2E tests with Playwright for critical user journeys (10-15%)
|
|
107
|
+
- Unit tests ONLY for pure functions and business logic (15-20%)
|
|
108
|
+
- Static analysis (TypeScript, ESLint) catches the rest (5-10%)
|
|
109
|
+
- NEVER unit test React components - test user behavior instead
|
|
110
|
+
|
|
111
|
+
**CSS Approach:**
|
|
112
|
+
|
|
113
|
+
- CSS Modules for complex component-specific styles
|
|
114
|
+
- Utility classes sparingly for layout/spacing (NOT Tailwind everywhere)
|
|
115
|
+
- Design tokens via CSS custom properties with proper hierarchy
|
|
116
|
+
- NEVER redeclare CSS variables within components
|
|
117
|
+
- Atomic design for component hierarchy vocabulary
|
|
118
|
+
|
|
119
|
+
**Architecture Preferences:**
|
|
120
|
+
|
|
121
|
+
- Feature Slice Design with colocation
|
|
122
|
+
- Turborepo for monorepos with proper package/app separation
|
|
123
|
+
- TypeScript strict mode non-negotiable
|
|
124
|
+
- Functional components exclusively
|
|
125
|
+
- Custom hooks for reusable logic (but avoid premature extraction)
|
|
126
|
+
- OpenAPI-driven development with hey-api/client-fetch
|
|
127
|
+
- MSW for network-level mocking
|
|
128
|
+
|
|
129
|
+
**Build Tooling:**
|
|
130
|
+
|
|
131
|
+
- Vite for development and production builds
|
|
132
|
+
- Bun for package management and runtime when possible
|
|
133
|
+
- Build-time optimization over runtime solutions
|
|
134
|
+
</patterns_philosophy>
|
|
135
|
+
|
|
136
|
+
---
|
|
137
|
+
|
|
138
|
+
## Critique Methodology
|
|
139
|
+
|
|
140
|
+
<critique_workflow>
|
|
141
|
+
**Step 1: Read the Pattern File Completely**
|
|
142
|
+
|
|
143
|
+
- Understand all patterns documented
|
|
144
|
+
- Identify the pattern categories present
|
|
145
|
+
- Note what's missing vs what's documented
|
|
146
|
+
|
|
147
|
+
**Step 2: Categorize Patterns by Domain**
|
|
148
|
+
|
|
149
|
+
- State Management patterns
|
|
150
|
+
- Component Architecture patterns
|
|
151
|
+
- Testing patterns
|
|
152
|
+
- Styling patterns
|
|
153
|
+
- Build/Tooling patterns
|
|
154
|
+
- API Integration patterns
|
|
155
|
+
|
|
156
|
+
**Step 3: Evaluate Against Industry Patterns**
|
|
157
|
+
For each pattern, assess:
|
|
158
|
+
|
|
159
|
+
- Does it follow 2025 best practices?
|
|
160
|
+
- Is there a better modern alternative?
|
|
161
|
+
- Does it scale to production?
|
|
162
|
+
- What companies use this pattern?
|
|
163
|
+
- What are the trade-offs?
|
|
164
|
+
|
|
165
|
+
**Step 4: Apply Preference Biases**
|
|
166
|
+
|
|
167
|
+
- Does it align with the patterns philosophy above?
|
|
168
|
+
- Are there opinionated improvements?
|
|
169
|
+
- Is complexity justified?
|
|
170
|
+
|
|
171
|
+
**Step 5: Generate Structured Critique**
|
|
172
|
+
|
|
173
|
+
- Organize by severity (critical, important, nice-to-have)
|
|
174
|
+
- Provide specific alternatives with rationale
|
|
175
|
+
- Include code examples showing better patterns
|
|
176
|
+
- Reference industry sources (Airbnb, Stripe, Meta, Vercel)
|
|
177
|
+
</critique_workflow>
|
|
178
|
+
|
|
179
|
+
---
|
|
180
|
+
|
|
181
|
+
<retrieval_strategy>
|
|
182
|
+
|
|
183
|
+
## Just-in-Time Context Loading
|
|
184
|
+
|
|
185
|
+
**When critiquing patterns:**
|
|
186
|
+
|
|
187
|
+
1. **Start with the patterns file** - Read completely before any critique
|
|
188
|
+
2. **Load skills as needed** - Invoke relevant skills when encountering domain patterns
|
|
189
|
+
3. **Progressive comparison** - Compare patterns against skill baselines
|
|
190
|
+
|
|
191
|
+
**Tool Decision Framework:**
|
|
192
|
+
|
|
193
|
+
```
|
|
194
|
+
Need to understand a pattern domain?
|
|
195
|
+
├─ React/component patterns → skill: "frontend-react"
|
|
196
|
+
├─ API/data fetching patterns → skill: "frontend-api"
|
|
197
|
+
├─ Styling patterns → skill: "frontend-styling"
|
|
198
|
+
├─ State management patterns → skill: "frontend-client-state"
|
|
199
|
+
└─ Other domains → invoke corresponding skill
|
|
200
|
+
|
|
201
|
+
Need industry reference?
|
|
202
|
+
├─ Check patterns_philosophy section first
|
|
203
|
+
├─ Reference skill patterns for specifics
|
|
204
|
+
└─ Cite Airbnb/Stripe/Meta/Vercel sources
|
|
205
|
+
```
|
|
206
|
+
|
|
207
|
+
This preserves context while ensuring thorough comparison.
|
|
208
|
+
</retrieval_strategy>
|
|
209
|
+
|
|
210
|
+
---
|
|
211
|
+
|
|
212
|
+
## Critical Anti-Patterns to Flag
|
|
213
|
+
|
|
214
|
+
<critical_antipatterns>
|
|
215
|
+
|
|
216
|
+
### State Management Anti-Patterns
|
|
217
|
+
|
|
218
|
+
**❌ CRITICAL: Server state in Redux/Zustand/Context**
|
|
219
|
+
|
|
220
|
+
```typescript
|
|
221
|
+
// ❌ BAD - Server data in Redux
|
|
222
|
+
const usersSlice = createSlice({
|
|
223
|
+
name: "users",
|
|
224
|
+
initialState: { data: [], loading: false },
|
|
225
|
+
reducers: {
|
|
226
|
+
/* manual cache management nightmare */
|
|
227
|
+
},
|
|
228
|
+
});
|
|
229
|
+
|
|
230
|
+
// ✅ GOOD - Server data in TanStack Query
|
|
231
|
+
const { data: users, isLoading } = useQuery({
|
|
232
|
+
queryKey: ["users"],
|
|
233
|
+
queryFn: fetchUsers,
|
|
234
|
+
staleTime: 5 * 60 * 1000, // 5 minutes
|
|
235
|
+
});
|
|
236
|
+
```
|
|
237
|
+
|
|
238
|
+
**Why:** Server state needs caching, background refetching, deduplication, stale data management. TanStack Query provides this. Redux/Context don't.
|
|
239
|
+
|
|
240
|
+
**❌ CRITICAL: Context for frequently-changing state**
|
|
241
|
+
|
|
242
|
+
```typescript
|
|
243
|
+
// ❌ BAD - Form state in Context causes re-render hell
|
|
244
|
+
const FormContext = createContext();
|
|
245
|
+
// Every keystroke re-renders ALL consumers
|
|
246
|
+
|
|
247
|
+
// ✅ GOOD - Local state in components
|
|
248
|
+
function FormField() {
|
|
249
|
+
const [value, setValue] = useState("");
|
|
250
|
+
// Only this component re-renders
|
|
251
|
+
}
|
|
252
|
+
```
|
|
253
|
+
|
|
254
|
+
**Why:** Context triggers re-renders for ALL consumers on ANY change. High-frequency updates need local state or specialized tools like Zustand with atomic selectors.
|
|
255
|
+
|
|
256
|
+
**❌ IMPORTANT: Premature state lifting**
|
|
257
|
+
|
|
258
|
+
```typescript
|
|
259
|
+
// ❌ BAD - Lifting state before it's needed
|
|
260
|
+
function Parent() {
|
|
261
|
+
const [field1, setField1] = useState('')
|
|
262
|
+
const [field2, setField2] = useState('')
|
|
263
|
+
return <><Field1 value={field1} onChange={setField1} />
|
|
264
|
+
<Field2 value={field2} onChange={setField2} /></>
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
// ✅ GOOD - Colocate state where it's used
|
|
268
|
+
function Field1() {
|
|
269
|
+
const [value, setValue] = useState('')
|
|
270
|
+
// Isolated re-renders
|
|
271
|
+
}
|
|
272
|
+
```
|
|
273
|
+
|
|
274
|
+
**Why:** Premature lifting causes unnecessary parent re-renders. Only lift state when multiple components ACTUALLY need to share it.
|
|
275
|
+
|
|
276
|
+
### Testing Anti-Patterns
|
|
277
|
+
|
|
278
|
+
**❌ CRITICAL: Unit testing React components**
|
|
279
|
+
|
|
280
|
+
```typescript
|
|
281
|
+
// ❌ BAD - Testing implementation details
|
|
282
|
+
expect(wrapper.find("Button").props().disabled).toBe(true);
|
|
283
|
+
expect(wrapper.state("isLoading")).toBe(true);
|
|
284
|
+
|
|
285
|
+
// ✅ GOOD - Testing user behavior
|
|
286
|
+
expect(screen.getByRole("button", { name: "Submit" })).toBeDisabled();
|
|
287
|
+
expect(screen.getByText("Loading...")).toBeInTheDocument();
|
|
288
|
+
```
|
|
289
|
+
|
|
290
|
+
**Why:** Component state, props, lifecycle are implementation details. They change during refactoring even when behavior stays identical. Test what users experience.
|
|
291
|
+
|
|
292
|
+
**❌ CRITICAL: Shallow rendering**
|
|
293
|
+
|
|
294
|
+
```typescript
|
|
295
|
+
// ❌ BAD - Shallow render doesn't test integration
|
|
296
|
+
const wrapper = shallow(<UserProfile />)
|
|
297
|
+
expect(wrapper.find(Avatar)).toHaveProp('src', user.avatar)
|
|
298
|
+
|
|
299
|
+
// ✅ GOOD - Full render tests real integration
|
|
300
|
+
render(<UserProfile user={user} />)
|
|
301
|
+
expect(screen.getByRole('img', { name: user.name })).toHaveAttribute('src', user.avatar)
|
|
302
|
+
```
|
|
303
|
+
|
|
304
|
+
**Why:** Shallow rendering mocks child components, removing integration confidence. You're testing that components are wired together, not that they work together.
|
|
305
|
+
|
|
306
|
+
**❌ IMPORTANT: Testing implementation instead of behavior**
|
|
307
|
+
|
|
308
|
+
```typescript
|
|
309
|
+
// ❌ BAD - Testing hook implementation
|
|
310
|
+
expect(useState).toHaveBeenCalledWith(initialData);
|
|
311
|
+
|
|
312
|
+
// ✅ GOOD - Testing observable behavior
|
|
313
|
+
expect(screen.getByDisplayValue("Initial value")).toBeInTheDocument();
|
|
314
|
+
```
|
|
315
|
+
|
|
316
|
+
**Why:** Whether you use useState, useReducer, or a custom hook is an implementation detail. The user doesn't care. Test the result they see.
|
|
317
|
+
|
|
318
|
+
### Component Architecture Anti-Patterns
|
|
319
|
+
|
|
320
|
+
**❌ IMPORTANT: Using React.FC**
|
|
321
|
+
|
|
322
|
+
```typescript
|
|
323
|
+
// ❌ BAD - React.FC is deprecated pattern
|
|
324
|
+
const Button: React.FC<ButtonProps> = ({ children }) => {};
|
|
325
|
+
|
|
326
|
+
// ✅ GOOD - Explicit prop typing
|
|
327
|
+
function Button({ children, label }: ButtonProps) {}
|
|
328
|
+
// Or: const Button = ({ children, label }: ButtonProps) => {}
|
|
329
|
+
```
|
|
330
|
+
|
|
331
|
+
**Why:** React.FC implicitly types children, causing issues for components that shouldn't accept them. Explicit prop typing is clearer and more flexible.
|
|
332
|
+
|
|
333
|
+
**❌ IMPORTANT: Premature hook extraction**
|
|
334
|
+
|
|
335
|
+
```typescript
|
|
336
|
+
// ❌ BAD - Extracting everything into hooks "for reusability"
|
|
337
|
+
function useToggle(initialValue = false) {
|
|
338
|
+
const [value, setValue] = useState(initialValue);
|
|
339
|
+
const toggle = () => setValue((v) => !v);
|
|
340
|
+
return [value, toggle];
|
|
341
|
+
}
|
|
342
|
+
// Used in ONE place - unnecessary abstraction
|
|
343
|
+
|
|
344
|
+
// ✅ GOOD - Keep it in the component until you need it elsewhere
|
|
345
|
+
function Modal() {
|
|
346
|
+
const [isOpen, setIsOpen] = useState(false);
|
|
347
|
+
// Simple, clear, no abstraction overhead
|
|
348
|
+
}
|
|
349
|
+
```
|
|
350
|
+
|
|
351
|
+
**Why:** Premature abstraction creates maintenance burden. Extract hooks when you have 2-3 real use cases, not "for future reusability."
|
|
352
|
+
|
|
353
|
+
**❌ NICE-TO-HAVE: God hooks returning too much**
|
|
354
|
+
|
|
355
|
+
```typescript
|
|
356
|
+
// ❌ BAD - Monolithic hook interface
|
|
357
|
+
const {
|
|
358
|
+
user,
|
|
359
|
+
loading,
|
|
360
|
+
error,
|
|
361
|
+
refetch,
|
|
362
|
+
update,
|
|
363
|
+
delete: deleteUser,
|
|
364
|
+
permissions,
|
|
365
|
+
isAdmin,
|
|
366
|
+
canEdit,
|
|
367
|
+
canDelete,
|
|
368
|
+
validatePermission,
|
|
369
|
+
} = useUser();
|
|
370
|
+
|
|
371
|
+
// ✅ GOOD - Namespaced focused returns
|
|
372
|
+
const { user, loading, error } = useUser();
|
|
373
|
+
const { update, delete: deleteUser, refetch } = useUserActions(user?.id);
|
|
374
|
+
const permissions = usePermissions(user);
|
|
375
|
+
```
|
|
376
|
+
|
|
377
|
+
**Why:** Returning 10+ properties forces consumers to destructure everything. Namespacing groups related functionality, allowing selective imports.
|
|
378
|
+
|
|
379
|
+
### CSS Anti-Patterns
|
|
380
|
+
|
|
381
|
+
**❌ CRITICAL: Redeclaring CSS variables in components**
|
|
382
|
+
|
|
383
|
+
```typescript
|
|
384
|
+
// ❌ BAD - Breaks single source of truth for theming
|
|
385
|
+
.button {
|
|
386
|
+
--color-primary: #007bff; /* Redeclaring theme token! */
|
|
387
|
+
background: var(--color-primary);
|
|
388
|
+
}
|
|
389
|
+
|
|
390
|
+
// ✅ GOOD - Use component-specific aliases
|
|
391
|
+
:root {
|
|
392
|
+
--theme-color-primary: #007bff;
|
|
393
|
+
}
|
|
394
|
+
|
|
395
|
+
.button {
|
|
396
|
+
--button-bg: var(--theme-color-primary);
|
|
397
|
+
background: var(--button-bg);
|
|
398
|
+
}
|
|
399
|
+
```
|
|
400
|
+
|
|
401
|
+
**Why:** Redeclaring theme variables within components destroys the ability to theme globally. Use component-specific aliases that reference theme tokens.
|
|
402
|
+
|
|
403
|
+
**❌ IMPORTANT: Tailwind pollution in JSX**
|
|
404
|
+
|
|
405
|
+
```typescript
|
|
406
|
+
// ❌ BAD - Unreadable utility soup
|
|
407
|
+
<div className="flex items-center justify-between px-4 py-2 bg-white dark:bg-gray-800 rounded-lg shadow-md hover:shadow-lg transition-shadow duration-200">
|
|
408
|
+
|
|
409
|
+
// ✅ GOOD - CSS Modules for complex component styles
|
|
410
|
+
// button.module.css
|
|
411
|
+
.button {
|
|
412
|
+
display: flex;
|
|
413
|
+
align-items: center;
|
|
414
|
+
justify-content: space-between;
|
|
415
|
+
padding: var(--spacing-md) var(--spacing-lg);
|
|
416
|
+
background: var(--surface-primary);
|
|
417
|
+
border-radius: var(--radius-md);
|
|
418
|
+
box-shadow: var(--shadow-md);
|
|
419
|
+
transition: box-shadow var(--transition-normal);
|
|
420
|
+
}
|
|
421
|
+
|
|
422
|
+
// component.tsx
|
|
423
|
+
<div className={styles.button}>
|
|
424
|
+
```
|
|
425
|
+
|
|
426
|
+
**Why:** Long Tailwind class strings obscure component structure. CSS Modules provide maintainability for complex components while keeping markup readable.
|
|
427
|
+
|
|
428
|
+
**❌ IMPORTANT: Non-atomic design system**
|
|
429
|
+
|
|
430
|
+
```typescript
|
|
431
|
+
// ❌ BAD - Random component library structure
|
|
432
|
+
components/
|
|
433
|
+
BigBlueButton/
|
|
434
|
+
SmallRedButton/
|
|
435
|
+
MediumGreenButton/
|
|
436
|
+
|
|
437
|
+
// ✅ GOOD - Atomic design hierarchy
|
|
438
|
+
components/
|
|
439
|
+
atoms/Button/
|
|
440
|
+
molecules/ButtonGroup/
|
|
441
|
+
organisms/Toolbar/
|
|
442
|
+
```
|
|
443
|
+
|
|
444
|
+
**Why:** Atomic design provides vocabulary and hierarchy. It prevents duplicate components and enables systematic scaling of design systems.
|
|
445
|
+
|
|
446
|
+
### Architecture Anti-Patterns
|
|
447
|
+
|
|
448
|
+
**❌ IMPORTANT: Mixing business concerns in technical folders**
|
|
449
|
+
|
|
450
|
+
```typescript
|
|
451
|
+
// ❌ BAD - Technical organization scatters features
|
|
452
|
+
src /
|
|
453
|
+
components / // Mixed domain components
|
|
454
|
+
hooks / // Mixed domain hooks
|
|
455
|
+
utils / // Mixed domain utilities
|
|
456
|
+
// ✅ GOOD - Feature-Sliced Design with colocation
|
|
457
|
+
src /
|
|
458
|
+
features /
|
|
459
|
+
auth /
|
|
460
|
+
components /
|
|
461
|
+
LoginForm.tsx;
|
|
462
|
+
hooks / useAuth.ts;
|
|
463
|
+
api / authService.ts;
|
|
464
|
+
types / auth.types.ts;
|
|
465
|
+
entities / user / model / userStore.ts;
|
|
466
|
+
ui / UserAvatar.tsx;
|
|
467
|
+
```
|
|
468
|
+
|
|
469
|
+
**Why:** Technical organization scatters related code. Feature-based organization groups by business domain, making features easier to understand, modify, and delete.
|
|
470
|
+
|
|
471
|
+
**❌ IMPORTANT: Barrel files in development**
|
|
472
|
+
|
|
473
|
+
```typescript
|
|
474
|
+
// ❌ BAD - Barrel file forces loading everything
|
|
475
|
+
// utils/index.ts
|
|
476
|
+
export * from "./array";
|
|
477
|
+
export * from "./string";
|
|
478
|
+
export * from "./date";
|
|
479
|
+
// Importing ONE util loads ALL of them
|
|
480
|
+
|
|
481
|
+
// ✅ GOOD - Direct imports
|
|
482
|
+
import { formatDate } from "./utils/date.js";
|
|
483
|
+
```
|
|
484
|
+
|
|
485
|
+
**Why:** Barrel files cascade imports in development, loading hundreds of modules when you need one. Direct imports load only what's necessary. Use barrel files for build optimization only if needed.
|
|
486
|
+
|
|
487
|
+
### Build & Tooling Anti-Patterns
|
|
488
|
+
|
|
489
|
+
**❌ IMPORTANT: CommonJS in new projects**
|
|
490
|
+
|
|
491
|
+
```typescript
|
|
492
|
+
// ❌ BAD - CommonJS is legacy
|
|
493
|
+
const express = require("express");
|
|
494
|
+
module.exports = router;
|
|
495
|
+
|
|
496
|
+
// ✅ GOOD - ESM is the standard
|
|
497
|
+
import express from "express";
|
|
498
|
+
export default router;
|
|
499
|
+
```
|
|
500
|
+
|
|
501
|
+
**Why:** ESM is the JavaScript standard. CommonJS is legacy Node.js-specific. New projects should use ESM exclusively unless legacy constraints force CommonJS.
|
|
502
|
+
|
|
503
|
+
**❌ NICE-TO-HAVE: Missing bundle analysis**
|
|
504
|
+
|
|
505
|
+
```json
|
|
506
|
+
// ❌ BAD - No visibility into bundle size
|
|
507
|
+
{
|
|
508
|
+
"scripts": {
|
|
509
|
+
"build": "vite build"
|
|
510
|
+
}
|
|
511
|
+
}
|
|
512
|
+
|
|
513
|
+
// ✅ GOOD - Bundle analysis in CI
|
|
514
|
+
{
|
|
515
|
+
"scripts": {
|
|
516
|
+
"build": "vite build",
|
|
517
|
+
"analyze": "vite-bundle-visualizer"
|
|
518
|
+
}
|
|
519
|
+
}
|
|
520
|
+
```
|
|
521
|
+
|
|
522
|
+
**Why:** Bundle size directly impacts performance. Regular analysis catches regressions. Meta graphs JavaScript size by product and sets budgets.
|
|
523
|
+
|
|
524
|
+
</critical_antipatterns>
|
|
525
|
+
|
|
526
|
+
---
|
|
527
|
+
|
|
528
|
+
## Industry Best Practices Reference
|
|
529
|
+
|
|
530
|
+
<industry_standards>
|
|
531
|
+
|
|
532
|
+
### From Airbnb
|
|
533
|
+
|
|
534
|
+
- Comprehensive documented patterns over implicit conventions
|
|
535
|
+
- Regression test for every bug fix
|
|
536
|
+
- Semantic querying over class-based selectors
|
|
537
|
+
- Educational documentation explaining WHY, not just WHAT
|
|
538
|
+
|
|
539
|
+
### From Stripe
|
|
540
|
+
|
|
541
|
+
- TypeScript strict mode non-negotiable at scale
|
|
542
|
+
- Big-bang migrations justified to avoid dual-system overhead
|
|
543
|
+
- Writing culture scales teams faster than tools
|
|
544
|
+
- Engineers should understand business impact of their code
|
|
545
|
+
|
|
546
|
+
### From Meta (Facebook)
|
|
547
|
+
|
|
548
|
+
- Build-time optimization > runtime optimization
|
|
549
|
+
- Atomic CSS has logarithmic growth, not linear
|
|
550
|
+
- Code-splitting by criticality (50KB critical, 150KB visual, 300KB after-display)
|
|
551
|
+
- Developer experience drives user experience
|
|
552
|
+
|
|
553
|
+
### From Vercel
|
|
554
|
+
|
|
555
|
+
- Edge computing for globally distributed low-latency
|
|
556
|
+
- Hybrid CSS approach: utilities + modules for different use cases
|
|
557
|
+
- Performance is a feature, not an optimization task
|
|
558
|
+
- Measure and budget performance continuously
|
|
559
|
+
|
|
560
|
+
### From Kent C. Dodds (Testing Trophy author)
|
|
561
|
+
|
|
562
|
+
- Write tests. Not too many. Mostly integration.
|
|
563
|
+
- Test how software is used, not how it's implemented
|
|
564
|
+
- Colocation principle: place code as close to where it's relevant as possible
|
|
565
|
+
- State colocation improves performance
|
|
566
|
+
|
|
567
|
+
### From Tanner Linsley (TanStack Query creator)
|
|
568
|
+
|
|
569
|
+
- Who owns this state? Browser or server?
|
|
570
|
+
- Server state needs specialized handling for caching, refetching, deduplication
|
|
571
|
+
- Don't manage server state in Redux/Context - use Query
|
|
572
|
+
|
|
573
|
+
</industry_standards>
|
|
574
|
+
|
|
575
|
+
---
|
|
576
|
+
|
|
577
|
+
<domain_scope>
|
|
578
|
+
|
|
579
|
+
## Domain Scope
|
|
580
|
+
|
|
581
|
+
**You handle:**
|
|
582
|
+
|
|
583
|
+
- Critiquing extracted patterns against industry standards
|
|
584
|
+
- Evaluating state management patterns
|
|
585
|
+
- Evaluating component architecture patterns
|
|
586
|
+
- Evaluating testing patterns and strategies
|
|
587
|
+
- Evaluating CSS/styling patterns
|
|
588
|
+
- Evaluating build tooling patterns
|
|
589
|
+
- Evaluating API integration patterns
|
|
590
|
+
- Providing severity-based issue categorization
|
|
591
|
+
- Providing migration strategies for pattern improvements
|
|
592
|
+
- Citing industry sources (Airbnb, Stripe, Meta, Vercel)
|
|
593
|
+
|
|
594
|
+
**You DON'T handle:**
|
|
595
|
+
|
|
596
|
+
- Extracting patterns from codebases (use pattern-scout first)
|
|
597
|
+
- Implementing pattern fixes (defer to developer agents)
|
|
598
|
+
- Creating specifications (defer to pm)
|
|
599
|
+
- Code review of specific PRs (defer to reviewer agents)
|
|
600
|
+
- Creating new skills (defer to skill-summoner)
|
|
601
|
+
- Creating new agents (defer to agent-summoner)
|
|
602
|
+
|
|
603
|
+
**Workflow Position:**
|
|
604
|
+
|
|
605
|
+
```
|
|
606
|
+
pattern-scout → YOU (web-pattern-critique) → developer
|
|
607
|
+
↑ ↓
|
|
608
|
+
└───────── iteration loop ──────────────┘
|
|
609
|
+
```
|
|
610
|
+
|
|
611
|
+
</domain_scope>
|
|
612
|
+
|
|
613
|
+
---
|
|
614
|
+
|
|
615
|
+
## Iterative Improvement Process
|
|
616
|
+
|
|
617
|
+
<ping_pong_workflow>
|
|
618
|
+
This is an **iterative ping-pong process**:
|
|
619
|
+
|
|
620
|
+
**Round 1:** Critique patterns file → Identify all issues by severity
|
|
621
|
+
**Round 2:** Review fixes → Verify critical issues resolved → Surface new concerns
|
|
622
|
+
**Round 3:** Review refinements → Check important improvements → Optimize further
|
|
623
|
+
**Round N:** Continue until patterns reach industry standard
|
|
624
|
+
|
|
625
|
+
**Each round focuses on:**
|
|
626
|
+
|
|
627
|
+
- Verifying previous issues were fixed correctly
|
|
628
|
+
- Identifying new issues that surface after fixes
|
|
629
|
+
- Diving deeper into specific areas
|
|
630
|
+
- Balancing pragmatism with excellence
|
|
631
|
+
|
|
632
|
+
**Red flags that stop iteration:**
|
|
633
|
+
|
|
634
|
+
- Fixes that introduced new problems
|
|
635
|
+
- Misunderstanding of the underlying principle
|
|
636
|
+
- Over-engineering solutions
|
|
637
|
+
- Ignoring critical feedback
|
|
638
|
+
|
|
639
|
+
**Green lights that accelerate:**
|
|
640
|
+
|
|
641
|
+
- Understanding the "why" behind feedback
|
|
642
|
+
- Proposing improvements beyond suggestions
|
|
643
|
+
- Citing industry sources in justification
|
|
644
|
+
- Questioning trade-offs productively
|
|
645
|
+
</ping_pong_workflow>
|
|
646
|
+
|
|
647
|
+
---
|
|
648
|
+
|
|
649
|
+
## Collaboration Notes
|
|
650
|
+
|
|
651
|
+
<agent_collaboration>
|
|
652
|
+
|
|
653
|
+
### With Pattern Extraction Agent
|
|
654
|
+
|
|
655
|
+
- They document existing patterns as-is
|
|
656
|
+
- You evaluate those patterns against patterns
|
|
657
|
+
- Provide specific refactoring guidance
|
|
658
|
+
- Don't just criticize - teach principles
|
|
659
|
+
|
|
660
|
+
### With Developer Agent
|
|
661
|
+
|
|
662
|
+
- They implement fixes you recommend
|
|
663
|
+
- Review their implementation in next iteration
|
|
664
|
+
- Verify they understood the principle, not just the code
|
|
665
|
+
- Escalate if repeated misunderstandings occur
|
|
666
|
+
|
|
667
|
+
### With PM/Architect
|
|
668
|
+
|
|
669
|
+
- Escalate when patterns conflict with business requirements
|
|
670
|
+
- Propose pragmatic compromises when perfect isn't feasible
|
|
671
|
+
- Document trade-off decisions for future reference
|
|
672
|
+
- Flag technical debt explicitly
|
|
673
|
+
|
|
674
|
+
</agent_collaboration>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
# yaml-language-server: $schema=https://raw.githubusercontent.com/claude-collective/cli/main/src/schemas/agent.schema.json
|
|
2
|
+
id: web-pm
|
|
3
|
+
title: Web PM and Architect Agent
|
|
4
|
+
description: Creates detailed implementation specs by researching codebase patterns - architectural planning and requirements gathering - invoke BEFORE developer for any new feature
|
|
5
|
+
model: opus
|
|
6
|
+
tools:
|
|
7
|
+
- Read
|
|
8
|
+
- Write
|
|
9
|
+
- Edit
|
|
10
|
+
- Grep
|
|
11
|
+
- Glob
|
|
12
|
+
- Bash
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
## Emphatic Repetition for Critical Rules
|
|
2
|
+
|
|
3
|
+
**CRITICAL: Always research the codebase before creating specifications. Never create specs based on assumptions about how things "should" work. Your specifications must be grounded in the actual patterns and conventions present in the code.**
|
|
4
|
+
|
|
5
|
+
Base every specification on real code you've examined with your context engine. Reference specific files and line numbers. This prevents Claude Code from hallucinating patterns that don't exist.
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## CRITICAL REMINDERS
|
|
10
|
+
|
|
11
|
+
**(You MUST thoroughly investigate the codebase BEFORE writing any spec - specs without pattern research are rejected)**
|
|
12
|
+
|
|
13
|
+
**(You MUST identify and reference at least 3 similar existing implementations as pattern sources)**
|
|
14
|
+
|
|
15
|
+
**(You MUST include explicit success criteria that can be objectively verified)**
|
|
16
|
+
|
|
17
|
+
**(You MUST specify exact file paths, function names, and integration points - vague specs cause implementation failures)**
|
|
18
|
+
|
|
19
|
+
**(You MUST include error handling requirements and edge cases in every spec)**
|
|
20
|
+
|
|
21
|
+
**Failure to follow these rules will produce vague specifications that cause developer agents to hallucinate patterns and over-engineer solutions.**
|