mcp-probe-kit 1.15.1 → 2.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.
Files changed (162) hide show
  1. package/README.md +113 -1642
  2. package/build/index.js +75 -42
  3. package/build/lib/elicitation-helper.d.ts +73 -0
  4. package/build/lib/elicitation-helper.js +130 -0
  5. package/build/lib/response.d.ts +32 -0
  6. package/build/lib/response.js +28 -0
  7. package/build/lib/tasks-manager.d.ts +116 -0
  8. package/build/lib/tasks-manager.js +217 -0
  9. package/build/lib/toolset-manager.d.ts +48 -0
  10. package/build/lib/toolset-manager.js +112 -0
  11. package/build/schemas/basic-tools.d.ts +0 -32
  12. package/build/schemas/basic-tools.js +0 -34
  13. package/build/schemas/code-analysis-tools.d.ts +0 -36
  14. package/build/schemas/code-analysis-tools.js +0 -38
  15. package/build/schemas/code-gen-tools.d.ts +0 -44
  16. package/build/schemas/code-gen-tools.js +0 -46
  17. package/build/schemas/doc-util-tools.d.ts +0 -54
  18. package/build/schemas/doc-util-tools.js +0 -58
  19. package/build/schemas/index.d.ts +0 -188
  20. package/build/schemas/orchestration-tools.d.ts +0 -22
  21. package/build/schemas/orchestration-tools.js +0 -23
  22. package/build/schemas/output/core-tools.d.ts +817 -0
  23. package/build/schemas/output/core-tools.js +421 -0
  24. package/build/schemas/output/generation-tools.d.ts +936 -0
  25. package/build/schemas/output/generation-tools.js +446 -0
  26. package/build/schemas/output/helper-tools.d.ts +243 -0
  27. package/build/schemas/output/helper-tools.js +138 -0
  28. package/build/schemas/output/index.d.ts +76 -0
  29. package/build/schemas/output/index.js +96 -0
  30. package/build/schemas/output/project-tools.d.ts +702 -0
  31. package/build/schemas/output/project-tools.js +339 -0
  32. package/build/schemas/output/ui-ux-tools.d.ts +469 -0
  33. package/build/schemas/output/ui-ux-tools.js +218 -0
  34. package/build/schemas/output/workflow-tools.d.ts +267 -0
  35. package/build/schemas/output/workflow-tools.js +179 -0
  36. package/build/schemas/structured-output.d.ts +1317 -0
  37. package/build/schemas/structured-output.js +1017 -0
  38. package/build/tools/__tests__/start_ui.integration.test.js +5 -5
  39. package/build/tools/__tests__/start_ui.property.test.js +11 -11
  40. package/build/tools/add_feature.d.ts +1 -13
  41. package/build/tools/add_feature.js +48 -13
  42. package/build/tools/analyze_project.js +57 -18
  43. package/build/tools/check_deps.d.ts +1 -13
  44. package/build/tools/check_deps.js +24 -15
  45. package/build/tools/code_review.d.ts +1 -13
  46. package/build/tools/code_review.js +19 -16
  47. package/build/tools/debug.d.ts +1 -13
  48. package/build/tools/debug.js +18 -16
  49. package/build/tools/estimate.d.ts +1 -19
  50. package/build/tools/estimate.js +36 -6
  51. package/build/tools/fix_bug.d.ts +1 -13
  52. package/build/tools/fix_bug.js +24 -6
  53. package/build/tools/gen_mock.d.ts +1 -19
  54. package/build/tools/gen_mock.js +42 -227
  55. package/build/tools/genapi.d.ts +1 -13
  56. package/build/tools/genapi.js +18 -15
  57. package/build/tools/genchangelog.d.ts +1 -13
  58. package/build/tools/genchangelog.js +36 -212
  59. package/build/tools/gencommit.d.ts +1 -7
  60. package/build/tools/gencommit.js +21 -13
  61. package/build/tools/gendoc.d.ts +1 -13
  62. package/build/tools/gendoc.js +18 -15
  63. package/build/tools/genpr.d.ts +1 -13
  64. package/build/tools/genpr.js +28 -157
  65. package/build/tools/genreadme.d.ts +1 -13
  66. package/build/tools/genreadme.js +22 -587
  67. package/build/tools/gensql.d.ts +1 -13
  68. package/build/tools/gensql.js +24 -283
  69. package/build/tools/gentest.d.ts +1 -13
  70. package/build/tools/gentest.js +49 -16
  71. package/build/tools/index.d.ts +0 -10
  72. package/build/tools/index.js +0 -10
  73. package/build/tools/init_component_catalog.d.ts +3 -20
  74. package/build/tools/init_component_catalog.js +141 -786
  75. package/build/tools/init_project.d.ts +7 -13
  76. package/build/tools/init_project.js +54 -16
  77. package/build/tools/init_project_context.d.ts +1 -13
  78. package/build/tools/init_project_context.js +41 -14
  79. package/build/tools/perf.d.ts +1 -13
  80. package/build/tools/perf.js +18 -15
  81. package/build/tools/refactor.d.ts +1 -13
  82. package/build/tools/refactor.js +54 -15
  83. package/build/tools/render_ui.d.ts +2 -19
  84. package/build/tools/render_ui.js +201 -347
  85. package/build/tools/resolve_conflict.d.ts +1 -13
  86. package/build/tools/resolve_conflict.js +18 -15
  87. package/build/tools/security_scan.d.ts +1 -13
  88. package/build/tools/security_scan.js +16 -5
  89. package/build/tools/start_api.d.ts +7 -13
  90. package/build/tools/start_api.js +69 -157
  91. package/build/tools/start_bugfix.d.ts +1 -7
  92. package/build/tools/start_bugfix.js +38 -2
  93. package/build/tools/start_doc.d.ts +7 -13
  94. package/build/tools/start_doc.js +76 -169
  95. package/build/tools/start_feature.d.ts +1 -7
  96. package/build/tools/start_feature.js +54 -2
  97. package/build/tools/start_onboard.d.ts +1 -7
  98. package/build/tools/start_onboard.js +40 -2
  99. package/build/tools/start_ralph.d.ts +1 -7
  100. package/build/tools/start_ralph.js +88 -2
  101. package/build/tools/start_refactor.d.ts +7 -13
  102. package/build/tools/start_refactor.js +75 -148
  103. package/build/tools/start_release.d.ts +7 -13
  104. package/build/tools/start_release.js +56 -131
  105. package/build/tools/start_review.d.ts +7 -13
  106. package/build/tools/start_review.js +70 -142
  107. package/build/tools/start_ui.d.ts +1 -7
  108. package/build/tools/start_ui.js +98 -8
  109. package/build/tools/ui-ux-tools.d.ts +3 -39
  110. package/build/tools/ui-ux-tools.js +201 -125
  111. package/docs/data/tools.js +864 -0
  112. package/docs/index.html +594 -0
  113. package/docs/pages/all-tools.html +649 -0
  114. package/docs/pages/examples.html +564 -0
  115. package/docs/pages/getting-started.html +529 -0
  116. package/docs/pages/migration.html +308 -0
  117. package/docs/specs/algorithm-enhancement/roadmap.md +619 -0
  118. package/docs/specs/vnext-upgrade/00-OVERVIEW.md +258 -0
  119. package/docs/specs/vnext-upgrade/BETA_RELEASE_GUIDE.md +328 -0
  120. package/docs/specs/vnext-upgrade/GITHUB_DISCUSSION_TEMPLATE.md +236 -0
  121. package/docs/specs/vnext-upgrade/M8.9-PROGRESS-UPDATE.md +248 -0
  122. package/docs/specs/vnext-upgrade/PROGRESS-SUMMARY.md +195 -0
  123. package/docs/specs/vnext-upgrade/QUICK_REFERENCE.md +338 -0
  124. package/docs/specs/vnext-upgrade/README.md +125 -0
  125. package/docs/specs/vnext-upgrade/STATUS-UPDATE-2026-01-26.md +230 -0
  126. package/docs/specs/vnext-upgrade/TOOL_CLEANUP.md +343 -0
  127. package/docs/specs/vnext-upgrade/completed/M1-M2-SUMMARY.md +27 -0
  128. package/docs/specs/vnext-upgrade/completed/M3_COMPLETION_SUMMARY.md +273 -0
  129. package/docs/specs/vnext-upgrade/completed/M4-SUMMARY.md +19 -0
  130. package/docs/specs/vnext-upgrade/completed/M5_COMPLETION_SUMMARY.md +0 -0
  131. package/docs/specs/vnext-upgrade/completed/M8.1-SUMMARY.md +247 -0
  132. package/docs/specs/vnext-upgrade/completed/M8.2-SUMMARY.md +296 -0
  133. package/docs/specs/vnext-upgrade/completed/M8.3-SUMMARY.md +241 -0
  134. package/docs/specs/vnext-upgrade/completed/M8.3-TEST-SUMMARY.md +216 -0
  135. package/docs/specs/vnext-upgrade/completed/M8.4-SUMMARY.md +217 -0
  136. package/docs/specs/vnext-upgrade/completed/M8.4-TEST-SUMMARY.md +198 -0
  137. package/docs/specs/vnext-upgrade/completed/M8.5-SUMMARY.md +202 -0
  138. package/docs/specs/vnext-upgrade/completed/M8.5-TEST-SUMMARY.md +223 -0
  139. package/docs/specs/vnext-upgrade/completed/M8.6-SUMMARY.md +299 -0
  140. package/docs/specs/vnext-upgrade/completed/M8.8-TEST-SUMMARY.md +216 -0
  141. package/docs/specs/vnext-upgrade/completed/TOOL-CLEANUP-SUMMARY.md +210 -0
  142. package/docs/specs/vnext-upgrade/design.md +848 -0
  143. package/docs/specs/vnext-upgrade/requirements.md +221 -0
  144. package/docs/specs/vnext-upgrade/tasks/00-INDEX.md +335 -0
  145. package/docs/specs/vnext-upgrade/tasks/M8.1-SCHEMA-DEFINITION.md +300 -0
  146. package/docs/specs/vnext-upgrade/tasks/M8.2-P1-TOOLS.md +249 -0
  147. package/docs/specs/vnext-upgrade/tasks/M8.3-GENERATION-TOOLS.md +49 -0
  148. package/docs/specs/vnext-upgrade/tasks/M8.4-ORCHESTRATION-TOOLS.md +28 -0
  149. package/docs/specs/vnext-upgrade/tasks/M8.5-PROJECT-TOOLS.md +29 -0
  150. package/docs/specs/vnext-upgrade/tasks/M8.6-UI-TOOLS.md +66 -0
  151. package/docs/specs/vnext-upgrade/tasks/M8.7-HELPER-TOOLS.md +24 -0
  152. package/docs/specs/vnext-upgrade/tasks/M8.8-INTEGRATION-TESTS.md +90 -0
  153. package/docs/specs/vnext-upgrade/tasks/M8.9-DOCUMENTATION.md +103 -0
  154. package/docs/styles/docs.css +556 -0
  155. package/docs/styles/page.css +815 -0
  156. package/docs/vnext/MCP_2025-11-25_GUIDE.md +276 -0
  157. package/docs/vnext/vNext-PRD.md +488 -0
  158. package/package.json +6 -6
  159. package/docs/BEST_PRACTICES.md +0 -1185
  160. package/docs/HOW_TO_TRIGGER.md +0 -1141
  161. package/docs/MCP-Probe-Kit-/344/275/277/347/224/250/346/211/213/345/206/214.html +0 -544
  162. package/docs/MCP-Probe-Kit-/344/275/277/347/224/250/346/211/213/345/206/214.md +0 -1447
