import type { Agent } from "../agent/agent.js";
import type { ToolInvoker } from "../agent/types.js";
import type { HookRegistry } from "../contracts/hooks.js";
import type { NotificationMethod, NotificationMethodMap } from "../protocol/notifications.js";
import type { AcpPermissionRequestParams } from "../protocol/wire/index.js";
import type { MemoryPrefetchState } from "../runtime/hooks/memory-hooks.js";
import type { BackgroundTaskManager } from "../runtime/infra/background-tasks.js";
import type { TaskStore } from "../runtime/infra/task-runtime.js";
import type { MemoryDreamRuntimeProvider, MemoryHandlerProvider, PermissionMetadataResolver, PermissionRuleEnginePort, PathService, ProjectMemoryStore, ToolCatalog } from "../runtime/ports/index.js";
import type { McpManager } from "../skills/mcp/mcp-manager.js";
import type { PluginLoader } from "../skills/plugins/plugin-loader.js";
import type { CliCoreToolHostDeps } from "./core-tool-coordinator.js";
import { type CliAgentClient } from "./cli-agent-builder.js";
import type { ResolvedTextGenerationConfig } from "./model-client-resolver.js";
import type { LLMTransport, ProviderRegistry } from "./provider-core-facade.js";
import type { MediaPersistence } from "../runtime/infra/media-persistence.js";
import type { FileWatcher } from "./agent-runtime-bootstrap.js";
export interface StdioAgentSessionBootstrapDeps {
    config: Record<string, unknown> & {
        maxRounds?: number;
    };
    resolvedTextConfig: ResolvedTextGenerationConfig;
    verbose: boolean;
    taskStore: TaskStore;
    backgroundTasks: BackgroundTaskManager;
    sessionId: string;
    getTurnId(): string;
    projectRoot: string;
    pathService: PathService;
    memdir: ProjectMemoryStore;
    currentUserId: string;
    memoryPrefetchState: MemoryPrefetchState;
    getLastUserMessage(): string | undefined;
    getLastAssistantMessage(): string | undefined;
    resolveSmallModelClient(): {
        transport: LLMTransport;
        apiKey: string;
        model: string;
    } | null;
    providerRegistry: ProviderRegistry;
    mediaPersistence: MediaPersistence;
    toolCatalog: ToolCatalog;
    runtimeSession: {
        mcpManager: McpManager | null;
        permissionUnregister: (() => void) | null;
        fileWatcher: FileWatcher | null;
        getPluginSkills(): ReturnType<PluginLoader["getPluginSkills"]>;
        applyBootstrap(result: {
            hooks: HookRegistry;
            memoryHandlerProvider: MemoryHandlerProvider | null;
            memoryDreamProvider: MemoryDreamRuntimeProvider | null;
            memoryUserId: string;
            permissionChecker: PermissionMetadataResolver;
            permissionUnregister: () => void;
            ruleEngine: PermissionRuleEnginePort;
        }): void;
    };
    setMcpManager(manager: McpManager | null): void;
    setMcpReady(ready: Promise<void>): void;
    setPluginLoader(loader: PluginLoader): void;
    setFileWatcher(watcher: FileWatcher | null): void;
    getAgent(): Agent | null;
    getAcpPermissionSession(): {
        sessionId: string;
        requestPermission(params: AcpPermissionRequestParams): Promise<{
            optionId?: string;
        }>;
    } | undefined;
    isPetActive(): boolean;
    coreToolHost: CliCoreToolHostDeps;
    log(message: string): void;
    sendNotification<M extends NotificationMethod>(method: M, params: NotificationMethodMap[M]): void;
}
export interface StdioAgentSessionBootstrapResult {
    agent: Agent;
    agentClient: CliAgentClient;
    toolInvoker: ToolInvoker;
    hooks: HookRegistry;
}
export declare function bootstrapStdioAgentSession(deps: StdioAgentSessionBootstrapDeps): StdioAgentSessionBootstrapResult;
