@ggailabs/cli-context 0.5.6 → 1.0.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.

Potentially problematic release.


This version of @ggailabs/cli-context might be problematic. Click here for more details.

Files changed (282) hide show
  1. package/dist/.context/docs/GENESIS_SYSTEM_PROMPT.md +62 -0
  2. package/dist/.context/eng/agents/architect.md +15 -0
  3. package/dist/.context/eng/agents/backend_typescript.md +1000 -0
  4. package/dist/.context/eng/agents/bug_hunter.md +49 -0
  5. package/dist/.context/eng/agents/code_reviewer.md +313 -0
  6. package/dist/.context/eng/agents/devops_specialist.md +718 -0
  7. package/dist/.context/eng/agents/frontend_specialist.md +1027 -0
  8. package/dist/.context/eng/agents/qa_specialist.md +1234 -0
  9. package/dist/.context/eng/agents/security_reviewer.md +382 -0
  10. package/dist/.context/eng/agents/ui_specialist.md +16 -0
  11. package/dist/.context/eng/docs/AGENT_HANDOFF_PROMPT.md +44 -0
  12. package/dist/.context/eng/docs/GENESIS_DESIGN_SYSTEM.md +15 -0
  13. package/dist/.context/eng/docs/GG_METHODOLOGY.md +48 -0
  14. package/dist/.context/eng/docs/OPERATIONS_LOG.md +30 -0
  15. package/dist/.context/eng/docs/PROJECT_MAP.md +35 -0
  16. package/dist/.context/eng/docs/standards/devops.md +0 -0
  17. package/dist/.context/eng/docs/standards/frontend.md +0 -0
  18. package/dist/.context/eng/docs/standards/typescript.md +12 -0
  19. package/dist/.context/eng/skills/agent_logging.md +18 -0
  20. package/dist/.context/eng/skills/brainstorming.md +227 -0
  21. package/dist/.context/eng/skills/exploring_codebase.md +1217 -0
  22. package/dist/.context/eng/skills/patterns/compliance_check.md +246 -0
  23. package/dist/.context/eng/skills/patterns/coverage_table.md +401 -0
  24. package/dist/.context/eng/skills/patterns/exit_criteria.md +31 -0
  25. package/dist/.context/eng/skills/patterns/failure_recovery.md +74 -0
  26. package/dist/.context/eng/skills/patterns/quality_gate.md +295 -0
  27. package/dist/.context/eng/skills/patterns/standards_workflow.md +391 -0
  28. package/dist/.context/eng/skills/patterns/state_tracking.md +30 -0
  29. package/dist/.context/eng/skills/patterns/task_tracking.md +38 -0
  30. package/dist/.context/eng/skills/previce.md +45 -0
  31. package/dist/.context/eng/skills/tdd.md +421 -0
  32. package/dist/.context/eng/skills/writing_plans.md +105 -0
  33. package/dist/.context/plans/.gitkeep +0 -0
  34. package/dist/.context/pt-br/agents/architect.md +69 -0
  35. package/dist/.context/pt-br/agents/backend_typescript.md +1000 -0
  36. package/dist/.context/pt-br/agents/bug_hunter.md +49 -0
  37. package/dist/.context/pt-br/agents/code_reviewer.md +313 -0
  38. package/dist/.context/pt-br/agents/devops_specialist.md +718 -0
  39. package/dist/.context/pt-br/agents/frontend_specialist.md +1027 -0
  40. package/dist/.context/pt-br/agents/qa_specialist.md +1234 -0
  41. package/dist/.context/pt-br/agents/security_reviewer.md +382 -0
  42. package/dist/.context/pt-br/agents/ui_specialist.md +55 -0
  43. package/dist/.context/pt-br/docs/AGENT_HANDOFF_PROMPT.md +44 -0
  44. package/dist/.context/pt-br/docs/GENESIS_DESIGN_SYSTEM.md +88 -0
  45. package/dist/.context/pt-br/docs/GG_METHODOLOGY.md +48 -0
  46. package/dist/.context/pt-br/docs/OPERATIONS_LOG.md +30 -0
  47. package/dist/.context/pt-br/docs/PROJECT_MAP.md +37 -0
  48. package/dist/.context/pt-br/docs/standards/devops.md +707 -0
  49. package/dist/.context/pt-br/docs/standards/frontend.md +748 -0
  50. package/dist/.context/pt-br/docs/standards/typescript.md +1150 -0
  51. package/dist/.context/pt-br/skills/agent_logging.md +36 -0
  52. package/dist/.context/pt-br/skills/brainstorming.md +227 -0
  53. package/dist/.context/pt-br/skills/exploring_codebase.md +1217 -0
  54. package/dist/.context/pt-br/skills/patterns/compliance_check.md +246 -0
  55. package/dist/.context/pt-br/skills/patterns/coverage_table.md +401 -0
  56. package/dist/.context/pt-br/skills/patterns/exit_criteria.md +31 -0
  57. package/dist/.context/pt-br/skills/patterns/failure_recovery.md +74 -0
  58. package/dist/.context/pt-br/skills/patterns/quality_gate.md +295 -0
  59. package/dist/.context/pt-br/skills/patterns/standards_workflow.md +391 -0
  60. package/dist/.context/pt-br/skills/patterns/state_tracking.md +30 -0
  61. package/dist/.context/pt-br/skills/patterns/task_tracking.md +38 -0
  62. package/dist/.context/pt-br/skills/previce.md +45 -0
  63. package/dist/.context/pt-br/skills/tdd.md +421 -0
  64. package/dist/.context/pt-br/skills/writing_plans.md +105 -0
  65. package/dist/.context/workflow/.gitkeep +0 -0
  66. package/dist/commands/init.js +140 -0
  67. package/dist/commands/monitor.js +34 -0
  68. package/dist/index.js +20 -568
  69. package/dist/services/monitor-service.js +340 -0
  70. package/dist/services/scaffolder.js +164 -0
  71. package/package.json +16 -58
  72. package/LICENSE +0 -21
  73. package/README.md +0 -195
  74. package/dist/generators/agents/agentConfig.d.ts +0 -4
  75. package/dist/generators/agents/agentConfig.d.ts.map +0 -1
  76. package/dist/generators/agents/agentConfig.js +0 -180
  77. package/dist/generators/agents/agentConfig.js.map +0 -1
  78. package/dist/generators/agents/agentGenerator.d.ts +0 -9
  79. package/dist/generators/agents/agentGenerator.d.ts.map +0 -1
  80. package/dist/generators/agents/agentGenerator.js +0 -97
  81. package/dist/generators/agents/agentGenerator.js.map +0 -1
  82. package/dist/generators/agents/agentTypes.d.ts +0 -4
  83. package/dist/generators/agents/agentTypes.d.ts.map +0 -1
  84. package/dist/generators/agents/agentTypes.js +0 -25
  85. package/dist/generators/agents/agentTypes.js.map +0 -1
  86. package/dist/generators/agents/index.d.ts +0 -4
  87. package/dist/generators/agents/index.d.ts.map +0 -1
  88. package/dist/generators/agents/index.js +0 -12
  89. package/dist/generators/agents/index.js.map +0 -1
  90. package/dist/generators/agents/templates/index.d.ts +0 -4
  91. package/dist/generators/agents/templates/index.d.ts.map +0 -1
  92. package/dist/generators/agents/templates/index.js +0 -8
  93. package/dist/generators/agents/templates/index.js.map +0 -1
  94. package/dist/generators/agents/templates/indexTemplate.d.ts +0 -3
  95. package/dist/generators/agents/templates/indexTemplate.d.ts.map +0 -1
  96. package/dist/generators/agents/templates/indexTemplate.js +0 -36
  97. package/dist/generators/agents/templates/indexTemplate.js.map +0 -1
  98. package/dist/generators/agents/templates/playbookTemplate.d.ts +0 -4
  99. package/dist/generators/agents/templates/playbookTemplate.d.ts.map +0 -1
  100. package/dist/generators/agents/templates/playbookTemplate.js +0 -99
  101. package/dist/generators/agents/templates/playbookTemplate.js.map +0 -1
  102. package/dist/generators/agents/templates/types.d.ts +0 -14
  103. package/dist/generators/agents/templates/types.d.ts.map +0 -1
  104. package/dist/generators/agents/templates/types.js +0 -3
  105. package/dist/generators/agents/templates/types.js.map +0 -1
  106. package/dist/generators/documentation/documentationGenerator.d.ts +0 -15
  107. package/dist/generators/documentation/documentationGenerator.d.ts.map +0 -1
  108. package/dist/generators/documentation/documentationGenerator.js +0 -188
  109. package/dist/generators/documentation/documentationGenerator.js.map +0 -1
  110. package/dist/generators/documentation/guideRegistry.d.ts +0 -6
  111. package/dist/generators/documentation/guideRegistry.d.ts.map +0 -1
  112. package/dist/generators/documentation/guideRegistry.js +0 -82
  113. package/dist/generators/documentation/guideRegistry.js.map +0 -1
  114. package/dist/generators/documentation/index.d.ts +0 -2
  115. package/dist/generators/documentation/index.d.ts.map +0 -1
  116. package/dist/generators/documentation/index.js +0 -6
  117. package/dist/generators/documentation/index.js.map +0 -1
  118. package/dist/generators/documentation/templates/apiReferenceTemplate.d.ts +0 -2
  119. package/dist/generators/documentation/templates/apiReferenceTemplate.d.ts.map +0 -1
  120. package/dist/generators/documentation/templates/apiReferenceTemplate.js +0 -490
  121. package/dist/generators/documentation/templates/apiReferenceTemplate.js.map +0 -1
  122. package/dist/generators/documentation/templates/architectureTemplate.d.ts +0 -3
  123. package/dist/generators/documentation/templates/architectureTemplate.d.ts.map +0 -1
  124. package/dist/generators/documentation/templates/architectureTemplate.js +0 -66
  125. package/dist/generators/documentation/templates/architectureTemplate.js.map +0 -1
  126. package/dist/generators/documentation/templates/common.d.ts +0 -7
  127. package/dist/generators/documentation/templates/common.d.ts.map +0 -1
  128. package/dist/generators/documentation/templates/common.js +0 -58
  129. package/dist/generators/documentation/templates/common.js.map +0 -1
  130. package/dist/generators/documentation/templates/dataFlowTemplate.d.ts +0 -3
  131. package/dist/generators/documentation/templates/dataFlowTemplate.d.ts.map +0 -1
  132. package/dist/generators/documentation/templates/dataFlowTemplate.js +0 -40
  133. package/dist/generators/documentation/templates/dataFlowTemplate.js.map +0 -1
  134. package/dist/generators/documentation/templates/developmentWorkflowTemplate.d.ts +0 -2
  135. package/dist/generators/documentation/templates/developmentWorkflowTemplate.d.ts.map +0 -1
  136. package/dist/generators/documentation/templates/developmentWorkflowTemplate.js +0 -44
  137. package/dist/generators/documentation/templates/developmentWorkflowTemplate.js.map +0 -1
  138. package/dist/generators/documentation/templates/glossaryTemplate.d.ts +0 -3
  139. package/dist/generators/documentation/templates/glossaryTemplate.d.ts.map +0 -1
  140. package/dist/generators/documentation/templates/glossaryTemplate.js +0 -41
  141. package/dist/generators/documentation/templates/glossaryTemplate.js.map +0 -1
  142. package/dist/generators/documentation/templates/index.d.ts +0 -15
  143. package/dist/generators/documentation/templates/index.d.ts.map +0 -1
  144. package/dist/generators/documentation/templates/index.js +0 -30
  145. package/dist/generators/documentation/templates/index.js.map +0 -1
  146. package/dist/generators/documentation/templates/indexTemplate.d.ts +0 -3
  147. package/dist/generators/documentation/templates/indexTemplate.d.ts.map +0 -1
  148. package/dist/generators/documentation/templates/indexTemplate.js +0 -42
  149. package/dist/generators/documentation/templates/indexTemplate.js.map +0 -1
  150. package/dist/generators/documentation/templates/migrationTemplate.d.ts +0 -2
  151. package/dist/generators/documentation/templates/migrationTemplate.d.ts.map +0 -1
  152. package/dist/generators/documentation/templates/migrationTemplate.js +0 -422
  153. package/dist/generators/documentation/templates/migrationTemplate.js.map +0 -1
  154. package/dist/generators/documentation/templates/onboardingTemplate.d.ts +0 -2
  155. package/dist/generators/documentation/templates/onboardingTemplate.d.ts.map +0 -1
  156. package/dist/generators/documentation/templates/onboardingTemplate.js +0 -431
  157. package/dist/generators/documentation/templates/onboardingTemplate.js.map +0 -1
  158. package/dist/generators/documentation/templates/projectOverviewTemplate.d.ts +0 -3
  159. package/dist/generators/documentation/templates/projectOverviewTemplate.d.ts.map +0 -1
  160. package/dist/generators/documentation/templates/projectOverviewTemplate.js +0 -65
  161. package/dist/generators/documentation/templates/projectOverviewTemplate.js.map +0 -1
  162. package/dist/generators/documentation/templates/securityTemplate.d.ts +0 -2
  163. package/dist/generators/documentation/templates/securityTemplate.d.ts.map +0 -1
  164. package/dist/generators/documentation/templates/securityTemplate.js +0 -39
  165. package/dist/generators/documentation/templates/securityTemplate.js.map +0 -1
  166. package/dist/generators/documentation/templates/testingTemplate.d.ts +0 -2
  167. package/dist/generators/documentation/templates/testingTemplate.d.ts.map +0 -1
  168. package/dist/generators/documentation/templates/testingTemplate.js +0 -45
  169. package/dist/generators/documentation/templates/testingTemplate.js.map +0 -1
  170. package/dist/generators/documentation/templates/toolingTemplate.d.ts +0 -2
  171. package/dist/generators/documentation/templates/toolingTemplate.d.ts.map +0 -1
  172. package/dist/generators/documentation/templates/toolingTemplate.js +0 -42
  173. package/dist/generators/documentation/templates/toolingTemplate.js.map +0 -1
  174. package/dist/generators/documentation/templates/troubleshootingTemplate.d.ts +0 -2
  175. package/dist/generators/documentation/templates/troubleshootingTemplate.d.ts.map +0 -1
  176. package/dist/generators/documentation/templates/troubleshootingTemplate.js +0 -292
  177. package/dist/generators/documentation/templates/troubleshootingTemplate.js.map +0 -1
  178. package/dist/generators/documentation/templates/types.d.ts +0 -23
  179. package/dist/generators/documentation/templates/types.d.ts.map +0 -1
  180. package/dist/generators/documentation/templates/types.js +0 -3
  181. package/dist/generators/documentation/templates/types.js.map +0 -1
  182. package/dist/generators/plans/index.d.ts +0 -2
  183. package/dist/generators/plans/index.d.ts.map +0 -1
  184. package/dist/generators/plans/index.js +0 -6
  185. package/dist/generators/plans/index.js.map +0 -1
  186. package/dist/generators/plans/planGenerator.d.ts +0 -22
  187. package/dist/generators/plans/planGenerator.d.ts.map +0 -1
  188. package/dist/generators/plans/planGenerator.js +0 -109
  189. package/dist/generators/plans/planGenerator.js.map +0 -1
  190. package/dist/generators/plans/templates/indexTemplate.d.ts +0 -3
  191. package/dist/generators/plans/templates/indexTemplate.d.ts.map +0 -1
  192. package/dist/generators/plans/templates/indexTemplate.js +0 -37
  193. package/dist/generators/plans/templates/indexTemplate.js.map +0 -1
  194. package/dist/generators/plans/templates/planTemplate.d.ts +0 -3
  195. package/dist/generators/plans/templates/planTemplate.d.ts.map +0 -1
  196. package/dist/generators/plans/templates/planTemplate.js +0 -166
  197. package/dist/generators/plans/templates/planTemplate.js.map +0 -1
  198. package/dist/generators/plans/templates/types.d.ts +0 -19
  199. package/dist/generators/plans/templates/types.d.ts.map +0 -1
  200. package/dist/generators/plans/templates/types.js +0 -3
  201. package/dist/generators/plans/templates/types.js.map +0 -1
  202. package/dist/generators/shared/contextGenerator.d.ts +0 -7
  203. package/dist/generators/shared/contextGenerator.d.ts.map +0 -1
  204. package/dist/generators/shared/contextGenerator.js +0 -13
  205. package/dist/generators/shared/contextGenerator.js.map +0 -1
  206. package/dist/generators/shared/directoryTemplateHelpers.d.ts +0 -2
  207. package/dist/generators/shared/directoryTemplateHelpers.d.ts.map +0 -1
  208. package/dist/generators/shared/directoryTemplateHelpers.js +0 -12
  209. package/dist/generators/shared/directoryTemplateHelpers.js.map +0 -1
  210. package/dist/generators/shared/generatorUtils.d.ts +0 -16
  211. package/dist/generators/shared/generatorUtils.d.ts.map +0 -1
  212. package/dist/generators/shared/generatorUtils.js +0 -119
  213. package/dist/generators/shared/generatorUtils.js.map +0 -1
  214. package/dist/generators/shared/index.d.ts +0 -4
  215. package/dist/generators/shared/index.d.ts.map +0 -1
  216. package/dist/generators/shared/index.js +0 -10
  217. package/dist/generators/shared/index.js.map +0 -1
  218. package/dist/index.d.ts +0 -9
  219. package/dist/index.d.ts.map +0 -1
  220. package/dist/index.js.map +0 -1
  221. package/dist/prompts/defaults.d.ts +0 -3
  222. package/dist/prompts/defaults.d.ts.map +0 -1
  223. package/dist/prompts/defaults.js +0 -95
  224. package/dist/prompts/defaults.js.map +0 -1
  225. package/dist/services/baseLLMClient.d.ts +0 -12
  226. package/dist/services/baseLLMClient.d.ts.map +0 -1
  227. package/dist/services/baseLLMClient.js +0 -80
  228. package/dist/services/baseLLMClient.js.map +0 -1
  229. package/dist/services/fill/fillService.d.ts +0 -46
  230. package/dist/services/fill/fillService.d.ts.map +0 -1
  231. package/dist/services/fill/fillService.js +0 -254
  232. package/dist/services/fill/fillService.js.map +0 -1
  233. package/dist/services/init/initService.d.ts +0 -37
  234. package/dist/services/init/initService.d.ts.map +0 -1
  235. package/dist/services/init/initService.js +0 -167
  236. package/dist/services/init/initService.js.map +0 -1
  237. package/dist/services/llmClientFactory.d.ts +0 -8
  238. package/dist/services/llmClientFactory.d.ts.map +0 -1
  239. package/dist/services/llmClientFactory.js +0 -23
  240. package/dist/services/llmClientFactory.js.map +0 -1
  241. package/dist/services/openRouterClient.d.ts +0 -9
  242. package/dist/services/openRouterClient.d.ts.map +0 -1
  243. package/dist/services/openRouterClient.js +0 -49
  244. package/dist/services/openRouterClient.js.map +0 -1
  245. package/dist/services/plan/planService.d.ts +0 -57
  246. package/dist/services/plan/planService.d.ts.map +0 -1
  247. package/dist/services/plan/planService.js +0 -334
  248. package/dist/services/plan/planService.js.map +0 -1
  249. package/dist/services/shared/llmConfig.d.ts +0 -22
  250. package/dist/services/shared/llmConfig.d.ts.map +0 -1
  251. package/dist/services/shared/llmConfig.js +0 -38
  252. package/dist/services/shared/llmConfig.js.map +0 -1
  253. package/dist/types.d.ts +0 -65
  254. package/dist/types.d.ts.map +0 -1
  255. package/dist/types.js +0 -3
  256. package/dist/types.js.map +0 -1
  257. package/dist/utils/cliUI.d.ts +0 -27
  258. package/dist/utils/cliUI.d.ts.map +0 -1
  259. package/dist/utils/cliUI.js +0 -252
  260. package/dist/utils/cliUI.js.map +0 -1
  261. package/dist/utils/fileMapper.d.ts +0 -11
  262. package/dist/utils/fileMapper.d.ts.map +0 -1
  263. package/dist/utils/fileMapper.js +0 -146
  264. package/dist/utils/fileMapper.js.map +0 -1
  265. package/dist/utils/gitService.d.ts +0 -50
  266. package/dist/utils/gitService.d.ts.map +0 -1
  267. package/dist/utils/gitService.js +0 -470
  268. package/dist/utils/gitService.js.map +0 -1
  269. package/dist/utils/i18n.d.ts +0 -171
  270. package/dist/utils/i18n.d.ts.map +0 -1
  271. package/dist/utils/i18n.js +0 -381
  272. package/dist/utils/i18n.js.map +0 -1
  273. package/dist/utils/promptLoader.d.ts +0 -12
  274. package/dist/utils/promptLoader.d.ts.map +0 -1
  275. package/dist/utils/promptLoader.js +0 -81
  276. package/dist/utils/promptLoader.js.map +0 -1
  277. package/dist/utils/versionChecker.d.ts +0 -15
  278. package/dist/utils/versionChecker.d.ts.map +0 -1
  279. package/dist/utils/versionChecker.js +0 -49
  280. package/dist/utils/versionChecker.js.map +0 -1
  281. package/prompts/update_plan_prompt.md +0 -41
  282. package/prompts/update_scaffold_prompt.md +0 -47
