/**
 * Custom streamSimple for the local Shortcut provider.
 *
 * Thin composition: converts context → request body, fetches the local
 * `/api/llm/stream` SSE proxy, maps SSE events → owned AI AssistantMessageEvents.
 *
 * This is the desktop/local provider path. Hosted `--cloud` mode does not use
 * this stream; cloud mode runs model calls inside the hosted WebSocket runtime.
 *
 * Message conversion lives in message-converter.ts.
 * SSE protocol types live in sse-protocol.ts.
 */
import { type Api, type AssistantMessageEventStream, type Context, type Model, type SimpleStreamOptions } from '../../ai/types.js';
import type { ShortcutAuthRecovery } from './shortcut-auth-recovery.js';
import { type SSEContentBlock } from './sse-protocol.js';
/**
 * Callback invoked when the proxy emits a `content_block` SSE event
 * (e.g., a text block carrying Anthropic citation arrays).
 */
export type ContentBlockHandler = (block: SSEContentBlock) => void;
/**
 * Create a streaming function for the local Shortcut LLM proxy.
 * Returns a owned AI StreamFn that connects to `/api/llm/stream` (SSE) and
 * translates SSE events into owned AI AssistantMessageEvents in real time.
 *
 * Do not use this in hosted cloud mode. The hosted runtime should call direct
 * cloud model providers and stream over the WebSocket session protocol instead.
 *
 * @param onContentBlock — optional callback for `content_block` events (e.g., citation data)
 */
export declare function createShortcutStream(baseUrl: string, getExtraHeaders?: () => Record<string, string> | undefined, onContentBlock?: ContentBlockHandler, recoverAuth?: ShortcutAuthRecovery): (model: Model<Api>, context: Context, options?: SimpleStreamOptions) => AssistantMessageEventStream;
//# sourceMappingURL=shortcut-stream.d.ts.map