https://tigerbeetle.com/blog/2025-02-27-why-we-designed-tigerbeetles-docs-from-scratch/ has an interesting distinction between "physical" and "logical" hash of a tarball. By storing the hash of the decompressed tarball contents (i.e. the logical hash), they can verify the validity of files without needing to keep the tarball around.