--- license: cc0-1.0 pretty_name: Internet Archive census (April 2016) — per-file md5+sha1 tags: - file-hashes configs: - config_name: data data_files: data/census-*.parquet - config_name: maps data_files: maps/md5.parquet --- # Internet Archive census (April 2016) — per-file md5+sha1 The April 2016 [Internet Archive census](https://archive.org/details/ia_census_201604) recorded md5 and sha1 for **every file of every public IA item** — the only bulk file-hash inventory of the Archive ever published (the census was not repeated; nothing uploaded after 2016-04-11 appears here). This dataset is those two dumps joined — they are line-aligned outputs of one item walk — into single witness rows co-observing both digests, republished as page-indexed parquet for point lookups over HTTP range reads. Every row's claim URL exists by construction: `https://archive.org/download//` (filenames are stored percent-encoded, exactly as the census dumps spell them — use them verbatim in URLs). Items can go dark after the fact, so a claim is "this item *held* these bytes in April 2016", and some URLs now 403. Both digests are weak (md5, sha1): rows are corroboration and crosswalk evidence, never byte-identity proof. Downstream tools should render matches as "consistent with", not "is". [hashdex](https://github.com/davidar/hashdex) does exactly that — its scan reports census matches in a separate "consistent (sha1)" tier. **150,129,712 rows** across ~14.9M items; **129,730,596 distinct sha1s** (equal to the md5→sha1 pair count: no sha1 in the corpus is claimed by two md5s). Items' own `_meta.xml`/`_files.xml`/`.torrent` sidecars (39.1M) are dropped as per-item plumbing; 496 rows with malformed hash fields skipped. ## Layout - `data/census-{0..f}.parquet` — sha1, md5, identifier, filename; **sorted by sha1**, sharded by its first nibble (~580 MB each). - `maps/md5.parquet` — md5 → sha1, **sorted by md5** (5.4 GB). - `ia-census.sha1.bloom` — DCSO membership filter over the distinct sha1s (p = 10⁻⁴, 311 MiB, UPPERCASE-hex keys); `hdx filters fetch ia-census` installs it so scans can route matching files here. All parquet carries page indexes (zstd, no dictionaries, 128 KiB pages): a point lookup over HTTP range reads fetches a few tens of KB. ## Rebuild `ia_census_parquet.py` in this repo streams the two census dumps (11.3 GB, from the IA item above), zip-joins them with per-line alignment checks, sorts one output file per sha1 nibble (DuckDB, memory-bounded), and transcodes with page indexes in per-file subprocesses (verified: sortedness, offset indexes, counts). The bloom is built by hdx from the distinct sha1 column: ``` hdx filters build ia-census sha1 sha1_keys.txt ``` The source census is frozen — a rebuild is deterministic. Census data by the Internet Archive and the 2016 census effort, generously public; this compilation CC0.