sumulige-claude 1.5.1 → 1.5.2

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 (219) hide show
  1. package/.claude/hooks/hook-registry.json +0 -15
  2. package/.claude/rules/coding-style.md +18 -7
  3. package/.claude/rules/hooks.md +15 -4
  4. package/.claude/rules/performance.md +15 -5
  5. package/.claude/rules/security.md +140 -4
  6. package/.claude/rules/testing.md +138 -9
  7. package/.claude/rules/web-design-standard.md +16 -5
  8. package/.claude/skills/algorithmic-art/metadata.yaml +28 -0
  9. package/.claude/skills/api-tester/SKILL.md +61 -0
  10. package/.claude/skills/api-tester/examples/basic.md +3 -0
  11. package/.claude/skills/api-tester/metadata.yaml +30 -0
  12. package/.claude/skills/api-tester/templates/default.md +3 -0
  13. package/.claude/skills/brand-guidelines/metadata.yaml +26 -0
  14. package/.claude/skills/canvas-design/metadata.yaml +27 -0
  15. package/.claude/skills/code-reviewer-123/SKILL.md +61 -0
  16. package/.claude/skills/code-reviewer-123/examples/basic.md +3 -0
  17. package/.claude/skills/code-reviewer-123/metadata.yaml +30 -0
  18. package/.claude/skills/code-reviewer-123/templates/default.md +3 -0
  19. package/.claude/skills/doc-coauthoring/metadata.yaml +27 -0
  20. package/.claude/skills/docx/metadata.yaml +30 -0
  21. package/.claude/skills/frontend-design/metadata.yaml +28 -0
  22. package/.claude/skills/internal-comms/metadata.yaml +28 -0
  23. package/.claude/skills/mcp-builder/metadata.yaml +26 -0
  24. package/.claude/skills/my-skill/SKILL.md +61 -0
  25. package/.claude/skills/my-skill/examples/basic.md +3 -0
  26. package/.claude/skills/my-skill/metadata.yaml +30 -0
  27. package/.claude/skills/my-skill/templates/default.md +3 -0
  28. package/.claude/skills/pdf/metadata.yaml +29 -0
  29. package/.claude/skills/pptx/metadata.yaml +29 -0
  30. package/.claude/skills/react-best-practices/metadata.yaml +26 -0
  31. package/.claude/skills/react-node-practices/SKILL.md +409 -0
  32. package/.claude/skills/react-node-practices/metadata.yaml +56 -0
  33. package/.claude/skills/skill-creator/metadata.yaml +25 -0
  34. package/.claude/skills/slack-gif-creator/metadata.yaml +28 -0
  35. package/.claude/skills/test-skill-name/SKILL.md +61 -0
  36. package/.claude/skills/test-skill-name/examples/basic.md +3 -0
  37. package/.claude/skills/test-skill-name/metadata.yaml +30 -0
  38. package/.claude/skills/test-skill-name/templates/default.md +3 -0
  39. package/.claude/skills/test-workflow/metadata.yaml +32 -0
  40. package/.claude/skills/theme-factory/metadata.yaml +26 -0
  41. package/.claude/skills/threejs-fundamentals/metadata.yaml +27 -0
  42. package/.claude/skills/web-artifacts-builder/metadata.yaml +30 -0
  43. package/.claude/skills/web-design-guidelines/metadata.yaml +26 -0
  44. package/.claude/skills/webapp-testing/metadata.yaml +26 -0
  45. package/.claude/skills/xlsx/metadata.yaml +29 -0
  46. package/LICENSE +21 -0
  47. package/cli.js +1 -1
  48. package/package.json +25 -3
  49. package/.claude/.kickoff-hint.txt +0 -52
  50. package/.claude/.sumulige-claude-version +0 -1
  51. package/.claude/.version +0 -1
  52. package/.claude/AGENTS.md +0 -42
  53. package/.claude/ANCHORS.md +0 -40
  54. package/.claude/CLAUDE.md +0 -138
  55. package/.claude/MEMORY.md +0 -69
  56. package/.claude/PROJECT_LOG.md +0 -101
  57. package/.claude/THINKING_CHAIN_GUIDE.md +0 -287
  58. package/.claude/USAGE.md +0 -175
  59. package/.claude/boris-optimizations.md +0 -167
  60. package/.claude/handoffs/INDEX.md +0 -21
  61. package/.claude/handoffs/LATEST.md +0 -76
  62. package/.claude/handoffs/handoff_2026-01-22T13-07-04-757Z.md +0 -76
  63. package/.claude/quality-gate.json +0 -82
  64. package/.claude/rag/skill-index.json +0 -135
  65. package/.claude/settings.json +0 -99
  66. package/.claude/settings.local.json +0 -175
  67. package/.claude/templates/PROJECT_KICKOFF.md +0 -89
  68. package/.claude/templates/PROJECT_PROPOSAL.md +0 -227
  69. package/.claude/templates/TASK_PLAN.md +0 -121
  70. package/.claude/templates/hooks/README.md +0 -302
  71. package/.claude/templates/hooks/hook.sh.template +0 -94
  72. package/.claude/templates/hooks/user-prompt-submit.cjs.template +0 -116
  73. package/.claude/templates/hooks/user-response-submit.cjs.template +0 -94
  74. package/.claude/templates/hooks/validate.js +0 -173
  75. package/.claude/templates/tasks/develop.md +0 -69
  76. package/.claude/templates/tasks/research.md +0 -64
  77. package/.claude/templates/tasks/test.md +0 -96
  78. package/.claude/thinking-routes/.last-sync +0 -1
  79. package/.claude/thinking-routes/QUICKREF.md +0 -98
  80. package/.claude/workflow/document-scanner.js +0 -426
  81. package/.claude/workflow/knowledge-engine.js +0 -941
  82. package/.claude/workflow/notebooklm/browser.js +0 -1028
  83. package/.claude/workflow/phases/phase1-research.js +0 -578
  84. package/.claude/workflow/phases/phase1-research.ts +0 -465
  85. package/.claude/workflow/phases/phase2-approve.js +0 -722
  86. package/.claude/workflow/phases/phase3-plan.js +0 -1200
  87. package/.claude/workflow/phases/phase4-develop.js +0 -894
  88. package/.claude/workflow/search-cache.js +0 -230
  89. package/.claude/workflow/templates/approval.md +0 -315
  90. package/.claude/workflow/templates/development.md +0 -377
  91. package/.claude/workflow/templates/planning.md +0 -328
  92. package/.claude/workflow/templates/research.md +0 -250
  93. package/.claude/workflow/types.js +0 -37
  94. package/.claude/workflow/web-search.js +0 -278
  95. package/.claude-plugin/marketplace.json +0 -71
  96. package/.github/workflows/sync-skills.yml +0 -74
  97. package/.versionrc +0 -25
  98. package/AGENTS.md +0 -580
  99. package/CHANGELOG.md +0 -481
  100. package/CLAUDE-template.md +0 -114
  101. package/DEV_TOOLS_GUIDE.md +0 -190
  102. package/PROJECT_STRUCTURE.md +0 -266
  103. package/Q&A.md +0 -325
  104. package/config/defaults.json +0 -34
  105. package/config/official-skills.json +0 -183
  106. package/config/quality-gate.json +0 -67
  107. package/config/skill-categories.json +0 -40
  108. package/config/version-manifest.json +0 -85
  109. package/demos/power-3d-scatter.html +0 -683
  110. package/development/cache/web-search/search_1193d605f8eb364651fc2f2041b58a31.json +0 -36
  111. package/development/cache/web-search/search_3798bf06960edc125f744a1abb5b72c5.json +0 -36
  112. package/development/cache/web-search/search_37c7d4843a53f0d83f1122a6f908a2a3.json +0 -36
  113. package/development/cache/web-search/search_44166fa0153709ee168485a22aa0ab40.json +0 -36
  114. package/development/cache/web-search/search_4deaebb1f77e86a8ca066dc5a49c59fd.json +0 -36
  115. package/development/cache/web-search/search_94da91789466070a7f545612e73c7372.json +0 -36
  116. package/development/cache/web-search/search_dd5de8491b8b803a3cb01339cd210fb0.json +0 -36
  117. package/development/knowledge-base/.index.clean.json +0 -1
  118. package/development/knowledge-base/.index.json +0 -486
  119. package/development/knowledge-base/test-best-practices.md +0 -29
  120. package/development/projects/proj_mkh1pazz_ixmt1/phase1/feasibility-report.md +0 -160
  121. package/development/projects/proj_mkh4jvnb_z7rwf/phase1/feasibility-report.md +0 -160
  122. package/development/projects/proj_mkh4jxkd_ewz5a/phase1/feasibility-report.md +0 -160
  123. package/development/projects/proj_mkh4k84n_ni73k/phase1/feasibility-report.md +0 -160
  124. package/development/projects/proj_mkh4wfyd_u9w88/phase1/feasibility-report.md +0 -160
  125. package/development/projects/proj_mkh4wsbo_iahvf/development/projects/proj_mkh4xbpg_4na5w/phase1/feasibility-report.md +0 -160
  126. package/development/projects/proj_mkh4wsbo_iahvf/phase1/feasibility-report.md +0 -160
  127. package/development/projects/proj_mkh4xulg_1ka8x/phase1/feasibility-report.md +0 -160
  128. package/development/projects/proj_mkh4xwhj_gch8j/phase1/feasibility-report.md +0 -160
  129. package/development/projects/proj_mkh4y2qk_9lm8z/phase1/feasibility-report.md +0 -160
  130. package/development/projects/proj_mkh4y2qk_9lm8z/phase2/requirements.md +0 -226
  131. package/development/projects/proj_mkh4y2qk_9lm8z/phase3/PRD.md +0 -345
  132. package/development/projects/proj_mkh4y2qk_9lm8z/phase3/TASK_PLAN.md +0 -284
  133. package/development/projects/proj_mkh4y2qk_9lm8z/phase3/prototype/README.md +0 -14
  134. package/development/projects/proj_mkh4y2qk_9lm8z/phase4/DEVELOPMENT_LOG.md +0 -35
  135. package/development/projects/proj_mkh4y2qk_9lm8z/phase4/TASKS.md +0 -34
  136. package/development/projects/proj_mkh4y2qk_9lm8z/phase4/source/.env.example +0 -5
  137. package/development/projects/proj_mkh4y2qk_9lm8z/phase4/source/README.md +0 -60
  138. package/development/projects/proj_mkh4y2qk_9lm8z/phase4/source/package.json +0 -25
  139. package/development/projects/proj_mkh4y2qk_9lm8z/phase4/source/src/index.js +0 -70
  140. package/development/projects/proj_mkh4y2qk_9lm8z/phase4/source/src/routes/index.js +0 -48
  141. package/development/projects/proj_mkh4y2qk_9lm8z/phase4/source/tests/health.test.js +0 -20
  142. package/development/projects/proj_mkh4y2qk_9lm8z/phase4/source/tests/jest.config.js +0 -21
  143. package/development/projects/proj_mkh7veqg_3lypc/phase1/feasibility-report.md +0 -160
  144. package/development/projects/proj_mkh7veqg_3lypc/phase2/requirements.md +0 -226
  145. package/development/projects/proj_mkh7veqg_3lypc/phase3/PRD.md +0 -345
  146. package/development/projects/proj_mkh7veqg_3lypc/phase3/TASK_PLAN.md +0 -284
  147. package/development/projects/proj_mkh7veqg_3lypc/phase3/prototype/README.md +0 -14
  148. package/development/projects/proj_mkh8k8fo_rmqn5/phase1/feasibility-report.md +0 -160
  149. package/development/projects/proj_mkh8xyhy_1vshq/phase1/feasibility-report.md +0 -178
  150. package/development/projects/proj_mkh8zddd_dhamf/phase1/feasibility-report.md +0 -377
  151. package/development/projects/proj_mkh8zddd_dhamf/phase2/requirements.md +0 -442
  152. package/development/projects/proj_mkh8zddd_dhamf/phase3/api-design.md +0 -800
  153. package/development/projects/proj_mkh8zddd_dhamf/phase3/architecture.md +0 -625
  154. package/development/projects/proj_mkh8zddd_dhamf/phase3/data-model.md +0 -830
  155. package/development/projects/proj_mkh8zddd_dhamf/phase3/risks.md +0 -957
  156. package/development/projects/proj_mkh8zddd_dhamf/phase3/wbs.md +0 -381
  157. package/development/todos/.state.json +0 -19
  158. package/development/todos/INDEX.md +0 -63
  159. package/development/todos/active/_README.md +0 -49
  160. package/development/todos/archived/_README.md +0 -11
  161. package/development/todos/backlog/_README.md +0 -11
  162. package/development/todos/backlog/mcp-integration.md +0 -35
  163. package/development/todos/completed/_README.md +0 -11
  164. package/development/todos/completed/boris-optimizations.md +0 -39
  165. package/development/todos/completed/develop/local-knowledge-index.md +0 -85
  166. package/development/todos/completed/develop/todo-system.md +0 -47
  167. package/development/todos/completed/develop/web-search-integration.md +0 -83
  168. package/development/todos/completed/test/phase1-e2e-test.md +0 -103
  169. package/docs/DEVELOPMENT.md +0 -461
  170. package/docs/MARKETPLACE.md +0 -352
  171. package/docs/RELEASE.md +0 -93
  172. package/jest.config.js +0 -63
  173. package/lib/commands.js +0 -3588
  174. package/lib/config-manager.js +0 -441
  175. package/lib/config-schema.js +0 -408
  176. package/lib/config-validator.js +0 -330
  177. package/lib/config.js +0 -122
  178. package/lib/errors.js +0 -305
  179. package/lib/incremental-sync.js +0 -274
  180. package/lib/marketplace.js +0 -487
  181. package/lib/migrations.js +0 -154
  182. package/lib/permission-audit.js +0 -255
  183. package/lib/quality-gate.js +0 -431
  184. package/lib/quality-rules.js +0 -373
  185. package/lib/utils.js +0 -150
  186. package/lib/version-check.js +0 -169
  187. package/lib/version-manifest.js +0 -171
  188. package/project-paradigm.md +0 -313
  189. package/prompts/how-to-find.md +0 -163
  190. package/prompts/linus-architect.md +0 -71
  191. package/prompts/software-architect.md +0 -173
  192. package/prompts/web-designer.md +0 -249
  193. package/scripts/fix-hooks.mjs +0 -97
  194. package/scripts/sync-external.mjs +0 -298
  195. package/scripts/sync-to-home.sh +0 -108
  196. package/scripts/update-registry.mjs +0 -325
  197. package/sources.yaml +0 -83
  198. package/tests/README.md +0 -263
  199. package/tests/commands.test.js +0 -1086
  200. package/tests/config-manager.test.js +0 -677
  201. package/tests/config-schema.test.js +0 -425
  202. package/tests/config-validator.test.js +0 -436
  203. package/tests/config.test.js +0 -100
  204. package/tests/errors.test.js +0 -477
  205. package/tests/manual/phase1-e2e.sh +0 -389
  206. package/tests/manual/phase2-test-cases.md +0 -311
  207. package/tests/manual/phase3-test-cases.md +0 -309
  208. package/tests/manual/phase4-test-cases.md +0 -414
  209. package/tests/manual/test-cases.md +0 -417
  210. package/tests/marketplace.test.js +0 -420
  211. package/tests/migrations.test.js +0 -187
  212. package/tests/quality-gate.test.js +0 -679
  213. package/tests/quality-rules.test.js +0 -619
  214. package/tests/sync-external.test.js +0 -214
  215. package/tests/update-registry.test.js +0 -251
  216. package/tests/utils.test.js +0 -171
  217. package/tests/version-check.test.js +0 -75
  218. package/tests/web-search.test.js +0 -392
  219. package/thinkinglens-silent.md +0 -138
