import type { PublicRealtimeAccess } from "../realtime-auth.ts"; import { RealtimeDelegationHandoff, type RealtimeHandoffChannel, type RealtimeHandoffTarget } from "./handoff.ts"; import type { CodexRealtimePeer } from "./peer.ts"; import { RealtimePlayback } from "./playback.ts"; import type { CodexConversationCallbacks } from "./session.ts"; export declare const SEND_TASK_TOOL: { type: string; name: string; description: string; parameters: { type: string; properties: { request: { type: string; description: string; }; }; required: string[]; additionalProperties: boolean; }; }; export declare const PUBLIC_REALTIME_INSTRUCTIONS = "This call has tools. Use send_task to delegate work without narrating the routing. Other listed tools run directly. Tool availability here supersedes earlier statements that voice has no tools. While work is underway, send only new instructions, not the same task again. Wait for findings rather than guessing. Updates are background context; speak useful progress and results without treating them as new user requests."; /** Public Realtime wire, independent from Codex delegation/transcript semantics. */ export declare class PublicRealtimeTurns { readonly handoff: RealtimeDelegationHandoff; readonly playback: RealtimePlayback; speakableResponsePending: boolean; private readonly tracker; private readonly abort; private access; private readonly calls; private readonly retired; private activeResponse; private awaitingResponse; private speech; private pendingTools; private ending; private completingResponse; private continuation; private quietUntil; private timer; private readonly callbacks; private readonly peer; private readonly isActive; private readonly onFailure; constructor(callbacks: CodexConversationCallbacks, peer: CodexRealtimePeer, isActive: () => boolean, onFailure: (error: Error) => void); cancelEndCall(): void; configure(access: PublicRealtimeAccess): void; get hasPendingInput(): boolean; audioActivity(): void; receive(value: unknown): void; sendContext(_target: RealtimeHandoffTarget, channel: RealtimeHandoffChannel, content: string): void; private execute; private send; private schedule; drainConversation(): void; }