import type { LLMConnector, LLMResult, LLMConfig } from '../types.js'; export interface CLIConnectorConfig { /** CLI 命令名 */ command: string; /** 显示名称(用于错误消息) */ displayName: string; /** 安装提示(ENOENT 时显示) */ installHint?: string; /** 构建命令行参数 */ buildArgs: (fullPrompt: string, config: LLMConfig) => string[]; /** 构建 stdin 模式的参数(prompt 过长时使用,默认用 buildArgs 替换 prompt 为 '-') */ buildStdinArgs?: (config: LLMConfig) => string[]; /** 从 stdout 提取内容(默认 trim) */ parseOutput?: (stdout: string) => string; } export declare class CLIBaseConnector implements LLMConnector { private cfg; constructor(cfg: CLIConnectorConfig); chat(systemPrompt: string, userMessage: string, config: LLMConfig): Promise; }