@mobiman/vector 1.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 (225) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +117 -0
  3. package/agents/vector-codebase-mapper.md +770 -0
  4. package/agents/vector-debugger.md +1338 -0
  5. package/agents/vector-executor.md +487 -0
  6. package/agents/vector-integration-checker.md +443 -0
  7. package/agents/vector-nyquist-auditor.md +176 -0
  8. package/agents/vector-phase-researcher.md +553 -0
  9. package/agents/vector-plan-checker.md +706 -0
  10. package/agents/vector-planner.md +1307 -0
  11. package/agents/vector-project-researcher.md +629 -0
  12. package/agents/vector-research-synthesizer.md +247 -0
  13. package/agents/vector-roadmapper.md +650 -0
  14. package/agents/vector-ui-auditor.md +439 -0
  15. package/agents/vector-ui-checker.md +300 -0
  16. package/agents/vector-ui-researcher.md +353 -0
  17. package/agents/vector-verifier.md +579 -0
  18. package/bin/install.cjs +2907 -0
  19. package/bin/install.cjs.map +1 -0
  20. package/bin/install.cts +3103 -0
  21. package/bin/install.d.cts +3 -0
  22. package/bin/install.d.cts.map +1 -0
  23. package/commands/vector/add-phase.md +43 -0
  24. package/commands/vector/add-tests.md +41 -0
  25. package/commands/vector/add-todo.md +47 -0
  26. package/commands/vector/audit-milestone.md +36 -0
  27. package/commands/vector/autonomous.md +41 -0
  28. package/commands/vector/check-todos.md +45 -0
  29. package/commands/vector/cleanup.md +18 -0
  30. package/commands/vector/complete-milestone.md +136 -0
  31. package/commands/vector/debug.md +168 -0
  32. package/commands/vector/discuss-phase.md +90 -0
  33. package/commands/vector/do.md +30 -0
  34. package/commands/vector/execute-phase.md +41 -0
  35. package/commands/vector/health.md +22 -0
  36. package/commands/vector/help.md +22 -0
  37. package/commands/vector/insert-phase.md +32 -0
  38. package/commands/vector/join-discord.md +18 -0
  39. package/commands/vector/list-phase-assumptions.md +46 -0
  40. package/commands/vector/map-codebase.md +71 -0
  41. package/commands/vector/new-milestone.md +44 -0
  42. package/commands/vector/new-project.md +42 -0
  43. package/commands/vector/pause-work.md +38 -0
  44. package/commands/vector/plan-milestone-gaps.md +34 -0
  45. package/commands/vector/plan-phase.md +45 -0
  46. package/commands/vector/progress.md +24 -0
  47. package/commands/vector/quick.md +47 -0
  48. package/commands/vector/reapply-patches.md +123 -0
  49. package/commands/vector/remove-phase.md +31 -0
  50. package/commands/vector/research-phase.md +190 -0
  51. package/commands/vector/resume-work.md +40 -0
  52. package/commands/vector/set-profile.md +12 -0
  53. package/commands/vector/settings.md +36 -0
  54. package/commands/vector/stats.md +18 -0
  55. package/commands/vector/ui-phase.md +34 -0
  56. package/commands/vector/ui-review.md +32 -0
  57. package/commands/vector/update.md +37 -0
  58. package/commands/vector/validate-phase.md +35 -0
  59. package/commands/vector/verify-work.md +38 -0
  60. package/core/bin/lib/commands.cjs +641 -0
  61. package/core/bin/lib/commands.cjs.map +1 -0
  62. package/core/bin/lib/commands.cts +712 -0
  63. package/core/bin/lib/commands.d.cts +23 -0
  64. package/core/bin/lib/commands.d.cts.map +1 -0
  65. package/core/bin/lib/config.cjs +281 -0
  66. package/core/bin/lib/config.cjs.map +1 -0
  67. package/core/bin/lib/config.cts +301 -0
  68. package/core/bin/lib/config.d.cts +50 -0
  69. package/core/bin/lib/config.d.cts.map +1 -0
  70. package/core/bin/lib/core.cjs +483 -0
  71. package/core/bin/lib/core.cjs.map +1 -0
  72. package/core/bin/lib/core.cts +544 -0
  73. package/core/bin/lib/core.d.cts +96 -0
  74. package/core/bin/lib/core.d.cts.map +1 -0
  75. package/core/bin/lib/frontmatter.cjs +341 -0
  76. package/core/bin/lib/frontmatter.cjs.map +1 -0
  77. package/core/bin/lib/frontmatter.cts +295 -0
  78. package/core/bin/lib/frontmatter.d.cts +18 -0
  79. package/core/bin/lib/frontmatter.d.cts.map +1 -0
  80. package/core/bin/lib/init.cjs +674 -0
  81. package/core/bin/lib/init.cjs.map +1 -0
  82. package/core/bin/lib/init.cts +775 -0
  83. package/core/bin/lib/init.d.cts +16 -0
  84. package/core/bin/lib/init.d.cts.map +1 -0
  85. package/core/bin/lib/milestone.cjs +210 -0
  86. package/core/bin/lib/milestone.cjs.map +1 -0
  87. package/core/bin/lib/milestone.cts +241 -0
  88. package/core/bin/lib/milestone.d.cts +11 -0
  89. package/core/bin/lib/milestone.d.cts.map +1 -0
  90. package/core/bin/lib/model-profiles.cjs +62 -0
  91. package/core/bin/lib/model-profiles.cjs.map +1 -0
  92. package/core/bin/lib/model-profiles.cts +66 -0
  93. package/core/bin/lib/model-profiles.d.cts +33 -0
  94. package/core/bin/lib/model-profiles.d.cts.map +1 -0
  95. package/core/bin/lib/phase.cjs +713 -0
  96. package/core/bin/lib/phase.cjs.map +1 -0
  97. package/core/bin/lib/phase.cts +914 -0
  98. package/core/bin/lib/phase.d.cts +21 -0
  99. package/core/bin/lib/phase.d.cts.map +1 -0
  100. package/core/bin/lib/roadmap.cjs +246 -0
  101. package/core/bin/lib/roadmap.cjs.map +1 -0
  102. package/core/bin/lib/roadmap.cts +311 -0
  103. package/core/bin/lib/roadmap.d.cts +7 -0
  104. package/core/bin/lib/roadmap.d.cts.map +1 -0
  105. package/core/bin/lib/state.cjs +709 -0
  106. package/core/bin/lib/state.cjs.map +1 -0
  107. package/core/bin/lib/state.cts +718 -0
  108. package/core/bin/lib/state.d.cts +47 -0
  109. package/core/bin/lib/state.d.cts.map +1 -0
  110. package/core/bin/lib/template.cjs +220 -0
  111. package/core/bin/lib/template.cjs.map +1 -0
  112. package/core/bin/lib/template.cts +229 -0
  113. package/core/bin/lib/template.d.cts +15 -0
  114. package/core/bin/lib/template.d.cts.map +1 -0
  115. package/core/bin/lib/verify.cjs +824 -0
  116. package/core/bin/lib/verify.cjs.map +1 -0
  117. package/core/bin/lib/verify.cts +829 -0
  118. package/core/bin/lib/verify.d.cts +17 -0
  119. package/core/bin/lib/verify.d.cts.map +1 -0
  120. package/core/bin/vector-tools.cjs +641 -0
  121. package/core/bin/vector-tools.cjs.map +1 -0
  122. package/core/bin/vector-tools.cts +603 -0
  123. package/core/bin/vector-tools.d.cts +128 -0
  124. package/core/bin/vector-tools.d.cts.map +1 -0
  125. package/core/references/checkpoints.md +776 -0
  126. package/core/references/continuation-format.md +249 -0
  127. package/core/references/decimal-phase-calculation.md +65 -0
  128. package/core/references/git-integration.md +248 -0
  129. package/core/references/git-planning-commit.md +38 -0
  130. package/core/references/model-profile-resolution.md +36 -0
  131. package/core/references/model-profiles.md +101 -0
  132. package/core/references/phase-argument-parsing.md +61 -0
  133. package/core/references/planning-config.md +200 -0
  134. package/core/references/questioning.md +162 -0
  135. package/core/references/tdd.md +263 -0
  136. package/core/references/ui-brand.md +160 -0
  137. package/core/references/verification-patterns.md +612 -0
  138. package/core/templates/DEBUG.md +164 -0
  139. package/core/templates/UAT.md +247 -0
  140. package/core/templates/UI-SPEC.md +100 -0
  141. package/core/templates/VALIDATION.md +76 -0
  142. package/core/templates/codebase/architecture.md +255 -0
  143. package/core/templates/codebase/concerns.md +310 -0
  144. package/core/templates/codebase/conventions.md +307 -0
  145. package/core/templates/codebase/integrations.md +280 -0
  146. package/core/templates/codebase/stack.md +186 -0
  147. package/core/templates/codebase/structure.md +285 -0
  148. package/core/templates/codebase/testing.md +480 -0
  149. package/core/templates/config.json +37 -0
  150. package/core/templates/context.md +352 -0
  151. package/core/templates/continue-here.md +78 -0
  152. package/core/templates/copilot-instructions.md +7 -0
  153. package/core/templates/debug-subagent-prompt.md +91 -0
  154. package/core/templates/discovery.md +146 -0
  155. package/core/templates/milestone-archive.md +123 -0
  156. package/core/templates/milestone.md +115 -0
  157. package/core/templates/phase-prompt.md +610 -0
  158. package/core/templates/planner-subagent-prompt.md +117 -0
  159. package/core/templates/project.md +184 -0
  160. package/core/templates/requirements.md +231 -0
  161. package/core/templates/research-project/ARCHITECTURE.md +204 -0
  162. package/core/templates/research-project/FEATURES.md +147 -0
  163. package/core/templates/research-project/PITFALLS.md +200 -0
  164. package/core/templates/research-project/STACK.md +120 -0
  165. package/core/templates/research-project/SUMMARY.md +170 -0
  166. package/core/templates/research.md +552 -0
  167. package/core/templates/retrospective.md +54 -0
  168. package/core/templates/roadmap.md +202 -0
  169. package/core/templates/state.md +176 -0
  170. package/core/templates/summary-complex.md +59 -0
  171. package/core/templates/summary-minimal.md +41 -0
  172. package/core/templates/summary-standard.md +48 -0
  173. package/core/templates/summary.md +248 -0
  174. package/core/templates/user-setup.md +311 -0
  175. package/core/templates/verification-report.md +322 -0
  176. package/core/workflows/add-phase.md +112 -0
  177. package/core/workflows/add-tests.md +351 -0
  178. package/core/workflows/add-todo.md +158 -0
  179. package/core/workflows/audit-milestone.md +332 -0
  180. package/core/workflows/autonomous.md +743 -0
  181. package/core/workflows/check-todos.md +177 -0
  182. package/core/workflows/cleanup.md +152 -0
  183. package/core/workflows/complete-milestone.md +766 -0
  184. package/core/workflows/diagnose-issues.md +219 -0
  185. package/core/workflows/discovery-phase.md +289 -0
  186. package/core/workflows/discuss-phase.md +762 -0
  187. package/core/workflows/do.md +104 -0
  188. package/core/workflows/execute-phase.md +468 -0
  189. package/core/workflows/execute-plan.md +483 -0
  190. package/core/workflows/health.md +159 -0
  191. package/core/workflows/help.md +513 -0
  192. package/core/workflows/insert-phase.md +130 -0
  193. package/core/workflows/list-phase-assumptions.md +178 -0
  194. package/core/workflows/map-codebase.md +316 -0
  195. package/core/workflows/new-milestone.md +386 -0
  196. package/core/workflows/new-project.md +1113 -0
  197. package/core/workflows/node-repair.md +92 -0
  198. package/core/workflows/pause-work.md +122 -0
  199. package/core/workflows/plan-milestone-gaps.md +274 -0
  200. package/core/workflows/plan-phase.md +666 -0
  201. package/core/workflows/progress.md +382 -0
  202. package/core/workflows/quick.md +717 -0
  203. package/core/workflows/remove-phase.md +155 -0
  204. package/core/workflows/research-phase.md +74 -0
  205. package/core/workflows/resume-project.md +307 -0
  206. package/core/workflows/settings.md +243 -0
  207. package/core/workflows/stats.md +60 -0
  208. package/core/workflows/transition.md +544 -0
  209. package/core/workflows/ui-phase.md +290 -0
  210. package/core/workflows/ui-review.md +157 -0
  211. package/core/workflows/update.md +320 -0
  212. package/core/workflows/validate-phase.md +167 -0
  213. package/core/workflows/verify-phase.md +243 -0
  214. package/core/workflows/verify-work.md +584 -0
  215. package/package.json +55 -0
  216. package/scripts/build-hooks.cjs +38 -0
  217. package/scripts/build-hooks.cjs.map +1 -0
  218. package/scripts/build-hooks.cts +41 -0
  219. package/scripts/build-hooks.d.cts +6 -0
  220. package/scripts/build-hooks.d.cts.map +1 -0
  221. package/scripts/run-tests.cjs +28 -0
  222. package/scripts/run-tests.cjs.map +1 -0
  223. package/scripts/run-tests.cts +28 -0
  224. package/scripts/run-tests.d.cts +3 -0
  225. package/scripts/run-tests.d.cts.map +1 -0
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Phase — Phase CRUD, query, and lifecycle operations
3
+ */
4
+ interface PhasesListOptions {
5
+ type?: string | null;
6
+ phase?: string | null;
7
+ includeArchived?: boolean;
8
+ }
9
+ export declare function cmdPhasesList(cwd: string, options: PhasesListOptions, raw: boolean): void;
10
+ export declare function cmdPhaseNextDecimal(cwd: string, basePhase: string, raw: boolean): void;
11
+ export declare function cmdFindPhase(cwd: string, phase: string | undefined, raw: boolean): void;
12
+ export declare function cmdPhasePlanIndex(cwd: string, phase: string | undefined, raw: boolean): void;
13
+ export declare function cmdPhaseAdd(cwd: string, description: string, raw: boolean): void;
14
+ export declare function cmdPhaseInsert(cwd: string, afterPhase: string, description: string, raw: boolean): void;
15
+ interface PhaseRemoveOptions {
16
+ force?: boolean;
17
+ }
18
+ export declare function cmdPhaseRemove(cwd: string, targetPhase: string | undefined, options: PhaseRemoveOptions, raw: boolean): void;
19
+ export declare function cmdPhaseComplete(cwd: string, phaseNum: string | undefined, raw: boolean): void;
20
+ export {};
21
+ //# sourceMappingURL=phase.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"phase.d.cts","sourceRoot":"","sources":["phase.cts"],"names":[],"mappings":"AAAA;;GAEG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@@ -0,0 +1,246 @@
1
+ "use strict";
2
+ /**
3
+ * Roadmap — Roadmap parsing and update operations
4
+ */
5
+ var __importDefault = (this && this.__importDefault) || function (mod) {
6
+ return (mod && mod.__esModule) ? mod : { "default": mod };
7
+ };
8
+ Object.defineProperty(exports, "__esModule", { value: true });
9
+ exports.cmdRoadmapGetPhase = cmdRoadmapGetPhase;
10
+ exports.cmdRoadmapAnalyze = cmdRoadmapAnalyze;
11
+ exports.cmdRoadmapUpdatePlanProgress = cmdRoadmapUpdatePlanProgress;
12
+ const fs_1 = __importDefault(require("fs"));
13
+ const path_1 = __importDefault(require("path"));
14
+ const core_cjs_1 = require("./core.cjs");
15
+ function cmdRoadmapGetPhase(cwd, phaseNum, raw) {
16
+ const roadmapPath = path_1.default.join(cwd, '.planning', 'ROADMAP.md');
17
+ if (!fs_1.default.existsSync(roadmapPath)) {
18
+ (0, core_cjs_1.output)({ found: false, error: 'ROADMAP.md not found' }, raw, '');
19
+ return;
20
+ }
21
+ try {
22
+ const content = (0, core_cjs_1.stripShippedMilestones)(fs_1.default.readFileSync(roadmapPath, 'utf-8'));
23
+ // Escape special regex chars in phase number, handle decimal
24
+ const escapedPhase = (0, core_cjs_1.escapeRegex)(phaseNum);
25
+ // Match "## Phase X:", "### Phase X:", or "#### Phase X:" with optional name
26
+ const phasePattern = new RegExp(`#{2,4}\\s*Phase\\s+${escapedPhase}:\\s*([^\\n]+)`, 'i');
27
+ const headerMatch = content.match(phasePattern);
28
+ if (!headerMatch) {
29
+ // Fallback: check if phase exists in summary list but missing detail section
30
+ const checklistPattern = new RegExp(`-\\s*\\[[ x]\\]\\s*\\*\\*Phase\\s+${escapedPhase}:\\s*([^*]+)\\*\\*`, 'i');
31
+ const checklistMatch = content.match(checklistPattern);
32
+ if (checklistMatch) {
33
+ // Phase exists in summary but missing detail section - malformed ROADMAP
34
+ (0, core_cjs_1.output)({
35
+ found: false,
36
+ phase_number: phaseNum,
37
+ phase_name: checklistMatch[1].trim(),
38
+ error: 'malformed_roadmap',
39
+ message: `Phase ${phaseNum} exists in summary list but missing "### Phase ${phaseNum}:" detail section. ROADMAP.md needs both formats.`
40
+ }, raw, '');
41
+ return;
42
+ }
43
+ (0, core_cjs_1.output)({ found: false, phase_number: phaseNum }, raw, '');
44
+ return;
45
+ }
46
+ const phaseName = headerMatch[1].trim();
47
+ const headerIndex = headerMatch.index;
48
+ // Find the end of this section (next ## or ### phase header, or end of file)
49
+ const restOfContent = content.slice(headerIndex);
50
+ const nextHeaderMatch = restOfContent.match(/\n#{2,4}\s+Phase\s+\d/i);
51
+ const sectionEnd = nextHeaderMatch
52
+ ? headerIndex + nextHeaderMatch.index
53
+ : content.length;
54
+ const section = content.slice(headerIndex, sectionEnd).trim();
55
+ // Extract goal if present (supports both **Goal:** and **Goal**: formats)
56
+ const goalMatch = section.match(/\*\*Goal(?::\*\*|\*\*:)\s*([^\n]+)/i);
57
+ const goal = goalMatch ? goalMatch[1].trim() : null;
58
+ // Extract success criteria as structured array
59
+ const criteriaMatch = section.match(/\*\*Success Criteria\*\*[^\n]*:\s*\n((?:\s*\d+\.\s*[^\n]+\n?)+)/i);
60
+ const success_criteria = criteriaMatch
61
+ ? criteriaMatch[1].trim().split('\n').map(line => line.replace(/^\s*\d+\.\s*/, '').trim()).filter(Boolean)
62
+ : [];
63
+ (0, core_cjs_1.output)({
64
+ found: true,
65
+ phase_number: phaseNum,
66
+ phase_name: phaseName,
67
+ goal,
68
+ success_criteria,
69
+ section,
70
+ }, raw, section);
71
+ }
72
+ catch (e) {
73
+ (0, core_cjs_1.error)('Failed to read ROADMAP.md: ' + e.message);
74
+ }
75
+ }
76
+ function cmdRoadmapAnalyze(cwd, raw) {
77
+ const roadmapPath = path_1.default.join(cwd, '.planning', 'ROADMAP.md');
78
+ if (!fs_1.default.existsSync(roadmapPath)) {
79
+ (0, core_cjs_1.output)({ error: 'ROADMAP.md not found', milestones: [], phases: [], current_phase: null }, raw);
80
+ return;
81
+ }
82
+ const rawContent = fs_1.default.readFileSync(roadmapPath, 'utf-8');
83
+ const content = (0, core_cjs_1.stripShippedMilestones)(rawContent);
84
+ const phasesDir = path_1.default.join(cwd, '.planning', 'phases');
85
+ // Extract all phase headings: ## Phase N: Name or ### Phase N: Name
86
+ const phasePattern = /#{2,4}\s*Phase\s+(\d+[A-Z]?(?:\.\d+)*)\s*:\s*([^\n]+)/gi;
87
+ const phases = [];
88
+ let match;
89
+ while ((match = phasePattern.exec(content)) !== null) {
90
+ const phaseNum = match[1];
91
+ const phaseName = match[2].replace(/\(INSERTED\)/i, '').trim();
92
+ // Extract goal from the section
93
+ const sectionStart = match.index;
94
+ const restOfContent = content.slice(sectionStart);
95
+ const nextHeader = restOfContent.match(/\n#{2,4}\s+Phase\s+\d/i);
96
+ const sectionEnd = nextHeader ? sectionStart + nextHeader.index : content.length;
97
+ const section = content.slice(sectionStart, sectionEnd);
98
+ const goalMatch = section.match(/\*\*Goal(?::\*\*|\*\*:)\s*([^\n]+)/i);
99
+ const goal = goalMatch ? goalMatch[1].trim() : null;
100
+ const dependsMatch = section.match(/\*\*Depends on(?::\*\*|\*\*:)\s*([^\n]+)/i);
101
+ const depends_on = dependsMatch ? dependsMatch[1].trim() : null;
102
+ // Check completion on disk
103
+ const normalized = (0, core_cjs_1.normalizePhaseName)(phaseNum);
104
+ let diskStatus = 'no_directory';
105
+ let planCount = 0;
106
+ let summaryCount = 0;
107
+ let hasContext = false;
108
+ let hasResearch = false;
109
+ try {
110
+ const entries = fs_1.default.readdirSync(phasesDir, { withFileTypes: true });
111
+ const dirs = entries.filter(e => e.isDirectory()).map(e => e.name);
112
+ const dirMatch = dirs.find(d => d.startsWith(normalized + '-') || d === normalized);
113
+ if (dirMatch) {
114
+ const phaseFiles = fs_1.default.readdirSync(path_1.default.join(phasesDir, dirMatch));
115
+ planCount = phaseFiles.filter(f => f.endsWith('-PLAN.md') || f === 'PLAN.md').length;
116
+ summaryCount = phaseFiles.filter(f => f.endsWith('-SUMMARY.md') || f === 'SUMMARY.md').length;
117
+ hasContext = phaseFiles.some(f => f.endsWith('-CONTEXT.md') || f === 'CONTEXT.md');
118
+ hasResearch = phaseFiles.some(f => f.endsWith('-RESEARCH.md') || f === 'RESEARCH.md');
119
+ if (summaryCount >= planCount && planCount > 0)
120
+ diskStatus = 'complete';
121
+ else if (summaryCount > 0)
122
+ diskStatus = 'partial';
123
+ else if (planCount > 0)
124
+ diskStatus = 'planned';
125
+ else if (hasResearch)
126
+ diskStatus = 'researched';
127
+ else if (hasContext)
128
+ diskStatus = 'discussed';
129
+ else
130
+ diskStatus = 'empty';
131
+ }
132
+ }
133
+ catch { }
134
+ // Check ROADMAP checkbox status
135
+ const checkboxPattern = new RegExp(`-\\s*\\[(x| )\\]\\s*.*Phase\\s+${(0, core_cjs_1.escapeRegex)(phaseNum)}[:\\s]`, 'i');
136
+ const checkboxMatch = content.match(checkboxPattern);
137
+ const roadmapComplete = checkboxMatch ? checkboxMatch[1] === 'x' : false;
138
+ // If roadmap marks phase complete, trust that over disk file structure.
139
+ // Phases completed before Vector tracking (or via external tools) may lack
140
+ // the standard PLAN/SUMMARY pairs but are still done.
141
+ if (roadmapComplete && diskStatus !== 'complete') {
142
+ diskStatus = 'complete';
143
+ }
144
+ phases.push({
145
+ number: phaseNum,
146
+ name: phaseName,
147
+ goal,
148
+ depends_on,
149
+ plan_count: planCount,
150
+ summary_count: summaryCount,
151
+ has_context: hasContext,
152
+ has_research: hasResearch,
153
+ disk_status: diskStatus,
154
+ roadmap_complete: roadmapComplete,
155
+ });
156
+ }
157
+ // Extract milestone info
158
+ const milestones = [];
159
+ const milestonePattern = /##\s*(.*v(\d+\.\d+)[^(\n]*)/gi;
160
+ let mMatch;
161
+ while ((mMatch = milestonePattern.exec(content)) !== null) {
162
+ milestones.push({
163
+ heading: mMatch[1].trim(),
164
+ version: 'v' + mMatch[2],
165
+ });
166
+ }
167
+ // Find current and next phase
168
+ const currentPhase = phases.find(p => p.disk_status === 'planned' || p.disk_status === 'partial') || null;
169
+ const nextPhase = phases.find(p => p.disk_status === 'empty' || p.disk_status === 'no_directory' || p.disk_status === 'discussed' || p.disk_status === 'researched') || null;
170
+ // Aggregated stats
171
+ const totalPlans = phases.reduce((sum, p) => sum + p.plan_count, 0);
172
+ const totalSummaries = phases.reduce((sum, p) => sum + p.summary_count, 0);
173
+ const completedPhases = phases.filter(p => p.disk_status === 'complete').length;
174
+ // Detect phases in summary list without detail sections (malformed ROADMAP)
175
+ const checklistPattern = /-\s*\[[ x]\]\s*\*\*Phase\s+(\d+[A-Z]?(?:\.\d+)*)/gi;
176
+ const checklistPhases = new Set();
177
+ let checklistMatch;
178
+ while ((checklistMatch = checklistPattern.exec(content)) !== null) {
179
+ checklistPhases.add(checklistMatch[1]);
180
+ }
181
+ const detailPhases = new Set(phases.map(p => p.number));
182
+ const missingDetails = [...checklistPhases].filter(p => !detailPhases.has(p));
183
+ const result = {
184
+ milestones,
185
+ phases,
186
+ phase_count: phases.length,
187
+ completed_phases: completedPhases,
188
+ total_plans: totalPlans,
189
+ total_summaries: totalSummaries,
190
+ progress_percent: totalPlans > 0 ? Math.min(100, Math.round((totalSummaries / totalPlans) * 100)) : 0,
191
+ current_phase: currentPhase ? currentPhase.number : null,
192
+ next_phase: nextPhase ? nextPhase.number : null,
193
+ missing_phase_details: missingDetails.length > 0 ? missingDetails : null,
194
+ };
195
+ (0, core_cjs_1.output)(result, raw);
196
+ }
197
+ function cmdRoadmapUpdatePlanProgress(cwd, phaseNum, raw) {
198
+ if (!phaseNum) {
199
+ (0, core_cjs_1.error)('phase number required for roadmap update-plan-progress');
200
+ }
201
+ const roadmapPath = path_1.default.join(cwd, '.planning', 'ROADMAP.md');
202
+ const phaseInfo = (0, core_cjs_1.findPhaseInternal)(cwd, phaseNum);
203
+ if (!phaseInfo) {
204
+ (0, core_cjs_1.error)(`Phase ${phaseNum} not found`);
205
+ }
206
+ const planCount = phaseInfo.plans.length;
207
+ const summaryCount = phaseInfo.summaries.length;
208
+ if (planCount === 0) {
209
+ (0, core_cjs_1.output)({ updated: false, reason: 'No plans found', plan_count: 0, summary_count: 0 }, raw, 'no plans');
210
+ return;
211
+ }
212
+ const isComplete = summaryCount >= planCount;
213
+ const status = isComplete ? 'Complete' : summaryCount > 0 ? 'In Progress' : 'Planned';
214
+ const today = new Date().toISOString().split('T')[0];
215
+ if (!fs_1.default.existsSync(roadmapPath)) {
216
+ (0, core_cjs_1.output)({ updated: false, reason: 'ROADMAP.md not found', plan_count: planCount, summary_count: summaryCount }, raw, 'no roadmap');
217
+ return;
218
+ }
219
+ let roadmapContent = fs_1.default.readFileSync(roadmapPath, 'utf-8');
220
+ const phaseEscaped = (0, core_cjs_1.escapeRegex)(phaseNum);
221
+ // Progress table row: update Plans column (summaries/plans) and Status column
222
+ const tablePattern = new RegExp(`(\\|\\s*${phaseEscaped}\\.?\\s[^|]*\\|)[^|]*(\\|)\\s*[^|]*(\\|)\\s*[^|]*(\\|)`, 'i');
223
+ const dateField = isComplete ? ` ${today} ` : ' ';
224
+ roadmapContent = (0, core_cjs_1.replaceInCurrentMilestone)(roadmapContent, tablePattern, `$1 ${summaryCount}/${planCount} $2 ${status.padEnd(11)}$3${dateField}$4`);
225
+ // Update plan count in phase detail section
226
+ const planCountPattern = new RegExp(`(#{2,4}\\s*Phase\\s+${phaseEscaped}[\\s\\S]*?\\*\\*Plans:\\*\\*\\s*)[^\\n]+`, 'i');
227
+ const planCountText = isComplete
228
+ ? `${summaryCount}/${planCount} plans complete`
229
+ : `${summaryCount}/${planCount} plans executed`;
230
+ roadmapContent = (0, core_cjs_1.replaceInCurrentMilestone)(roadmapContent, planCountPattern, `$1${planCountText}`);
231
+ // If complete: check checkbox
232
+ if (isComplete) {
233
+ const checkboxPattern = new RegExp(`(-\\s*\\[)[ ](\\]\\s*.*Phase\\s+${phaseEscaped}[:\\s][^\\n]*)`, 'i');
234
+ roadmapContent = (0, core_cjs_1.replaceInCurrentMilestone)(roadmapContent, checkboxPattern, `$1x$2 (completed ${today})`);
235
+ }
236
+ fs_1.default.writeFileSync(roadmapPath, roadmapContent, 'utf-8');
237
+ (0, core_cjs_1.output)({
238
+ updated: true,
239
+ phase: phaseNum,
240
+ plan_count: planCount,
241
+ summary_count: summaryCount,
242
+ status,
243
+ complete: isComplete,
244
+ }, raw, `${summaryCount}/${planCount} ${status}`);
245
+ }
246
+ //# sourceMappingURL=roadmap.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"roadmap.cjs","sourceRoot":"","sources":["roadmap.cts"],"names":[],"mappings":";AAAA;;GAEG;;;;;AAMH,gDAkFC;AAED,8CAgJC;AAED,oEAwEC;AAlTD,4CAAoB;AACpB,gDAAwB;AACxB,yCAAkJ;AAElJ,SAAgB,kBAAkB,CAAC,GAAW,EAAE,QAAgB,EAAE,GAAY;IAC5E,MAAM,WAAW,GAAG,cAAI,CAAC,IAAI,CAAC,GAAG,EAAE,WAAW,EAAE,YAAY,CAAC,CAAC;IAE9D,IAAI,CAAC,YAAE,CAAC,UAAU,CAAC,WAAW,CAAC,EAAE,CAAC;QAChC,IAAA,iBAAM,EAAC,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,sBAAsB,EAAE,EAAE,GAAG,EAAE,EAAE,CAAC,CAAC;QACjE,OAAO;IACT,CAAC;IAED,IAAI,CAAC;QACH,MAAM,OAAO,GAAG,IAAA,iCAAsB,EAAC,YAAE,CAAC,YAAY,CAAC,WAAW,EAAE,OAAO,CAAC,CAAC,CAAC;QAE9E,6DAA6D;QAC7D,MAAM,YAAY,GAAG,IAAA,sBAAW,EAAC,QAAQ,CAAC,CAAC;QAE3C,6EAA6E;QAC7E,MAAM,YAAY,GAAG,IAAI,MAAM,CAC7B,sBAAsB,YAAY,gBAAgB,EAClD,GAAG,CACJ,CAAC;QACF,MAAM,WAAW,GAAG,OAAO,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC;QAEhD,IAAI,CAAC,WAAW,EAAE,CAAC;YACjB,6EAA6E;YAC7E,MAAM,gBAAgB,GA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AM,eAAe,GAAG,IAAI,MAAM,CAChC,mCAAmC,YAAY,gBAAgB,EAC/D,GAAG,CACJ,CAAC;QACF,cAAc,GAAG,IAAA,oCAAyB,EAAC,cAAc,EAAE,eAAe,EAAE,oBAAoB,KAAK,GAAG,CAAC,CAAC;IAC5G,CAAC;IAED,YAAE,CAAC,aAAa,CAAC,WAAW,EAAE,cAAc,EAAE,OAAO,CAAC,CAAC;IAEvD,IAAA,iBAAM,EAAC;QACL,OAAO,EAAE,IAAI;QACb,KAAK,EAAE,QAAQ;QACf,UAAU,EAAE,SAAS;QACrB,aAAa,EAAE,YAAY;QAC3B,MAAM;QACN,QAAQ,EAAE,UAAU;KACrB,EAAE,GAAG,EAAE,GAAG,YAAY,IAAI,SAAS,IAAI,MAAM,EAAE,CAAC,CAAC;AACpD,CAAC"}
@@ -0,0 +1,311 @@
1
+ /**
2
+ * Roadmap — Roadmap parsing and update operations
3
+ */
4
+
5
+ import fs from 'fs';
6
+ import path from 'path';
7
+ import { escapeRegex, normalizePhaseName, output, error, findPhaseInternal, stripShippedMilestones, replaceInCurrentMilestone } from './core.cjs';
8
+
9
+ export function cmdRoadmapGetPhase(cwd: string, phaseNum: string, raw: boolean): void {
10
+ const roadmapPath = path.join(cwd, '.planning', 'ROADMAP.md');
11
+
12
+ if (!fs.existsSync(roadmapPath)) {
13
+ output({ found: false, error: 'ROADMAP.md not found' }, raw, '');
14
+ return;
15
+ }
16
+
17
+ try {
18
+ const content = stripShippedMilestones(fs.readFileSync(roadmapPath, 'utf-8'));
19
+
20
+ // Escape special regex chars in phase number, handle decimal
21
+ const escapedPhase = escapeRegex(phaseNum);
22
+
23
+ // Match "## Phase X:", "### Phase X:", or "#### Phase X:" with optional name
24
+ const phasePattern = new RegExp(
25
+ `#{2,4}\\s*Phase\\s+${escapedPhase}:\\s*([^\\n]+)`,
26
+ 'i'
27
+ );
28
+ const headerMatch = content.match(phasePattern);
29
+
30
+ if (!headerMatch) {
31
+ // Fallback: check if phase exists in summary list but missing detail section
32
+ const checklistPattern = new RegExp(
33
+ `-\\s*\\[[ x]\\]\\s*\\*\\*Phase\\s+${escapedPhase}:\\s*([^*]+)\\*\\*`,
34
+ 'i'
35
+ );
36
+ const checklistMatch = content.match(checklistPattern);
37
+
38
+ if (checklistMatch) {
39
+ // Phase exists in summary but missing detail section - malformed ROADMAP
40
+ output({
41
+ found: false,
42
+ phase_number: phaseNum,
43
+ phase_name: checklistMatch[1].trim(),
44
+ error: 'malformed_roadmap',
45
+ message: `Phase ${phaseNum} exists in summary list but missing "### Phase ${phaseNum}:" detail section. ROADMAP.md needs both formats.`
46
+ }, raw, '');
47
+ return;
48
+ }
49
+
50
+ output({ found: false, phase_number: phaseNum }, raw, '');
51
+ return;
52
+ }
53
+
54
+ const phaseName = headerMatch[1].trim();
55
+ const headerIndex = headerMatch.index!;
56
+
57
+ // Find the end of this section (next ## or ### phase header, or end of file)
58
+ const restOfContent = content.slice(headerIndex);
59
+ const nextHeaderMatch = restOfContent.match(/\n#{2,4}\s+Phase\s+\d/i);
60
+ const sectionEnd = nextHeaderMatch
61
+ ? headerIndex + nextHeaderMatch.index!
62
+ : content.length;
63
+
64
+ const section = content.slice(headerIndex, sectionEnd).trim();
65
+
66
+ // Extract goal if present (supports both **Goal:** and **Goal**: formats)
67
+ const goalMatch = section.match(/\*\*Goal(?::\*\*|\*\*:)\s*([^\n]+)/i);
68
+ const goal = goalMatch ? goalMatch[1].trim() : null;
69
+
70
+ // Extract success criteria as structured array
71
+ const criteriaMatch = section.match(/\*\*Success Criteria\*\*[^\n]*:\s*\n((?:\s*\d+\.\s*[^\n]+\n?)+)/i);
72
+ const success_criteria = criteriaMatch
73
+ ? criteriaMatch[1].trim().split('\n').map(line => line.replace(/^\s*\d+\.\s*/, '').trim()).filter(Boolean)
74
+ : [];
75
+
76
+ output(
77
+ {
78
+ found: true,
79
+ phase_number: phaseNum,
80
+ phase_name: phaseName,
81
+ goal,
82
+ success_criteria,
83
+ section,
84
+ },
85
+ raw,
86
+ section
87
+ );
88
+ } catch (e) {
89
+ error('Failed to read ROADMAP.md: ' + (e as Error).message);
90
+ }
91
+ }
92
+
93
+ export function cmdRoadmapAnalyze(cwd: string, raw: boolean): void {
94
+ const roadmapPath = path.join(cwd, '.planning', 'ROADMAP.md');
95
+
96
+ if (!fs.existsSync(roadmapPath)) {
97
+ output({ error: 'ROADMAP.md not found', milestones: [], phases: [], current_phase: null }, raw);
98
+ return;
99
+ }
100
+
101
+ const rawContent = fs.readFileSync(roadmapPath, 'utf-8');
102
+ const content = stripShippedMilestones(rawContent);
103
+ const phasesDir = path.join(cwd, '.planning', 'phases');
104
+
105
+ // Extract all phase headings: ## Phase N: Name or ### Phase N: Name
106
+ const phasePattern = /#{2,4}\s*Phase\s+(\d+[A-Z]?(?:\.\d+)*)\s*:\s*([^\n]+)/gi;
107
+ const phases: Array<{
108
+ number: string;
109
+ name: string;
110
+ goal: string | null;
111
+ depends_on: string | null;
112
+ plan_count: number;
113
+ summary_count: number;
114
+ has_context: boolean;
115
+ has_research: boolean;
116
+ disk_status: string;
117
+ roadmap_complete: boolean;
118
+ }> = [];
119
+ let match: RegExpExecArray | null;
120
+
121
+ while ((match = phasePattern.exec(content)) !== null) {
122
+ const phaseNum = match[1];
123
+ const phaseName = match[2].replace(/\(INSERTED\)/i, '').trim();
124
+
125
+ // Extract goal from the section
126
+ const sectionStart = match.index;
127
+ const restOfContent = content.slice(sectionStart);
128
+ const nextHeader = restOfContent.match(/\n#{2,4}\s+Phase\s+\d/i);
129
+ const sectionEnd = nextHeader ? sectionStart + nextHeader.index! : content.length;
130
+ const section = content.slice(sectionStart, sectionEnd);
131
+
132
+ const goalMatch = section.match(/\*\*Goal(?::\*\*|\*\*:)\s*([^\n]+)/i);
133
+ const goal = goalMatch ? goalMatch[1].trim() : null;
134
+
135
+ const dependsMatch = section.match(/\*\*Depends on(?::\*\*|\*\*:)\s*([^\n]+)/i);
136
+ const depends_on = dependsMatch ? dependsMatch[1].trim() : null;
137
+
138
+ // Check completion on disk
139
+ const normalized = normalizePhaseName(phaseNum);
140
+ let diskStatus = 'no_directory';
141
+ let planCount = 0;
142
+ let summaryCount = 0;
143
+ let hasContext = false;
144
+ let hasResearch = false;
145
+
146
+ try {
147
+ const entries = fs.readdirSync(phasesDir, { withFileTypes: true });
148
+ const dirs = entries.filter(e => e.isDirectory()).map(e => e.name);
149
+ const dirMatch = dirs.find(d => d.startsWith(normalized + '-') || d === normalized);
150
+
151
+ if (dirMatch) {
152
+ const phaseFiles = fs.readdirSync(path.join(phasesDir, dirMatch));
153
+ planCount = phaseFiles.filter(f => f.endsWith('-PLAN.md') || f === 'PLAN.md').length;
154
+ summaryCount = phaseFiles.filter(f => f.endsWith('-SUMMARY.md') || f === 'SUMMARY.md').length;
155
+ hasContext = phaseFiles.some(f => f.endsWith('-CONTEXT.md') || f === 'CONTEXT.md');
156
+ hasResearch = phaseFiles.some(f => f.endsWith('-RESEARCH.md') || f === 'RESEARCH.md');
157
+
158
+ if (summaryCount >= planCount && planCount > 0) diskStatus = 'complete';
159
+ else if (summaryCount > 0) diskStatus = 'partial';
160
+ else if (planCount > 0) diskStatus = 'planned';
161
+ else if (hasResearch) diskStatus = 'researched';
162
+ else if (hasContext) diskStatus = 'discussed';
163
+ else diskStatus = 'empty';
164
+ }
165
+ } catch {}
166
+
167
+ // Check ROADMAP checkbox status
168
+ const checkboxPattern = new RegExp(`-\\s*\\[(x| )\\]\\s*.*Phase\\s+${escapeRegex(phaseNum)}[:\\s]`, 'i');
169
+ const checkboxMatch = content.match(checkboxPattern);
170
+ const roadmapComplete = checkboxMatch ? checkboxMatch[1] === 'x' : false;
171
+
172
+ // If roadmap marks phase complete, trust that over disk file structure.
173
+ // Phases completed before Vector tracking (or via external tools) may lack
174
+ // the standard PLAN/SUMMARY pairs but are still done.
175
+ if (roadmapComplete && diskStatus !== 'complete') {
176
+ diskStatus = 'complete';
177
+ }
178
+
179
+ phases.push({
180
+ number: phaseNum,
181
+ name: phaseName,
182
+ goal,
183
+ depends_on,
184
+ plan_count: planCount,
185
+ summary_count: summaryCount,
186
+ has_context: hasContext,
187
+ has_research: hasResearch,
188
+ disk_status: diskStatus,
189
+ roadmap_complete: roadmapComplete,
190
+ });
191
+ }
192
+
193
+ // Extract milestone info
194
+ const milestones: Array<{ heading: string; version: string }> = [];
195
+ const milestonePattern = /##\s*(.*v(\d+\.\d+)[^(\n]*)/gi;
196
+ let mMatch: RegExpExecArray | null;
197
+ while ((mMatch = milestonePattern.exec(content)) !== null) {
198
+ milestones.push({
199
+ heading: mMatch[1].trim(),
200
+ version: 'v' + mMatch[2],
201
+ });
202
+ }
203
+
204
+ // Find current and next phase
205
+ const currentPhase = phases.find(p => p.disk_status === 'planned' || p.disk_status === 'partial') || null;
206
+ const nextPhase = phases.find(p => p.disk_status === 'empty' || p.disk_status === 'no_directory' || p.disk_status === 'discussed' || p.disk_status === 'researched') || null;
207
+
208
+ // Aggregated stats
209
+ const totalPlans = phases.reduce((sum, p) => sum + p.plan_count, 0);
210
+ const totalSummaries = phases.reduce((sum, p) => sum + p.summary_count, 0);
211
+ const completedPhases = phases.filter(p => p.disk_status === 'complete').length;
212
+
213
+ // Detect phases in summary list without detail sections (malformed ROADMAP)
214
+ const checklistPattern = /-\s*\[[ x]\]\s*\*\*Phase\s+(\d+[A-Z]?(?:\.\d+)*)/gi;
215
+ const checklistPhases = new Set<string>();
216
+ let checklistMatch: RegExpExecArray | null;
217
+ while ((checklistMatch = checklistPattern.exec(content)) !== null) {
218
+ checklistPhases.add(checklistMatch[1]);
219
+ }
220
+ const detailPhases = new Set(phases.map(p => p.number));
221
+ const missingDetails = [...checklistPhases].filter(p => !detailPhases.has(p));
222
+
223
+ const result = {
224
+ milestones,
225
+ phases,
226
+ phase_count: phases.length,
227
+ completed_phases: completedPhases,
228
+ total_plans: totalPlans,
229
+ total_summaries: totalSummaries,
230
+ progress_percent: totalPlans > 0 ? Math.min(100, Math.round((totalSummaries / totalPlans) * 100)) : 0,
231
+ current_phase: currentPhase ? currentPhase.number : null,
232
+ next_phase: nextPhase ? nextPhase.number : null,
233
+ missing_phase_details: missingDetails.length > 0 ? missingDetails : null,
234
+ };
235
+
236
+ output(result, raw);
237
+ }
238
+
239
+ export function cmdRoadmapUpdatePlanProgress(cwd: string, phaseNum: string | undefined, raw: boolean): void {
240
+ if (!phaseNum) {
241
+ error('phase number required for roadmap update-plan-progress');
242
+ }
243
+
244
+ const roadmapPath = path.join(cwd, '.planning', 'ROADMAP.md');
245
+
246
+ const phaseInfo = findPhaseInternal(cwd, phaseNum!);
247
+ if (!phaseInfo) {
248
+ error(`Phase ${phaseNum} not found`);
249
+ }
250
+
251
+ const planCount = phaseInfo!.plans.length;
252
+ const summaryCount = phaseInfo!.summaries.length;
253
+
254
+ if (planCount === 0) {
255
+ output({ updated: false, reason: 'No plans found', plan_count: 0, summary_count: 0 }, raw, 'no plans');
256
+ return;
257
+ }
258
+
259
+ const isComplete = summaryCount >= planCount;
260
+ const status = isComplete ? 'Complete' : summaryCount > 0 ? 'In Progress' : 'Planned';
261
+ const today = new Date().toISOString().split('T')[0];
262
+
263
+ if (!fs.existsSync(roadmapPath)) {
264
+ output({ updated: false, reason: 'ROADMAP.md not found', plan_count: planCount, summary_count: summaryCount }, raw, 'no roadmap');
265
+ return;
266
+ }
267
+
268
+ let roadmapContent = fs.readFileSync(roadmapPath, 'utf-8');
269
+ const phaseEscaped = escapeRegex(phaseNum!);
270
+
271
+ // Progress table row: update Plans column (summaries/plans) and Status column
272
+ const tablePattern = new RegExp(
273
+ `(\\|\\s*${phaseEscaped}\\.?\\s[^|]*\\|)[^|]*(\\|)\\s*[^|]*(\\|)\\s*[^|]*(\\|)`,
274
+ 'i'
275
+ );
276
+ const dateField = isComplete ? ` ${today} ` : ' ';
277
+ roadmapContent = replaceInCurrentMilestone(
278
+ roadmapContent, tablePattern,
279
+ `$1 ${summaryCount}/${planCount} $2 ${status.padEnd(11)}$3${dateField}$4`
280
+ );
281
+
282
+ // Update plan count in phase detail section
283
+ const planCountPattern = new RegExp(
284
+ `(#{2,4}\\s*Phase\\s+${phaseEscaped}[\\s\\S]*?\\*\\*Plans:\\*\\*\\s*)[^\\n]+`,
285
+ 'i'
286
+ );
287
+ const planCountText = isComplete
288
+ ? `${summaryCount}/${planCount} plans complete`
289
+ : `${summaryCount}/${planCount} plans executed`;
290
+ roadmapContent = replaceInCurrentMilestone(roadmapContent, planCountPattern, `$1${planCountText}`);
291
+
292
+ // If complete: check checkbox
293
+ if (isComplete) {
294
+ const checkboxPattern = new RegExp(
295
+ `(-\\s*\\[)[ ](\\]\\s*.*Phase\\s+${phaseEscaped}[:\\s][^\\n]*)`,
296
+ 'i'
297
+ );
298
+ roadmapContent = replaceInCurrentMilestone(roadmapContent, checkboxPattern, `$1x$2 (completed ${today})`);
299
+ }
300
+
301
+ fs.writeFileSync(roadmapPath, roadmapContent, 'utf-8');
302
+
303
+ output({
304
+ updated: true,
305
+ phase: phaseNum,
306
+ plan_count: planCount,
307
+ summary_count: summaryCount,
308
+ status,
309
+ complete: isComplete,
310
+ }, raw, `${summaryCount}/${planCount} ${status}`);
311
+ }
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Roadmap — Roadmap parsing and update operations
3
+ */
4
+ export declare function cmdRoadmapGetPhase(cwd: string, phaseNum: string, raw: boolean): void;
5
+ export declare function cmdRoadmapAnalyze(cwd: string, raw: boolean): void;
6
+ export declare function cmdRoadmapUpdatePlanProgress(cwd: string, phaseNum: string | undefined, raw: boolean): void;
7
+ //# sourceMappingURL=roadmap.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"roadmap.d.cts","sourceRoot":"","sources":["roadmap.cts"],"names":[],"mappings":"AAAA;;GAEG;AAMH,wBAAgB,kBAAkB,CAAC,GAAG,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,GAAG,EAAE,OAAO,GAAG,IAAI,CAkFpF;AAED,wBAAgB,iBAAiB,CAAC,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,OAAO,GAAG,IAAI,CAgJjE;AAED,wBAAgB,4BAA4B,CAAC,GAAG,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,SAAS,EAAE,GAAG,EAAE,OAAO,GAAG,IAAI,CAwE1G"}