UNPKG

@logspace/mcp-server

Version:

MCP server for Logspace log analysis integration with AI models.

348 lines 10.5 kB
/** * Enhanced MCP Tool: Analyze Session with Fallback Strategy * Combines the efficiency of the new approach with the safety of the original */ import { Tool } from '@modelcontextprotocol/sdk/types.js'; interface AnalyzeSessionArgs { bugId: number; strategy?: 'auto' | 'targeted' | 'comprehensive' | 'fallback'; maxTokens?: number; } export declare const analyzeSessionWithFallback: Tool; export declare function executeAnalyzeSessionWithFallback(args: AnalyzeSessionArgs): Promise<{ error: string; executionTime: number; strategy?: undefined; success?: undefined; issuesFound?: undefined; data?: undefined; tokenEstimate?: undefined; message?: undefined; fallbackReason?: undefined; comparison?: undefined; } | { strategy: string; success: boolean; issuesFound: number; data: any; tokenEstimate: number; executionTime: number; message: string; error?: undefined; fallbackReason?: undefined; comparison?: undefined; } | { strategy: string; success: boolean; issuesFound: any; data: { quickPatterns: { sessionSummary: { sessionInfo: { id: any; username: any; assignee: any; environment: any; status: any; created_at: any; video_url: any; }; metadata: any; sessionData: any; }; criticalIssues: { type: string; severity: string; count: number; details: any[]; }[]; recommendations: any[]; }; sessionAnalysis: { sessionInfo: { sessionInfo: { id: any; username: any; assignee: any; environment: any; status: any; created_at: any; video_url: any; }; metadata: any; sessionData: any; }; data: { network: any; console: any; interactions: { patterns: { userEngagement: number; rapidClicking: any[]; unusualScrolling: any[]; navigationPattern: any[]; inputBehavior: any[]; }; total: any; interactions: any; summary: { clickCount: any; inputCount: any; scrollCount: any; navigationCount: any; }; }; performance: { patterns: { slowestOperations: any[]; averageLoadTime: number; performanceBottlenecks: any[]; }; total: any; logs: any; summary: { averageDuration: number; slowestRequest: number; totalRequests: any; }; }; annotations: { total: any; annotations: any; summary: { noteCount: any; issueCount: any; highlightCount: any; }; }; drawings: { total: any; drawings: any; hasDrawings: boolean; }; }; timeline: any[]; insights: { potentialIssues: { type: string; severity: string; count: number; details: any[]; }[]; suspiciousSequences: { type: string; trigger: any; reactions: any[]; pattern: string; }[]; missingExpectedActions: any[]; }; }; networkRequests: any; consoleLogs: any; interactions: { total: any; interactions: any; summary: { clickCount: any; inputCount: any; scrollCount: any; navigationCount: any; }; }; fullSession?: undefined; allNetworkRequests?: undefined; allConsoleLogs?: undefined; allPerformance?: undefined; allInteractions?: undefined; metadata?: undefined; comprehensiveStats?: undefined; }; tokenEstimate: number; executionTime: number; message: string; error?: undefined; fallbackReason?: undefined; comparison?: undefined; } | { strategy: string; success: boolean; issuesFound: any; data: { quickPatterns: { sessionSummary: { sessionInfo: { id: any; username: any; assignee: any; environment: any; status: any; created_at: any; video_url: any; }; metadata: any; sessionData: any; }; criticalIssues: { type: string; severity: string; count: number; details: any[]; }[]; recommendations: any[]; }; fullSession: { sessionInfo: { sessionInfo: { id: any; username: any; assignee: any; environment: any; status: any; created_at: any; video_url: any; }; metadata: any; sessionData: any; }; data: { network: any; console: any; interactions: { patterns: { userEngagement: number; rapidClicking: any[]; unusualScrolling: any[]; navigationPattern: any[]; inputBehavior: any[]; }; total: any; interactions: any; summary: { clickCount: any; inputCount: any; scrollCount: any; navigationCount: any; }; }; performance: { patterns: { slowestOperations: any[]; averageLoadTime: number; performanceBottlenecks: any[]; }; total: any; logs: any; summary: { averageDuration: number; slowestRequest: number; totalRequests: any; }; }; annotations: { total: any; annotations: any; summary: { noteCount: any; issueCount: any; highlightCount: any; }; }; drawings: { total: any; drawings: any; hasDrawings: boolean; }; }; timeline: any[]; insights: { potentialIssues: { type: string; severity: string; count: number; details: any[]; }[]; suspiciousSequences: { type: string; trigger: any; reactions: any[]; pattern: string; }[]; missingExpectedActions: any[]; }; }; allNetworkRequests: any; allConsoleLogs: any; allPerformance: { total: any; logs: any; summary: { averageDuration: number; slowestRequest: number; totalRequests: any; }; }; allInteractions: { total: any; interactions: any; summary: { clickCount: any; inputCount: any; scrollCount: any; navigationCount: any; }; }; metadata: { sessionInfo: { id: any; username: any; assignee: any; environment: any; status: any; created_at: any; video_url: any; }; metadata: any; sessionData: any; }; comprehensiveStats: { totalNetworkRequests: any; totalConsoleLogs: any; totalInteractions: any; totalTimelineEvents: number; networkErrors: any; successfulRequests: any; allLogLevels: { errors: any; warnings: any; info: any; debug: any; }; }; sessionAnalysis?: undefined; networkRequests?: undefined; consoleLogs?: undefined; interactions?: undefined; }; tokenEstimate: number; executionTime: number; message: string; fallbackReason: string; comparison: { vsOriginalApproach: string; }; error?: undefined; } | { strategy: string; success: boolean; error: string; executionTime: number; issuesFound?: undefined; data?: undefined; tokenEstimate?: undefined; message?: undefined; fallbackReason?: undefined; comparison?: undefined; }>; export {}; //# sourceMappingURL=analyzeSessionWithFallback.d.ts.map