Fact hash producers.
A FactHash is a blake3:-prefixed hex64 blake3 digest. The prefix makes
the hash self-identifying — any text scanner can find it without prior
knowledge of the source.
The vocabulary — FactHashSchema, FACT_HASH_PREFIX, FACT_HASH_PATTERN,
is_fact_hash — lives in hash_schemas.ts, which imports no WASM. This
module holds the functions that actually hash, so importing it costs the
@fuzdev/blake3_wasm binary. Client code validating a hash it received
should import from hash_schemas.ts instead.
Runtime validation happens at construction (fact_hash_bytes /
fact_hash_stream cast at the source; FactHashSchema.parse /
is_fact_hash validate inputs from external boundaries).
The hash-producing helpers carry the fact_hash_ prefix so they namespace
cleanly alongside the branded FactHash type and the FACT_HASH_*
constants, and stay distinct from the raw-hex hash_blake3 / hash_sha256
family in hash.ts (those return bare digests; these return the branded,
blake3:-prefixed wire form).