reasoning_assist
Provides structured reasoning assistance to break down complex problems into logical steps using specified models.
Instructions
Structured reasoning assistance for complex problems
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| problem | Yes | Problem statement requiring reasoning | |
| steps | No | Number of reasoning steps requested | |
| model | No | Model to use for reasoning | architecture-reasoning:latest |
Implementation Reference
- local-ai-server.js:214-231 (handler)The main handler function for 'reasoning_assist' that constructs a structured multi-step reasoning prompt based on the problem and number of steps, then delegates to the local AI via queryLocalAI.async reasoningAssist(problem, steps = 5, model = 'architecture-reasoning:latest') { const structuredPrompt = `Problem: ${problem} Please provide a structured reasoning approach with exactly ${steps} steps: 1. [Step 1 reasoning] 2. [Step 2 reasoning] 3. [Step 3 reasoning] ${steps > 3 ? '4. [Step 4 reasoning]' : ''} ${steps > 4 ? '5. [Step 5 reasoning]' : ''} ${steps > 5 ? Array.from({length: steps - 5}, (_, i) => `${i + 6}. [Step ${i + 6} reasoning]`).join('\n') : ''} Conclusion: [Final reasoning conclusion] Think step by step and show your reasoning process clearly.`; return await this.queryLocalAI(structuredPrompt, model, 0.6); }
- local-ai-server.js:60-79 (schema)Input schema definition for the reasoning_assist tool, specifying required 'problem' string, optional 'steps' number (default 5), and 'model' string (default 'architecture-reasoning:latest').inputSchema: { type: 'object', properties: { problem: { type: 'string', description: 'Problem statement requiring reasoning' }, steps: { type: 'number', description: 'Number of reasoning steps requested', default: 5 }, model: { type: 'string', description: 'Model to use for reasoning', default: 'architecture-reasoning:latest' } }, required: ['problem'] }
- local-ai-server.js:57-80 (registration)Tool registration in the ListTools response, defining name, description, and input schema.{ name: 'reasoning_assist', description: 'Structured reasoning assistance for complex problems', inputSchema: { type: 'object', properties: { problem: { type: 'string', description: 'Problem statement requiring reasoning' }, steps: { type: 'number', description: 'Number of reasoning steps requested', default: 5 }, model: { type: 'string', description: 'Model to use for reasoning', default: 'architecture-reasoning:latest' } }, required: ['problem'] } },
- local-ai-server.js:149-150 (registration)Registration of the tool handler in the CallToolRequest switch statement, routing calls to the reasoningAssist method.case 'reasoning_assist': return await this.reasoningAssist(args.problem, args.steps, args.model);