/**
 * Shared helper for routing fact bytes between embedded (PG `bytes`
 * column) and external (filesystem + `put_ref`) storage tiers based
 * on size.
 *
 * External writes go through atomic temp+rename so the `facts` row
 * never references a partial file; idempotence comes from POSIX
 * `rename` overwrite + `INSERT ... ON CONFLICT DO NOTHING` in the
 * fact-store queries layer.
 *
 * @module
 */
import { type FactHash } from '@fuzdev/fuz_util/fact_hash.js';
import type { FactStore } from '@fuzdev/fuz_util/fact_store.js';
export interface WriteFactOptions {
    content_type: string;
}
/**
 * Write `bytes` as a fact, choosing embedded (PG) vs external (disk +
 * `put_ref`) based on `embedded_threshold`. Returns the canonical
 * `blake3:` hash either way.
 *
 * @param fact_store - the `FactStore` (typically `PgFactStore`)
 * @param embedded_threshold - bytes ≤ threshold → embedded; > threshold → disk
 * @param facts_dir - root of the sharded facts directory tree on disk
 * @param bytes - the raw fact bytes
 * @param options - content type for the fact metadata
 * @returns the fact's `blake3:<hex64>` hash
 * @mutates `fact_store`, `facts_dir` filesystem
 */
export declare const write_fact: (fact_store: FactStore, embedded_threshold: number, facts_dir: string, bytes: Uint8Array, options: WriteFactOptions) => Promise<FactHash>;
//# sourceMappingURL=fact_write.d.ts.map