mcp-adr-analysis-server 2.0.8 → 2.0.10

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 (62) hide show
  1. package/dist/src/index.d.ts +8 -0
  2. package/dist/src/index.d.ts.map +1 -1
  3. package/dist/src/index.js +434 -5
  4. package/dist/src/index.js.map +1 -1
  5. package/dist/src/resources/index.d.ts.map +1 -1
  6. package/dist/src/resources/index.js +71 -1
  7. package/dist/src/resources/index.js.map +1 -1
  8. package/dist/src/tools/human-override-tool.d.ts +42 -0
  9. package/dist/src/tools/human-override-tool.d.ts.map +1 -0
  10. package/dist/src/tools/human-override-tool.js +431 -0
  11. package/dist/src/tools/human-override-tool.js.map +1 -0
  12. package/dist/src/tools/smart-git-push-tool.d.ts +5 -1
  13. package/dist/src/tools/smart-git-push-tool.d.ts.map +1 -1
  14. package/dist/src/tools/smart-git-push-tool.js +75 -30
  15. package/dist/src/tools/smart-git-push-tool.js.map +1 -1
  16. package/dist/src/tools/smart-score-tool.d.ts +138 -0
  17. package/dist/src/tools/smart-score-tool.d.ts.map +1 -0
  18. package/dist/src/tools/smart-score-tool.js +602 -0
  19. package/dist/src/tools/smart-score-tool.js.map +1 -0
  20. package/dist/src/tools/todo-management-tool.d.ts +184 -6
  21. package/dist/src/tools/todo-management-tool.d.ts.map +1 -1
  22. package/dist/src/tools/todo-management-tool.js +819 -42
  23. package/dist/src/tools/todo-management-tool.js.map +1 -1
  24. package/dist/src/tools/tool-chain-orchestrator.d.ts +164 -0
  25. package/dist/src/tools/tool-chain-orchestrator.d.ts.map +1 -0
  26. package/dist/src/tools/tool-chain-orchestrator.js +738 -0
  27. package/dist/src/tools/tool-chain-orchestrator.js.map +1 -0
  28. package/dist/src/tools/troubleshoot-guided-workflow-tool.d.ts +150 -0
  29. package/dist/src/tools/troubleshoot-guided-workflow-tool.d.ts.map +1 -0
  30. package/dist/src/tools/troubleshoot-guided-workflow-tool.js +520 -0
  31. package/dist/src/tools/troubleshoot-guided-workflow-tool.js.map +1 -0
  32. package/dist/src/types/knowledge-graph-schemas.d.ts +481 -0
  33. package/dist/src/types/knowledge-graph-schemas.d.ts.map +1 -0
  34. package/dist/src/types/knowledge-graph-schemas.js +59 -0
  35. package/dist/src/types/knowledge-graph-schemas.js.map +1 -0
  36. package/dist/src/utils/enhanced-sensitive-detector.js +1 -1
  37. package/dist/src/utils/enhanced-sensitive-detector.js.map +1 -1
  38. package/dist/src/utils/json-safe.d.ts +38 -0
  39. package/dist/src/utils/json-safe.d.ts.map +1 -0
  40. package/dist/src/utils/json-safe.js +86 -0
  41. package/dist/src/utils/json-safe.js.map +1 -0
  42. package/dist/src/utils/knowledge-graph-manager.d.ts +28 -0
  43. package/dist/src/utils/knowledge-graph-manager.d.ts.map +1 -0
  44. package/dist/src/utils/knowledge-graph-manager.js +192 -0
  45. package/dist/src/utils/knowledge-graph-manager.js.map +1 -0
  46. package/dist/src/utils/mcp-response-validator.d.ts +30 -0
  47. package/dist/src/utils/mcp-response-validator.d.ts.map +1 -0
  48. package/dist/src/utils/mcp-response-validator.js +197 -0
  49. package/dist/src/utils/mcp-response-validator.js.map +1 -0
  50. package/dist/src/utils/project-health-scoring.d.ts +177 -0
  51. package/dist/src/utils/project-health-scoring.d.ts.map +1 -0
  52. package/dist/src/utils/project-health-scoring.js +370 -0
  53. package/dist/src/utils/project-health-scoring.js.map +1 -0
  54. package/dist/src/utils/release-readiness-detector.d.ts +2 -0
  55. package/dist/src/utils/release-readiness-detector.d.ts.map +1 -1
  56. package/dist/src/utils/release-readiness-detector.js +4 -2
  57. package/dist/src/utils/release-readiness-detector.js.map +1 -1
  58. package/dist/src/utils/todo-file-watcher.d.ts +26 -0
  59. package/dist/src/utils/todo-file-watcher.d.ts.map +1 -0
  60. package/dist/src/utils/todo-file-watcher.js +163 -0
  61. package/dist/src/utils/todo-file-watcher.js.map +1 -0
  62. package/package.json +1 -1
