flyee 0.1.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 (302) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +134 -0
  3. package/bin/install.js +357 -0
  4. package/bridge/bridge.py +1780 -0
  5. package/bridge/local_tracker.py +722 -0
  6. package/core/agents/backend-specialist.md +266 -0
  7. package/core/agents/code-archaeologist.md +106 -0
  8. package/core/agents/database-architect.md +226 -0
  9. package/core/agents/debugger.md +225 -0
  10. package/core/agents/devops-engineer.md +323 -0
  11. package/core/agents/documentation-writer.md +104 -0
  12. package/core/agents/explorer-agent.md +73 -0
  13. package/core/agents/frontend-specialist.md +743 -0
  14. package/core/agents/game-developer.md +162 -0
  15. package/core/agents/mobile-developer.md +377 -0
  16. package/core/agents/orchestrator.md +416 -0
  17. package/core/agents/penetration-tester.md +188 -0
  18. package/core/agents/performance-optimizer.md +187 -0
  19. package/core/agents/product-manager.md +112 -0
  20. package/core/agents/product-owner.md +95 -0
  21. package/core/agents/project-planner.md +470 -0
  22. package/core/agents/qa-automation-engineer.md +103 -0
  23. package/core/agents/security-auditor.md +170 -0
  24. package/core/agents/seo-specialist.md +111 -0
  25. package/core/agents/stitch-designer.md +190 -0
  26. package/core/agents/tdd-reviewer.md +282 -0
  27. package/core/agents/test-engineer.md +158 -0
  28. package/core/scripts/auto_preview.py +148 -0
  29. package/core/scripts/checklist.py +243 -0
  30. package/core/scripts/cost_report.py +149 -0
  31. package/core/scripts/doc-sync-check.py +461 -0
  32. package/core/scripts/parse_user_stories.py +79 -0
  33. package/core/scripts/prepare_notion_updates.py +172 -0
  34. package/core/scripts/print_create_payload.py +18 -0
  35. package/core/scripts/session_manager.py +120 -0
  36. package/core/scripts/task_complete.py +127 -0
  37. package/core/scripts/verify_all.py +327 -0
  38. package/core/skills/analytics-strategy/SKILL.md +128 -0
  39. package/core/skills/api-patterns/SKILL.md +81 -0
  40. package/core/skills/api-patterns/api-style.md +42 -0
  41. package/core/skills/api-patterns/auth.md +24 -0
  42. package/core/skills/api-patterns/documentation.md +26 -0
  43. package/core/skills/api-patterns/graphql.md +41 -0
  44. package/core/skills/api-patterns/rate-limiting.md +31 -0
  45. package/core/skills/api-patterns/response.md +37 -0
  46. package/core/skills/api-patterns/rest.md +40 -0
  47. package/core/skills/api-patterns/scripts/api_validator.py +211 -0
  48. package/core/skills/api-patterns/security-testing.md +122 -0
  49. package/core/skills/api-patterns/trpc.md +41 -0
  50. package/core/skills/api-patterns/versioning.md +22 -0
  51. package/core/skills/app-builder/SKILL.md +75 -0
  52. package/core/skills/app-builder/agent-coordination.md +71 -0
  53. package/core/skills/app-builder/feature-building.md +53 -0
  54. package/core/skills/app-builder/project-detection.md +34 -0
  55. package/core/skills/app-builder/scaffolding.md +118 -0
  56. package/core/skills/app-builder/tech-stack.md +40 -0
  57. package/core/skills/app-builder/templates/SKILL.md +39 -0
  58. package/core/skills/app-builder/templates/astro-static/TEMPLATE.md +76 -0
  59. package/core/skills/app-builder/templates/chrome-extension/TEMPLATE.md +92 -0
  60. package/core/skills/app-builder/templates/cli-tool/TEMPLATE.md +88 -0
  61. package/core/skills/app-builder/templates/electron-desktop/TEMPLATE.md +88 -0
  62. package/core/skills/app-builder/templates/express-api/TEMPLATE.md +83 -0
  63. package/core/skills/app-builder/templates/flutter-app/TEMPLATE.md +90 -0
  64. package/core/skills/app-builder/templates/monorepo-turborepo/TEMPLATE.md +90 -0
  65. package/core/skills/app-builder/templates/nextjs-fullstack/TEMPLATE.md +82 -0
  66. package/core/skills/app-builder/templates/nextjs-saas/TEMPLATE.md +100 -0
  67. package/core/skills/app-builder/templates/nextjs-static/TEMPLATE.md +106 -0
  68. package/core/skills/app-builder/templates/nuxt-app/TEMPLATE.md +101 -0
  69. package/core/skills/app-builder/templates/python-fastapi/TEMPLATE.md +83 -0
  70. package/core/skills/app-builder/templates/react-native-app/TEMPLATE.md +93 -0
  71. package/core/skills/architecture/SKILL.md +55 -0
  72. package/core/skills/architecture/context-discovery.md +43 -0
  73. package/core/skills/architecture/examples.md +94 -0
  74. package/core/skills/architecture/pattern-selection.md +68 -0
  75. package/core/skills/architecture/patterns-reference.md +50 -0
  76. package/core/skills/architecture/trade-off-analysis.md +77 -0
  77. package/core/skills/atomic-design/SKILL.md +282 -0
  78. package/core/skills/atomic-design/references/classification-guide.md +132 -0
  79. package/core/skills/atomic-design/references/quality-checklist.md +60 -0
  80. package/core/skills/atomic-design/references/stacks/stack-blade.md +254 -0
  81. package/core/skills/atomic-design/references/stacks/stack-nextjs.md +272 -0
  82. package/core/skills/atomic-design/references/stacks/stack-react.md +239 -0
  83. package/core/skills/atomic-design/references/stacks/stack-vue.md +224 -0
  84. package/core/skills/bash-linux/SKILL.md +199 -0
  85. package/core/skills/behavioral-modes/SKILL.md +242 -0
  86. package/core/skills/brainstorming/SKILL.md +163 -0
  87. package/core/skills/brainstorming/dynamic-questioning.md +373 -0
  88. package/core/skills/checkpointing-patterns/SKILL.md +163 -0
  89. package/core/skills/clean-code/SKILL.md +201 -0
  90. package/core/skills/code-review-checklist/SKILL.md +109 -0
  91. package/core/skills/code-truth-validation/SKILL.md +149 -0
  92. package/core/skills/component-library-discovery/SKILL.md +154 -0
  93. package/core/skills/content-strategy/SKILL.md +222 -0
  94. package/core/skills/context-budget/SKILL.md +155 -0
  95. package/core/skills/context-gathering-patterns/SKILL.md +278 -0
  96. package/core/skills/cost-tracking/SKILL.md +206 -0
  97. package/core/skills/database-design/SKILL.md +52 -0
  98. package/core/skills/database-design/database-selection.md +43 -0
  99. package/core/skills/database-design/indexing.md +39 -0
  100. package/core/skills/database-design/migrations.md +48 -0
  101. package/core/skills/database-design/optimization.md +36 -0
  102. package/core/skills/database-design/orm-selection.md +30 -0
  103. package/core/skills/database-design/schema-design.md +56 -0
  104. package/core/skills/database-design/scripts/schema_validator.py +172 -0
  105. package/core/skills/deployment-procedures/SKILL.md +295 -0
  106. package/core/skills/design-md/README.md +34 -0
  107. package/core/skills/design-md/SKILL.md +172 -0
  108. package/core/skills/design-md/examples/DESIGN.md +154 -0
  109. package/core/skills/design-system-enforcement/SKILL.md +339 -0
  110. package/core/skills/doc.md +177 -0
  111. package/core/skills/document-registry/SKILL.md +130 -0
  112. package/core/skills/documentation-publishing/SKILL.md +174 -0
  113. package/core/skills/documentation-templates/SKILL.md +194 -0
  114. package/core/skills/enhance-prompt/README.md +34 -0
  115. package/core/skills/enhance-prompt/SKILL.md +204 -0
  116. package/core/skills/enhance-prompt/references/KEYWORDS.md +114 -0
  117. package/core/skills/frontend-design/SKILL.md +430 -0
  118. package/core/skills/frontend-design/animation-guide.md +331 -0
  119. package/core/skills/frontend-design/color-system.md +311 -0
  120. package/core/skills/frontend-design/decision-trees.md +418 -0
  121. package/core/skills/frontend-design/motion-graphics.md +306 -0
  122. package/core/skills/frontend-design/scripts/accessibility_checker.py +183 -0
  123. package/core/skills/frontend-design/scripts/ux_audit.py +722 -0
  124. package/core/skills/frontend-design/typography-system.md +345 -0
  125. package/core/skills/frontend-design/ux-psychology.md +541 -0
  126. package/core/skills/frontend-design/visual-effects.md +383 -0
  127. package/core/skills/game-development/2d-games/SKILL.md +119 -0
  128. package/core/skills/game-development/3d-games/SKILL.md +135 -0
  129. package/core/skills/game-development/SKILL.md +167 -0
  130. package/core/skills/game-development/game-art/SKILL.md +185 -0
  131. package/core/skills/game-development/game-audio/SKILL.md +190 -0
  132. package/core/skills/game-development/game-design/SKILL.md +129 -0
  133. package/core/skills/game-development/mobile-games/SKILL.md +108 -0
  134. package/core/skills/game-development/multiplayer/SKILL.md +132 -0
  135. package/core/skills/game-development/pc-games/SKILL.md +144 -0
  136. package/core/skills/game-development/vr-ar/SKILL.md +123 -0
  137. package/core/skills/game-development/web-games/SKILL.md +150 -0
  138. package/core/skills/geo-fundamentals/SKILL.md +156 -0
  139. package/core/skills/geo-fundamentals/scripts/geo_checker.py +289 -0
  140. package/core/skills/git-workflow/SKILL.md +263 -0
  141. package/core/skills/history-check-patterns/SKILL.md +125 -0
  142. package/core/skills/i18n-localization/SKILL.md +154 -0
  143. package/core/skills/i18n-localization/scripts/i18n_checker.py +241 -0
  144. package/core/skills/integration-completeness/SKILL.md +219 -0
  145. package/core/skills/intelligent-routing/SKILL.md +370 -0
  146. package/core/skills/lint-and-validate/SKILL.md +45 -0
  147. package/core/skills/lint-and-validate/scripts/lint_runner.py +173 -0
  148. package/core/skills/lint-and-validate/scripts/type_coverage.py +173 -0
  149. package/core/skills/local-verification/SKILL.md +195 -0
  150. package/core/skills/mcp-builder/SKILL.md +176 -0
  151. package/core/skills/mobile-design/SKILL.md +394 -0
  152. package/core/skills/mobile-design/decision-trees.md +516 -0
  153. package/core/skills/mobile-design/mobile-backend.md +491 -0
  154. package/core/skills/mobile-design/mobile-color-system.md +420 -0
  155. package/core/skills/mobile-design/mobile-debugging.md +122 -0
  156. package/core/skills/mobile-design/mobile-design-thinking.md +357 -0
  157. package/core/skills/mobile-design/mobile-navigation.md +458 -0
  158. package/core/skills/mobile-design/mobile-performance.md +767 -0
  159. package/core/skills/mobile-design/mobile-testing.md +356 -0
  160. package/core/skills/mobile-design/mobile-typography.md +433 -0
  161. package/core/skills/mobile-design/platform-android.md +666 -0
  162. package/core/skills/mobile-design/platform-ios.md +561 -0
  163. package/core/skills/mobile-design/scripts/mobile_audit.py +670 -0
  164. package/core/skills/mobile-design/touch-psychology.md +537 -0
  165. package/core/skills/nextjs-react-expert/1-async-eliminating-waterfalls.md +312 -0
  166. package/core/skills/nextjs-react-expert/2-bundle-bundle-size-optimization.md +240 -0
  167. package/core/skills/nextjs-react-expert/3-server-server-side-performance.md +490 -0
  168. package/core/skills/nextjs-react-expert/4-client-client-side-data-fetching.md +264 -0
  169. package/core/skills/nextjs-react-expert/5-rerender-re-render-optimization.md +581 -0
  170. package/core/skills/nextjs-react-expert/6-rendering-rendering-performance.md +432 -0
  171. package/core/skills/nextjs-react-expert/7-js-javascript-performance.md +684 -0
  172. package/core/skills/nextjs-react-expert/8-advanced-advanced-patterns.md +150 -0
  173. package/core/skills/nextjs-react-expert/SKILL.md +267 -0
  174. package/core/skills/nextjs-react-expert/scripts/convert_rules.py +222 -0
  175. package/core/skills/nextjs-react-expert/scripts/react_performance_checker.py +252 -0
  176. package/core/skills/nodejs-best-practices/SKILL.md +333 -0
  177. package/core/skills/notion-task-patterns/SKILL.md +2529 -0
  178. package/core/skills/page-specifications/SKILL.md +367 -0
  179. package/core/skills/parallel-agents/SKILL.md +175 -0
  180. package/core/skills/performance-profiling/SKILL.md +143 -0
  181. package/core/skills/performance-profiling/scripts/lighthouse_audit.py +76 -0
  182. package/core/skills/plan-writing/SKILL.md +190 -0
  183. package/core/skills/powershell-windows/SKILL.md +167 -0
  184. package/core/skills/project-foundation/SKILL.md +117 -0
  185. package/core/skills/project-setup/SKILL.md +141 -0
  186. package/core/skills/project-tracking-patterns/SKILL.md +357 -0
  187. package/core/skills/project-type-discovery/SKILL.md +239 -0
  188. package/core/skills/python-patterns/SKILL.md +441 -0
  189. package/core/skills/qa-test-generation/SKILL.md +156 -0
  190. package/core/skills/react-components/README.md +36 -0
  191. package/core/skills/react-components/SKILL.md +47 -0
  192. package/core/skills/react-components/examples/gold-standard-card.tsx +80 -0
  193. package/core/skills/react-components/package-lock.json +231 -0
  194. package/core/skills/react-components/package.json +16 -0
  195. package/core/skills/react-components/resources/architecture-checklist.md +15 -0
  196. package/core/skills/react-components/resources/component-template.tsx +37 -0
  197. package/core/skills/react-components/resources/stitch-api-reference.md +14 -0
  198. package/core/skills/react-components/resources/style-guide.json +27 -0
  199. package/core/skills/react-components/scripts/fetch-stitch.sh +30 -0
  200. package/core/skills/react-components/scripts/validate.js +68 -0
  201. package/core/skills/red-team-tactics/SKILL.md +199 -0
  202. package/core/skills/remotion/README.md +105 -0
  203. package/core/skills/remotion/SKILL.md +393 -0
  204. package/core/skills/remotion/examples/WalkthroughComposition.tsx +78 -0
  205. package/core/skills/remotion/examples/screens.json +56 -0
  206. package/core/skills/remotion/resources/composition-checklist.md +124 -0
  207. package/core/skills/remotion/resources/screen-slide-template.tsx +123 -0
  208. package/core/skills/remotion/scripts/download-stitch-asset.sh +38 -0
  209. package/core/skills/seo-fundamentals/SKILL.md +129 -0
  210. package/core/skills/seo-fundamentals/scripts/seo_checker.py +219 -0
  211. package/core/skills/server-management/SKILL.md +161 -0
  212. package/core/skills/session-resilience/SKILL.md +199 -0
  213. package/core/skills/shadcn-ui/README.md +248 -0
  214. package/core/skills/shadcn-ui/SKILL.md +326 -0
  215. package/core/skills/shadcn-ui/examples/auth-layout.tsx +177 -0
  216. package/core/skills/shadcn-ui/examples/data-table.tsx +313 -0
  217. package/core/skills/shadcn-ui/examples/form-pattern.tsx +177 -0
  218. package/core/skills/shadcn-ui/resources/component-catalog.md +481 -0
  219. package/core/skills/shadcn-ui/resources/customization-guide.md +516 -0
  220. package/core/skills/shadcn-ui/resources/migration-guide.md +463 -0
  221. package/core/skills/shadcn-ui/resources/setup-guide.md +412 -0
  222. package/core/skills/shadcn-ui/scripts/verify-setup.sh +134 -0
  223. package/core/skills/state-machine/SKILL.md +264 -0
  224. package/core/skills/stitch-loop/README.md +54 -0
  225. package/core/skills/stitch-loop/SKILL.md +203 -0
  226. package/core/skills/stitch-loop/examples/SITE.md +73 -0
  227. package/core/skills/stitch-loop/examples/next-prompt.md +25 -0
  228. package/core/skills/stitch-loop/resources/baton-schema.md +61 -0
  229. package/core/skills/stitch-loop/resources/site-template.md +104 -0
  230. package/core/skills/systematic-debugging/SKILL.md +109 -0
  231. package/core/skills/tailwind-patterns/SKILL.md +284 -0
  232. package/core/skills/tdd-validation/SKILL.md +243 -0
  233. package/core/skills/tdd-workflow/SKILL.md +284 -0
  234. package/core/skills/testing-patterns/SKILL.md +196 -0
  235. package/core/skills/testing-patterns/scripts/test_runner.py +219 -0
  236. package/core/skills/ui-ux-discovery/SKILL.md +329 -0
  237. package/core/skills/ui-validation/SKILL.md +190 -0
  238. package/core/skills/ui-validation/scripts/ui_antipattern_check.py +317 -0
  239. package/core/skills/verification-gate/SKILL.md +205 -0
  240. package/core/skills/vulnerability-scanner/SKILL.md +276 -0
  241. package/core/skills/vulnerability-scanner/checklists.md +121 -0
  242. package/core/skills/vulnerability-scanner/scripts/security_scan.py +458 -0
  243. package/core/skills/web-design-guidelines/SKILL.md +57 -0
  244. package/core/skills/webapp-testing/SKILL.md +187 -0
  245. package/core/skills/webapp-testing/scripts/playwright_runner.py +173 -0
  246. package/core/templates/ARCHITECTURE.template.md +407 -0
  247. package/core/templates/project-resources.example.json +71 -0
  248. package/core/workflows/atomic.md +182 -0
  249. package/core/workflows/brainstorm.md +134 -0
  250. package/core/workflows/check-task.md +242 -0
  251. package/core/workflows/copy-collect.md +306 -0
  252. package/core/workflows/create-agent.md +33 -0
  253. package/core/workflows/create-skill.md +39 -0
  254. package/core/workflows/create-workflow.md +33 -0
  255. package/core/workflows/create.md +92 -0
  256. package/core/workflows/debug.md +186 -0
  257. package/core/workflows/demand.md +443 -0
  258. package/core/workflows/deploy.md +260 -0
  259. package/core/workflows/discovery.md +267 -0
  260. package/core/workflows/document.md +272 -0
  261. package/core/workflows/ds-components.md +296 -0
  262. package/core/workflows/ds-init.md +58 -0
  263. package/core/workflows/ds-refactor.md +245 -0
  264. package/core/workflows/ds-references.md +197 -0
  265. package/core/workflows/ds-styleguide.md +237 -0
  266. package/core/workflows/ds-token-diff.md +103 -0
  267. package/core/workflows/ds-tokens.md +317 -0
  268. package/core/workflows/ds-validate.md +309 -0
  269. package/core/workflows/execute.md +483 -0
  270. package/core/workflows/extract-template.md +278 -0
  271. package/core/workflows/fix-failed-tests.md +160 -0
  272. package/core/workflows/init-project.md +386 -0
  273. package/core/workflows/legacy-project.md +849 -0
  274. package/core/workflows/log.md +97 -0
  275. package/core/workflows/new-project.md +610 -0
  276. package/core/workflows/new-project.md.bak +3292 -0
  277. package/core/workflows/new-task.md +404 -0
  278. package/core/workflows/orchestrate.md +237 -0
  279. package/core/workflows/page-build.md +296 -0
  280. package/core/workflows/plan.md +89 -0
  281. package/core/workflows/prd.md +255 -0
  282. package/core/workflows/preview.md +81 -0
  283. package/core/workflows/review-page.md +304 -0
  284. package/core/workflows/status.md +86 -0
  285. package/core/workflows/stitch.md +226 -0
  286. package/core/workflows/task-complete.md +473 -0
  287. package/core/workflows/task-update.md +163 -0
  288. package/core/workflows/tdd.md +344 -0
  289. package/core/workflows/test.md +251 -0
  290. package/core/workflows/ui-ux-pro-max.md +437 -0
  291. package/core/workflows/ux-mobile-optimize.md +262 -0
  292. package/core/workflows/ux-mobile-validate.md +297 -0
  293. package/engine-files/GEMINI.md +69 -0
  294. package/package.json +47 -0
  295. package/runtime-adapters/antigravity.js +26 -0
  296. package/runtime-adapters/claude.js +57 -0
  297. package/runtime-adapters/codex.js +51 -0
  298. package/runtime-adapters/copilot.js +51 -0
  299. package/runtime-adapters/cursor.js +51 -0
  300. package/runtime-adapters/gemini-cli.js +30 -0
  301. package/runtime-adapters/opencode.js +51 -0
  302. package/runtime-adapters/windsurf.js +51 -0
