import { V as VoiceTransport, a as VoiceSessionMetadata, b as VoiceToolResult, A as AudioInputChunk, c as VoiceSessionConfig, d as VoiceSession, e as VoiceTool, f as VoiceToolCall, g as VoiceToolContext, R as RealtimeFunctionToolDefinition, h as VoiceProvider, i as VoiceEvent, j as VoiceProviderConnectOptions, k as AudioOutputChunk, J as JsonObject } from './types-Dc4Q3Z6X.cjs'; export { T as ToolConfirmationDecision, l as ToolConfirmationPolicy, m as ToolConfirmationRequest, n as ToolConfirmationResolver, o as VoiceAuthConfig, p as VoiceBridgeCommand, q as VoiceBridgeEvent, r as VoiceConnectionState, s as VoiceEventHandler, t as VoiceToolExecutionError, u as VoiceToolExecutionResult, v as VoiceTransportConnectOptions, w as VoiceTransportEvent, x as VoiceTransportEventHandler, y as VoiceTransportSendEvent } from './types-Dc4Q3Z6X.cjs'; import { AgentTool } from '@kenkaiiii/gg-agent'; import { Tool } from '@kenkaiiii/gg-ai'; import { z } from 'zod'; interface VoiceSessionControllerOptions { readonly id: string; readonly provider: string; readonly transport?: VoiceTransport; readonly metadata?: VoiceSessionMetadata; readonly onSendToolResult?: (result: VoiceToolResult, signal?: AbortSignal) => Promise; readonly onSendAudio?: (chunk: AudioInputChunk, signal?: AbortSignal) => Promise; readonly onSendText?: (text: string, signal?: AbortSignal) => Promise; readonly onUpdateConfig?: (config: Partial, signal?: AbortSignal) => Promise; readonly onClose?: (reason?: string) => Promise; } declare function createVoiceSession(options: VoiceSessionControllerOptions): VoiceSession; declare function normalizeVoiceProviderError(error: unknown): Error; type VoiceToolSource = VoiceTool | AgentTool | Tool; interface ExecuteVoiceToolCallOptions { readonly tools: readonly VoiceTool[]; readonly call: VoiceToolCall; readonly signal?: AbortSignal; readonly confirmation?: VoiceToolContext["confirmation"]; readonly onUpdate?: VoiceToolContext["onUpdate"]; } declare function ggAiToolToRealtimeFunctionTool(tool: Tool): RealtimeFunctionToolDefinition; declare function voiceToolToRealtimeFunctionTool(tool: VoiceTool): RealtimeFunctionToolDefinition; declare function ggAiToolToVoiceTool(tool: Tool): VoiceTool; declare function agentToolToVoiceTool(tool: AgentTool): VoiceTool; declare function executeVoiceToolCall(options: ExecuteVoiceToolCallOptions): Promise; interface InMemoryVoiceProviderOptions { readonly now?: () => Date; readonly idFactory?: () => string; } interface InMemoryVoiceProvider extends Omit { readonly sessions: readonly InMemoryVoiceSession[]; connect(options: VoiceProviderConnectOptions): Promise; } interface InMemoryVoiceSession extends VoiceSession { emit(event: VoiceEvent): void; readonly sentAudio: readonly AudioInputChunk[]; readonly sentText: readonly string[]; readonly sentToolResults: readonly VoiceToolResult[]; triggerToolCall(call: VoiceToolCall): void; } declare function createInMemoryVoiceProvider(options?: InMemoryVoiceProviderOptions): InMemoryVoiceProvider; interface PlatformSecureTokenStore { getToken(key: string, signal?: AbortSignal): Promise; setToken(key: string, value: string, signal?: AbortSignal): Promise; deleteToken(key: string, signal?: AbortSignal): Promise; } interface OpenUrlRequest { readonly url: string; readonly fallbackUrl?: string; } interface PlatformUrlOpener { canOpenUrl(url: string, signal?: AbortSignal): Promise; openUrl(request: OpenUrlRequest, signal?: AbortSignal): Promise; } interface PlatformNotification { readonly title: string; readonly body?: string; readonly data?: JsonObject; } interface PlatformAudioAdapter { startCapture(signal?: AbortSignal): Promise>; play(chunk: AudioOutputChunk, signal?: AbortSignal): Promise; stop(reason?: string): Promise; } interface RelayRequest { readonly path: string; readonly method: "GET" | "POST" | "PATCH" | "DELETE"; readonly headers?: Readonly>; readonly body?: unknown; } interface RelayResponse { readonly status: number; readonly headers: Readonly>; readonly body: unknown; } interface RelayHttpClient { send(request: RelayRequest, signal?: AbortSignal): Promise; } export { AudioInputChunk, AudioOutputChunk, type ExecuteVoiceToolCallOptions, type InMemoryVoiceProvider, type InMemoryVoiceProviderOptions, type InMemoryVoiceSession, JsonObject, type OpenUrlRequest, type PlatformAudioAdapter, type PlatformNotification, type PlatformSecureTokenStore, type PlatformUrlOpener, RealtimeFunctionToolDefinition, type RelayHttpClient, type RelayRequest, type RelayResponse, VoiceEvent, VoiceProvider, VoiceProviderConnectOptions, VoiceSession, VoiceSessionConfig, type VoiceSessionControllerOptions, VoiceSessionMetadata, VoiceTool, VoiceToolCall, VoiceToolContext, VoiceToolResult, type VoiceToolSource, VoiceTransport, agentToolToVoiceTool, createInMemoryVoiceProvider, createVoiceSession, executeVoiceToolCall, ggAiToolToRealtimeFunctionTool, ggAiToolToVoiceTool, normalizeVoiceProviderError, voiceToolToRealtimeFunctionTool };