@@ -0,0 +1,42 @@
1
+ /**
2
+ * Simple Human Override Tool
3
+ *
4
+ * Forces AI-powered planning through OpenRouter.ai when humans need
5
+ * to cut through LLM confusion and get specific tasks done.
6
+ */
7
+ import { z } from 'zod';
8
+ declare const HumanOverrideSchema: z.ZodObject<{
9
+ taskDescription: z.ZodString;
10
+ projectPath: z.ZodString;
11
+ adrDirectory: z.ZodDefault<z.ZodString>;
12
+ todoPath: z.ZodDefault<z.ZodString>;
13
+ priority: z.ZodDefault<z.ZodEnum<["low", "medium", "high", "critical"]>>;
14
+ forceExecution: z.ZodDefault<z.ZodBoolean>;
15
+ deadline: z.ZodOptional<z.ZodString>;
16
+ additionalContext: z.ZodOptional<z.ZodString>;
17
+ }, "strip", z.ZodTypeAny, {
18
+ projectPath: string;
19
+ priority: "medium" | "low" | "high" | "critical";
20
+ adrDirectory: string;
21
+ todoPath: string;
22
+ taskDescription: string;
23
+ forceExecution: boolean;
24
+ deadline?: string | undefined;
25
+ additionalContext?: string | undefined;
26
+ }, {
27
+ projectPath: string;
28
+ taskDescription: string;
29
+ priority?: "medium" | "low" | "high" | "critical" | undefined;
30
+ adrDirectory?: string | undefined;
31
+ todoPath?: string | undefined;
32
+ forceExecution?: boolean | undefined;
33
+ deadline?: string | undefined;
34
+ additionalContext?: string | undefined;
35
+ }>;
36
+ type HumanOverrideArgs = z.infer<typeof HumanOverrideSchema>;
37
+ /**
38
+ * Main human override function
39
+ */
40
+ export declare function humanOverride(args: HumanOverrideArgs): Promise<any>;
41
+ export {};
42
+ //# sourceMappingURL=human-override-tool.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"human-override-tool.d.ts","sourceRoot":"","sources":["../../../src/tools/human-override-tool.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,QAAA,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;EASvB,CAAC;AAEH,KAAK,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAsP7D;;GAEG;AACH,wBAAsB,aAAa,CAAC,IAAI,EAAE,iBAAiB,GAAG,OAAO,CAAC,GAAG,CAAC,CA4NzE"}
@@ -0,0 +1,431 @@
1
+ /**
2
+ * Simple Human Override Tool
3
+ *
4
+ * Forces AI-powered planning through OpenRouter.ai when humans need
5
+ * to cut through LLM confusion and get specific tasks done.
6
+ */
7
+ import { z } from 'zod';
8
+ import { McpAdrError } from '../types/index.js';
9
+ import { loadAIConfig, isAIExecutionEnabled, getRecommendedModel } from '../config/ai-config.js';
10
+ import { KnowledgeGraphManager } from '../utils/knowledge-graph-manager.js';
11
+ // Simple human override schema
12
+ const HumanOverrideSchema = z.object({
13
+ taskDescription: z.string().describe('What the human wants accomplished (in plain English)'),
14
+ projectPath: z.string().describe('Path to project directory'),
15
+ adrDirectory: z.string().default('docs/adrs').describe('ADR directory path'),
16
+ todoPath: z.string().default('TODO.md').describe('Path to TODO.md file'),
17
+ priority: z.enum(['low', 'medium', 'high', 'critical']).default('high').describe('Task priority'),
18
+ forceExecution: z.boolean().default(true).describe('Force immediate execution planning'),
19
+ deadline: z.string().optional().describe('When this must be completed'),
20
+ additionalContext: z.string().optional().describe('Any additional context or constraints')
21
+ });
22
+ /**
23
+ * Generate execution plan using AI (forced override mode)
24
+ */
25
+ async function generateForcedAIPlan(args) {
26
+ const aiConfig = loadAIConfig();
27
+ if (!isAIExecutionEnabled(aiConfig)) {
28
+ // Fallback to basic analysis if AI not available
29
+ return generateFallbackPlan(args);
30
+ }
31
+ // Available MCP tools for AI to choose from
32
+ const availableTools = [
33
+ 'analyze_project_ecosystem - Analyze technology stack and architectural patterns',
34
+ 'generate_adrs_from_prd - Convert requirements to Architectural Decision Records',
35
+ 'suggest_adrs - Auto-suggest ADRs based on code analysis',
36
+ 'analyze_content_security - Detect and mask sensitive information',
37
+ 'generate_rules - Extract architectural rules from project',
38
+ 'generate_adr_todo - Generate TODO.md from ADRs with task breakdown',
39
+ 'compare_adr_progress - Validate TODO vs ADRs vs environment state',
40
+ 'manage_todo - TODO.md lifecycle management and progress tracking',
41
+ 'generate_deployment_guidance - AI-driven deployment procedures',
42
+ 'smart_score - Project health scoring with cross-tool sync',
43
+ 'troubleshoot_guided_workflow - Systematic troubleshooting workflow',
44
+ 'smart_git_push - Release readiness analysis and git operations',
45
+ 'generate_research_questions - Generate targeted research questions',
46
+ 'validate_rules - Validate architectural rule compliance',
47
+ 'analyze_deployment_progress - Analyze deployment progress and completion'
48
+ ];
49
+ const systemPrompt = `You are an expert MCP tool orchestrator. A human has issued an override command to force completion of a specific task.
50
+
51
+ CRITICAL: The human wants this task completed efficiently and correctly. Generate a focused tool execution plan.
52
+
53
+ Available MCP Tools:
54
+ ${availableTools.join('\n')}
55
+
56
+ Project Context:
57
+ - Project Path: ${args.projectPath}
58
+ - ADR Directory: ${args.adrDirectory}
59
+ - TODO Path: ${args.todoPath}
60
+ - Priority: ${args.priority}
61
+ - Force Execution: ${args.forceExecution}
62
+
63
+ Return a JSON plan with this exact structure:
64
+ {
65
+ "planId": "override-TIMESTAMP",
66
+ "toolChain": [
67
+ {
68
+ "tool": "tool_name",
69
+ "params": {
70
+ "projectPath": "${args.projectPath}",
71
+ "adrDirectory": "${args.adrDirectory}",
72
+ "todoPath": "${args.todoPath}"
73
+ },
74
+ "description": "what this step accomplishes"
75
+ }
76
+ ],
77
+ "executionNotes": [
78
+ "Step-by-step execution guidance",
79
+ "Important considerations"
80
+ ],
81
+ "confidence": 0.95
82
+ }
83
+
84
+ Keep the plan focused and executable. Maximum 5 tools unless the task is very complex.`;
85
+ const userPrompt = `HUMAN OVERRIDE TASK: "${args.taskDescription}"
86
+
87
+ ${args.additionalContext ? `Additional Context: ${args.additionalContext}` : ''}
88
+ ${args.deadline ? `Deadline: ${args.deadline}` : ''}
89
+
90
+ Priority: ${args.priority.toUpperCase()}
91
+
92
+ Generate an optimal tool execution plan to complete this task efficiently.`;
93
+ try {
94
+ const response = await fetch(aiConfig.baseURL + '/chat/completions', {
95
+ method: 'POST',
96
+ headers: {
97
+ 'Authorization': `Bearer ${aiConfig.apiKey}`,
98
+ 'Content-Type': 'application/json',
99
+ 'HTTP-Referer': aiConfig.siteUrl || '',
100
+ 'X-Title': aiConfig.siteName || ''
101
+ },
102
+ body: JSON.stringify({
103
+ model: getRecommendedModel('analysis'),
104
+ messages: [
105
+ { role: 'system', content: systemPrompt },
106
+ { role: 'user', content: userPrompt }
107
+ ],
108
+ temperature: 0.1, // Low for consistent planning
109
+ max_tokens: 2000,
110
+ response_format: { type: 'json_object' }
111
+ })
112
+ });
113
+ if (!response.ok) {
114
+ throw new Error(`OpenRouter API error: ${response.status}`);
115
+ }
116
+ const result = await response.json();
117
+ const planContent = result.choices?.[0]?.message?.content;
118
+ if (!planContent) {
119
+ throw new Error('No plan generated from AI');
120
+ }
121
+ const aiPlan = JSON.parse(planContent);
122
+ // Validate and ensure required structure
123
+ return {
124
+ planId: aiPlan.planId || `override-${Date.now()}`,
125
+ toolChain: aiPlan.toolChain || [],
126
+ executionNotes: aiPlan.executionNotes || ['Execute tools in sequence', 'Report results after each step'],
127
+ confidence: aiPlan.confidence || 0.8
128
+ };
129
+ }
130
+ catch (error) {
131
+ // Fallback to basic planning
132
+ return generateFallbackPlan(args);
133
+ }
134
+ }
135
+ /**
136
+ * Extract goals from task description using simple keyword analysis
137
+ */
138
+ function extractGoalsFromDescription(description) {
139
+ const goals = [];
140
+ const lowerDesc = description.toLowerCase();
141
+ // Goal detection patterns
142
+ const goalPatterns = [
143
+ { pattern: /analyze|analysis/, goal: 'Analyze project or codebase' },
144
+ { pattern: /generate|create/, goal: 'Generate or create artifacts' },
145
+ { pattern: /deploy|deployment/, goal: 'Handle deployment tasks' },
146
+ { pattern: /todo|task/, goal: 'Manage TODO and task tracking' },
147
+ { pattern: /adr|decision/, goal: 'Work with architectural decisions' },
148
+ { pattern: /test|testing/, goal: 'Handle testing and validation' },
149
+ { pattern: /fix|repair|solve/, goal: 'Fix or resolve issues' },
150
+ { pattern: /document|documentation/, goal: 'Create or update documentation' },
151
+ { pattern: /score|health|metrics/, goal: 'Evaluate project health and metrics' },
152
+ { pattern: /integrate|integration/, goal: 'Integrate systems or components' }
153
+ ];
154
+ for (const { pattern, goal } of goalPatterns) {
155
+ if (pattern.test(lowerDesc)) {
156
+ goals.push(goal);
157
+ }
158
+ }
159
+ // Default goal if no patterns match
160
+ if (goals.length === 0) {
161
+ goals.push('Complete requested task');
162
+ }
163
+ return goals;
164
+ }
165
+ /**
166
+ * Fallback plan generation when AI is not available
167
+ */
168
+ function generateFallbackPlan(args) {
169
+ const task = args.taskDescription.toLowerCase();
170
+ const toolChain = [];
171
+ const baseParams = {
172
+ projectPath: args.projectPath,
173
+ adrDirectory: args.adrDirectory,
174
+ todoPath: args.todoPath
175
+ };
176
+ // Basic keyword matching for fallback
177
+ if (task.includes('analyze') || task.includes('analysis')) {
178
+ toolChain.push({
179
+ tool: 'analyze_project_ecosystem',
180
+ params: baseParams,
181
+ description: 'Analyze project ecosystem and technology stack'
182
+ });
183
+ }
184
+ if (task.includes('todo') || task.includes('task')) {
185
+ toolChain.push({
186
+ tool: 'manage_todo',
187
+ params: { ...baseParams, operation: 'analyze_progress' },
188
+ description: 'Analyze TODO.md progress and task status'
189
+ });
190
+ }
191
+ if (task.includes('deploy') || task.includes('release')) {
192
+ toolChain.push({
193
+ tool: 'smart_git_push',
194
+ params: { ...baseParams, checkReleaseReadiness: true },
195
+ description: 'Check deployment and release readiness'
196
+ });
197
+ }
198
+ if (task.includes('adr') || task.includes('decision')) {
199
+ toolChain.push({
200
+ tool: 'suggest_adrs',
201
+ params: baseParams,
202
+ description: 'Analyze and suggest architectural decisions'
203
+ });
204
+ }
205
+ if (task.includes('score') || task.includes('health')) {
206
+ toolChain.push({
207
+ tool: 'smart_score',
208
+ params: { ...baseParams, operation: 'recalculate_scores' },
209
+ description: 'Calculate project health scores'
210
+ });
211
+ }
212
+ // Default fallback if no keywords match
213
+ if (toolChain.length === 0) {
214
+ toolChain.push({
215
+ tool: 'analyze_project_ecosystem',
216
+ params: baseParams,
217
+ description: 'General project analysis as requested'
218
+ });
219
+ }
220
+ return {
221
+ planId: `fallback-override-${Date.now()}`,
222
+ toolChain,
223
+ executionNotes: [
224
+ 'Fallback plan generated (AI not available)',
225
+ 'Execute tools in sequence',
226
+ 'Verify results manually'
227
+ ],
228
+ confidence: 0.6
229
+ };
230
+ }
231
+ /**
232
+ * Main human override function
233
+ */
234
+ export async function humanOverride(args) {
235
+ try {
236
+ const validatedArgs = HumanOverrideSchema.parse(args);
237
+ // Initialize knowledge graph manager
238
+ const kgManager = new KnowledgeGraphManager();
239
+ // Parse goals from task description
240
+ const parsedGoals = extractGoalsFromDescription(validatedArgs.taskDescription);
241
+ // Create intent snapshot in knowledge graph
242
+ const intentId = await kgManager.createIntent(validatedArgs.taskDescription, parsedGoals, validatedArgs.priority === 'critical' ? 'high' : validatedArgs.priority);
243
+ // Generate AI-powered execution plan
244
+ const plan = await generateForcedAIPlan(validatedArgs);
245
+ // Store initial plan in knowledge graph
246
+ await kgManager.addToolExecution(intentId, 'human_override_planning', validatedArgs, { plan }, true, [], [], undefined);
247
+ // Generate structured LLM command schema
248
+ const llmCommandSchema = {
249
+ type: "object",
250
+ properties: {
251
+ humanOverrideRequest: {
252
+ type: "object",
253
+ properties: {
254
+ taskDescription: {
255
+ type: "string",
256
+ description: validatedArgs.taskDescription
257
+ },
258
+ priority: {
259
+ type: "string",
260
+ enum: ["low", "medium", "high", "critical"],
261
+ default: validatedArgs.priority
262
+ },
263
+ executionPlan: {
264
+ type: "object",
265
+ properties: {
266
+ planId: { type: "string", default: plan.planId },
267
+ confidence: { type: "number", default: plan.confidence },
268
+ toolChain: {
269
+ type: "array",
270
+ items: {
271
+ type: "object",
272
+ properties: {
273
+ stepId: { type: "string" },
274
+ tool: { type: "string" },
275
+ params: { type: "object" },
276
+ description: { type: "string" },
277
+ conditional: { type: "boolean", default: false },
278
+ retryable: { type: "boolean", default: true }
279
+ },
280
+ required: ["tool", "params", "description"]
281
+ }
282
+ }
283
+ },
284
+ required: ["planId", "toolChain"]
285
+ },
286
+ executionInstructions: {
287
+ type: "array",
288
+ items: { type: "string" },
289
+ default: [
290
+ "Execute each tool in the exact sequence provided",
291
+ "Use the exact parameters shown in the toolChain",
292
+ "Report results after each step before proceeding",
293
+ "Do not deviate from the plan unless critical errors occur",
294
+ "If any step fails, stop execution and report the failure immediately"
295
+ ]
296
+ }
297
+ },
298
+ required: ["taskDescription", "priority", "executionPlan"]
299
+ }
300
+ },
301
+ required: ["humanOverrideRequest"]
302
+ };
303
+ return {
304
+ content: [{
305
+ type: 'text',
306
+ text: `# 🚨 HUMAN OVERRIDE ACTIVATED
307
+
308
+ ## Task Request
309
+ **Description**: ${validatedArgs.taskDescription}
310
+ **Priority**: ${validatedArgs.priority.toUpperCase()}
311
+ **Force Execution**: ${validatedArgs.forceExecution ? 'YES' : 'NO'}
312
+ ${validatedArgs.deadline ? `**Deadline**: ${validatedArgs.deadline}` : ''}
313
+
314
+ ## AI-Generated Execution Plan
315
+ **Plan ID**: \`${plan.planId}\`
316
+ **Confidence**: ${(plan.confidence * 100).toFixed(0)}%
317
+
318
+ ## Tool Execution Chain
319
+
320
+ ${plan.toolChain.map((step, i) => `### Step ${i + 1}: ${step.description}
321
+
322
+ **Tool**: \`${step.tool}\`
323
+
324
+ **Parameters**:
325
+ \`\`\`json
326
+ ${JSON.stringify(step.params, null, 2)}
327
+ \`\`\`
328
+
329
+ `).join('')}
330
+
331
+ ## Execution Notes
332
+ ${plan.executionNotes.map(note => `• ${note}`).join('\n')}
333
+
334
+ ## ⚠️ HUMAN OVERRIDE INSTRUCTIONS
335
+
336
+ 1. **Execute each tool in the exact sequence shown above**
337
+ 2. **Use the exact parameters provided**
338
+ 3. **Report results after each step before proceeding**
339
+ 4. **Do not deviate from the plan unless critical errors occur**
340
+ 5. **If any step fails, stop and report the failure**
341
+
342
+ ${validatedArgs.deadline ? `**DEADLINE**: ${validatedArgs.deadline} - Execute promptly!` : ''}
343
+
344
+ ## 📋 Structured Command Schema for LLM
345
+
346
+ The LLM should use this JSON schema structure to understand and execute the human override request:
347
+
348
+ \`\`\`json
349
+ ${JSON.stringify(llmCommandSchema, null, 2)}
350
+ \`\`\`
351
+
352
+ ## 🤖 LLM Execution Data
353
+
354
+ When executing this human override, use the following structured data:
355
+
356
+ \`\`\`json
357
+ {
358
+ "humanOverrideRequest": {
359
+ "taskDescription": "${validatedArgs.taskDescription}",
360
+ "priority": "${validatedArgs.priority}",
361
+ "executionPlan": {
362
+ "planId": "${plan.planId}",
363
+ "confidence": ${plan.confidence},
364
+ "toolChain": ${JSON.stringify(plan.toolChain.map((step, i) => ({
365
+ stepId: `step_${i + 1}`,
366
+ tool: step.tool,
367
+ params: step.params,
368
+ description: step.description,
369
+ conditional: false,
370
+ retryable: true
371
+ })), null, 6)}
372
+ },
373
+ "executionInstructions": [
374
+ "Execute each tool in the exact sequence provided",
375
+ "Use the exact parameters shown in the toolChain",
376
+ "Report results after each step before proceeding",
377
+ "Do not deviate from the plan unless critical errors occur",
378
+ "If any step fails, stop execution and report the failure immediately"
379
+ ]
380
+ }
381
+ }
382
+ \`\`\`
383
+
384
+ *This plan was generated by AI to fulfill your specific request. The structured schema ensures precise LLM understanding and execution.*`
385
+ }],
386
+ metadata: {
387
+ intentId,
388
+ planId: plan.planId,
389
+ isHumanOverride: true,
390
+ toolCount: plan.toolChain.length,
391
+ confidence: plan.confidence,
392
+ priority: validatedArgs.priority,
393
+ forceExecution: validatedArgs.forceExecution,
394
+ parsedGoals,
395
+ llmCommandSchema,
396
+ structuredExecutionData: {
397
+ humanOverrideRequest: {
398
+ taskDescription: validatedArgs.taskDescription,
399
+ priority: validatedArgs.priority,
400
+ executionPlan: {
401
+ planId: plan.planId,
402
+ confidence: plan.confidence,
403
+ toolChain: plan.toolChain.map((step, i) => ({
404
+ stepId: `step_${i + 1}`,
405
+ tool: step.tool,
406
+ params: step.params,
407
+ description: step.description,
408
+ conditional: false,
409
+ retryable: true
410
+ }))
411
+ },
412
+ executionInstructions: [
413
+ "Execute each tool in the exact sequence provided",
414
+ "Use the exact parameters shown in the toolChain",
415
+ "Report results after each step before proceeding",
416
+ "Do not deviate from the plan unless critical errors occur",
417
+ "If any step fails, stop execution and report the failure immediately"
418
+ ]
419
+ }
420
+ }
421
+ }
422
+ };
423
+ }
424
+ catch (error) {
425
+ if (error instanceof z.ZodError) {
426
+ throw new McpAdrError(`Invalid input: ${error.errors.map(e => e.message).join(', ')}`, 'INVALID_INPUT');
427
+ }
428
+ throw new McpAdrError(`Human override failed: ${error instanceof Error ? error.message : String(error)}`, 'OVERRIDE_ERROR');
429
+ }
430
+ }
431
+ //# sourceMappingURL=human-override-tool.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"human-override-tool.js","sourceRoot":"","sources":["../../../src/tools/human-override-tool.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,YAAY,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AACjG,OAAO,EAAE,qBAAqB,EAAE,MAAM,qCAAqC,CAAC;AAE5E,+BAA+B;AAC/B,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IACnC,eAAe,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,sDAAsD,CAAC;IAC5F,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,2BAA2B,CAAC;IAC7D,YAAY,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC,QAAQ,CAAC,oBAAoB,CAAC;IAC5E,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,QAAQ,CAAC,sBA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AAW,EAAE,IAAI,CAAC,WAAW;gCAC7B,WAAW,EAAE,KAAK;gCAClB,SAAS,EAAE,IAAI;6BAChB,CAAC,CAAC;yBACJ;wBACD,qBAAqB,EAAE;4BACrB,kDAAkD;4BAClD,iDAAiD;4BACjD,kDAAkD;4BAClD,2DAA2D;4BAC3D,sEAAsE;yBACvE;qBACF;iBACF;aACF;SACF,CAAC;IAEJ,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,IAAI,KAAK,YAAY,CAAC,CAAC,QAAQ,EAAE,CAAC;YAChC,MAAM,IAAI,WAAW,CAAC,kBAAkB,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,EAAE,eAAe,CAAC,CAAC;QAC1G,CAAC;QAED,MAAM,IAAI,WAAW,CACnB,0BAA0B,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,EAClF,gBAAgB,CACjB,CAAC;IACJ,CAAC;AACH,CAAC"}
@@ -17,8 +17,12 @@ interface SmartGitPushArgs {
17
17
  releaseType?: 'major' | 'minor' | 'patch';
18
18
  }
19
19
  /**
20
- * Main smart git push function - MCP Safe Version
20
+ * Exported smart git push function with JSON-safe content escaping
21
21
  */
22
22
  export declare function smartGitPush(args: SmartGitPushArgs): Promise<any>;
23
+ /**
24
+ * MCP-safe wrapper for smart git push that never throws
25
+ */
26
+ export declare function smartGitPushMcpSafe(args: SmartGitPushArgs): Promise<any>;
23
27
  export {};
24
28
  //# sourceMappingURL=smart-git-push-tool.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"smart-git-push-tool.d.ts","sourceRoot":"","sources":["../../../src/tools/smart-git-push-tool.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAOH,UAAU,gBAAgB;IACxB,MAAM,CAAC,EAA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