@@ -0,0 +1,817 @@
1
+ /**
2
+ * 核心开发工具的结构化输出 Schema
3
+ * 包含: code_review, debug, fix_bug, gentest, refactor, security_scan, perf
4
+ */
5
+ /**
6
+ * Code Review Report Schema
7
+ * 用于 code_review 工具的结构化输出
8
+ */
9
+ export declare const CodeReviewReportSchema: {
10
+ readonly type: "object";
11
+ readonly properties: {
12
+ readonly summary: {
13
+ readonly type: "string";
14
+ readonly description: "审查总结";
15
+ };
16
+ readonly overallScore: {
17
+ readonly type: "number";
18
+ readonly minimum: 0;
19
+ readonly maximum: 100;
20
+ readonly description: "总体评分(0-100)";
21
+ };
22
+ readonly issues: {
23
+ readonly type: "array";
24
+ readonly description: "问题列表";
25
+ readonly items: {
26
+ readonly type: "object";
27
+ readonly properties: {
28
+ readonly severity: {
29
+ readonly type: "string";
30
+ readonly enum: readonly ["critical", "high", "medium", "low", "info"];
31
+ readonly description: "严重程度";
32
+ };
33
+ readonly category: {
34
+ readonly type: "string";
35
+ readonly enum: readonly ["security", "performance", "quality", "style", "best-practice"];
36
+ readonly description: "问题类别";
37
+ };
38
+ readonly line: {
39
+ readonly type: "number";
40
+ readonly description: "行号";
41
+ };
42
+ readonly file: {
43
+ readonly type: "string";
44
+ readonly description: "文件路径";
45
+ };
46
+ readonly message: {
47
+ readonly type: "string";
48
+ readonly description: "问题描述";
49
+ };
50
+ readonly suggestion: {
51
+ readonly type: "string";
52
+ readonly description: "修复建议";
53
+ };
54
+ readonly code: {
55
+ readonly type: "string";
56
+ readonly description: "问题代码片段";
57
+ };
58
+ };
59
+ readonly required: readonly ["severity", "category", "message"];
60
+ };
61
+ };
62
+ readonly strengths: {
63
+ readonly type: "array";
64
+ readonly items: {
65
+ readonly type: "string";
66
+ };
67
+ readonly description: "代码优点";
68
+ };
69
+ readonly recommendations: {
70
+ readonly type: "array";
71
+ readonly items: {
72
+ readonly type: "string";
73
+ };
74
+ readonly description: "改进建议";
75
+ };
76
+ readonly metrics: {
77
+ readonly type: "object";
78
+ readonly description: "代码指标";
79
+ readonly properties: {
80
+ readonly complexity: {
81
+ readonly type: "number";
82
+ };
83
+ readonly maintainability: {
84
+ readonly type: "number";
85
+ };
86
+ readonly testCoverage: {
87
+ readonly type: "number";
88
+ };
89
+ };
90
+ };
91
+ };
92
+ readonly required: readonly ["summary", "overallScore", "issues"];
93
+ };
94
+ /**
95
+ * Debug Report Schema
96
+ * 用于 debug 工具的结构化输出
97
+ */
98
+ export declare const DebugReportSchema: {
99
+ readonly type: "object";
100
+ readonly properties: {
101
+ readonly summary: {
102
+ readonly type: "string";
103
+ readonly description: "调试摘要";
104
+ };
105
+ readonly rootCause: {
106
+ readonly type: "string";
107
+ readonly description: "根本原因分析";
108
+ };
109
+ readonly errorType: {
110
+ readonly type: "string";
111
+ readonly enum: readonly ["syntax", "runtime", "logic", "performance", "memory", "network", "unknown"];
112
+ readonly description: "错误类型";
113
+ };
114
+ readonly location: {
115
+ readonly type: "object";
116
+ readonly properties: {
117
+ readonly file: {
118
+ readonly type: "string";
119
+ };
120
+ readonly line: {
121
+ readonly type: "number";
122
+ };
123
+ readonly column: {
124
+ readonly type: "number";
125
+ };
126
+ readonly function: {
127
+ readonly type: "string";
128
+ };
129
+ };
130
+ };
131
+ readonly stackTrace: {
132
+ readonly type: "array";
133
+ readonly items: {
134
+ readonly type: "object";
135
+ readonly properties: {
136
+ readonly file: {
137
+ readonly type: "string";
138
+ };
139
+ readonly line: {
140
+ readonly type: "number";
141
+ };
142
+ readonly function: {
143
+ readonly type: "string";
144
+ };
145
+ };
146
+ };
147
+ };
148
+ readonly debugStrategy: {
149
+ readonly type: "array";
150
+ readonly items: {
151
+ readonly type: "string";
152
+ };
153
+ readonly description: "调试策略";
154
+ };
155
+ readonly solutions: {
156
+ readonly type: "array";
157
+ readonly items: {
158
+ readonly type: "object";
159
+ readonly properties: {
160
+ readonly title: {
161
+ readonly type: "string";
162
+ };
163
+ readonly description: {
164
+ readonly type: "string";
165
+ };
166
+ readonly code: {
167
+ readonly type: "string";
168
+ };
169
+ readonly priority: {
170
+ readonly type: "string";
171
+ readonly enum: readonly ["high", "medium", "low"];
172
+ };
173
+ };
174
+ readonly required: readonly ["title", "description"];
175
+ };
176
+ };
177
+ readonly relatedIssues: {
178
+ readonly type: "array";
179
+ readonly items: {
180
+ readonly type: "string";
181
+ };
182
+ };
183
+ };
184
+ readonly required: readonly ["summary", "rootCause", "errorType", "solutions"];
185
+ };
186
+ /**
187
+ * Bug Analysis Schema
188
+ * 用于 fix_bug 工具的结构化输出
189
+ */
190
+ export declare const BugAnalysisSchema: {
191
+ readonly type: "object";
192
+ readonly properties: {
193
+ readonly summary: {
194
+ readonly type: "string";
195
+ readonly description: "Bug 摘要";
196
+ };
197
+ readonly bugType: {
198
+ readonly type: "string";
199
+ readonly enum: readonly ["functional", "performance", "security", "ui", "data", "integration"];
200
+ };
201
+ readonly severity: {
202
+ readonly type: "string";
203
+ readonly enum: readonly ["critical", "high", "medium", "low"];
204
+ };
205
+ readonly rootCause: {
206
+ readonly type: "string";
207
+ };
208
+ readonly affectedComponents: {
209
+ readonly type: "array";
210
+ readonly items: {
211
+ readonly type: "string";
212
+ };
213
+ };
214
+ readonly affectedFiles: {
215
+ readonly type: "array";
216
+ readonly items: {
217
+ readonly type: "string";
218
+ };
219
+ };
220
+ readonly fixPlan: {
221
+ readonly type: "object";
222
+ readonly properties: {
223
+ readonly steps: {
224
+ readonly type: "array";
225
+ readonly items: {
226
+ readonly type: "string";
227
+ };
228
+ };
229
+ readonly estimatedTime: {
230
+ readonly type: "string";
231
+ };
232
+ readonly risks: {
233
+ readonly type: "array";
234
+ readonly items: {
235
+ readonly type: "string";
236
+ };
237
+ };
238
+ };
239
+ readonly required: readonly ["steps"];
240
+ };
241
+ readonly testPlan: {
242
+ readonly type: "object";
243
+ readonly properties: {
244
+ readonly unitTests: {
245
+ readonly type: "array";
246
+ readonly items: {
247
+ readonly type: "string";
248
+ };
249
+ };
250
+ readonly integrationTests: {
251
+ readonly type: "array";
252
+ readonly items: {
253
+ readonly type: "string";
254
+ };
255
+ };
256
+ readonly manualTests: {
257
+ readonly type: "array";
258
+ readonly items: {
259
+ readonly type: "string";
260
+ };
261
+ };
262
+ };
263
+ };
264
+ readonly preventionMeasures: {
265
+ readonly type: "array";
266
+ readonly items: {
267
+ readonly type: "string";
268
+ };
269
+ };
270
+ };
271
+ readonly required: readonly ["summary", "bugType", "severity", "rootCause", "fixPlan", "testPlan"];
272
+ };
273
+ /**
274
+ * Test Suite Schema
275
+ * 用于 gentest 工具的结构化输出
276
+ */
277
+ export declare const TestSuiteSchema: {
278
+ readonly type: "object";
279
+ readonly properties: {
280
+ readonly summary: {
281
+ readonly type: "string";
282
+ };
283
+ readonly framework: {
284
+ readonly type: "string";
285
+ readonly enum: readonly ["jest", "vitest", "mocha", "jasmine", "pytest", "junit"];
286
+ };
287
+ readonly testCases: {
288
+ readonly type: "array";
289
+ readonly items: {
290
+ readonly type: "object";
291
+ readonly properties: {
292
+ readonly name: {
293
+ readonly type: "string";
294
+ };
295
+ readonly description: {
296
+ readonly type: "string";
297
+ };
298
+ readonly type: {
299
+ readonly type: "string";
300
+ readonly enum: readonly ["unit", "integration", "e2e", "performance"];
301
+ };
302
+ readonly code: {
303
+ readonly type: "string";
304
+ };
305
+ readonly assertions: {
306
+ readonly type: "array";
307
+ readonly items: {
308
+ readonly type: "string";
309
+ };
310
+ };
311
+ };
312
+ readonly required: readonly ["name", "type", "code"];
313
+ };
314
+ };
315
+ readonly edgeCases: {
316
+ readonly type: "array";
317
+ readonly items: {
318
+ readonly type: "object";
319
+ readonly properties: {
320
+ readonly scenario: {
321
+ readonly type: "string";
322
+ };
323
+ readonly input: {
324
+ readonly type: "string";
325
+ };
326
+ readonly expectedOutput: {
327
+ readonly type: "string";
328
+ };
329
+ };
330
+ };
331
+ };
332
+ readonly mockData: {
333
+ readonly type: "object";
334
+ readonly additionalProperties: true;
335
+ };
336
+ readonly coverage: {
337
+ readonly type: "object";
338
+ readonly properties: {
339
+ readonly statements: {
340
+ readonly type: "number";
341
+ };
342
+ readonly branches: {
343
+ readonly type: "number";
344
+ };
345
+ readonly functions: {
346
+ readonly type: "number";
347
+ };
348
+ readonly lines: {
349
+ readonly type: "number";
350
+ };
351
+ };
352
+ };
353
+ };
354
+ readonly required: readonly ["summary", "framework", "testCases"];
355
+ };
356
+ /**
357
+ * Refactor Plan Schema
358
+ * 用于 refactor 工具的结构化输出
359
+ */
360
+ export declare const RefactorPlanSchema: {
361
+ readonly type: "object";
362
+ readonly properties: {
363
+ readonly summary: {
364
+ readonly type: "string";
365
+ };
366
+ readonly goal: {
367
+ readonly type: "string";
368
+ readonly enum: readonly ["improve_readability", "reduce_complexity", "improve_performance", "improve_maintainability", "modernize"];
369
+ };
370
+ readonly currentIssues: {
371
+ readonly type: "array";
372
+ readonly items: {
373
+ readonly type: "string";
374
+ };
375
+ };
376
+ readonly refactoringSteps: {
377
+ readonly type: "array";
378
+ readonly items: {
379
+ readonly type: "object";
380
+ readonly properties: {
381
+ readonly step: {
382
+ readonly type: "number";
383
+ };
384
+ readonly title: {
385
+ readonly type: "string";
386
+ };
387
+ readonly description: {
388
+ readonly type: "string";
389
+ };
390
+ readonly before: {
391
+ readonly type: "string";
392
+ };
393
+ readonly after: {
394
+ readonly type: "string";
395
+ };
396
+ readonly rationale: {
397
+ readonly type: "string";
398
+ };
399
+ };
400
+ readonly required: readonly ["step", "title", "description"];
401
+ };
402
+ };
403
+ readonly riskAssessment: {
404
+ readonly type: "object";
405
+ readonly properties: {
406
+ readonly level: {
407
+ readonly type: "string";
408
+ readonly enum: readonly ["low", "medium", "high"];
409
+ };
410
+ readonly risks: {
411
+ readonly type: "array";
412
+ readonly items: {
413
+ readonly type: "string";
414
+ };
415
+ };
416
+ readonly mitigations: {
417
+ readonly type: "array";
418
+ readonly items: {
419
+ readonly type: "string";
420
+ };
421
+ };
422
+ };
423
+ readonly required: readonly ["level", "risks"];
424
+ };
425
+ readonly rollbackPlan: {
426
+ readonly type: "string";
427
+ };
428
+ readonly estimatedEffort: {
429
+ readonly type: "object";
430
+ readonly properties: {
431
+ readonly hours: {
432
+ readonly type: "number";
433
+ };
434
+ readonly complexity: {
435
+ readonly type: "string";
436
+ readonly enum: readonly ["low", "medium", "high"];
437
+ };
438
+ };
439
+ };
440
+ readonly expectedBenefits: {
441
+ readonly type: "array";
442
+ readonly items: {
443
+ readonly type: "string";
444
+ };
445
+ };
446
+ };
447
+ readonly required: readonly ["summary", "goal", "refactoringSteps", "riskAssessment"];
448
+ };
449
+ /**
450
+ * Security Report Schema
451
+ * 用于 security_scan 工具的结构化输出
452
+ */
453
+ export declare const SecurityReportSchema: {
454
+ readonly type: "object";
455
+ readonly properties: {
456
+ readonly summary: {
457
+ readonly type: "string";
458
+ };
459
+ readonly overallRisk: {
460
+ readonly type: "string";
461
+ readonly enum: readonly ["critical", "high", "medium", "low", "none"];
462
+ };
463
+ readonly vulnerabilities: {
464
+ readonly type: "array";
465
+ readonly items: {
466
+ readonly type: "object";
467
+ readonly properties: {
468
+ readonly id: {
469
+ readonly type: "string";
470
+ };
471
+ readonly type: {
472
+ readonly type: "string";
473
+ readonly enum: readonly ["injection", "xss", "csrf", "auth", "crypto", "data-exposure", "dos", "other"];
474
+ };
475
+ readonly severity: {
476
+ readonly type: "string";
477
+ readonly enum: readonly ["critical", "high", "medium", "low"];
478
+ };
479
+ readonly title: {
480
+ readonly type: "string";
481
+ };
482
+ readonly description: {
483
+ readonly type: "string";
484
+ };
485
+ readonly location: {
486
+ readonly type: "object";
487
+ readonly properties: {
488
+ readonly file: {
489
+ readonly type: "string";
490
+ };
491
+ readonly line: {
492
+ readonly type: "number";
493
+ };
494
+ readonly code: {
495
+ readonly type: "string";
496
+ };
497
+ };
498
+ };
499
+ readonly cwe: {
500
+ readonly type: "string";
501
+ };
502
+ readonly cvss: {
503
+ readonly type: "number";
504
+ };
505
+ readonly remediation: {
506
+ readonly type: "string";
507
+ };
508
+ readonly references: {
509
+ readonly type: "array";
510
+ readonly items: {
511
+ readonly type: "string";
512
+ };
513
+ };
514
+ };
515
+ readonly required: readonly ["type", "severity", "title", "description"];
516
+ };
517
+ };
518
+ readonly complianceChecks: {
519
+ readonly type: "array";
520
+ readonly items: {
521
+ readonly type: "object";
522
+ readonly properties: {
523
+ readonly standard: {
524
+ readonly type: "string";
525
+ };
526
+ readonly passed: {
527
+ readonly type: "boolean";
528
+ };
529
+ readonly details: {
530
+ readonly type: "string";
531
+ };
532
+ };
533
+ };
534
+ };
535
+ readonly recommendations: {
536
+ readonly type: "array";
537
+ readonly items: {
538
+ readonly type: "string";
539
+ };
540
+ };
541
+ };
542
+ readonly required: readonly ["summary", "overallRisk", "vulnerabilities"];
543
+ };
544
+ /**
545
+ * Performance Report Schema
546
+ * 用于 perf 工具的结构化输出
547
+ */
548
+ export declare const PerformanceReportSchema: {
549
+ readonly type: "object";
550
+ readonly properties: {
551
+ readonly summary: {
552
+ readonly type: "string";
553
+ };
554
+ readonly overallScore: {
555
+ readonly type: "number";
556
+ readonly minimum: 0;
557
+ readonly maximum: 100;
558
+ };
559
+ readonly bottlenecks: {
560
+ readonly type: "array";
561
+ readonly items: {
562
+ readonly type: "object";
563
+ readonly properties: {
564
+ readonly type: {
565
+ readonly type: "string";
566
+ readonly enum: readonly ["algorithm", "memory", "database", "network", "rendering", "io"];
567
+ };
568
+ readonly severity: {
569
+ readonly type: "string";
570
+ readonly enum: readonly ["critical", "high", "medium", "low"];
571
+ };
572
+ readonly location: {
573
+ readonly type: "object";
574
+ readonly properties: {
575
+ readonly file: {
576
+ readonly type: "string";
577
+ };
578
+ readonly line: {
579
+ readonly type: "number";
580
+ };
581
+ readonly function: {
582
+ readonly type: "string";
583
+ };
584
+ };
585
+ };
586
+ readonly description: {
587
+ readonly type: "string";
588
+ };
589
+ readonly impact: {
590
+ readonly type: "string";
591
+ };
592
+ readonly currentMetric: {
593
+ readonly type: "string";
594
+ };
595
+ };
596
+ readonly required: readonly ["type", "severity", "description"];
597
+ };
598
+ };
599
+ readonly metrics: {
600
+ readonly type: "object";
601
+ readonly properties: {
602
+ readonly executionTime: {
603
+ readonly type: "number";
604
+ };
605
+ readonly memoryUsage: {
606
+ readonly type: "number";
607
+ };
608
+ readonly cpuUsage: {
609
+ readonly type: "number";
610
+ };
611
+ readonly throughput: {
612
+ readonly type: "number";
613
+ };
614
+ readonly latency: {
615
+ readonly type: "number";
616
+ };
617
+ };
618
+ };
619
+ readonly optimizations: {
620
+ readonly type: "array";
621
+ readonly items: {
622
+ readonly type: "object";
623
+ readonly properties: {
624
+ readonly title: {
625
+ readonly type: "string";
626
+ };
627
+ readonly description: {
628
+ readonly type: "string";
629
+ };
630
+ readonly priority: {
631
+ readonly type: "string";
632
+ readonly enum: readonly ["high", "medium", "low"];
633
+ };
634
+ readonly expectedImprovement: {
635
+ readonly type: "string";
636
+ };
637
+ readonly implementation: {
638
+ readonly type: "string";
639
+ };
640
+ };
641
+ readonly required: readonly ["title", "description", "priority"];
642
+ };
643
+ };
644
+ readonly benchmarks: {
645
+ readonly type: "object";
646
+ readonly additionalProperties: true;
647
+ };
648
+ };
649
+ readonly required: readonly ["summary", "overallScore", "bottlenecks", "optimizations"];
650
+ };
651
+ export interface CodeReviewReport {
652
+ summary: string;
653
+ overallScore: number;
654
+ issues: Array<{
655
+ severity: 'critical' | 'high' | 'medium' | 'low' | 'info';
656
+ category: 'security' | 'performance' | 'quality' | 'style' | 'best-practice';
657
+ line?: number;
658
+ file?: string;
659
+ message: string;
660
+ suggestion?: string;
661
+ code?: string;
662
+ }>;
663
+ strengths?: string[];
664
+ recommendations?: string[];
665
+ metrics?: {
666
+ complexity?: number;
667
+ maintainability?: number;
668
+ testCoverage?: number;
669
+ };
670
+ }
671
+ export interface DebugReport {
672
+ summary: string;
673
+ rootCause: string;
674
+ errorType: 'syntax' | 'runtime' | 'logic' | 'performance' | 'memory' | 'network' | 'unknown';
675
+ location?: {
676
+ file?: string;
677
+ line?: number;
678
+ column?: number;
679
+ function?: string;
680
+ };
681
+ stackTrace?: Array<{
682
+ file?: string;
683
+ line?: number;
684
+ function?: string;
685
+ }>;
686
+ debugStrategy?: string[];
687
+ solutions: Array<{
688
+ title: string;
689
+ description: string;
690
+ code?: string;
691
+ priority?: 'high' | 'medium' | 'low';
692
+ }>;
693
+ relatedIssues?: string[];
694
+ }
695
+ export interface BugAnalysis {
696
+ summary: string;
697
+ bugType: 'functional' | 'performance' | 'security' | 'ui' | 'data' | 'integration';
698
+ severity: 'critical' | 'high' | 'medium' | 'low';
699
+ rootCause: string;
700
+ affectedComponents?: string[];
701
+ affectedFiles?: string[];
702
+ fixPlan: {
703
+ steps: string[];
704
+ estimatedTime?: string;
705
+ risks?: string[];
706
+ };
707
+ testPlan?: {
708
+ unitTests?: string[];
709
+ integrationTests?: string[];
710
+ manualTests?: string[];
711
+ };
712
+ preventionMeasures?: string[];
713
+ }
714
+ export interface TestSuite {
715
+ summary: string;
716
+ framework: 'jest' | 'vitest' | 'mocha' | 'jasmine' | 'pytest' | 'junit';
717
+ testCases: Array<{
718
+ name: string;
719
+ description?: string;
720
+ type: 'unit' | 'integration' | 'e2e' | 'performance';
721
+ code: string;
722
+ assertions?: string[];
723
+ }>;
724
+ edgeCases?: Array<{
725
+ scenario?: string;
726
+ input?: string;
727
+ expectedOutput?: string;
728
+ }>;
729
+ mockData?: Record<string, any>;
730
+ coverage?: {
731
+ statements?: number;
732
+ branches?: number;
733
+ functions?: number;
734
+ lines?: number;
735
+ };
736
+ }
737
+ export interface RefactorPlan {
738
+ summary: string;
739
+ goal: 'improve_readability' | 'reduce_complexity' | 'improve_performance' | 'improve_maintainability' | 'modernize';
740
+ currentIssues?: string[];
741
+ refactoringSteps: Array<{
742
+ step: number;
743
+ title: string;
744
+ description: string;
745
+ before?: string;
746
+ after?: string;
747
+ rationale?: string;
748
+ }>;
749
+ riskAssessment: {
750
+ level: 'low' | 'medium' | 'high';
751
+ risks: string[];
752
+ mitigations?: string[];
753
+ };
754
+ rollbackPlan?: string;
755
+ estimatedEffort?: {
756
+ hours?: number;
757
+ complexity?: 'low' | 'medium' | 'high';
758
+ };
759
+ expectedBenefits?: string[];
760
+ }
761
+ export interface SecurityReport {
762
+ summary: string;
763
+ overallRisk: 'critical' | 'high' | 'medium' | 'low' | 'none';
764
+ vulnerabilities: Array<{
765
+ id?: string;
766
+ type: 'injection' | 'xss' | 'csrf' | 'auth' | 'crypto' | 'data-exposure' | 'dos' | 'other';
767
+ severity: 'critical' | 'high' | 'medium' | 'low';
768
+ title: string;
769
+ description: string;
770
+ location?: {
771
+ file?: string;
772
+ line?: number;
773
+ code?: string;
774
+ };
775
+ cwe?: string;
776
+ cvss?: number;
777
+ remediation?: string;
778
+ references?: string[];
779
+ }>;
780
+ complianceChecks?: Array<{
781
+ standard?: string;
782
+ passed?: boolean;
783
+ details?: string;
784
+ }>;
785
+ recommendations?: string[];
786
+ }
787
+ export interface PerformanceReport {
788
+ summary: string;
789
+ overallScore: number;
790
+ bottlenecks: Array<{
791
+ type: 'algorithm' | 'memory' | 'database' | 'network' | 'rendering' | 'io';
792
+ severity: 'critical' | 'high' | 'medium' | 'low';
793
+ location?: {
794
+ file?: string;
795
+ line?: number;
796
+ function?: string;
797
+ };
798
+ description: string;
799
+ impact?: string;
800
+ currentMetric?: string;
801
+ }>;
802
+ metrics?: {
803
+ executionTime?: number;
804
+ memoryUsage?: number;
805
+ cpuUsage?: number;
806
+ throughput?: number;
807
+ latency?: number;
808
+ };
809
+ optimizations: Array<{
810
+ title: string;
811
+ description: string;
812
+ priority: 'high' | 'medium' | 'low';
813
+ expectedImprovement?: string;
814
+ implementation?: string;
815
+ }>;
816
+ benchmarks?: Record<string, any>;
817
+ }