@orchestrator-claude/cli 1.7.1 → 1.7.3

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 (51) hide show
  1. package/dist/index.d.ts +1 -1
  2. package/dist/index.js +1 -1
  3. package/dist/templates/base/.orchestrator/patterns/legacy/README.md +360 -0
  4. package/dist/templates/base/.orchestrator/patterns/legacy/php/laravel.patterns.json +396 -0
  5. package/dist/templates/base/.orchestrator/templates/legacy/README.md +296 -0
  6. package/dist/templates/base/.orchestrator/templates/legacy/analysis-report.md.hbs +342 -0
  7. package/dist/templates/base/.orchestrator/templates/legacy/api-spec.yaml.hbs +263 -0
  8. package/dist/templates/base/.orchestrator/templates/legacy/business-rules.md.hbs +449 -0
  9. package/dist/templates/base/.orchestrator/templates/legacy/database-schema.md.hbs +356 -0
  10. package/dist/templates/base/.orchestrator/templates/legacy/dead-code-report.md.hbs +330 -0
  11. package/dist/templates/base/.orchestrator/templates/legacy/discovery-report.md.hbs +267 -0
  12. package/dist/templates/base/.orchestrator/templates/legacy/final-report.md.hbs +451 -0
  13. package/dist/templates/base/.orchestrator/templates/legacy/inventory.json.schema +346 -0
  14. package/dist/templates/base/.orchestrator/templates/legacy/migration-roadmap.md.hbs +571 -0
  15. package/dist/templates/base/.orchestrator/templates/legacy/tech-debt.md.hbs +412 -0
  16. package/dist/templates/base/claude/agents/api-extractor.md +665 -0
  17. package/dist/templates/base/claude/agents/business-rule-miner.md +734 -0
  18. package/dist/templates/base/claude/agents/code-archaeologist.md +715 -0
  19. package/dist/templates/base/claude/agents/legacy-discoverer.md +578 -0
  20. package/dist/templates/base/claude/agents/legacy-synthesizer.md +1097 -0
  21. package/dist/templates/base/claude/agents/schema-extractor.md +767 -0
  22. package/dist/templates/workflows/README.md +137 -0
  23. package/dist/templates/workflows/bug-fix.json +73 -0
  24. package/dist/templates/workflows/feature-development.json +87 -0
  25. package/dist/templates/workflows/legacy-analysis.json +288 -0
  26. package/dist/templates/workflows/refactoring.json +73 -0
  27. package/package.json +1 -1
  28. package/templates/base/.orchestrator/patterns/legacy/README.md +360 -0
  29. package/templates/base/.orchestrator/patterns/legacy/php/laravel.patterns.json +396 -0
  30. package/templates/base/.orchestrator/templates/legacy/README.md +296 -0
  31. package/templates/base/.orchestrator/templates/legacy/analysis-report.md.hbs +342 -0
  32. package/templates/base/.orchestrator/templates/legacy/api-spec.yaml.hbs +263 -0
  33. package/templates/base/.orchestrator/templates/legacy/business-rules.md.hbs +449 -0
  34. package/templates/base/.orchestrator/templates/legacy/database-schema.md.hbs +356 -0
  35. package/templates/base/.orchestrator/templates/legacy/dead-code-report.md.hbs +330 -0
  36. package/templates/base/.orchestrator/templates/legacy/discovery-report.md.hbs +267 -0
  37. package/templates/base/.orchestrator/templates/legacy/final-report.md.hbs +451 -0
  38. package/templates/base/.orchestrator/templates/legacy/inventory.json.schema +346 -0
  39. package/templates/base/.orchestrator/templates/legacy/migration-roadmap.md.hbs +571 -0
  40. package/templates/base/.orchestrator/templates/legacy/tech-debt.md.hbs +412 -0
  41. package/templates/base/claude/agents/api-extractor.md +665 -0
  42. package/templates/base/claude/agents/business-rule-miner.md +734 -0
  43. package/templates/base/claude/agents/code-archaeologist.md +715 -0
  44. package/templates/base/claude/agents/legacy-discoverer.md +578 -0
  45. package/templates/base/claude/agents/legacy-synthesizer.md +1097 -0
  46. package/templates/base/claude/agents/schema-extractor.md +767 -0
  47. package/templates/workflows/README.md +137 -0
  48. package/templates/workflows/bug-fix.json +73 -0
  49. package/templates/workflows/feature-development.json +87 -0
  50. package/templates/workflows/legacy-analysis.json +288 -0
  51. package/templates/workflows/refactoring.json +73 -0
