import { ArchetypeLoader } from '../../agents/archetypes.js';
import { AgentMessageBus } from '../../agents/message-bus.js';
import { WrfcController } from '../../agents/wrfc-controller.js';
import type { ConfigManager } from '../../config/manager.js';
import type { RuntimeEventBus } from '../../runtime/events/index.js';
import type { ExecutionIntent } from '../../runtime/execution-intents.js';
import type { AgentInput } from './schema.js';
export type AgentExecutor = {
    runAgent(record: AgentRecord): Promise<void>;
};
export interface AgentManagerDependencies {
    readonly archetypeLoader?: Pick<ArchetypeLoader, 'loadArchetype'> | undefined;
    readonly messageBus?: Pick<AgentMessageBus, 'registerAgent'> | undefined;
    readonly wrfcController?: Pick<WrfcController, 'createChain'> | null | undefined;
    readonly executor?: AgentExecutor | null | undefined;
    readonly configManager?: Pick<ConfigManager, 'get'> | undefined;
}
export declare const AGENT_TEMPLATES: Record<string, {
    description: string;
    defaultTools: string[];
}>;
export interface AgentRecord {
    id: string;
    task: string;
    template: string;
    model?: string | undefined;
    provider?: string | undefined;
    fallbackModels?: string[] | undefined;
    routing?: AgentInput['routing'] | undefined;
    executionIntent?: ExecutionIntent | undefined;
    reasoningEffort?: 'instant' | 'low' | 'medium' | 'high' | undefined;
    context?: string | undefined;
    tools: string[];
    status: 'pending' | 'running' | 'completed' | 'failed' | 'cancelled';
    startedAt: number;
    completedAt?: number | undefined;
    progress?: string | undefined;
    toolCallCount: number;
    usage?: {
        inputTokens: number;
        outputTokens: number;
        cacheReadTokens: number;
        cacheWriteTokens: number;
        reasoningTokens?: number | undefined;
        llmCallCount: number;
        turnCount: number;
        reasoningSummaryCount?: number | undefined;
    };
    error?: string | undefined;
    fullOutput?: string | undefined;
    streamingContent?: string | undefined;
    wrfcId?: string | undefined;
    dangerously_disable_wrfc?: boolean | undefined;
    cohort?: string | undefined;
    orchestrationGraphId?: string | undefined;
    orchestrationNodeId?: string | undefined;
    orchestrationDepth: number;
    parentAgentId?: string | undefined;
    parentNodeId?: string | undefined;
    capabilityCeilingTools?: string[] | undefined;
    successCriteria?: string[] | undefined;
    requiredEvidence?: string[] | undefined;
    writeScope?: string[] | undefined;
    executionProtocol: 'direct' | 'gather-plan-apply';
    reviewMode: 'none' | 'wrfc';
    communicationLane: 'parent-only' | 'parent-and-children' | 'cohort' | 'direct';
    /** Appended verbatim to the system prompt when the agent runs. Used by WRFC to inject constraint addenda. */
    systemPromptAddendum?: string | undefined;
    knowledgeInjections?: Array<{
        id: string;
        cls: string;
        summary: string;
        reason: string;
        confidence: number;
        reviewState: 'fresh' | 'reviewed' | 'stale' | 'contradicted';
    }>;
}
export declare class AgentManager {
    private agents;
    private runtimeBus;
    private orchestrationGraphs;
    private readonly archetypeLoader;
    private readonly messageBus;
    private wrfcController;
    private executor;
    private readonly configManager;
    constructor(deps?: AgentManagerDependencies);
    setRuntimeBus(runtimeBus: RuntimeEventBus | null): void;
    private deriveEffectiveTools;
    spawn(input: AgentInput): AgentRecord;
    getStatus(id: string): AgentRecord | null;
    cancel(id: string): boolean;
    listByGraph(graphId: string): AgentRecord[];
    cancelSubtree(rootAgentId: string): string[];
    cancelGraph(graphId: string): string[];
    list(): AgentRecord[];
    listByCohort(cohort: string): AgentRecord[];
    clear(): void;
    exportState(): AgentRecord[];
    importState(records: AgentRecord[]): void;
    setExecutor(executor: AgentExecutor | null): void;
    setWrfcController(wrfcController: Pick<WrfcController, 'createChain'> | null): void;
}
//# sourceMappingURL=manager.d.ts.map