debuggingapproach
Apply systematic debugging methods like binary search and cause elimination to identify and resolve technical issues through structured problem-solving approaches.
Instructions
A tool for applying systematic debugging approaches to solve technical issues. Supports various debugging methods including:
Binary Search
Reverse Engineering
Divide and Conquer
Backtracking
Cause Elimination
Program Slicing
Each approach provides a structured method for identifying and resolving issues.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| approachName | Yes | ||
| issue | Yes | ||
| steps | No | ||
| findings | No | ||
| resolution | No |
Implementation Reference
- The `processApproach` method in `DebuggingApproachServer` class handles the execution logic for the 'debuggingapproach' tool, including input validation and result formatting.
public processApproach(input: unknown): { content: Array<{ type: string; text: string }>; isError?: boolean } { try { const validatedInput = this.validateApproachData(input); const formattedOutput = this.formatApproachOutput(validatedInput); console.error(formattedOutput); return { content: [{ type: "text", text: JSON.stringify({ approachName: validatedInput.approachName, status: 'success', hasSteps: validatedInput.steps.length > 0, hasResolution: !!validatedInput.resolution }, null, 2) }] }; } catch (error) { return { content: [{ type: "text", text: JSON.stringify({ error: error instanceof Error ? error.message : String(error), status: 'failed' }, null, 2) }], isError: true }; } } - src/models/interfaces.ts:48-56 (schema)The `DebuggingApproachData` interface defines the input structure and types for the debugging approach tool.
export interface DebuggingApproachData { approachName: string; issue: string; steps: string[]; findings: string; resolution: string; } // Collaborative Reasoning - src/index.ts:1083-1095 (registration)The 'debuggingapproach' tool handler is registered within the main switch statement of the tool execution logic in `src/index.ts`, delegating to `debuggingServer.processApproach`.
case "debuggingapproach": { const result = debuggingServer.processApproach( request.params.arguments ); return { content: [ { type: "text", text: JSON.stringify(result, null, 2), }, ], }; }