#!/usr/bin/env node /** * 故障排除案例元数据 */ interface TroubleshootingCase { id: string; framework: string; title: string; problemType: string; tags: string[]; severity: string; timeSaved: string; filePath: string; } /** * 查询结果 */ interface TroubleshootingQueryResult { cases: Array<{ id: string; title: string; framework: string; problemType: string; tags: string[]; matchScore: number; timeSaved: string; preview: string; }>; totalFound: number; queryInfo: { framework?: string; keywords: string[]; errorMessage?: string; }; } /** * 查询故障排除案例 */ declare function queryTroubleshootingCases(params: { framework?: string; keywords?: string[]; errorMessage?: string; codePattern?: string; limit?: number; }): Promise; /** * 获取案例完整内容 */ declare function getTroubleshootingCaseContent(params: { framework: string; caseId: string; }): Promise<{ content: string; metadata: TroubleshootingCase | null; }>; /** * 列出所有可用案例 */ declare function listTroubleshootingCases(framework?: string): Promise<{ cases: TroubleshootingCase[]; frameworks: string[]; }>; export { getTroubleshootingCaseContent, listTroubleshootingCases, queryTroubleshootingCases };