@@ -0,0 +1,412 @@
1
+ # Technical Debt Catalog: {{projectName}}
2
+
3
+ **Generated:** {{generatedAt}}
4
+ **Agent:** code-archaeologist
5
+ **Workflow Phase:** ANALYZE
6
+ **Total Tech Debt Score:** {{techDebtScore}}/100 ({{techDebtLevel}})
7
+
8
+ ---
9
+
10
+ ## Executive Summary
11
+
12
+ This catalog documents all technical debt identified in the codebase, categorized by type and priority.
13
+
14
+ **Total Issues:** {{totalIssues}}
15
+ **Estimated Remediation:** {{totalRemediationHours}} hours (~{{totalRemediationWeeks}} weeks)
16
+ **Annual Interest Cost:** ~{{annualInterestCost}} hours/year in maintenance overhead
17
+
18
+ ---
19
+
20
+ ## Debt by Category
21
+
22
+ | Category | Count | Severity | Remediation | Priority |
23
+ |----------|-------|----------|-------------|----------|
24
+ | **Code Quality** | {{categories.codeQuality.count}} | {{categories.codeQuality.severity}} | {{categories.codeQuality.hours}}h | {{categories.codeQuality.priority}} |
25
+ | **Architecture** | {{categories.architecture.count}} | {{categories.architecture.severity}} | {{categories.architecture.hours}}h | {{categories.architecture.priority}} |
26
+ | **Security** | {{categories.security.count}} | {{categories.security.severity}} | {{categories.security.hours}}h | {{categories.security.priority}} |
27
+ | **Performance** | {{categories.performance.count}} | {{categories.performance.severity}} | {{categories.performance.hours}}h | {{categories.performance.priority}} |
28
+ | **Testing** | {{categories.testing.count}} | {{categories.testing.severity}} | {{categories.testing.hours}}h | {{categories.testing.priority}} |
29
+ | **Documentation** | {{categories.documentation.count}} | {{categories.documentation.severity}} | {{categories.documentation.hours}}h | {{categories.documentation.priority}} |
30
+ | **Dependencies** | {{categories.dependencies.count}} | {{categories.dependencies.severity}} | {{categories.dependencies.hours}}h | {{categories.dependencies.priority}} |
31
+
32
+ ---
33
+
34
+ ## Code Quality Debt
35
+
36
+ {{#if codeQuality.items}}
37
+ {{#each codeQuality.items}}
38
+ ### TD-CQ-{{id}}: {{title}}
39
+
40
+ - **Severity:** {{severity}}
41
+ - **Location:** `{{location.file}}:{{location.line}}`
42
+ - **Impact:** {{impact}}
43
+ - **Effort:** {{effort}} hours
44
+ - **Interest:** {{interest}}/10 (maintenance overhead)
45
+
46
+ **Problem:**
47
+ {{problem}}
48
+
49
+ **Current State:**
50
+ ```{{language}}
51
+ {{currentCode}}
52
+ ```
53
+
54
+ **Recommended Solution:**
55
+ {{solution}}
56
+
57
+ {{#if benefitsOfFixing}}
58
+ **Benefits of Fixing:**
59
+ {{#each benefitsOfFixing}}
60
+ - {{this}}
61
+ {{/each}}
62
+ {{/if}}
63
+
64
+ **Priority:** {{priority}} - {{priorityReason}}
65
+
66
+ ---
67
+
68
+ {{/each}}
69
+ {{else}}
70
+ ✅ No code quality debt identified.
71
+ {{/if}}
72
+
73
+ ---
74
+
75
+ ## Architecture Debt
76
+
77
+ {{#if architecture.items}}
78
+ {{#each architecture.items}}
79
+ ### TD-ARCH-{{id}}: {{title}}
80
+
81
+ - **Severity:** {{severity}}
82
+ - **Location:** {{location.module}}
83
+ - **Impact:** {{impact}}
84
+ - **Effort:** {{effort}} hours
85
+ - **Interest:** {{interest}}/10
86
+
87
+ **Problem:**
88
+ {{problem}}
89
+
90
+ **Current Architecture:**
91
+ ```mermaid
92
+ {{currentArchitectureDiagram}}
93
+ ```
94
+
95
+ **Recommended Architecture:**
96
+ ```mermaid
97
+ {{recommendedArchitectureDiagram}}
98
+ ```
99
+
100
+ **Migration Path:**
101
+ {{#each migrationSteps}}
102
+ {{@index}}. {{this}}
103
+ {{/each}}
104
+
105
+ **Priority:** {{priority}}
106
+
107
+ ---
108
+
109
+ {{/each}}
110
+ {{else}}
111
+ ✅ No architectural debt identified.
112
+ {{/if}}
113
+
114
+ ---
115
+
116
+ ## Security Debt
117
+
118
+ {{#if security.items}}
119
+ {{#each security.items}}
120
+ ### TD-SEC-{{id}}: {{title}}
121
+
122
+ - **Severity:** ❌ {{severity}}
123
+ - **Location:** `{{location.file}}:{{location.line}}`
124
+ - **CVE/CWE:** {{cve}}
125
+ - **Impact:** {{impact}}
126
+ - **Exploit Risk:** {{exploitRisk}}
127
+ - **Effort:** {{effort}} hours
128
+
129
+ **Vulnerability:**
130
+ {{vulnerability}}
131
+
132
+ **Evidence:**
133
+ ```{{language}}
134
+ {{vulnerableCode}}
135
+ ```
136
+ **NOTE:** Actual sensitive data has been sanitized in this report.
137
+
138
+ **Fix:**
139
+ {{fix}}
140
+
141
+ **Priority:** IMMEDIATE - Security vulnerabilities MUST be fixed first
142
+
143
+ ---
144
+
145
+ {{/each}}
146
+ {{else}}
147
+ ✅ No security debt identified.
148
+ {{/if}}
149
+
150
+ ---
151
+
152
+ ## Performance Debt
153
+
154
+ {{#if performance.items}}
155
+ {{#each performance.items}}
156
+ ### TD-PERF-{{id}}: {{title}}
157
+
158
+ - **Severity:** {{severity}}
159
+ - **Location:** `{{location.file}}:{{location.line}}`
160
+ - **Impact:** {{impact}}
161
+ - **Current Performance:** {{currentPerformance}}
162
+ - **Expected Performance:** {{expectedPerformance}}
163
+ - **Effort:** {{effort}} hours
164
+
165
+ **Problem:**
166
+ {{problem}}
167
+
168
+ **Bottleneck:**
169
+ {{bottleneck}}
170
+
171
+ **Optimization:**
172
+ {{optimization}}
173
+
174
+ **Priority:** {{priority}}
175
+
176
+ ---
177
+
178
+ {{/each}}
179
+ {{else}}
180
+ ✅ No performance debt identified.
181
+ {{/if}}
182
+
183
+ ---
184
+
185
+ ## Testing Debt
186
+
187
+ {{#if testing.items}}
188
+ {{#each testing.items}}
189
+ ### TD-TEST-{{id}}: {{title}}
190
+
191
+ - **Severity:** {{severity}}
192
+ - **Location:** {{location.module}}
193
+ - **Impact:** {{impact}}
194
+ - **Current Coverage:** {{currentCoverage}}%
195
+ - **Target Coverage:** {{targetCoverage}}%
196
+ - **Effort:** {{effort}} hours
197
+
198
+ **Problem:**
199
+ {{problem}}
200
+
201
+ **Missing Tests:**
202
+ {{#each missingTests}}
203
+ - {{this}}
204
+ {{/each}}
205
+
206
+ **Recommended Actions:**
207
+ {{#each actions}}
208
+ {{@index}}. {{this}}
209
+ {{/each}}
210
+
211
+ **Priority:** {{priority}}
212
+
213
+ ---
214
+
215
+ {{/each}}
216
+ {{else}}
217
+ ✅ No testing debt identified.
218
+ {{/if}}
219
+
220
+ ---
221
+
222
+ ## Documentation Debt
223
+
224
+ {{#if documentation.items}}
225
+ {{#each documentation.items}}
226
+ ### TD-DOC-{{id}}: {{title}}
227
+
228
+ - **Severity:** {{severity}}
229
+ - **Location:** {{location}}
230
+ - **Impact:** {{impact}}
231
+ - **Effort:** {{effort}} hours
232
+
233
+ **Problem:**
234
+ {{problem}}
235
+
236
+ **What's Missing:**
237
+ {{#each missing}}
238
+ - {{this}}
239
+ {{/each}}
240
+
241
+ **Priority:** {{priority}}
242
+
243
+ ---
244
+
245
+ {{/each}}
246
+ {{else}}
247
+ ✅ No documentation debt identified.
248
+ {{/if}}
249
+
250
+ ---
251
+
252
+ ## Dependency Debt
253
+
254
+ {{#if dependencies.items}}
255
+ {{#each dependencies.items}}
256
+ ### TD-DEP-{{id}}: {{title}}
257
+
258
+ - **Severity:** {{severity}}
259
+ - **Package:** {{package}}
260
+ - **Current Version:** {{currentVersion}}
261
+ - **Latest Version:** {{latestVersion}}
262
+ - **Age:** {{age}}
263
+ - **Security Issues:** {{securityIssues}}
264
+ - **Effort:** {{effort}} hours
265
+
266
+ **Problem:**
267
+ {{problem}}
268
+
269
+ **Breaking Changes:**
270
+ {{#if breakingChanges}}
271
+ {{#each breakingChanges}}
272
+ - {{this}}
273
+ {{/each}}
274
+ {{else}}
275
+ None identified
276
+ {{/if}}
277
+
278
+ **Migration Path:**
279
+ {{migrationPath}}
280
+
281
+ **Priority:** {{priority}}
282
+
283
+ ---
284
+
285
+ {{/each}}
286
+ {{else}}
287
+ ✅ No dependency debt identified.
288
+ {{/if}}
289
+
290
+ ---
291
+
292
+ ## Prioritized Remediation Roadmap
293
+
294
+ ### Phase 1: Critical (Immediate Action) - {{roadmap.phase1.effort}}h
295
+
296
+ **Timeline:** 1-2 weeks
297
+ **Focus:** Security vulnerabilities, critical bugs, blocking issues
298
+
299
+ {{#each roadmap.phase1.items}}
300
+ {{@index}}. {{title}} ({{effort}}h) - `{{location}}`
301
+ {{/each}}
302
+
303
+ ### Phase 2: High Priority (Short-Term) - {{roadmap.phase2.effort}}h
304
+
305
+ **Timeline:** 1-2 months
306
+ **Focus:** Architecture improvements, major refactoring
307
+
308
+ {{#each roadmap.phase2.items}}
309
+ {{@index}}. {{title}} ({{effort}}h)
310
+ {{/each}}
311
+
312
+ ### Phase 3: Medium Priority (Medium-Term) - {{roadmap.phase3.effort}}h
313
+
314
+ **Timeline:** 3-6 months
315
+ **Focus:** Code quality, testing, documentation
316
+
317
+ {{#each roadmap.phase3.items}}
318
+ {{@index}}. {{title}} ({{effort}}h)
319
+ {{/each}}
320
+
321
+ ### Phase 4: Low Priority (Long-Term) - {{roadmap.phase4.effort}}h
322
+
323
+ **Timeline:** 6-12 months
324
+ **Focus:** Minor improvements, optimizations
325
+
326
+ {{#each roadmap.phase4.items}}
327
+ {{@index}}. {{title}} ({{effort}}h)
328
+ {{/each}}
329
+
330
+ ---
331
+
332
+ ## Debt Interest Calculation
333
+
334
+ Technical debt accrues "interest" in the form of increased maintenance cost:
335
+
336
+ | Debt Type | Interest Rate | Annual Cost |
337
+ |-----------|---------------|-------------|
338
+ | Security | High (3x) | {{interest.security}}h/year |
339
+ | Architecture | High (2.5x) | {{interest.architecture}}h/year |
340
+ | Code Quality | Medium (1.5x) | {{interest.codeQuality}}h/year |
341
+ | Performance | Medium (1.5x) | {{interest.performance}}h/year |
342
+ | Testing | Medium (2x) | {{interest.testing}}h/year |
343
+ | Documentation | Low (1x) | {{interest.documentation}}h/year |
344
+ | **Total** | - | **{{interest.total}}h/year** |
345
+
346
+ **Cost Interpretation:**
347
+ - Each hour of unresolved debt costs {{interest.multiplier}}x that in annual maintenance
348
+ - Fixing debt early reduces long-term costs significantly
349
+ - Security debt compounds faster than other types
350
+
351
+ ---
352
+
353
+ ## Quick Wins (Low Effort, High Impact)
354
+
355
+ {{#if quickWins}}
356
+ These items provide maximum benefit for minimum effort:
357
+
358
+ {{#each quickWins}}
359
+ {{@index}}. **{{title}}** ({{effort}}h) - {{benefit}}
360
+ - Location: `{{location}}`
361
+ - Impact: {{impact}}
362
+ {{/each}}
363
+ {{else}}
364
+ No quick wins identified.
365
+ {{/if}}
366
+
367
+ ---
368
+
369
+ ## Debt Prevention Strategies
370
+
371
+ To prevent future technical debt:
372
+
373
+ {{#each preventionStrategies}}
374
+ ### {{title}}
375
+ {{description}}
376
+
377
+ **Actions:**
378
+ {{#each actions}}
379
+ - {{this}}
380
+ {{/each}}
381
+
382
+ {{/each}}
383
+
384
+ ---
385
+
386
+ ## Monitoring & Metrics
387
+
388
+ Track these metrics over time to measure debt reduction:
389
+
390
+ | Metric | Current | Target | Status |
391
+ |--------|---------|--------|--------|
392
+ | Tech Debt Score | {{metrics.current.score}} | {{metrics.target.score}} | {{#if metrics.improving}}⬆️{{else}}⬇️{{/if}} |
393
+ | Total Issues | {{metrics.current.issues}} | {{metrics.target.issues}} | {{#if metrics.improving}}⬆️{{else}}⬇️{{/if}} |
394
+ | Cyclomatic Complexity | {{metrics.current.complexity}} | {{metrics.target.complexity}} | {{#if metrics.improving}}⬆️{{else}}⬇️{{/if}} |
395
+ | Test Coverage | {{metrics.current.coverage}}% | {{metrics.target.coverage}}% | {{#if metrics.improving}}⬆️{{else}}⬇️{{/if}} |
396
+ | Security Issues | {{metrics.current.security}} | {{metrics.target.security}} | {{#if metrics.improving}}⬆️{{else}}⬇️{{/if}} |
397
+
398
+ ---
399
+
400
+ ## Next Steps
401
+
402
+ 1. Review and approve prioritized roadmap
403
+ 2. Allocate dedicated time for debt reduction (recommend 20% per sprint)
404
+ 3. Start with Phase 1 (Critical items)
405
+ 4. Track progress using metrics dashboard
406
+ 5. Re-assess debt quarterly
407
+
408
+ ---
409
+
410
+ **Generated by:** code-archaeologist agent
411
+ **Standards:** AGENT-PROMPT-STANDARDS v1.1
412
+ **RFC:** RFC-004-LEGACY-ANALYSIS-WORKFLOW