UNPKG

crewai-ts

Version:

TypeScript port of crewAI for agent-based workflows

104 lines 3.95 kB
import { EventEmitter } from 'events'; import { FlowOrchestrator, FlowOrchestratorOptions, FlowMetrics, FlowState, ExtendedFlow, FlowExecutionMetrics, FlowVisualizationOptions } from './interfaces/FlowOrchestrator.js'; import { FlowStatus } from '../types.js'; export declare class MultiFlowOrchestrator extends EventEmitter implements FlowOrchestrator { #private; constructor(options?: Partial<FlowOrchestratorOptions>); getOrchestrator(): FlowOrchestrator | undefined; getFlowOrchestrator(flowId: string): FlowOrchestrator | undefined; registerFlow(definition: any): string; getFlow(flowId: string): ExtendedFlow<any, FlowState> | undefined; removeFlow(flowId: string): void; reset(): void; execute(options?: { inputData?: Record<string, any>; }): Promise<any>; startFlow(flowId: string, options?: any): Promise<void>; waitForAnyFlowToComplete(): Promise<{ flowId: string; result: any; } | null>; saveExecutionCheckpoint(): Promise<void>; loadExecutionCheckpoint(): Promise<void>; getMetrics(): FlowExecutionMetrics; getMetricsForFlow(flowId: string): FlowExecutionMetrics; getFlowDependencyOrder(): string[]; getFlowDependencyMatrix(): Record<string, Record<string, boolean>>; getFlowDependencyTree(): Record<string, string[]>; getFlowDependencyList(): Array<{ id: string; dependencies: string[]; }>; getFlowDependencyDepth(): Record<string, number>; getFlowDependencyWidth(): Record<string, number>; getFlowDependencyFanIn(): Record<string, number>; getFlowDependencyFanOut(): Record<string, number>; getFlowDependencyCycles(): string[][]; getFlowDependencyCriticalPath(): string[]; getFlowDependencyCriticalPathFlows(): string[]; getDependentFlows(flowId: string): string[]; getFlowGraph(): { nodes: Array<{ id: string; }>; edges: Array<{ from: string; to: string; }>; }; getFlowDependencies(flowId: string): string[]; get nodes(): Array<{ id: string; }>; get edges(): Array<{ from: string; to: string; }>; get options(): Required<FlowOrchestratorOptions>; get pendingFlows(): Map<string, ExtendedFlow<any, FlowState>>; get completedFlows(): Map<string, ExtendedFlow<any, FlowState>>; get failedFlows(): Map<string, ExtendedFlow<any, FlowState>>; get currentExecution(): { startTime: number; endTime?: number; status: 'running' | 'completed' | 'failed'; error?: Error; }; get criticalPath(): { flows: string[]; time: number; }; get runningFlows(): Set<string>; get flowExecutionTimes(): Map<string, number>; get timeSeriesData(): Array<{ timestamp: number; metrics: Record<string, number>; }>; get errors(): Map<string, Error>; get executionStartTime(): number; get executionEndTime(): number | undefined; get checkpointTimer(): NodeJS.Timeout | undefined; get memoryUsage(): { initial: number; peak: number; current: number; }; get performanceMetrics(): { totalExecutionTime: number; averageFlowTime: number; maxFlowTime: number; minFlowTime: number; flowCount: number; completedFlows: number; failedFlows: number; }; get visualizationPath(): string | undefined; get visualizationOptions(): FlowVisualizationOptions | undefined; getOptimizedOptions(): Record<string, any>; getFlowMetrics(flowId: string): FlowMetrics | undefined; getFlowExecutionTime(flowId: string): number; getFlowResourceUsage(flowId: string): FlowMetrics['nodeExecutions'] | undefined; getFlowStatus(flowId: string): FlowStatus; getFlowState(flowId: string): FlowState | undefined; } //# sourceMappingURL=MultiFlowOrchestrator.d.ts.map