/** Stores streamed tool-call argument JSON for live renderers and parser recovery. */ export declare const kStreamingPartialJson: unique symbol; /** Carries streamed tool-call argument JSON without exposing a string-keyed property. */ export type StreamingPartialJsonCarrier = object & { [kStreamingPartialJson]?: string; }; /** Reads streamed tool-call argument JSON from a block or event snapshot. */ export declare function getStreamingPartialJson(block: StreamingPartialJsonCarrier | null | undefined): string | undefined; /** Writes streamed tool-call argument JSON to a block or clears it with `undefined`. */ export declare function setStreamingPartialJson(block: StreamingPartialJsonCarrier, value: string | undefined): void; /** Clears streamed tool-call argument JSON without deleting or changing object shape. */ export declare function clearStreamingPartialJson(block: StreamingPartialJsonCarrier): void; /** Stores a provider-local stream block index without exposing a string-keyed property. */ export declare const kStreamingBlockIndex: unique symbol; /** Stores the last parsed argument prefix length for throttled streaming JSON parsing. */ export declare const kStreamingLastParseLen: unique symbol; /** * The Cursor interaction envelope's `call_id` for a streamed tool-call block. * * Tracked separately from the block's own `id` because they are NOT the same * key: MCP and Pi blocks are filed under the id inside the call's `args`, which * is what the exec channel pairs its result under, while every streamed * `ToolCall*Update` correlates on the envelope's `call_id`. Matching * completions against the block id would mis-route every call whose args carry * their own id. */ export declare const kStreamingEnvelopeId: unique symbol; /** Marks streamed tool-call arguments that already received an authoritative done payload. */ export declare const kStreamingArgumentsDone: unique symbol; /** Classifies Cursor's in-flight tool-call kind without leaking provider-private state. */ export declare const kStreamingBlockKind: unique symbol; /** * Marks a `toolCall` content block that Cursor's exec channel already * executed server-side (via the coding-agent bridge) and whose result is * buffered separately for emission via the assistant-loop stream. * * `agent-loop.ts` MUST skip execution of blocks carrying this marker — * treating them as a fresh runnable tool call would run the same * side-effecting tool (bash, write, delete, …) a second time. Symbol-keyed * so it never persists across the JSONL round-trip, where rebuild instead * pairs the block with its already-persisted `toolResult` message by id. */ export declare const kCursorExecResolved: unique symbol; /** Carries the resolved marker without exposing a string-keyed property. */ export type CursorExecResolvedCarrier = object & { [kCursorExecResolved]?: true; }; /** True when a toolCall block was already executed by Cursor's exec channel. */ export declare function isCursorExecResolved(block: CursorExecResolvedCarrier | null | undefined): boolean; /** * Copy {@link kCursorExecResolved} onto a cloned/projected toolCall block. * * Stream projectors (owned/in-band dialect, leaked-thinking heal) rebuild * toolCall objects field-by-field. Dropping this marker lets `agent-loop.ts` * re-execute a call Cursor already settled — duplicate toolResults and a * second bash/write/delete. Partial-JSON is already copied explicitly; this * marker is the other load-bearing symbol that must survive the same way. */ export declare function copyCursorExecResolved(target: CursorExecResolvedCarrier, source: CursorExecResolvedCarrier): void; /** * Marks a text block synthesized by cross-model thinking demotion in * `transformMessages`. Converters that flatten adjacent text blocks into one * string (openai-completions) insert a paragraph separator after marked * blocks; unmarked adjacent blocks keep their original byte sequence. * Symbol-keyed so the marker never persists across the JSONL round-trip and * never reaches the wire. */ export declare const kDemotedThinking: unique symbol; /** Carries the demoted-thinking marker without exposing a string-keyed property. */ export type DemotedThinkingCarrier = object & { [kDemotedThinking]?: boolean; }; /** True for text blocks synthesized by cross-model thinking demotion. */ export declare function isDemotedThinking(block: DemotedThinkingCarrier | null | undefined): boolean;