Skip to content

Data model - RetroBIOS

database.json

Primary key: SHA1. 8925 file entries.

Each entry:

{
  "path": "bios/Nintendo/GameCube/GC/USA/IPL.bin",
  "name": "IPL.bin",
  "size": 2097152,
  "sha1": "...",
  "md5": "...",
  "sha256": "...",
  "crc32": "...",
  "adler32": "...",
  "provenance": {
    "redump": {"dat": "...", "name": "...", "description": "..."}
  }
}

provenance maps each catalog that lists the file to the DAT and entry it was matched against. It is present only when the file matches a snapshot under provenance/; the join runs by SHA1 first, then by MD5 + size. See dump provenance.

Indexes

Index Entries Purpose
by_md5 8925 MD5 to SHA1 lookup (Batocera, Recalbox verification)
by_name 9175 filename to SHA1 list (name-based resolution)
by_crc32 8925 CRC32 to SHA1 lookup
by_path_suffix 5946 relative path to SHA1 (regional variant disambiguation)
by_sha256 8925 SHA256 to SHA1 lookup (emulator profile validation)

File resolution order

resolve_local_file tries these steps in order:

  1. SHA1 exact match; every other declared hash must agree with the record
  2. SHA256 exact match, with the same all-declarations-must-agree rule
  3. CRC32 plus declared size, only when no stronger hash is present
  4. MD5 direct lookup (including explicitly supported truncated MD5 values)
  5. Path suffix lookup for regional variants; with hashes it is accepted only if those hashes match
  6. Name and alias lookup only when no content hash was declared
  7. Candidate inspection for composite ZIP MD5 or direct MD5; a named candidate with the wrong content returns hash_mismatch
  8. zipped_file content match via the inner-ROM MD5 index
  9. MAME clone fallback, only for declarations without a content hash
  10. Data-directory scan; declared hashes are computed over the candidate before it is accepted
  11. Agnostic size/path fallback, only for declarations without a content hash

A filename or destination can never override a declared hash. The first evidence-compatible match wins; otherwise the resolver reports a mismatch or absence. Steps and their return codes are described in verification modes.

Platform YAML

Scraped from upstream sources. Structure:

platform: Batocera
verification_mode: md5        # how the platform checks files
hash_type: md5                # hash type in file entries
base_destination: bios        # root directory for BIOS files
systems:
  system-id:
    files:
      - name: filename
        destination: path/in/bios/dir
        md5: expected_hash
        sha1: expected_hash
        required: true

Supports inheritance (inherits: retroarch) and shared groups (includes: [group_name] referencing _shared.yml).

base_destination is the prefix the pack applies to every entry. It is empty when the upstream destinations already carry their own root, which is why the RetroDECK pack ships bios/ and roms/ at its top level.

Emulator YAML

459 profile files, 436 distinct emulators once aliases are folded in. Source-verified from emulator code.

See the profiling guide for the full field reference.

Static API and bulk exports

The website publishes versioned JSON, CSV and SQLite metadata generated from these same structures. Start with the Data & API catalog; each downloadable artifact carries a SHA256 in api/v1/catalog.json.