/** * verify-engine — 代码验证引擎 * * 执行后自动验证:编译检查 + Lint + 单元测试 * 根据项目类型(Node.js/Java/Go/Python)自动检测命令 * 生成结构化报告到 VERIFY_REPORT.md(任务根目录) */ export type ProjectType = 'node' | 'java' | 'go' | 'python' | 'unknown'; export interface CheckResult { name: string; status: 'pass' | 'fail' | 'skip' | 'warn'; duration: number; output: string; details: string; blocking: boolean; } export interface VerifyReport { taskId: string; timestamp: string; projectType: ProjectType; codePath: string; checks: CheckResult[]; summary: { total: number; passed: number; failed: number; skipped: number; warnings: number; }; } export declare function detectProjectType(codePath: string): Promise; export declare function generateReportMarkdown(report: VerifyReport): string; export declare function runVerification(taskId: string, codePath: string, options?: { type?: 'compile' | 'lint' | 'test' | 'all'; timeout?: number; }): Promise; /** * 将验证报告写入文件 */ export declare function writeVerifyReport(report: VerifyReport, outputDir: string): Promise; /** * 生成 AI 修复 Prompt * 当验证失败时,生成结构化 Prompt 让 AI 定位并修复问题 */ export declare function generateFixPrompt(report: VerifyReport, taskDir: string): string; /** * 生成 SPECCORE_EXEC 标签,触发 AI 修复 */ export declare function outputFixTag(report: VerifyReport, taskDir: string, round: number): void; export interface AgentQualityCheck { agent: string; prompt: string; } export interface QualityGateResult { passed: boolean; blockingFailed: CheckResult[]; warnings: CheckResult[]; report: VerifyReport; agentChecks?: AgentQualityCheck[]; } /** * 质量门禁 — execute 后自动运行,不可跳过 * 阻塞性检查(编译/Lint/测试/依赖)失败 → 不允许进入下一步 * 非阻塞检查(安全/Spec一致性)失败 → 警告但不阻塞 */ export declare function runQualityGate(taskId: string, codePath: string, taskDir: string, options?: { timeout?: number; withAgents?: boolean; projectRoot?: string; }): Promise; /** * 根据单元测试结果同步更新 TEST.md 勾选状态 * - 测试全部通过 → 所有 `[ ]` 改为 `[x]` * - 测试有失败 → 保持 `[ ]` 不变(等待修复后重试) * - 无 TEST.md → 跳过 */ export declare function syncTestDocFromResults(taskDir: string, testPassed: boolean): Promise; //# sourceMappingURL=verify-engine.d.ts.map