@@ -1,465 +0,0 @@
1
- /**
2
- * Phase 1: Research - NotebookLM Feasibility Analysis
3
- *
4
- * This phase uses NotebookLM (via notebooklm-mcp integration) to:
5
- * 1. Structure requirements
6
- * 2. Connect dots with related work
7
- * 3. Research best practices
8
- * 4. Assess feasibility
9
- *
10
- * Output: feasibility-report.md
11
- */
12
-
13
- import * as fs from 'fs';
14
- import * as path from 'path';
15
- import { getKnowledgeEngine } from '../knowledge-engine';
16
- import { FeasibilityValidator } from '../validators/feasibility';
17
- import type { FeasibilityReport, ProjectPhase, ProgressCallback } from '../types';
18
-
19
- // ============================================================================
20
- // Configuration
21
- // ============================================================================
22
-
23
- const PROJECTS_DIR = path.join(process.cwd(), 'development/projects');
24
-
25
- // ============================================================================
26
- // Phase 1 Executor
27
- // ============================================================================
28
-
29
- export class Phase1ResearchExecutor {
30
- private projectId: string;
31
- private projectDir: string;
32
- private phaseDir: string;
33
- private reportPath: string;
34
-
35
- constructor(projectId: string) {
36
- this.projectId = projectId;
37
- this.projectDir = path.join(PROJECTS_DIR, projectId);
38
- this.phaseDir = path.join(this.projectDir, 'phase1');
39
- this.reportPath = path.join(this.phaseDir, 'feasibility-report.md');
40
- }
41
-
42
- /**
43
- * Execute Phase 1 research workflow
44
- */
45
- async execute(
46
- idea: string,
47
- context: string = '',
48
- progressCallback?: ProgressCallback
49
- ): Promise<FeasibilityReport> {
50
- await progressCallback?.('Initializing Phase 1 research...', 0, 5);
51
-
52
- // Ensure directories exist
53
- await this.ensureDirectories();
54
-
55
- // Step 1: Gather knowledge
56
- await progressCallback?.('Gathering relevant knowledge...', 1, 5);
57
- const knowledgeContext = await this.gatherKnowledge(idea);
58
-
59
- // Step 2: Generate research prompt
60
- await progressCallback?.('Preparing research prompt...', 2, 5);
61
- const prompt = this.generatePrompt(idea, context, knowledgeContext);
62
-
63
- // Step 3: Save prompt for Claude/AI to execute
64
- await progressCallback?.('Generating feasibility report...', 3, 5);
65
- await this.savePrompt(prompt);
66
-
67
- // Step 4: Return structured result for AI execution
68
- await progressCallback?.('Preparing AI execution context...', 4, 5);
69
-
70
- const reportTemplate = this.generateReportTemplate(idea, context, knowledgeContext);
71
- await fs.promises.writeFile(this.reportPath, reportTemplate, 'utf-8');
72
-
73
- await progressCallback?.('Phase 1 research context prepared. Ready for AI analysis.', 5, 5);
74
-
75
- return {
76
- projectId: this.projectId,
77
- createdAt: Date.now(),
78
- requirements: {
79
- summary: idea,
80
- keyFeatures: [],
81
- constraints: [],
82
- assumptions: []
83
- },
84
- correlations: {
85
- relatedProjects: [],
86
- overlappingTech: [],
87
- lessonsLearned: []
88
- },
89
- bestPractices: [],
90
- feasibility: {
91
- technical: 0,
92
- time: 0,
93
- complexity: 'medium',
94
- risks: []
95
- },
96
- recommendations: {
97
- techStack: [],
98
- architecture: '',
99
- potentialIssues: [],
100
- nextSteps: [
101
- 'Review and complete the feasibility report',
102
- 'Validate with quality gate: smc workflow validate',
103
- 'Proceed to Phase 2: Claude approval'
104
- ]
105
- },
106
- quality: {
107
- completeness: 0,
108
- confidence: 0,
109
- sourcesCount: knowledgeContext.sourceCount,
110
- webSearchPerformed: false
111
- }
112
- };
113
- }
114
-
115
- /**
116
- * Gather relevant knowledge from knowledge base
117
- */
118
- private async gatherKnowledge(idea: string): Promise<{
119
- sources: Array<{ title: string; type: string; relevance: number }>;
120
- excerpts: string[];
121
- sourceCount: number;
122
- }> {
123
- const engine = getKnowledgeEngine();
124
- const result = await engine.query(idea, { includeWeb: true });
125
-
126
- return {
127
- sources: result.sources.map(s => ({
128
- title: s.title,
129
- type: s.type,
130
- relevance: s.relevance
131
- })),
132
- excerpts: result.sources.map(s => s.excerpt || '').filter(Boolean),
133
- sourceCount: result.sources.length
134
- };
135
- }
136
-
137
- /**
138
- * Generate research prompt for AI execution
139
- */
140
- private generatePrompt(idea: string, context: string, knowledgeContext: any): string {
141
- return `
142
- # Phase 1 Research Task
143
-
144
- ## User Idea
145
- ${idea}
146
-
147
- ${context ? `## Additional Context\n${context}\n` : ''}
148
-
149
- ## Knowledge Context
150
- Found ${knowledgeContext.sourceCount} relevant sources in the knowledge base.
151
-
152
- ${knowledgeContext.sources.length > 0 ? `
153
- ### Relevant Sources
154
- ${knowledgeContext.sources.map((s: any) => `- ${s.title} (${(s.relevance * 100).toFixed(0)}% relevance)`).join('\n')}
155
- ` : ''}
156
-
157
- ## Your Task
158
-
159
- Please complete a comprehensive feasibility analysis following the template in:
160
- ${path.join(__dirname, '../templates/research.md')}
161
-
162
- ## Output
163
-
164
- Save the complete feasibility report to:
165
- ${this.reportPath}
166
-
167
- Then validate with: smc workflow validate ${this.reportPath}
168
- `.trim();
169
- }
170
-
171
- /**
172
- * Generate report template for AI to fill
173
- */
174
- private generateReportTemplate(idea: string, context: string, knowledgeContext: any): string {
175
- const date = new Date().toLocaleDateString();
176
- const time = new Date().toLocaleTimeString();
177
-
178
- return `# Feasibility Analysis Report
179
-
180
- **Project**: ${this.projectId}
181
- **Date**: ${date} ${time}
182
- **Phase**: 1 - Research
183
- **Status**: 🚧 In Progress
184
-
185
- ---
186
-
187
- ## Executive Summary
188
-
189
- > Brief overview of the project and feasibility assessment
190
-
191
- ---
192
-
193
- ## Requirements Summary
194
-
195
- ### Problem Statement
196
- [What problem are we solving?]
197
-
198
- ### Target Users
199
- [Who will use this? What are their pain points?]
200
-
201
- ### Key Features
202
- 1. [Feature 1]
203
- 2. [Feature 2]
204
- 3. [Feature 3]
205
-
206
- ### Constraints
207
- - [Constraint 1]
208
- - [Constraint 2]
209
-
210
- ### Assumptions
211
- - [Assumption 1]
212
- - [Assumption 2]
213
-
214
- ---
215
-
216
- ## Original Idea
217
-
218
- ${idea}
219
-
220
- ${context ? `### Additional Context\n${context}` : ''}
221
-
222
- ---
223
-
224
- ## Correlation Analysis (Connect The Dots)
225
-
226
- ### Related Projects
227
- | Project | Similarity | Reusable Components |
228
- |---------|------------|---------------------|
229
- | [Project A] | 85% | [Component list] |
230
- | [Project B] | 60% | [Component list] |
231
-
232
- ### Overlapping Technology
233
- - [Tech stack overlap]
234
- - [Shared libraries]
235
- - [Common patterns]
236
-
237
- ### Lessons from History
238
- - [Lesson 1]: [Context and outcome]
239
- - [Lesson 2]: [Context and outcome]
240
-
241
- ### Risks Based on History
242
- - [Risk from past project]: [How we'll address it]
243
-
244
- ---
245
-
246
- ## Industry Best Practices
247
-
248
- ### Architecture
249
- **Practice**: [Specific practice]
250
- **Rationale**: [Why this is recommended]
251
- **Sources**: [Citations]
252
- **Applicability**: [How this applies to current project]
253
-
254
- ### Security
255
- **Practice**: [Security best practice]
256
- **Rationale**: [Why this matters]
257
- **Sources**: [Citations]
258
-
259
- ### Performance
260
- **Practice**: [Performance approach]
261
- **Rationale**: [Performance considerations]
262
-
263
- ### UX/UI
264
- **Practice**: [UX principle]
265
- **Rationale**: [User experience impact]
266
-
267
- ---
268
-
269
- ## Feasibility Assessment
270
-
271
- ### Technical Feasibility: ⭐⭐⭐☆☆ (3/5)
272
-
273
- **Strengths**:
274
- - [Strength 1]
275
- - [Strength 2]
276
-
277
- **Challenges**:
278
- - [Challenge 1]: [Mitigation strategy]
279
- - [Challenge 2]: [Mitigation strategy]
280
-
281
- ### Time Estimate: X hours
282
-
283
- **Breakdown**:
284
- - Research & Planning: Xh
285
- - Design: Xh
286
- - Implementation: Xh
287
- - Testing: Xh
288
- - Documentation: Xh
289
-
290
- **Total**: X hours
291
-
292
- ### Complexity: Medium
293
-
294
- **Reasoning**: [Explain complexity assessment]
295
-
296
- ### Risk Assessment
297
-
298
- | Risk | Severity | Probability | Mitigation |
299
- |------|----------|-------------|------------|
300
- | [Risk 1] | High | Medium | [Mitigation strategy] |
301
- | [Risk 2] | Medium | Low | [Mitigation strategy] |
302
- | [Risk 3] | Low | Low | [Mitigation strategy] |
303
-
304
- ---
305
-
306
- ## Recommendations
307
-
308
- ### Recommended Tech Stack
309
-
310
- **Frontend**:
311
- - [Choice 1] - [Rationale]
312
- - [Choice 2] - [Rationale]
313
-
314
- **Backend**:
315
- - [Choice 1] - [Rationale]
316
- - [Choice 2] - [Rationale]
317
-
318
- **Database**:
319
- - [Choice] - [Rationale]
320
-
321
- **Other**:
322
- - [Choice] - [Rationale]
323
-
324
- ### Suggested Architecture
325
-
326
- [High-level architecture description - could include diagrams]
327
-
328
- ### Potential Issues to Watch
329
-
330
- 1. **[Issue 1]**: [Monitoring approach, early warning signs]
331
- 2. **[Issue 2]**: [Monitoring approach, early warning signs]
332
- 3. **[Issue 3]**: [Monitoring approach, early warning signs]
333
-
334
- ### Next Steps (Phase 2: Approval)
335
-
336
- 1. [ ] Review this report and ensure all sections are complete
337
- 2. [ ] Run quality gate: \`smc workflow validate ${this.reportPath}\`
338
- 3. [ ] Address any blockers identified
339
- 4. [ ] Proceed to Phase 2 for Claude review and consensus
340
-
341
- ---
342
-
343
- ## Quality Checklist
344
-
345
- - [x] Requirement summary is clear and complete
346
- - [ ] Correlation analysis found related work/patterns
347
- - [ ] Best practices are cited with sources
348
- - [ ] Feasibility has concrete ratings (not vague)
349
- - [ ] Time estimate is justified
350
- - [ ] Risks have mitigation strategies
351
- - [ ] Recommendations are actionable
352
-
353
- ---
354
-
355
- ## Metadata
356
-
357
- - **Generated**: ${date} ${time}
358
- - **Knowledge Sources Queried**: ${knowledgeContext.sourceCount}
359
- - **Web Search Performed**: No
360
- - **Confidence Level**: [To be filled by AI]
361
-
362
- ---
363
-
364
- *This report was generated by the Phase 1 Research Executor. Please complete all sections before proceeding to Phase 2.*
365
- `;
366
- }
367
-
368
- /**
369
- * Save prompt for AI execution
370
- */
371
- private async savePrompt(prompt: string): Promise<void> {
372
- const promptPath = path.join(this.phaseDir, 'research-prompt.md');
373
- await fs.promises.writeFile(promptPath, prompt, 'utf-8');
374
- }
375
-
376
- /**
377
- * Ensure project directories exist
378
- */
379
- private async ensureDirectories(): Promise<void> {
380
- await fs.promises.mkdir(this.projectDir, { recursive: true });
381
- await fs.promises.mkdir(this.phaseDir, { recursive: true });
382
- }
383
-
384
- /**
385
- * Get the report path
386
- */
387
- getReportPath(): string {
388
- return this.reportPath;
389
- }
390
-
391
- /**
392
- * Check if report exists
393
- */
394
- reportExists(): boolean {
395
- return fs.existsSync(this.reportPath);
396
- }
397
-
398
- /**
399
- * Read the existing report
400
- */
401
- readReport(): string | null {
402
- if (!this.reportExists()) return null;
403
- return fs.readFileSync(this.reportPath, 'utf-8');
404
- }
405
-
406
- /**
407
- * Validate the report
408
- */
409
- validateReport() {
410
- return FeasibilityValidator.validateFile(this.reportPath);
411
- }
412
- }
413
-
414
- // ============================================================================
415
- // Project Management Helpers
416
- // ============================================================================
417
-
418
- export function generateProjectId(): string {
419
- const timestamp = Date.now().toString(36);
420
- const random = Math.random().toString(36).substr(2, 5);
421
- return `proj_${timestamp}_${random}`;
422
- }
423
-
424
- export async function createProject(idea: string, context: string = ''): Promise<string> {
425
- const projectId = generateProjectId();
426
- const executor = new Phase1ResearchExecutor(projectId);
427
-
428
- await executor.execute(idea, context, (msg, current, total) => {
429
- const progress = Math.round((current / total) * 100);
430
- console.log(`[${progress}%] ${msg}`);
431
- });
432
-
433
- return projectId;
434
- }
435
-
436
- export function listProjects(): Array<{
437
- id: string;
438
- path: string;
439
- hasReport: boolean;
440
- }> {
441
- if (!fs.existsSync(PROJECTS_DIR)) {
442
- return [];
443
- }
444
-
445
- const projects: Array<{
446
- id: string;
447
- path: string;
448
- hasReport: boolean;
449
- }> = [];
450
-
451
- const entries = fs.readdirSync(PROJECTS_DIR, { withFileTypes: true });
452
- for (const entry of entries) {
453
- if (entry.isDirectory() && entry.name.startsWith('proj_')) {
454
- const projectPath = path.join(PROJECTS_DIR, entry.name);
455
- const reportPath = path.join(projectPath, 'phase1', 'feasibility-report.md');
456
- projects.push({
457
- id: entry.name,
458
- path: projectPath,
459
- hasReport: fs.existsSync(reportPath)
460
- });
461
- }
462
- }
463
-
464
- return projects.sort((a, b) => b.id.localeCompare(a.id));
465
- }