export interface DebugWriter {
    /** Path to the debug output directory (timestamped subdirectory) */
    readonly outputDir: string | undefined;
    writeText(filename: string, content: string): Promise<void>;
    writeJson(filename: string, value: unknown): Promise<void>;
}
/** A single debug artifact collected in memory */
export interface DebugArtifact {
    filename: string;
    content: string;
    type: 'text' | 'json';
}
/** Collection of debug artifacts from a conversion run */
export interface DebugArtifacts {
    files: DebugArtifact[];
}
/** Extended DebugWriter that can retrieve collected artifacts */
export interface InMemoryDebugWriter extends DebugWriter {
    getArtifacts(): DebugArtifacts;
}
/**
 * Create a debug writer that collects artifacts in memory.
 * Useful for API endpoints where disk access is not available or desired.
 */
export declare function createInMemoryDebugWriter(): InMemoryDebugWriter;
/** Default max size for debug artifacts (5MB) */
export declare const DEFAULT_MAX_DEBUG_SIZE = 5000000;
/**
 * Cap total debug artifact size to prevent huge responses.
 * Files are processed in order; once the limit is reached,
 * remaining files are replaced with truncation notices.
 */
export declare function capDebugArtifacts(artifacts: DebugArtifacts, maxBytes?: number): DebugArtifacts;
/**
 * Create a debug writer that outputs to a timestamped subdirectory.
 *
 * Each invocation creates a unique directory like:
 * `{debugDir}/manifest-20260126-083345/`
 *
 * This avoids the dangerous pattern of clearing arbitrary directories.
 */
export declare function createDebugWriter(debugDir?: string): DebugWriter;
