import type { ConversationManager } from './conversation.js'; import type { ConfigManager } from '../config/manager.js'; import type { ContentPart, LLMProvider } from '../providers/interface.js'; import type { ProviderRegistry } from '../providers/registry.js'; import type { AdaptivePlanner } from './adaptive-planner.js'; import type { ExecutionPlan } from './execution-plan.js'; import type { ExecutionPlanManager } from './execution-plan.js'; import type { RuntimeEventBus } from '../runtime/events/index.js'; import type { ToolCall, ToolResult } from '../types/tools.js'; import type { AgentManager } from '../tools/agent/index.js'; type EmitterContextFactory = (turnId: string) => import('../runtime/emitters/index.js').EmitterContext; export type ChatResponseWithReasoning = Awaited> & { reasoning?: string | undefined; reasoningSummary?: string | undefined; }; export declare function maybeEmitAdaptivePlannerDecision(text: string, flagEnabled: boolean, adaptivePlanner: Pick | null, runtimeBus: RuntimeEventBus | null, emitterContext: EmitterContextFactory, turnId: string): void; export declare function prepareConversationForTurn(conversation: ConversationManager, providerRegistry: Pick, text: string, content: ContentPart[] | undefined, sessionId?: string, planManager?: Pick | null): ExecutionPlan | null; export declare function handleToolResponseOutcome(args: { conversation: ConversationManager; agentManager: Pick; planManager: Pick | null; configManager: Pick; providerRegistry: Pick; runtimeBus: RuntimeEventBus | null; emitterContext: EmitterContextFactory; turnId: string; response: ChatResponseWithReasoning; userText: string; executeToolCalls: (turnId: string, calls: ToolCall[]) => Promise; setPendingToolCalls: (calls: ToolCall[]) => void; messageQueueLength: number; requestRender: () => void; sessionId?: string | undefined; /** This turn's MEMORY-sourced injected knowledge ids, stamped onto TURN_COMPLETED as metadata.memory.recordIds when non-empty (absent otherwise). */ memoryRecordIds?: readonly string[] | undefined; }): Promise<{ continueLoop: boolean; results: ToolResult[]; }>; export declare function handleFinalResponseOutcome(args: { conversation: ConversationManager; agentManager: Pick; planManager: Pick | null; configManager: Pick; providerRegistry: Pick; runtimeBus: RuntimeEventBus | null; emitterContext: EmitterContextFactory; turnId: string; response: ChatResponseWithReasoning; preTurnPlan: ExecutionPlan | null; requestRender: () => void; setAutoSpawnTimeout: (timeout: ReturnType | null) => void; autoSpawnTimeoutMs: number; sessionId?: string | undefined; /** This turn's MEMORY-sourced injected knowledge ids, stamped onto TURN_COMPLETED as metadata.memory.recordIds when non-empty (absent otherwise). */ memoryRecordIds?: readonly string[] | undefined; }): false; export declare function emitMalformedToolUseWarning(args: { conversation: ConversationManager; providerRegistry: Pick; runtimeBus: RuntimeEventBus | null; emitterContext: EmitterContextFactory; turnId: string; isReconciliationEnabled: boolean; }): void; export {}; //# sourceMappingURL=orchestrator-turn-helpers.d.ts.map