/** * Web Chat Server — 类 LobeChat 的现代 AI 对话界面 * * 提供完整的 Web Chat 体验: * - 实时对话(SSE 流式输出) * - 对话历史管理 * - Agent 状态面板 * - Skills / Memory / 任务监控 * - 深色/浅色主题 * - 移动端响应式 * * 零依赖:仅 Node.js 内置 http 模块 */ import type { AgentCore } from "../agent.js"; import type { VectorMemory } from "../memory/vector-store.js"; import type { AutonomousPlanner } from "../autonomous/planner.js"; import type { KnowledgeBase } from "../knowledge/base.js"; import type { NotificationCenter } from "../notification/center.js"; import type { ConversationManager } from "../conversation/manager.js"; import type { LLMClient } from "../providers/llm.js"; export interface WebChatConfig { port: number; host?: string; title?: string; } export declare class WebChatServer { private agent; private vectorMemory?; private planner?; private knowledgeBase?; private notifications?; private convManager?; private llmClient?; private config; private server?; /** SSE 连接池 */ private sseClients; /** 对话历史(内存版,优先使用 ConversationManager) */ private conversations; constructor(agent: AgentCore, config?: Partial, deps?: { vectorMemory?: VectorMemory; planner?: AutonomousPlanner; knowledgeBase?: KnowledgeBase; notifications?: NotificationCenter; convManager?: ConversationManager; llmClient?: LLMClient; }); start(): Promise; stop(): void; private handleRequest; private apiChat; private apiChatStream; private apiHistory; private apiStatus; private apiSkills; private apiMemory; private apiMemorySearch; private apiAutonomousExecute; private apiAutonomousTraces; private apiSSE; private broadcast; private serveHTML; private generateChatHTML; private apiKnowledgeQuery; private apiKnowledgeStatus; private apiNotifications; private apiNotificationsClear; private apiConversations; private apiConversationsExport; private addMessage; private splitIntoChunks; private readBody; private json; } //# sourceMappingURL=chat-server.d.ts.map