@@ -0,0 +1,97 @@
1
+ ---
2
+ description: Registrar trabalho já concluído no Flyee. Suporta busca dinâmica de database.
3
+ skills: project-tracking-patterns
4
+ ---
5
+
6
+ # /log - Registrar Trabalho Retroativo
7
+
8
+ $ARGUMENTS
9
+
10
+ ---
11
+
12
+ ## 🎯 PROPÓSITO
13
+
14
+ Registrar no Tracker trabalhos já concluídos (**Retroativo**).
15
+ Adapta-se a qualquer projeto buscando o database automaticamente.
16
+
17
+ ---
18
+
19
+ ## 📋 SINTAXE
20
+
21
+ ```bash
22
+ /log <tipo> "<descrição>" [opções]
23
+ ```
24
+
25
+ ---
26
+
27
+ ## 🔴 FLUXO: DISCOVER → ANALYSE → TRACK
28
+
29
+ > [!NOTE]
30
+ > Não use IDs fixos. O agente deve descobrir o ambiente.
31
+
32
+ ---
33
+
34
+ ### 🔍 Fase 0: DISCOVERY (Setup)
35
+
36
+ **Ação:** Encontrar onde registrar.
37
+
38
+ **Agente Envolvido:** `explorer-agent`
39
+
40
+ 1. **Buscar Database:**
41
+ * Procure por "Tarefas", "Tasks", "Daily" ou similar.
42
+ ```
43
+ Use: Flyee API: list_tasks()
44
+ query: "Tarefas"
45
+ filter: { "value": "database" }
46
+ ```
47
+
48
+ 2. **Validar "Tempo Gasto":**
49
+ * Analise o schema do banco encontrado.
50
+ * Se `Tempo Gasto` não existir:
51
+ > 🛑 **PARE E PERGUNTE:** "Propriedade 'Tempo Gasto' não encontrada no banco '{Nome}'. Deseja criar?"
52
+ * Sim -> Crie.
53
+ * Não -> Prossiga sem ela.
54
+
55
+ ---
56
+
57
+ ### ✅ Fase 1: ANALYSE & EXTRACT
58
+
59
+ **Objetivo:** Coletar dados do contexto (Chat/Arquivos).
60
+
61
+ **Agentes Envolvidos:**
62
+ - `project-planner` - Categorização e estimativa
63
+ - `backend-specialist` / `frontend-specialist` / `mobile-developer` - Conforme domínio do trabalho
64
+
65
+ 1. **Extrair:** Tipo (`fix`, `feat`), Descrição e **Tempo**.
66
+ 2. **Perguntar:** Se o tempo não foi informado, pergunte.
67
+
68
+ ---
69
+
70
+ ### ✅ Fase 2: TRACK (Flyee)
71
+
72
+ **Ação:** Criar Task já concluída.
73
+
74
+ **Agente Envolvido:** `project-planner`
75
+
76
+ > [!IMPORTANT]
77
+ > **SKILL OBRIGATÓRIA:** Seguir Flyee API para criação de tasks.
78
+ > Ver seção "➕ CRIAR TASK (2 ETAPAS OBRIGATÓRIAS)" - usar template "Log".
79
+
80
+ > [!CAUTION]
81
+ > **2 ETAPAS OBRIGATÓRIAS:**
82
+ > 1. `API-post-page` → Criar task com Status "Concluído"
83
+ > 2. `API-patch-block-children` → Adicionar corpo (template Log)
84
+
85
+ **Resultado:**
86
+ ```
87
+ ✅ LOG REGISTRADO (Database: {Nome Encontrado})
88
+ 📄 Body: ✅ Adicionado
89
+ 🔗 Link: [Flyee]
90
+ ```
91
+
92
+ ---
93
+
94
+ ## ⚠️ REGRAS
95
+
96
+ 1. **Busca Dinâmica:** Se a busca retornar múltiplos bancos, LISTE e PEÇA para o usuário escolher. Não adivinhe.
97
+ 2. **Consistência:** Se você já encontrou o ID no passo anterior (`/new-task` ou outra chamada), pode reutilizá-lo para evitar buscas repetidas na mesma sessão.
@@ -0,0 +1,610 @@
1
+ ---
2
+ description: Workflow unificado para novo projeto. Orquestra PRD → SDD → Project Foundation → Design System → Breakdown → Tests → Impl → Security Review → Verify (a11y+perf) → Staging → Deploy. Fluxo completo com checkpointing.
3
+ skills: checkpointing-patterns, project-tracking-patterns
4
+ ---
5
+
6
+ # /new-project - Novo Projeto Completo
7
+
8
+ $ARGUMENTS
9
+
10
+ ---
11
+
12
+ ## 🎯 PROPÓSITO
13
+
14
+ Workflow **orquestrador** que guia a criação de um novo projeto do zero, garantindo:
15
+ - Exploração de ideias quando necessário (Brainstorm)
16
+ - Documentação completa (PRD + SDD)
17
+ - Project Foundation gerado automaticamente (README, SECURITY, INDEX, ADR, .env, openapi)
18
+ - Testes antes do código (TDD Metodologia)
19
+ - Security Review + Code Review antes do deploy
20
+ - Verificação de acessibilidade (WCAG AA) e performance baseline
21
+ - Rastreabilidade entre documentos via `docs/INDEX.md`
22
+ - Cobertura mínima de 80%
23
+
24
+ > [!IMPORTANT]
25
+ > **Nomenclatura:** Neste workflow, `SDD` = Software Design Document (documento de design técnico).
26
+ > **`TDD`** refere-se exclusivamente à **metodologia Test-Driven Development** (Phase 4).
27
+
28
+ ---
29
+
30
+ ## 📊 QUANDO USAR ESTE WORKFLOW?
31
+
32
+ > [!TIP]
33
+ > **Use este guia para escolher o workflow correto:**
34
+
35
+ | Situação | Workflow Recomendado | Por quê? |
36
+ |----------|---------------------|----------|
37
+ | Ideia vaga, preciso explorar opções | `/new-project --brainstorm` | Inclui fase de exploração |
38
+ | Ideia clara, quero documentação formal | `/new-project` | Fluxo completo com PRD + TDD |
39
+ | Projeto rápido, sem PRD formal | `/new-project --quick` | Direto para TDD + Tasks |
40
+ | Apenas explorar ideias técnicas | `/brainstorm` | Sem compromisso de implementar |
41
+ | Projeto legado, preciso documentar | `/document` → `/discovery --from-project` | Engenharia reversa |
42
+ | Nova feature em projeto existente | `/new-task` ou `/tdd new` | Contexto já existe |
43
+
44
+ ---
45
+
46
+ ## 🧩 SUBCOMMANDS
47
+
48
+ | Comando | Ação |
49
+ |---------|------|
50
+ | `/new-project [nome]` | Fluxo **completo** (PRD → SDD → Tests → Code → Security → Deploy) |
51
+ | `/new-project --brainstorm [nome]` | Inclui **Phase 0** para explorar ideias |
52
+ | `/new-project --quick [nome]` | Modo **ágil** (sem PRD formal, direto SDD) |
53
+ | `/new-project --resume` | **Retomar** de onde parou |
54
+ | `/new-project --from-prd [arquivo]` | Continua de PRD já aprovado |
55
+ | `/new-project --from-sdd [arquivo]` | Continua de SDD já aprovado |
56
+ | `/new-project --from-demand [nome]` | Importa de proposta comercial aprovada |
57
+ | `/new-project --from-figma [url]` | Importa Design System do Figma |
58
+ | `/new-project status` | Mostra status e progresso atual |
59
+
60
+ ---
61
+
62
+ ## 🔀 MODOS DE OPERAÇÃO
63
+
64
+ ### Modo COMPLETO (Padrão)
65
+ ```
66
+ /new-project meu-app
67
+ Ph1 (PRD) → Ph2 (SDD) → Ph2.05 (Foundation) → Ph2.1 (Task Setup) → Ph2.5+ (Design) → Ph3 (Breakdown) → Ph4 (Tests) → Ph5 (Code) → Ph5.5 (Security) → Ph5.6 (Code Review) → Ph6 (Verify+a11y+perf) → Ph6.5 (Staging) → Ph7 (Deploy+Retro)
68
+ ```
69
+
70
+ ### Modo BRAINSTORM (Ideia indefinida)
71
+ ```
72
+ /new-project --brainstorm meu-app
73
+ Phase 0 (Brainstorm) → Phase 1 (PRD) → ... → Phase 7 (Deploy)
74
+ ```
75
+
76
+ ### Modo QUICK (Ágil, sem PRD formal)
77
+ ```
78
+ /new-project --quick meu-app
79
+ Ph2 (SDD) → Ph2.05 (Foundation) → Ph3 (Breakdown) → Ph4 (Tests) → Ph5 (Code) → Ph5.5 (Security) → Ph6 (Verify) → Ph7 (Deploy)
80
+ ```
81
+ > Pula Phase 0, Phase 1, Phase 2.1. Direto para SDD com Socratic Gate simplificado.
82
+
83
+ ---
84
+
85
+ ## 💾 SISTEMA DE CHECKPOINTING
86
+
87
+ > [!IMPORTANT]
88
+ > **Projetos podem ser interrompidos.** O workflow salva progresso em `docs/PROJECT-PROGRESS.md` a cada fase.
89
+ > Seguir skill `checkpointing-patterns` para detalhes de persistência e resume.
90
+
91
+ ### Arquivo de Controle: `docs/PROJECT-PROGRESS.md`
92
+
93
+ Criado automaticamente ao iniciar o projeto. Contém:
94
+
95
+ | Seção | Conteúdo |
96
+ |-------|----------|
97
+ | Status Geral | Nome, fases, última atualização |
98
+ | Project Profile | Tipo, stack, agent, design approach |
99
+ | Fases | Checklist de cada phase com artefatos |
100
+ | Tasks | Lista de tasks pendentes/concluídas |
101
+ | Histórico | Log de ações |
102
+
103
+ ### Retomada: `--resume`
104
+
105
+ ```bash
106
+ /new-project --resume
107
+ ```
108
+
109
+ **Ao executar `--resume`:**
110
+ 1. Carrega `docs/PROJECT-PROGRESS.md`
111
+ 2. Identifica fase pendente
112
+ 3. **🚨 DESYNC DETECTOR (OBRIGATÓRIO):**
113
+ - Comparar tasks marcadas ✅ em PROJECT-PROGRESS.md com status real no Tracker
114
+ - Se LOCAL=✅ mas TRACKER=Não iniciado → **PARAR e executar sync retroativo**
115
+ - Se TRACKER retorna **0 tasks** mas LOCAL tem tasks ✅ → **DESYNC TOTAL. Executar sync retroativo de TODAS as tasks**
116
+ 4. **🔗 FLYEE BRIDGE CHECK (OBRIGATÓRIO):**
117
+ - Ler `flyee.json`
118
+ - Se `enabled: true` OU `opted_out: true` → Prosseguir silenciosamente
119
+ - Se `enabled: false` E `opted_out: false` → Perguntar usando skill `project-type-discovery` seção "Flyee Integration"
120
+ 5. **🎯 OKR GAP DETECTOR (se Flyee habilitado):**
121
+ - Executar `python3 .agent/flyee-bridge/bridge.py --list-okrs`
122
+ - Se 0 OKRs: extrair do PRD/TDD, gerar 1-3 OKRs com bridge.py, validar com usuário
123
+ - Se >= 1 OKR: skip silencioso
124
+ 6. Continua execução (apenas se sem desync)
125
+
126
+ > [!CAUTION]
127
+ > **DESYNC DETECTOR:** Antes de continuar qualquer trabalho em --resume, o agente DEVE:
128
+ > 1. Buscar status de TODAS as tasks marcadas como completas localmente
129
+ > 2. Se encontrar desync (local ✅, Tracker ≠ completed) → sync retroativo PRIMEIRO
130
+ > 3. Se Tracker retorna **0 tasks** mas projeto tem fases completas → isto é **DESYNC TOTAL**, não "sem desync"
131
+ > 4. Só prosseguir após: "Nenhum desync detectado" ou "Desync corrigido"
132
+
133
+ > [!CAUTION]
134
+ > **FLYEE API ERROR HANDLING:**
135
+ > - Erro 500/502/503 na API Flyee → **RETRY 1x após 5s**
136
+ > - Se retry falhar → **INFORMAR USUÁRIO** com mensagem explícita, não pular silenciosamente
137
+ > - 🚫 **PROIBIDO** tratar erro de API como "não bloqueante" e continuar sem sync
138
+
139
+ > [!IMPORTANT]
140
+ > **OKR GAP DETECTOR:** Template de key results deve incluir:
141
+ > - **KR de entrega:** Features implementadas vs. planejadas
142
+ > - **KR de qualidade:** Cobertura de testes, performance
143
+ > - **KR de impacto:** Métricas de negócio do PRD
144
+
145
+ ---
146
+
147
+ ## 🔴 FLUXO COMPLETO
148
+
149
+ ```
150
+ DISCOVERY → BRAINSTORM → PRD → SDD → FOUNDATION → REFERÊNCIAS → DESIGN SYSTEM → CONTENT → STITCH → PAGE SPECS → BREAKDOWN → TESTS → IMPLEMENT → SECURITY → CODE REVIEW → VERIFY → STAGING → DEPLOY+RETRO
151
+ (TIPO+STACK) (OPCIONAL) (O QUÊ) (COMO) (README+.env) (COLETAR) (TOKENS) (O QUE DIZ) (PROTÓTIPO) (BLUEPRINT) (TASKS) (PRIMEIRO) (CÓDIGO) (OWASP) (CHECKLIST) (a11y+perf) (HUMANO) (PROD+RETRO)
152
+ ```
153
+
154
+ > **🚦 GATE 0 (Discovery)** é OBRIGATÓRIO e roda ANTES de tudo.
155
+ > **📋 Phase 2.05 (Foundation)** gera README, SECURITY, .env.example, INDEX.md, ADR-000 (e openapi.yaml se API).
156
+ > **📋 Phase 2.1 (Task Setup)** ocorre entre SDD e REFERÊNCIAS.
157
+ > **📋 Phase 5.5/5.6 (Security + Code Review)** obrigatórias antes de Phase 6.
158
+
159
+ ---
160
+
161
+ ## 📋 FASES — Skill Routing
162
+
163
+ > [!IMPORTANT]
164
+ > **PRINCÍPIO:** Cada fase carrega APENAS o skill necessário sob demanda.
165
+ > NÃO carregar todos os skills de antemão. Ler o skill ao iniciar cada fase.
166
+
167
+ ### 🚦 Gate 0: PROJECT TYPE DISCOVERY (Obrigatório)
168
+
169
+ > **Skill:** `project-type-discovery`
170
+ > Carregar skill e executar todas as 4 perguntas. AGUARDAR respostas.
171
+ >
172
+ > **Gate de Saída:** Project Profile salvo em PROJECT-PROGRESS.md
173
+ > **Exceção:** `--resume` (já tem profile)
174
+
175
+ ---
176
+
177
+ ### Phase 0: BRAINSTORM (Opcional)
178
+
179
+ > **Workflow:** `/brainstorm`
180
+ > Apenas se `/new-project --brainstorm`.
181
+ > Gate de Saída: direção escolhida e validada
182
+
183
+ ---
184
+
185
+ ### Phase 1: PRD (Product Requirements Document)
186
+
187
+ > **Workflow:** `/prd new`
188
+ > Executa workflow completo de PRD com Socratic Gate (12 perguntas).
189
+ > Gera `docs/PRD-{nome}.md` usando `prd-template.md` (com YAML frontmatter + Agent Context).
190
+ > Registra entry em `docs/INDEX.md` após aprovação.
191
+ > Gate de Saída: PRD aprovado pelo humano + entry no INDEX.md
192
+
193
+ ---
194
+
195
+ ### Phase 2: SDD (Software Design Document)
196
+
197
+ > **Atenção:** `SDD` = Software Design Document. **Não confundir** com `TDD` (Test-Driven Development — Phase 4).
198
+ >
199
+ > **Workflow:** `/tdd new` + `/tdd validate` → outputs salvo como `SDD-{nome}.md`
200
+ > **Skill extra:** `deployment-procedures` (seção "Environment Strategy")
201
+ >
202
+ > SDD DEVE incluir:
203
+ > - Seção `## 0. Agent Context` preenchida
204
+ > - Seção `## Environment Strategy` com tabela dev/staging/prod
205
+ > - Se projeto tem API: confirmar se é necessário gerar `docs/api/openapi.yaml` na Phase 2.05
206
+ >
207
+ > Gera `docs/design/SDD-{nome}.md` usando `sdd-template.md`.
208
+ > **Registry:** `document-registry` — registrar entry `SDD-{nome}` no INDEX.md após aprovação.
209
+ > Gate de Saída: SDD aprovado + Environment Strategy definida + ADR inicial registrado se houver decisão arquitetural significativa
210
+
211
+ ---
212
+
213
+ ### Phase 2.05: PROJECT FOUNDATION (Auto-gerado)
214
+
215
+ > **Skill:** `project-foundation` (modo: `new`)
216
+ > **Registry:** `document-registry`
217
+ >
218
+ > Executar o skill `project-foundation` em modo `new`. O skill gerará automaticamente:
219
+ > - `README.md`, `.env.example`, `SECURITY.md`, `docs/INDEX.md`, `docs/adr/ADR-000-initial-setup.md`
220
+ > - `docs/api/openapi.yaml` — **se projeto tem API** (skill pergunta ao usuário)
221
+ >
222
+ > Cada artefato gerado é registrado no `docs/INDEX.md` pelo skill `document-registry`.
223
+ >
224
+ > **Adicionalmente, criar desde o início:**
225
+ > - `docs/RETRO-{nome}-v1.md` — arquivo vazio com template de retrospectiva
226
+ > (será preenchido ao longo do desenvolvimento via `/task-complete` Etapa 4.7)
227
+ > - `.agent/project-resources.json` — mapa de resources do projeto (iniciar com `[]`,
228
+ > preencher conforme PRD, SDD, specs e referências visuais são criadas)
229
+ >
230
+ > **Motivo:** Estes dois arquivos são críticos para retomada de contexto eficiente.
231
+ > Criá-los tarde significa que o agente não terá cache de bugs/decisões durante o desenvolvimento.
232
+ >
233
+ > Gate de Saída: checklist do `project-foundation` 100% marcado + RETRO criado + project-resources.json criado
234
+
235
+ ---
236
+
237
+ ### Phase 2.1: TASK SETUP (Tracking desde o início)
238
+
239
+ > **Skill:** `project-tracking-patterns`
240
+ > Criar tasks de tracking para fases 2.45→2.9 no tracker configurado.
241
+ >
242
+ > **Ações:** Para cada fase de design (2.45, 2.5, 2.65, 2.7, 2.8, 2.9), criar task no tracker.
243
+ > **Pulado no modo:** `--quick`
244
+ > Gate de Saída: tasks de planejamento criadas no tracker
245
+
246
+ ---
247
+
248
+ ### Phase 2.45: VISUAL REFERENCE COLLECTION
249
+
250
+ > **Skill:** `ui-ux-discovery`
251
+ > Se Gate 0 Pergunta 3 já respondida → usar essa resposta.
252
+ > Se não → executar descoberta de referências visuais.
253
+ >
254
+ > Gate de Saída: abordagem de design definida (referências coletadas OU recomendações aceitas)
255
+
256
+ ---
257
+
258
+ ### Phase 2.5: DESIGN SYSTEM (Tokens)
259
+
260
+ > **Skills:** `ui-ux-discovery` + `frontend-design`
261
+ > Gerar `docs/design/DESIGN-SYSTEM.md` com tokens CSS, tipografia, efeitos visuais.
262
+ > Usar `design-system-template.md` como base (já inclui YAML frontmatter + Agent Context).
263
+ > **Registry:** `document-registry` — registrar entry `DS-{nome}` no INDEX.md após aprovação.
264
+ >
265
+ > Gate de Saída: `DESIGN-SYSTEM.md` aprovado pelo usuário + entry atualizada em `docs/INDEX.md`
266
+
267
+ ---
268
+
269
+ ### Phase 2.65: CONTENT STRATEGY
270
+
271
+ > **Skill:** `content-strategy`
272
+ > Definir conteúdo textual para cada página.
273
+ >
274
+ > Gate de Saída: CONTENT-STRATEGY-{nome}.md aprovado
275
+
276
+ ---
277
+
278
+ ### Phase 2.7: STITCH GENERATION (Opcional)
279
+
280
+ > **Workflow:** `/stitch`
281
+ > Se projeto tem UI e design approach permite geração AI.
282
+ >
283
+ > Gate de Saída: protótipos validados pelo cliente/usuário
284
+
285
+ ---
286
+
287
+ ### Phase 2.8: PAGE SPECIFICATIONS
288
+
289
+ > **Skill:** `page-specifications`
290
+ > Detalhar cada página: layout, seções, componentes, estados, responsividade.
291
+ >
292
+ > Gate de Saída: PAGE-SPECs aprovados
293
+
294
+ ---
295
+
296
+ ### Phase 2.9: ANALYTICS STRATEGY
297
+
298
+ > **Skill:** `analytics-strategy`
299
+ > Definir stack, eventos por página, funnels, feature flags.
300
+ >
301
+ > **Pulado se:** POC interno sem necessidade de métricas
302
+ > Gate de Saída: eventos mapeados, SDD + PAGE-SPECs atualizados
303
+
304
+ ---
305
+
306
+ ### Phase 3: BREAKDOWN (Tasks)
307
+
308
+ > **Workflow:** `/tdd breakdown`
309
+ > **Skill:** `project-tracking-patterns`
310
+ >
311
+ > Gerar tasks a partir do SDD e criar no tracker.
312
+ > Gate de Saída: tasks criadas no tracker
313
+
314
+ ### Phase 3.1: OKR AUTO-CREATION (se Flyee habilitado)
315
+
316
+ > **Executa automaticamente após Phase 3.**
317
+ > Extrai 1-3 OKRs do PRD/SDD e cria via bridge.
318
+ >
319
+ > 1. Executar `python3 .agent/flyee-bridge/bridge.py --list-okrs`
320
+ > 2. Se 0 OKRs: extrair objetivos do PRD/TDD, gerar com `--create-okr`
321
+ > - **KR de entrega:** Features implementadas vs. planejadas
322
+ > - **KR de qualidade:** Cobertura de testes, performance
323
+ > - **KR de impacto:** Métricas de negócio do PRD
324
+ > 3. Se >= 1 OKR: skip silencioso
325
+ > 4. Validar com usuário
326
+ >
327
+ > Gate de Saída: OKRs criados ou confirmado skip
328
+
329
+ ---
330
+
331
+ ### Phase 3.5: SETUP BASE (Infraestrutura)
332
+
333
+ > **Skill:** `project-setup`
334
+ > Inicializar projeto, configurar test runner, separar ambientes.
335
+ >
336
+ > Gate de Saída: projeto inicializado, `npm test` roda, ambientes separados
337
+
338
+ ---
339
+
340
+ ### Phase 4: TDD METODOLOGIA (Tests First)
341
+
342
+ > **Skill:** `tdd-workflow` (inclui Anti-Mock Validation + E2E Smoke Test)
343
+ > **Skill:** `design-system-enforcement` (para tasks com UI — inclui UI Spec Reading Gate)
344
+ >
345
+ > Ciclo por task: RED (teste falha) → SPEC READING → GREEN (código mínimo com styling premium) → REFACTOR
346
+ >
347
+ > **Gates obrigatórios por task:**
348
+ > - Anti-Mock Check (skill `tdd-workflow` §11)
349
+ > - UI Spec Reading Gate (skill `design-system-enforcement` §UI Spec Reading Gate)
350
+ > - Sync tracker após cada task (skill `project-tracking-patterns`)
351
+ >
352
+ > Gate de Saída: todos testes passando, sync concluído
353
+
354
+ ---
355
+
356
+ ### Phase 5: IMPLEMENTAÇÃO (5.0 → 5.4)
357
+
358
+ > **Sub-fases obrigatórias:**
359
+
360
+ | Sub-fase | Skill | O que |
361
+ |----------|-------|-------|
362
+ | 🔴 **5.0 Context Gathering** | `context-gathering-patterns` | Ler Task/PRD/TDD e consultar Resources |
363
+ | **5.1 Backend/Lógica** | `tdd-workflow` | Implementar lógica, DB queries, APIs |
364
+ | **5.2 UI Components** | `design-system-enforcement`, `integration-completeness` | Componentes com styling premium + Data Integration Scan |
365
+ | **5.3 Styling Validation** | `design-system-enforcement` (§Premium Styling), `ui-validation` | Verificar e ajustar styling. **Apenas fine-tuning** — styling principal foi aplicado no GREEN |
366
+ | **5.4 Task Completion** | `project-tracking-patterns` | Executar `/task-complete` para atualizar status das tasks no Flyee |
367
+
368
+ > [!CAUTION]
369
+ > **VERIFICAÇÃO OBRIGATÓRIA (antes de Phase 5.5):**
370
+ > ```
371
+ > [ ] 5.0 Context Gathering concluído (checklist preenchido)
372
+ > [ ] 5.1 Backend/Lógica implementado
373
+ > [ ] 5.2 UI Components criados + Data Integration Scan limpo
374
+ > [ ] 5.3 Styling validado (glassmorphism, shadows, animations verificados)
375
+ > [ ] 5.4 /task-complete executado
376
+ > ```
377
+ > ❌ Se QUALQUER sub-fase pendente → NÃO PROSSEGUIR
378
+
379
+ ---
380
+
381
+ ### Phase 5.5: SECURITY REVIEW
382
+
383
+ > **Skill:** `security-auditor` (consultar `.agent/agents/security-auditor.md`)
384
+ >
385
+ > | Verificação | Ação |
386
+ > |-------------|------|
387
+ > | OWASP Top 10 | Checklist item por item |
388
+ > | Dependências vulneráveis | `npm audit` / `pip-audit` / `trivy` |
389
+ > | Secrets em código | `grep -r "secret\|password\|key" src/` |
390
+ > | Auth/Authz | Endpoints protegidos verificados |
391
+ > | CORS/CSP | Headers configurados corretamente |
392
+ > | Input validation | Todos endpoints validam entrada |
393
+ >
394
+ > **Issues encontrados:** Registrar em `docs/adr/ADR-{NNN}-security-decision.md`
395
+ >
396
+ > **🔔 Decision Hook (Condicional):**
397
+ > Se `flyee.json` existe E `enabled: true` — registrar decisões de segurança:
398
+ > ```bash
399
+ > python3 .agent/flyee-bridge/bridge.py --create-decision \
400
+ > --decision "Security: {resumo da decisão/issue}" \
401
+ > --category security \
402
+ > --reason "{contexto — OWASP Top 10 item, CVE, etc.}" \
403
+ > --impact "{endpoints/módulos afetados}"
404
+ > ```
405
+ >
406
+ > Gate de Saída: relatório limpo OU issues documentados em ADR + aprovados pelo usuário
407
+
408
+ ---
409
+
410
+ ### Phase 5.6: CODE REVIEW GATE
411
+
412
+ > **Skill:** `code-review-checklist`
413
+ >
414
+ > ```
415
+ > [ ] Sem TODOs/FIXMEs pendentes na base de código
416
+ > [ ] Sem mock data ou stubs em rotas de produção
417
+ > [ ] Cobertura >= 80% confirmada
418
+ > [ ] Naming consistente com glossario do SDD
419
+ > [ ] Nenhum console.log / print debug no código de produção
420
+ > [ ] Imports limpos (sem módulos não utilizados)
421
+ > ```
422
+ >
423
+ > Gate de Saída: checklist 100% preenchido
424
+
425
+ ---
426
+
427
+ ### Phase 6: VERIFICAÇÃO (6.0 + 6.1 + 6.2)
428
+
429
+ > **Skills:** `tdd-workflow` (§E2E Core Loop Smoke Test), `web-design-guidelines` (§a11y), `performance-profiling`
430
+
431
+ | Sub-fase | O que verificar | Critério |
432
+ |----------|-----------------|----------|
433
+ | **6.0 Coverage + E2E** | Cobertura e fluxo principal | Coverage ≥ 80% + E2E passando |
434
+ | **6.1 Accessibility (a11y)** | WCAG AA audit | Zero critical violations |
435
+ | **6.2 Performance Baseline** | Lighthouse (web) ou equivalente (mobile) | Score ≥ 90 por categoria |
436
+
437
+ > | Resultado | Ação |
438
+ > |-----------|------|
439
+ > | Coverage ≥ 80% | ✅ Prosseguir |
440
+ > | Coverage < 80% | ❌ Adicionar testes |
441
+ > | E2E Smoke FALHOU | ❌ CORRIGIR — fluxo principal broken |
442
+ > | a11y critical violations | ❌ CORRIGIR antes de prosseguir |
443
+ > | Perf baseline < 90 | ⚠️ Documentar em ADR e validar com usuário |
444
+ >
445
+ > Gate de Saída: coverage ≥ 80% + E2E funcional + a11y sem critical violations + performance baseline documentado
446
+
447
+ ---
448
+
449
+ ### Phase 6.5: STAGING VALIDATION
450
+
451
+ > Fase separada do deploy em produção. **Obrigatória** antes de Phase 7.
452
+ >
453
+ > 1. Deploy em ambiente de staging
454
+ > 2. Executar smoke tests em staging
455
+ > 3. Validação com usuário / stakeholder chave
456
+ > 4. Documentação de issues encontrados
457
+ >
458
+ > Gate de Saída: aprovação explícita do usuário antes de prosseguir para produção
459
+
460
+ ---
461
+
462
+ ### Phase 7: DEPLOY (7.1 → 7.7)
463
+
464
+ > **Skill:** `deployment-procedures` (§Environment Separation, §Pre-Deploy)
465
+ > **Workflow:** `/deploy`
466
+
467
+ | Sub-fase | O que |
468
+ |----------|-------|
469
+ | 7.1 Environment Discovery | Perguntar ambientes ao usuário (dev/staging/prod) |
470
+ | 7.2 Pre-flight Checks | Build, testes, env vars verificados |
471
+ | 7.3 Deploy | Executar deploy na plataforma |
472
+ | 7.4 Verify | Health check, logs, key flows |
473
+ | 7.5 Tech Documentation | Publicar docs técnicos no Flyee (se habilitado) |
474
+ | 7.6 User Documentation | Publicar guias de uso no Flyee (se habilitado) |
475
+ | **7.7 Post-Deploy Retrospective** | **Registrar aprendizados em `docs/RETRO-{nome}-v1.md`** |
476
+
477
+ > Gate de Saída: deploy bem-sucedido + documentação publicada + retrospectiva registrada
478
+
479
+ ---
480
+
481
+ ## 🔴 REGRAS CRÍTICAS
482
+
483
+ 1. **Aprovação humana obrigatória** em PRD e SDD
484
+ 2. **Testes ANTES do código** (TDD Metodologia)
485
+ 3. **Cobertura ≥ 80%** antes de deploy
486
+ 4. **Rastreabilidade:** SDD referencia PRD, Tasks referenciam SDD, via `docs/INDEX.md`
487
+ 5. **Um projeto = Um PRD = Um SDD principal**
488
+ 6. **Ambientes obrigatórios:** SEMPRE perguntar sobre dev/staging/prod antes de deploy (Phase 7.1)
489
+ 7. **📚 DOCUMENTAÇÃO PARA DEVS E USUÁRIOS** - Ao final do projeto (Phase 7.5 + 7.6), publicar docs
490
+ 8. **📋 TRACKING DESDE O INÍCIO** - Tasks de planejamento (Phase 2.5–2.9) criadas na Phase 2.1
491
+ 9. **🔒 SECURITY GATE** - Phase 5.5 e 5.6 obrigatórias antes de Phase 6, sem exceções
492
+ 10. **♿ ACESSIBILIDADE** - Phase 6.1 obrigatória; WCAG AA mínimo para projetos com UI
493
+ 11. **📊 RETROSPECTIVA** - Phase 7.7 obrigatória após cada deploy de versão
494
+
495
+ ---
496
+
497
+ ## 🔗 INTEGRAÇÃO COM OUTROS WORKFLOWS
498
+
499
+ | Este workflow chama | Propósito |
500
+ |---------------------|-----------|
501
+ | `/brainstorm` | Phase 0 (opcional) |
502
+ | `/prd new` | Phase 1 |
503
+ | `/tdd new` + `/tdd validate` + `/tdd breakdown` | Phase 2-3 |
504
+ | `/test [feature]` | Phase 4 |
505
+ | `/create` ou `/orchestrate` | Phase 5 |
506
+ | `/test coverage` | Phase 6 |
507
+ | `/deploy` | Phase 7 |
508
+
509
+ | Workflows Relacionados | Quando Usar |
510
+ |------------------------|-------------|
511
+ | `/discovery` | Alternativa ágil (equivale a `--quick` + Tracker) |
512
+ | `/brainstorm` | Exploração standalone sem projeto |
513
+ | `/new-task` | Nova feature em projeto existente |
514
+ | `/document` | Documentar projeto legado |
515
+
516
+ ---
517
+
518
+ ## 📁 Estrutura de Arquivos Gerados
519
+
520
+ ### Modo Completo
521
+ ```
522
+ projeto/
523
+ ├── README.md # Phase 2.05
524
+ ├── .env.example # Phase 2.05
525
+ ├── SECURITY.md # Phase 2.05
526
+ ├── CHANGELOG.md # Phase 7
527
+ ├── docs/
528
+ │ ├── INDEX.md # Phase 2.05 (Document Registry)
529
+ │ ├── PRD-{nome}.md # Phase 1
530
+ │ ├── RETRO-{nome}-v1.md # Phase 7.7
531
+ │ ├── adr/
532
+ │ │ └── ADR-000-initial-setup.md # Phase 2.05
533
+ │ ├── api/
534
+ │ │ └── openapi.yaml # Phase 2.05 (se projeto tem API)
535
+ │ └── design/
536
+ │ ├── SDD-{nome}.md # Phase 2 (Software Design Document)
537
+ │ ├── DESIGN-SYSTEM.md # Phase 2.5
538
+ │ ├── PAGE-SPEC-{pagina}.md # Phase 2.8
539
+ │ └── CONTENT-{pagina}.md # Phase 2.65
540
+ ├── {nome}.md # Plan file (Phase 3)
541
+ ├── tests/ # Phase 4
542
+ │ ├── unit/
543
+ │ └── integration/
544
+ └── src/ # Phase 5
545
+ ```
546
+
547
+ ### Modo --quick
548
+ ```
549
+ projeto/
550
+ ├── README.md # Phase 2.05
551
+ ├── .env.example # Phase 2.05
552
+ ├── SECURITY.md # Phase 2.05
553
+ ├── docs/
554
+ │ ├── INDEX.md # Phase 2.05
555
+ │ ├── adr/
556
+ │ └── design/
557
+ │ └── SDD-{nome}.md # Phase 2 (sem PRD)
558
+ ├── {nome}.md
559
+ ├── tests/
560
+ └── src/
561
+ ```
562
+
563
+ ---
564
+
565
+ ## 📋 Comparativo de Modos
566
+
567
+ | Aspecto | Completo | --brainstorm | --quick |
568
+ |---------|----------|--------------| --------|
569
+ | Phase 0 (Brainstorm) | ❌ | ✅ | ❌ |
570
+ | Phase 1 (PRD) | ✅ | ✅ | ❌ |
571
+ | Phase 2 (SDD) | ✅ | ✅ | ✅ |
572
+ | Phase 2.05 (Foundation) | ✅ | ✅ | ✅ |
573
+ | Phase 2.1 (Task Setup) | ✅ | ✅ | ❌ |
574
+ | Phase 5.5 (Security Review) | ✅ | ✅ | ✅ |
575
+ | Phase 5.6 (Code Review) | ✅ | ✅ | ✅ |
576
+ | Phase 6.1 (a11y) | ✅ | ✅ | ✅ |
577
+ | Phase 6.2 (Performance) | ✅ | ✅ | ✅ |
578
+ | Phase 6.5 (Staging) | ✅ | ✅ | ❌ |
579
+ | Phase 7.7 (Retrospective) | ✅ | ✅ | ❌ |
580
+ | Socratic Gate | 12 perguntas | 12 perguntas | 5 perguntas |
581
+ | Documentação | PRD + SDD | PRD + SDD | SDD only |
582
+ | Tempo estimado | Maior | Maior | Menor |
583
+ | Recomendado para | Projetos formais | Ideias indefinidas | MVPs rápidos |
584
+
585
+ ---
586
+
587
+ ## Usage Examples
588
+
589
+ ```bash
590
+ # Novo projeto com ideia indefinida (inclui brainstorm)
591
+ /new-project --brainstorm meu-app-fitness
592
+
593
+ # Novo projeto com ideia clara (fluxo completo)
594
+ /new-project meu-app-fitness
595
+
596
+ # Projeto rápido sem PRD formal (modo ágil)
597
+ /new-project --quick meu-app-fitness
598
+
599
+ # Continuar de PRD já aprovado
600
+ /new-project --from-prd docs/PRD-meu-app.md
601
+
602
+ # Continuar de SDD já aprovado
603
+ /new-project --from-sdd docs/design/SDD-meu-app.md
604
+
605
+ # Importar de proposta comercial aprovada
606
+ /new-project --from-demand "Proposta App Fitness"
607
+
608
+ # Ver status do projeto
609
+ /new-project status
610
+ ```