/** * Cursor LLM 客户端 - 零成本架构的核心实现 * 通过 MCP 协议向 Cursor IDE 请求 LLM 补全,实现智能对话 */ import type { LLMRequest, LLMResponse, ConversationTurn, AccumulatedContext } from './types.js'; export declare class CursorLLMClient { private mcpServer; constructor(mcpServer: any); /** * 核心方法:向 Cursor 请求 LLM 补全 * 这是零成本架构的关键 - 使用用户在 Cursor 中已配置的模型 */ requestCompletion(request: LLMRequest): Promise; /** * 意图分类 - 使用专门的分类提示词 */ classifyIntent(userInput: string): Promise<{ project_type: string; confidence: number; reasoning: string; }>; /** * 构建对话响应 - 使用专家角色卡和上下文 */ generateConversationResponse(userInput: string, expertPrompt: string, conversationHistory: ConversationTurn[], accumulatedContext: AccumulatedContext): Promise<{ response: string; type: 'question' | 'suggestion' | 'completion'; confidence: number; }>; /** * 分析对话准备度 - 判断是否可以生成 PRD */ analyzeReadiness(conversationHistory: ConversationTurn[], accumulatedContext: AccumulatedContext): Promise<{ ready: boolean; confidence: number; missing_info: string[]; next_questions: string[]; }>; private buildIntentClassificationPrompt; private buildConversationPrompt; private buildReadinessAnalysisPrompt; private parseIntentResponse; private parseConversationResponse; private parseReadinessResponse; private estimateConfidence; /** * 使用 OpenAI 官方 REST 接口的兜底实现 */ private requestViaOpenAI; } //# sourceMappingURL=llm-client.d.ts.map