import { EventEmitter } from 'events'; export interface AgentMessage { id: string; from: string; to: string | string[]; type: MessageType; payload: any; timestamp: number; priority: MessagePriority; requiresResponse: boolean; correlationId?: string; metadata: { intent: string; context: Record; securityLevel: 'public' | 'internal' | 'restricted' | 'confidential'; }; } export declare enum MessageType { TASK_ASSIGNMENT = "task_assignment", TASK_PROGRESS = "task_progress", TASK_COMPLETION = "task_completion", TASK_FAILURE = "task_failure", CONTEXT_SHARE = "context_share", KNOWLEDGE_SHARE = "knowledge_share", RESOURCE_SHARE = "resource_share", CAPABILITY_QUERY = "capability_query", AVAILABILITY_CHECK = "availability_check", COLLABORATION_REQUEST = "collaboration_request", HEARTBEAT = "heartbeat", STATUS_UPDATE = "status_update", ERROR_REPORT = "error_report", VALIDATION_REQUEST = "validation_request", VALIDATION_RESPONSE = "validation_response", EMERGENCY_STOP = "emergency_stop", ESCALATION = "escalation" } export declare enum MessagePriority { LOW = 1, NORMAL = 2, HIGH = 3, URGENT = 4, EMERGENCY = 5 } export interface AgentStatus { id: string; status: 'idle' | 'busy' | 'error' | 'offline'; currentTask?: string; capabilities: string[]; load: number; lastHeartbeat: number; metadata: Record; } export interface ConversationContext { conversationId: string; participants: string[]; topic: string; sharedState: Record; messageHistory: AgentMessage[]; startTime: number; lastActivity: number; } export declare class AgentCommunicationHub extends EventEmitter { private logger; private validator; private agents; private messageQueue; private conversations; private messageHistory; private readonly maxMessageHistory; private readonly heartbeatInterval; private readonly messageTimeout; constructor(); registerAgent(agentId: string, capabilities: string[], metadata?: Record): void; unregisterAgent(agentId: string): void; sendMessage(message: Omit): Promise; getMessages(agentId: string): AgentMessage[]; updateAgentStatus(agentId: string, updates: Partial): void; queryAgentsByCapability(capability: string): AgentStatus[]; findBestAgent(requiredCapabilities: string[], excludeAgents?: string[]): AgentStatus | null; startConversation(participants: string[], topic: string, _context?: Record): string; addToConversation(conversationId: string, message: AgentMessage): void; getConversation(conversationId: string): ConversationContext | null; broadcast(from: string, type: MessageType, payload: any, priority?: MessagePriority, securityLevel?: 'public' | 'internal' | 'restricted' | 'confidential'): Promise; emergencyStop(reason: string, initiatedBy: string): Promise; private validateMessage; private routeMessage; private deliverMessage; private isAuthorizedForConfidential; private generateMessageId; private generateConversationId; private startHeartbeatMonitoring; private startMessageCleanup; private trimMessageHistory; getStats(): { agentCount: number; activeAgents: number; messagesInHistory: number; activeConversations: number; queuedMessages: number; }; } //# sourceMappingURL=agent-communication.d.ts.map