import type { LLMProvider } from './types.js';
export interface RunLlmTextOpts {
    prompt: string;
    maxTokens?: number;
    modelOverride?: string;
    timeoutMs?: number;
    signal?: AbortSignal;
}
export interface RunLlmTextResult {
    text: string;
    provider: LLMProvider | 'custom';
    model: string;
    latencyMs: number;
}
export interface RunLlmJsonOpts extends RunLlmTextOpts {
    jsonSchema?: Record<string, unknown>;
}
export interface RunLlmJsonResult {
    values: Record<string, unknown>;
    provider: LLMProvider | 'custom';
    model: string;
    latencyMs: number;
}
export declare function isLlmConfigured(env?: Record<string, string | undefined>): boolean;
/**
 * Async variant of isLlmConfigured that also checks the keystore.
 * Use this when you have access to the data dir.
 */
export declare function isLlmConfiguredWithKeyStore(env?: Record<string, string | undefined>): Promise<boolean>;
export declare function runLlmText(opts: RunLlmTextOpts): Promise<RunLlmTextResult>;
export declare function runLlmJson(opts: RunLlmJsonOpts): Promise<RunLlmJsonResult>;
/**
 * Resolve the API key for the currently configured provider through the
 * full keystore chain (keychain → file → env). Returns undefined when no
 * provider is configured.
 *
 * Used by llm-fallback.ts which needs the key + provider separately.
 */
export declare function resolveActiveProviderKey(): Promise<{
    provider: LLMProvider;
    key: string;
} | null>;
export { resolveProviderKey } from '../../../security/key-store.js';
//# sourceMappingURL=run.d.ts.map