@@ -0,0 +1,391 @@
1
+ # Standards Workflow
2
+
3
+ Canonical source for the complete standards loading and handling workflow used by all dev-team agents.
4
+
5
+ ## Overview
6
+
7
+ All dev-team agents MUST follow this workflow before any work:
8
+
9
+ ```text
10
+ ┌─────────────────────────────────────────────────────────────┐
11
+ │ Step 1: Read PROJECT_RULES.md │
12
+ │ ├─ Exists? → Continue to Step 2 │
13
+ │ └─ Missing? → Create PROJECT_RULES.md (see Scenario 1) │
14
+ ├─────────────────────────────────────────────────────────────┤
15
+ │ Step 2: WebFetch Ring Standards │
16
+ │ ├─ Success? → Continue to Step 3 │
17
+ │ └─ Failed? → HARD BLOCK, report blocker │
18
+ ├─────────────────────────────────────────────────────────────┤
19
+ │ Step 3: Check Existing Code Compliance │
20
+ │ ├─ Compliant? → Proceed with work │
21
+ │ └─ Non-Compliant + No PROJECT_RULES? → HARD BLOCK (Scenario 2) │
22
+ └─────────────────────────────────────────────────────────────┘
23
+ ```
24
+
25
+ ---
26
+
27
+ ## Step 1: Read Local PROJECT_RULES.md (HARD GATE)
28
+
29
+ ```text
30
+ Read docs/PROJECT_RULES.md
31
+ ```
32
+
33
+ **MANDATORY:** Project-specific technical information that must always be considered. Cannot proceed without reading this file.
34
+
35
+ ### What PROJECT_RULES.md Contains (COMPLEMENTARY to Ring Standards)
36
+
37
+ **⛔ DEDUPLICATION RULE:** PROJECT_RULES.md documents only what Ring Standards DO NOT cover.
38
+
39
+ | Category | Belongs In | Examples |
40
+ |----------|------------|----------|
41
+ | **Tech stack not in Ring** | PROJECT_RULES.md | Specific message broker, specific cache, DB if not PostgreSQL |
42
+ | **Non-standard directories** | PROJECT_RULES.md | Pooling workers, MessageBroker consumers, custom workers |
43
+ | **External integrations** | PROJECT_RULES.md | Third-party APIs, webhooks, external services |
44
+ | **Project-specific env vars** | PROJECT_RULES.md | Environment config not covered by Ring |
45
+ | **Domain terminology** | PROJECT_RULES.md | Technical names of entities/classes in this codebase |
46
+ | Error handling patterns | Ring Standards | ❌ Do not duplicate |
47
+ | Logging standards | Ring Standards | ❌ Do not duplicate |
48
+ | Testing patterns | Ring Standards | ❌ Do not duplicate |
49
+ | Architecture patterns | Ring Standards | ❌ Do not duplicate |
50
+ | lib-commons, shared packages | Ring Standards | ❌ Do not duplicate |
51
+ | API directory structure | Ring Standards | ❌ Do not duplicate |
52
+ | Business rules | Product docs (PRD) | ❌ Does not belong in PROJECT_RULES |
53
+
54
+ ---
55
+
56
+ ## Step 2: WebFetch Ring Standards (HARD GATE)
57
+
58
+ **⛔ CRITICAL: You CANNOT proceed without successfully loading standards.**
59
+
60
+ **MANDATORY ACTION:** You MUST use the WebFetch tool NOW.
61
+
62
+ | Parameter | Value |
63
+ |-----------|-------|
64
+ | url | See agent-specific URL below |
65
+ | prompt | "Extract all [domain] standards, patterns, and requirements" |
66
+
67
+ **Execute this WebFetch before proceeding.** Do not continue until standards are loaded and understood.
68
+
69
+ ### If WebFetch Fails → STOP IMMEDIATELY
70
+
71
+ **You CANNOT proceed. You CANNOT use "cached knowledge". You CANNOT assume patterns.**
72
+
73
+ ```markdown
74
+ ## Blocker
75
+
76
+ **Status:** BLOCKED - Cannot load standards
77
+ **Reason:** WebFetch failed for [standards_file].md
78
+ **URL Attempted:** [url]
79
+ **Error:** [error message or "timeout"]
80
+
81
+ **Required Action:**
82
+ 1. Retry WebFetch (max 2 retries)
83
+ 2. If still fails → Report to orchestrator
84
+ 3. User must resolve network/access issue
85
+
86
+ **I CANNOT proceed without standards. Inline patterns are FORBIDDEN.**
87
+ ```
88
+
89
+ ### Why This Is Non-Negotiable
90
+
91
+ | Rationalization | Why It's WRONG | Required Action |
92
+ |-----------------|----------------|-----------------|
93
+ | "I know the patterns from training" | Training data may be outdated. Standards evolve. | **MUST WebFetch current standards** |
94
+ | "I'll use general best practices" | General ≠ Lerian standards. Compliance requires specifics. | **MUST WebFetch current standards** |
95
+ | "WebFetch is slow, I'll skip it" | Speed ≠ correctness. Wrong patterns = rework. | **MUST WebFetch, wait for result** |
96
+ | "I'll add the patterns I remember" | Memory ≠ source of truth. Standards file is authoritative. | **MUST WebFetch current standards** |
97
+ | "Standards haven't changed recently" | You don't know this. Always fetch latest. | **MUST WebFetch current standards** |
98
+
99
+ ### Agent-Specific WebFetch URLs
100
+
101
+ | Agent | Standards File | URL |
102
+ |-------|---------------|-----|
103
+ | `genesis:backend-engineer-golang` | golang.md | `https://raw.githubusercontent.com/LerianStudio/ring/main/dev-team/docs/standards/golang.md` |
104
+ | `genesis:backend-engineer-typescript` | typescript.md | `https://raw.githubusercontent.com/LerianStudio/ring/main/dev-team/docs/standards/typescript.md` |
105
+ | `frontend-bff-engineer-typescript` | typescript.md | `https://raw.githubusercontent.com/LerianStudio/ring/main/dev-team/docs/standards/typescript.md` |
106
+ | `genesis:frontend-engineer` | frontend.md | `https://raw.githubusercontent.com/LerianStudio/ring/main/dev-team/docs/standards/frontend.md` |
107
+ | `genesis:frontend-designer` | frontend.md | `https://raw.githubusercontent.com/LerianStudio/ring/main/dev-team/docs/standards/frontend.md` |
108
+ | `genesis:devops-engineer` | devops.md | `https://raw.githubusercontent.com/LerianStudio/ring/main/dev-team/docs/standards/devops.md` |
109
+ | `genesis:sre` | sre.md | `https://raw.githubusercontent.com/LerianStudio/ring/main/dev-team/docs/standards/sre.md` |
110
+ | `genesis:qa-analyst` | golang.md or typescript.md | Based on project language (check PROJECT_RULES.md first) |
111
+ | `prompt-quality-reviewer` | N/A | Domain-independent (no standards WebFetch required) |
112
+
113
+ ---
114
+
115
+ ## Step 3: Apply Both Sources (MANDATORY)
116
+
117
+ - **Ring Standards** = Base technical patterns (error handling, testing, architecture)
118
+ - **PROJECT_RULES.md** = Project tech stack and specific patterns
119
+ - **Both are complementary. Neither excludes the other. Both must be followed.**
120
+
121
+ ### Precedence Rules
122
+
123
+ | Scenario | Resolution |
124
+ |----------|------------|
125
+ | Ring says X, PROJECT_RULES.md silent | Follow Ring |
126
+ | Ring says X, PROJECT_RULES.md says Y | Follow PROJECT_RULES.md (project can override) |
127
+ | Ring says X, PROJECT_RULES.md says "follow Ring" | Follow Ring |
128
+ | Neither covers topic | Ask user (STOP and report blocker) |
129
+
130
+ ---
131
+
132
+ ## Scenario 1: PROJECT_RULES.md Does Not Exist
133
+
134
+ **If `docs/PROJECT_RULES.md` does not exist → Offer to CREATE it with user input.**
135
+
136
+ **Action:** Guide user through PROJECT_RULES.md creation with automatic deduplication against Ring Standards.
137
+
138
+ ### Creation Flow
139
+
140
+ ```text
141
+ ┌─────────────────────────────────────────────────────────────────────────────┐
142
+ │ Step 1: WebFetch Ring Standards FIRST │
143
+ │ ├─ Load standards for detected language (Go, TypeScript, etc.) │
144
+ │ └─ This establishes what is ALREADY covered │
145
+ ├─────────────────────────────────────────────────────────────────────────────┤
146
+ │ Step 2: Analyze Codebase for Project-Specific Information │
147
+ │ ├─ Detect tech stack not in Ring (message brokers, caches, etc.) │
148
+ │ ├─ Detect non-standard directories (workers, consumers, etc.) │
149
+ │ ├─ Detect external integrations (third-party APIs, webhooks) │
150
+ │ └─ Detect domain terminology (entity names, module names) │
151
+ ├─────────────────────────────────────────────────────────────────────────────┤
152
+ │ Step 3: Ask User only for What Cannot Be Detected │
153
+ │ ├─ "Any external APIs or services not visible in code?" │
154
+ │ ├─ "Any specific environment variables needed?" │
155
+ │ └─ "Any planned tech not yet in codebase?" │
156
+ ├─────────────────────────────────────────────────────────────────────────────┤
157
+ │ Step 4: Generate PROJECT_RULES.md (Deduplicated) │
158
+ │ ├─ Header referencing Ring Standards │
159
+ │ ├─ only project-specific sections │
160
+ │ └─ no content that duplicates Ring Standards │
161
+ └─────────────────────────────────────────────────────────────────────────────┘
162
+ ```
163
+
164
+ ### PROJECT_RULES.md Template (Deduplicated)
165
+
166
+ ```markdown
167
+ # Project Rules
168
+
169
+ > ⛔ IMPORTANT: Ring Standards are not automatic. Agents MUST WebFetch them before implementation.
170
+ > This file documents only project-specific information not covered by Ring Standards.
171
+ >
172
+ > Ring Standards URLs:
173
+ > - Go: https://raw.githubusercontent.com/LerianStudio/ring/main/dev-team/docs/standards/golang.md
174
+ > - TypeScript: https://raw.githubusercontent.com/LerianStudio/ring/main/dev-team/docs/standards/typescript.md
175
+ > - Frontend: https://raw.githubusercontent.com/LerianStudio/ring/main/dev-team/docs/standards/frontend.md
176
+ > - DevOps: https://raw.githubusercontent.com/LerianStudio/ring/main/dev-team/docs/standards/devops.md
177
+ > - SRE: https://raw.githubusercontent.com/LerianStudio/ring/main/dev-team/docs/standards/sre.md
178
+
179
+ ## What Ring Standards Cover (DO not DUPLICATE HERE)
180
+
181
+ The following are defined in Ring Standards and MUST not be duplicated in this file:
182
+ - Error handling patterns (no panic, wrap errors)
183
+ - Logging standards (structured JSON via lib-commons)
184
+ - Testing patterns (table-driven tests, mocks)
185
+ - Architecture patterns (Hexagonal, Clean Architecture)
186
+ - Observability (OpenTelemetry via lib-commons)
187
+ - lib-commons / lib-common-js usage and patterns
188
+ - API directory structure (Lerian pattern)
189
+ - Database connections (PostgreSQL, MongoDB, Redis via lib-commons)
190
+ - Bootstrap pattern (config.go, service.go, server.go)
191
+
192
+ **Agents MUST WebFetch Ring Standards and output Standards Coverage Table.**
193
+
194
+ ---
195
+
196
+ ## Tech Stack (Not in Ring Standards)
197
+
198
+ [only technologies not covered by Ring Standards]
199
+
200
+ | Technology | Purpose | Notes |
201
+ |------------|---------|-------|
202
+ | [e.g., NATS] | [Message broker] | [Specific config notes] |
203
+ | [e.g., Valkey] | [Cache] | [If not Redis] |
204
+
205
+ ## Non-Standard Directory Structure
206
+
207
+ [only directories that deviate from Ring's standard API structure]
208
+
209
+ | Directory | Purpose | Pattern |
210
+ |-----------|---------|---------|
211
+ | [e.g., `workers/`] | [Pooling workers] | [Not API, different pattern] |
212
+ | [e.g., `consumers/`] | [Message consumers] | [Async processing] |
213
+
214
+ ## External Integrations
215
+
216
+ [Third-party services specific to this project]
217
+
218
+ | Service | Purpose | Docs |
219
+ |---------|---------|------|
220
+ | [e.g., Stripe] | [Payments] | [Link to integration docs] |
221
+ | [e.g., SendGrid] | [Email] | [Link] |
222
+
223
+ ## Environment Configuration
224
+
225
+ [Project-specific env vars not covered by Ring's standard config]
226
+
227
+ | Variable | Purpose | Example |
228
+ |----------|---------|---------|
229
+ | [e.g., `STRIPE_API_KEY`] | [Payment processing] | [Format notes] |
230
+
231
+ ## Domain Terminology
232
+
233
+ [Technical names used in this codebase]
234
+
235
+ | Term | Definition | Used In |
236
+ |------|------------|---------|
237
+ | [e.g., `Ledger`] | [Financial record container] | [Models, services] |
238
+
239
+ ---
240
+
241
+ *Generated: [ISO timestamp]*
242
+ *Ring Standards Version: [version from WebFetch]*
243
+ ```
244
+
245
+ ### Deduplication Validation
246
+
247
+ **Before saving PROJECT_RULES.md, validate no duplication exists:**
248
+
249
+ | If Content Mentions | Action |
250
+ |---------------------|--------|
251
+ | Error handling patterns | ❌ REMOVE - Ring Standards covers this |
252
+ | Logging format/structure | ❌ REMOVE - Ring Standards covers this |
253
+ | Testing patterns | ❌ REMOVE - Ring Standards covers this |
254
+ | lib-commons | ❌ REMOVE - Ring Standards covers this |
255
+ | Hexagonal/Clean Architecture | ❌ REMOVE - Ring Standards covers this |
256
+ | OpenTelemetry/tracing | ❌ REMOVE - Ring Standards covers this |
257
+ | Standard API directory structure | ❌ REMOVE - Ring Standards covers this |
258
+ | Business rules | ❌ REMOVE - Belongs in PRD/product docs |
259
+
260
+ ### Response Format (When PROJECT_RULES.md Missing)
261
+
262
+ ```markdown
263
+ ## PROJECT_RULES.md Not Found
264
+
265
+ I'll help you create `docs/PROJECT_RULES.md` with only project-specific information.
266
+
267
+ **Ring Standards already cover:**
268
+ - Error handling, logging, testing patterns
269
+ - Architecture (Hexagonal), observability (OpenTelemetry)
270
+ - lib-commons usage, API structure
271
+
272
+ **I need to document (if applicable):**
273
+ 1. Tech stack not in Ring (specific message broker, cache, etc.)
274
+ 2. Non-standard directories (workers, consumers, etc.)
275
+ 3. External integrations (third-party APIs)
276
+ 4. Project-specific environment variables
277
+ 5. Domain terminology (entity/module names)
278
+
279
+ **Analyzing codebase...**
280
+ [Analysis results]
281
+
282
+ **Questions (only what I couldn't detect):**
283
+ 1. Any external APIs or services not visible in code?
284
+ 2. Any specific environment variables needed?
285
+ 3. Any planned technology not yet implemented?
286
+ ```
287
+
288
+ ### Anti-Rationalization for Creation
289
+
290
+ | Rationalization | Why It's WRONG | Required Action |
291
+ |-----------------|----------------|-----------------|
292
+ | "Include error handling section anyway" | Ring Standards covers this. Duplication causes drift. | **REMOVE from PROJECT_RULES.md** |
293
+ | "Add lib-commons usage notes" | Ring Standards is the source of truth. | **REMOVE from PROJECT_RULES.md** |
294
+ | "Document testing patterns here" | Ring Standards defines testing patterns. | **REMOVE from PROJECT_RULES.md** |
295
+ | "Include business rules for context" | Business rules belong in PRD, not tech docs. | **REMOVE from PROJECT_RULES.md** |
296
+ | "Better to have everything in one place" | Single source of truth prevents drift. Ring = patterns. | **Reference Ring, don't duplicate** |
297
+
298
+ ---
299
+
300
+ ## Scenario 2: PROJECT_RULES.md Missing and Existing Code is Non-Compliant
301
+
302
+ **Scenario:** No PROJECT_RULES.md, existing code violates Ring Standards.
303
+
304
+ **Action:** STOP. Report blocker. Do not match non-compliant patterns.
305
+
306
+ ### Response Format
307
+
308
+ ```markdown
309
+ ## Blockers
310
+ - **Decision Required:** Project standards missing, existing code non-compliant
311
+ - **Current State:** Existing code uses [specific violations]
312
+ - **Options:**
313
+ 1. Create docs/PROJECT_RULES.md adopting Ring standards (RECOMMENDED)
314
+ 2. Document existing patterns as intentional project convention (requires explicit approval)
315
+ 3. Migrate existing code to Ring standards before implementing new features
316
+ - **Recommendation:** Option 1 - Establish standards first, then implement
317
+ - **Awaiting:** User decision on standards establishment
318
+ ```
319
+
320
+ ### Agent-Specific Non-Compliant Signs
321
+
322
+ | Agent Type | Signs of Non-Compliant Code |
323
+ |------------|----------------------------|
324
+ | **Go Backend** | `panic()` for errors, `fmt.Println` instead of structured logging, ignored errors with `result, _ :=`, no context propagation |
325
+ | **TypeScript Backend** | `any` types, no Zod validation, `// @ts-ignore`, missing Result type for errors |
326
+ | **Frontend** | No component tests, inline styles instead of design system, missing accessibility attributes |
327
+ | **DevOps** | Hardcoded secrets, no health checks, missing resource limits |
328
+ | **SRE** | Unstructured logging (plain text), missing trace_id correlation |
329
+ | **QA** | Tests without assertions, mocking implementation details, no edge cases |
330
+
331
+ **You CANNOT implement new code that matches non-compliant patterns. This is non-negotiable.**
332
+
333
+ ---
334
+
335
+ ## Scenario 3: Ask Only When Standards Don't Answer
336
+
337
+ After loading both PROJECT_RULES.md and Ring Standards:
338
+
339
+ **Ask when standards don't cover:**
340
+ - Database selection (PostgreSQL vs MongoDB)
341
+ - Authentication provider (WorkOS vs Auth0 vs custom)
342
+ - Multi-tenancy approach (schema vs row-level vs database-per-tenant)
343
+ - Message queue selection (RabbitMQ vs Kafka vs NATS)
344
+ - UI framework selection (React vs Vue vs Svelte)
345
+
346
+ **Don't ask (follow standards or best practices):**
347
+ - Error handling patterns → Follow Ring Standards
348
+ - Testing patterns → Follow Ring Standards
349
+ - Logging format → Follow Ring Standards
350
+ - Code structure → Check PROJECT_RULES.md or match compliant existing code
351
+
352
+ **IMPORTANT:** "Match existing code" only applies when existing code IS COMPLIANT. If existing code violates Ring Standards, DO NOT match it - report blocker instead.
353
+
354
+ ---
355
+
356
+ ## Anti-Rationalization
357
+
358
+ | Rationalization | Why It's WRONG | Required Action |
359
+ |-----------------|----------------|-----------------|
360
+ | "PROJECT_RULES.md not critical" | It defines everything. Cannot assume. | **STOP. Report blocker.** |
361
+ | "Existing code is fine to follow" | Only if compliant. Non-compliant = blocker. | **Verify compliance first** |
362
+ | "I'll just use best practices" | Best practices ≠ project conventions. | **Load PROJECT_RULES.md first** |
363
+ | "Small task, doesn't need rules" | All tasks need rules. Size is irrelevant. | **Load PROJECT_RULES.md first** |
364
+ | "I can infer from codebase" | Inference ≠ explicit standards. | **STOP. Report blocker.** |
365
+ | "I know the standards already" | Knowledge ≠ loading. Load for THIS task. | **Execute WebFetch NOW** |
366
+ | "Standards are too strict" | Standards exist to prevent failures. | **Follow Ring standards** |
367
+ | "WebFetch failed, use cached knowledge" | Stale knowledge causes drift. | **Report blocker, retry WebFetch** |
368
+
369
+ ---
370
+
371
+ ## How to Reference This File
372
+
373
+ Agents should include:
374
+
375
+ ```markdown
376
+ ## Standards Loading (MANDATORY)
377
+
378
+ See [shared-patterns/standards-workflow.md](../skills/shared-patterns/standards-workflow.md) for:
379
+ - Full loading process (PROJECT_RULES.md + WebFetch)
380
+ - Precedence rules
381
+ - Missing/non-compliant handling
382
+ - Anti-rationalization table
383
+
384
+ **Agent-Specific Configuration:**
385
+
386
+ | Setting | Value |
387
+ |---------|-------|
388
+ | **WebFetch URL** | `https://raw.githubusercontent.com/LerianStudio/ring/main/dev-team/docs/standards/{file}.md` |
389
+ | **Standards File** | {file}.md |
390
+ | **Prompt** | "Extract all [domain] standards, patterns, and requirements" |
391
+ ```
@@ -0,0 +1,30 @@
1
+ # Universal State Tracking Pattern
2
+
3
+ Add this section to any multi-step skill:
4
+
5
+ ## State Tracking (MANDATORY)
6
+
7
+ Create and maintain a status comment:
8
+
9
+ ```
10
+ SKILL: [skill-name]
11
+ PHASE: [current phase/step]
12
+ COMPLETED: [✓ list what's done]
13
+ NEXT: [→ what's next]
14
+ EVIDENCE: [last verification output]
15
+ BLOCKED: [any blockers]
16
+ ```
17
+
18
+ **Update after EACH phase/step.**
19
+
20
+ Example:
21
+ ```
22
+ SKILL: systematic-debugging
23
+ PHASE: 2 - Pattern Analysis
24
+ COMPLETED: ✓ Error reproduced ✓ Recent changes reviewed
25
+ NEXT: → Compare with working examples
26
+ EVIDENCE: Test fails with "KeyError: 'user_id'"
27
+ BLOCKED: None
28
+ ```
29
+
30
+ This comment should be included in EVERY response while using the skill.
@@ -0,0 +1,38 @@
1
+ # Universal TodoWrite Integration
2
+
3
+ Add this requirement to skill starts:
4
+
5
+ ## TodoWrite Requirement
6
+
7
+ **BEFORE starting this skill:**
8
+
9
+ 1. Create todos for major phases:
10
+ ```javascript
11
+ [
12
+ {content: "Phase 1: [name]", status: "in_progress", activeForm: "Working on Phase 1"},
13
+ {content: "Phase 2: [name]", status: "pending", activeForm: "Working on Phase 2"},
14
+ {content: "Phase 3: [name]", status: "pending", activeForm: "Working on Phase 3"}
15
+ ]
16
+ ```
17
+
18
+ 2. Update after each phase:
19
+ - Mark complete when done
20
+ - Move next to in_progress
21
+ - Add any new discovered tasks
22
+
23
+ 3. Never work without todos:
24
+ - Skipping todos = skipping the skill
25
+ - Mental tracking = guaranteed to miss steps
26
+ - Todos are your external memory
27
+
28
+ **Example for debugging:**
29
+ ```javascript
30
+ [
31
+ {content: "Root cause investigation", status: "in_progress", ...},
32
+ {content: "Pattern analysis", status: "pending", ...},
33
+ {content: "Hypothesis testing", status: "pending", ...},
34
+ {content: "Implementation", status: "pending", ...}
35
+ ]
36
+ ```
37
+
38
+ If you're not updating todos, you're not following the skill.
@@ -0,0 +1,45 @@
1
+ ---
2
+ name: genesis:previce
3
+ description: Main implementation workflow (Planejamento, Revisão, Execução, Validação, Confirmação).
4
+ trigger: |
5
+ - New feature request
6
+ - Bug fix implementation
7
+ - Architectural refactoring
8
+ ---
9
+
10
+ # ⚡ PREVICE Workflow - Genesis Grid AI Labs
11
+
12
+ Este é o workflow mandatório para o desenvolvimento no **GG-Framework**. Ele garante governança, qualidade e alinhamento com a visão de **Guilherme Giorgi (GG)**.
13
+
14
+ ## Fases do Ciclo
15
+
16
+ ### 1. P - Planejamento (Planning)
17
+ **Objetivo:** Definir o escopo e a estratégia técnica antes de codar.
18
+ - **Ação:** O agente `genesis:architect` deve criar um arquivo de plano em `.context/plans/[YYYY-MM-DD]-[feature-name].md`.
19
+ - **Conteúdo:** Objetivo, arquivos afetados, agent lineup e passos detalhados (bite-sized).
20
+
21
+ ### 2. R - Revisão (Review)
22
+ **Objetivo:** Validação humana (GG) do plano técnico.
23
+ - **Ação:** Notificar o usuário para revisar o plano gerado.
24
+ - **Critério de Saída:** Aprovação explícita do usuário.
25
+
26
+ ### 3. E - Execução (Execution)
27
+ **Objetivo:** Implementação do código seguindo o plano.
28
+ - **Ação:** Executar os passos do plano um a um.
29
+ - **Regra:** Usar agentes especialistas (`genesis:ui_specialist`, `genesis:bug_hunter`) conforme necessário.
30
+
31
+ ### 4. V - Validação (Validation)
32
+ **Objetivo:** Garantir que a implementação está correta e segura.
33
+ - **Ação:** Rodar testes (unitários/E2E) e realizar o check visual do Genesis Design System.
34
+ - **Ferramenta:** Usar `genesis:bug_hunter` para auditoria de estabilidade.
35
+
36
+ ### 5. C - Confirmação (Confirmation)
37
+ **Objetivo:** Finalização e entrega.
38
+ - **Ação:** Realizar o commit com mensagem padronizada e informar ao usuário o sucesso da tarefa.
39
+
40
+ ## Regras de Execução
41
+ - **TODO Tracking:** Use um arquivo `task.md` ou similar para rastrear o progresso de cada fase.
42
+ - **Context Preservation:** Mantenha o estado do workflow em `.context/workflow/state.json`.
43
+
44
+ ---
45
+ *Genesis Grid AI Labs - Efficiency by Design.*