UNPKG

cortexweaver

Version:

CortexWeaver is a command-line interface (CLI) tool that orchestrates a swarm of specialized AI agents, powered by Claude Code and Gemini CLI, to assist in software development. It transforms a high-level project plan (plan.md) into a series of coordinate

52 lines 1.83 kB
import { AgentStatus, AgentConfig, TaskContext } from './types/agent-types'; import { TaskData } from './cognitive-canvas'; import { Message } from './claude-client'; import { SessionInfo } from './session'; export interface ErrorHandlingCapabilities { reportImpasse(reason: string, context?: Record<string, any>, urgency?: 'low' | 'medium' | 'high'): Promise<void>; handleError(error: Error): Promise<void>; } export declare class AgentErrorHandler { private config; private cognitiveCanvas; private currentTask; private taskContext; private status; private conversationHistory; private currentSession; private lastError; constructor(config: AgentConfig | null, cognitiveCanvas: any, currentTask: TaskData | null, taskContext: TaskContext | null, status: AgentStatus, conversationHistory: Message[], currentSession: SessionInfo | null, lastError: Error | null); /** * Report an impasse to the cognitive canvas */ reportImpasse(reason: string, context?: Record<string, any>, urgency?: 'low' | 'medium' | 'high'): Promise<void>; /** * Handle errors and attempt recovery */ handleError(error: Error): Promise<void>; /** * Generate structured impasse details */ private generateImpasseDetails; /** * Identify blockers from impasse reason */ private identifyBlockers; /** * Generate suggested actions based on reason and blockers */ private generateSuggestions; /** * Estimate task progress based on agent state */ private estimateTaskProgress; /** * Map urgency to error severity */ private mapUrgencyToSeverity; /** * Map error severity to pheromone strength */ private mapSeverityToStrength; } //# sourceMappingURL=agent-error-handling.d.ts.map