import type { SearchHit } from "../../core/retrieval/search.js"; /** * 安全渲染搜索结果:plain text,不含 path,显式 truncated。 */ export interface SafeToolHit { sessionId: string; entryId: string; role: string; occurredAt: string; snippet: string; truncated: boolean; } /** * 将 hit 转为 tool 安全 JSON(剥离 path/score/sourceKey 等内部字段)。 */ export declare function toSafeToolHits(hits: SearchHit[]): SafeToolHit[]; /** * TUI/print 纯文本渲染。 */ export declare function formatHitsPlain(hits: SearchHit[]): string; /** * 去掉 ANSI / 控制字符,避免历史文本污染终端。 */ export declare function sanitizeSnippet(text: string): string; /** * 断言对象不含 path 字段(测试用)。 */ export declare function assertNoPathLeak(value: unknown): void; //# sourceMappingURL=format.d.ts.map