Skip to main content
Glama

rapid_debug

Analyze server logs to identify issues and receive actionable fixes with debug commands in under 30 seconds.

Instructions

🚀 DEBUG SERVER LOGS IN UNDER 30 SECONDS - Instant analysis with actionable fixes and debug commands

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
logTextYesLog content to rapidly analyze and debug

Implementation Reference

  • Core handler function that executes the rapid_debug tool logic: performs instant pattern analysis, AI-powered log analysis, generates quick fixes and debug commands, all optimized to complete in under 30 seconds.
    async debugInUnder30Seconds(logContent: string): Promise<RapidDebugResult> { const startTime = Date.now(); // Phase 1: Instant Pattern Analysis (< 1 second) const patterns = this.instantPatternAnalysis(logContent); // Phase 2: AI Analysis (< 5 seconds) const aiAnalysis = await this.logAnalyzer.analyzeLogs(logContent, { logFormat: 'auto', contextLines: 20 // Reduced for speed }); // Phase 3: Generate Quick Fixes (< 2 seconds) const quickFixes = this.generateQuickFixes(patterns, aiAnalysis); // Phase 4: Debug Commands (< 1 second) const debugCommands = this.generateDebugCommands(patterns); const totalTime = Date.now() - startTime; return { timeToAnalysis: totalTime, criticalErrors: patterns.criticalErrors, quickFixes, debugCommands, rootCause: aiAnalysis.rootCause, confidence: aiAnalysis.confidence, nextSteps: this.generateNextSteps(patterns, aiAnalysis) }; }
  • src/server.ts:50-63 (registration)
    Registration of the 'rapid_debug' tool in the ListToolsRequestSchema handler, including name, description, and input schema.
    { name: 'rapid_debug', description: '🚀 DEBUG SERVER LOGS IN UNDER 30 SECONDS - Instant analysis with actionable fixes and debug commands', inputSchema: { type: 'object', properties: { logText: { type: 'string', description: 'Log content to rapidly analyze and debug' } }, required: ['logText'] } },
  • MCP server-side handler for the 'rapid_debug' tool call, validates input, invokes core debugger, and formats the MCPToolResult response.
    private async handleRapidDebug(args: any): Promise<MCPToolResult> { const { logText } = args; if (!logText || typeof logText !== 'string') { throw new Error('logText is required and must be a string'); } const startTime = Date.now(); const debugResult = await this.rapidDebugger.debugInUnder30Seconds(logText); const totalTime = Date.now() - startTime; return { success: true, data: { ...debugResult, totalProcessingTime: totalTime, message: `🚀 Server debugging completed in ${debugResult.timeToAnalysis}ms`, under30Seconds: debugResult.timeToAnalysis < 30000 }, metadata: { processedAt: new Date(), logLength: logText.length, debugMode: 'rapid' } }; }
  • Output schema defining the structure of the RapidDebugResult returned by the tool.
    export interface RapidDebugResult { timeToAnalysis: number; criticalErrors: string[]; quickFixes: QuickFix[]; debugCommands: string[]; rootCause: string; confidence: number; nextSteps: string[]; }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ChiragPatankar/loganalyzer-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server