analyze_problem
Break down complex problems into structured steps to identify how to approach and analyze them effectively.
Instructions
문제 분석|어떻게 접근|분석해줘|analyze this|how to approach|break this down - Break down complex problem into structured steps
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| problem | Yes | Problem to analyze | |
| domain | No | Problem domain |
Implementation Reference
- The main handler function that implements the core logic of the 'analyze_problem' tool. It takes a problem description and optional domain, then returns a structured analysis with breakdown, considerations, and next steps.export async function analyzeProblem(args: { problem: string; domain?: string }): Promise<ToolResult> { const { problem, domain = 'general' } = args; const problemAnalysis = { action: 'analyze_problem', problem, domain, analysis: { breakdown: [ 'Define the problem clearly', 'Identify key constraints and requirements', 'Break down into smaller sub-problems', 'Determine solution approach', 'Plan implementation steps' ], considerations: [ 'What are the inputs and expected outputs?', 'Are there any edge cases to consider?', 'What are the performance requirements?', 'How will this integrate with existing systems?' ], nextSteps: [ 'Research existing solutions', 'Create detailed implementation plan', 'Identify potential risks and mitigation strategies', 'Define success criteria' ] }, status: 'success' }; return { content: [{ type: 'text', text: `Problem: ${problem}\nDomain: ${domain}\n\nBreakdown:\n${problemAnalysis.analysis.breakdown.map((b, i) => `${i+1}. ${b}`).join('\n')}\n\nConsiderations:\n${problemAnalysis.analysis.considerations.map(c => `- ${c}`).join('\n')}\n\nNext Steps:\n${problemAnalysis.analysis.nextSteps.map(n => `- ${n}`).join('\n')}` }] }; }
- The ToolDefinition schema defining the input schema, description, and annotations for the 'analyze_problem' tool.export const analyzeProblemDefinition: ToolDefinition = { name: 'analyze_problem', description: '문제 분석|어떻게 접근|분석해줘|analyze this|how to approach|break this down - Break down complex problem into structured steps', inputSchema: { type: 'object', properties: { problem: { type: 'string', description: 'Problem to analyze' }, domain: { type: 'string', description: 'Problem domain' } }, required: ['problem'] }, annotations: { title: 'Analyze Problem', audience: ['user', 'assistant'], readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false } };
- src/index.ts:192-192 (registration)Registration of the analyzeProblem handler function in the toolHandlers object, which is used for dynamic tool dispatch during execution.'analyze_problem': analyzeProblem,
- src/index.ts:127-127 (registration)Registration of the analyzeProblemDefinition in the tools array, which is returned in ListToolsRequestSchema responses.analyzeProblemDefinition,
- src/index.ts:37-37 (registration)Import statement bringing in the tool definition and handler from the implementation file.import { analyzeProblemDefinition, analyzeProblem } from './tools/thinking/analyzeProblem.js';