il2cpp-dump-analyzer-mcp
Version:
Agentic RAG system for analyzing IL2CPP dump.cs files from Unity games
132 lines (131 loc) • 3.49 kB
TypeScript
/**
* @fileoverview MCP Tool Orchestration Engine
* Provides intelligent tool orchestration, task decomposition, and workflow management
* for complex IL2CPP analysis requests within the MCP framework
*/
import { ToolExecutionContext } from '../mcp/base-tool-handler';
import { OrchestratorConfig, TaskDecomposition, WorkflowExecution, IntentAnalysis, OrchestratorStats } from './types';
/**
* MCP Tool Orchestration Engine
* Intelligently decomposes complex requests into MCP tool workflows
*/
export declare class MCPOrchestrator {
private context;
private config;
private stats;
private cache;
private workflowHistory;
constructor(context: ToolExecutionContext, config?: Partial<OrchestratorConfig>);
/**
* Decompose a complex request into executable subtasks
*/
decomposeTask(request: string): Promise<TaskDecomposition>;
/**
* Execute a complete workflow from task decomposition
*/
executeWorkflow(decomposition: TaskDecomposition): Promise<WorkflowExecution>;
/**
* Select the most appropriate tool for a given intent
*/
selectTool(intent: IntentAnalysis): string;
/**
* Get orchestrator statistics
*/
getStats(): OrchestratorStats;
/**
* Clear cache and reset statistics
*/
reset(): void;
/**
* Initialize orchestrator statistics
*/
private initializeStats;
/**
* Analyze intent from natural language request
*/
private analyzeIntent;
/**
* Extract target entity from request
*/
private extractTarget;
/**
* Extract type from request
*/
private extractType;
/**
* Extract filters from request
*/
private extractFilters;
/**
* Extract keywords from request
*/
private extractKeywords;
/**
* Calculate confidence score for intent analysis
*/
private calculateIntentConfidence;
/**
* Generate subtasks based on intent analysis
*/
private generateSubtasks;
/**
* Check if request requires multiple tools
*/
private isComplexRequest;
/**
* Generate subtasks for complex requests
*/
private generateComplexSubtasks;
/**
* Generate parameters for a specific tool based on intent
*/
private generateToolParameters;
/**
* Determine execution strategy for subtasks
*/
private determineExecutionStrategy;
/**
* Calculate estimated duration for workflow
*/
private calculateEstimatedDuration;
/**
* Generate explanation for decomposition strategy
*/
private generateDecompositionExplanation;
/**
* Execute subtasks in parallel
*/
private executeParallel;
/**
* Execute subtasks sequentially with dependency resolution
*/
private executeSequential;
/**
* Execute a single subtask with retry logic
*/
private executeSubtask;
/**
* Execute a specific MCP tool
*/
private executeTool;
/**
* Sort tasks by dependencies and priority
*/
private sortTasksByDependencies;
/**
* Resolve parameter dependencies using completed task results
*/
private resolveDependencies;
/**
* Generate cache key for subtask
*/
private generateCacheKey;
/**
* Calculate workflow metrics
*/
private calculateWorkflowMetrics;
/**
* Update orchestrator statistics
*/
private updateStats;
}