/**
 * Claude Code CLI Provider — wraps Anthropic's Claude Code CLI as a Jait provider.
 *
 * Spawns `claude --print --output-format stream-json --include-partial-messages --verbose`
 * and parses newline-delimited JSON events from stdout.
 *
 * Event types from Claude Code stream-json:
 *   { type: "system",       subtype: "init", model, tools, ... }
 *   { type: "stream_event", event: { type: "content_block_delta", delta: { type: "text_delta", text } } }
 *   { type: "stream_event", event: { type: "content_block_start", content_block: { type: "tool_use", ... } } }
 *   { type: "assistant",    message: { content: [...blocks...] } }   — partial/full message snapshots
 *   { type: "user",         message: { content: [{ type: "tool_result", ... }] } }
 *   { type: "result",       result: "...", usage: {...} }
 */
import type { CliProviderAdapter, ProviderInfo, ProviderModelInfo, ProviderSession, ProviderEvent, StartSessionOptions } from "./contracts.js";
export declare class ClaudeCodeProvider implements CliProviderAdapter {
    readonly id: "claude-code";
    readonly info: ProviderInfo;
    private sessions;
    private emitter;
    private claudePath;
    checkAvailability(): Promise<boolean>;
    /**
     * Dynamically discover available models by probing the Claude CLI.
     *
     * Spawns a short-lived `claude --print` for each candidate alias in parallel,
     * reads the `system` init event to get the resolved model name, and deduplicates
     * so that aliases pointing to the same underlying model only appear once.
     */
    listModels(): Promise<ProviderModelInfo[]>;
    startSession(options: StartSessionOptions): Promise<ProviderSession>;
    sendTurn(sessionId: string, message: string, _attachments?: string[]): Promise<void>;
    interruptTurn(sessionId: string): Promise<void>;
    respondToApproval(_sessionId: string, _requestId: string, _approved: boolean): Promise<void>;
    stopSession(sessionId: string): Promise<void>;
    onEvent(handler: (event: ProviderEvent) => void): () => void;
    private emit;
    private getState;
    private processBuffer;
    private handleEvent;
    /**
     * Handle unwrapped Anthropic API streaming events from inside stream_event wrappers.
     * These follow the Anthropic Messages API streaming format.
     */
    private handleStreamEvent;
    /**
     * Register a tool_use content block as a pending tool call and emit tool.start.
     * Only called from `assistant` message snapshots where input is complete.
     */
    private handleToolUseBlock;
    private buildClaudeMcpConfig;
    private hasClaudeConfig;
    /**
     * Probe a single model alias by spawning `claude --print` with a trivial prompt
     * and reading the system init event. Returns the alias and resolved model name,
     * or null if the alias is invalid.
     */
    private probeModel;
    /**
     * Parse `claude --help` to discover model alias names mentioned in the --model description.
     */
    private parseAliasesFromHelp;
    private testCommand;
}
//# sourceMappingURL=claude-code-provider.d.ts.map