Download docs/ORTHOLOGY.md from Tinyants21/varianthound-data: direct link, hf CLI and curl.
- Browser
- Download file 4.09 kB
-
https://huggingface.co/datasets/Tinyants21/varianthound-data/resolve/main/docs/ORTHOLOGY.md
- Command line
-
hf download hf://datasets/Tinyants21/varianthound-data/docs/ORTHOLOGY.md
-
curl -L -o ORTHOLOGY.md https://huggingface.co/datasets/Tinyants21/varianthound-data/resolve/main/docs/ORTHOLOGY.md
Gene identity and orthology contract
VariantHound joins dog, human, and mouse evidence only through release-qualified stable identifiers. Gene symbols are useful labels, but they are mutable and are never accepted as the sole join key.
Fail-closed release states
data/manifests/orthology.json has two states:
unmaterialized: the policy is defined, but the Ensembl release, assemblies, timestamp, and checksum are deliberately null and the mapping arrays must be empty;pinned: all release metadata and species annotation assemblies are present, the source artifact has a SHA-256 checksum, and at least one validated mapping exists.
Ranking builds must refuse orthology evidence unless the manifest is pinned. This keeps a development placeholder or live API response from becoming scientific evidence by accident.
The repository keeps the lightweight checked-in manifest unmaterialized. The manual Hugging Face workflow uses the immutable descriptor in data/manifests/ensembl-compara-116.json to generate and validate the full pinned manifest at build time.
Identifier rules
- Resolve Ensembl gene IDs first and NCBI Gene IDs second.
- Preserve the species taxon on every identity.
- Retain canonical symbols and aliases for display and search only.
- Record retired, replaced, ambiguous, and unverified IDs instead of silently rewriting them.
- Put records that cannot be resolved deterministically into the
unresolvedreport and exclude them from scoring.
The normalized record shape is defined by schemas/gene-identity.schema.json.
Orthology rules
The browser-facing mapping is dog-centered. Each record is one dog-to-human or dog-to-mouse edge and preserves:
- the Ensembl homology identifier and source record identifier;
- one-to-one, one-to-many, or many-to-many homology type;
- Ensembl's high-confidence flag and normalized confidence when available;
- an explicit
resolvedorambiguousstatus; - warnings needed by downstream explanations.
Ambiguous edges are retained and flagged so the ranker can expose or down-weight them; they are never collapsed by choosing the first symbol match.
Assembly rules
Gene identities record the annotation assembly supplied by the pinned Ensembl release. Coordinate-bearing canine data has a separate target of UU_Cfam_GSD_1.0. Any liftover must retain original and target coordinates, chain-file identity, and mapping status. Orthology does not itself imply that coordinates were lifted successfully.
Materialization sequence
- Pin one Ensembl release and download a complete dog-human-mouse Compara export.
- Record the raw artifact checksum and the three annotation assemblies.
- Normalize stable identifiers and create an unresolved-ID report.
- Expand one-to-many and many-to-many relationships into explicit edges.
- Validate the complete manifest, then change
release_statustopinned. - Compare row counts, unresolved rates, and ID drift against the previous release before publication.
Ensembl 116 materialization
Ensembl's genome-specific homology dumps are not complete independently: each contains an arbitrary subset intended to reduce redundancy. VariantHound therefore verifies and unions the dog, human, and mouse protein_default files before filtering dog-human and dog-mouse edges.
python3 pipelines/ingest_ensembl_orthology.py
python3 pipelines/validate_data.py --orthology dist/ensembl/orthology.json
The release is accepted only when it produces exactly 41,504 unique edges with the pinned species and homology-type counts. The normalized data orients every edge dog-first, retains source homology IDs and metrics, and marks every non-one-to-one relationship ambiguous. Compara does not include canonical gene symbols in this bulk table, so symbols remain null rather than being guessed or used as join keys.
This contract is intentionally in place before bulk ingestion because symbol drift and assembly changes are data-layer concerns, not evaluation-time cleanup.