Skip to content

Publish T2T-CHM13v2.0's names, contig aliases and mitochondria (0.51.0) - #205

Merged
iskandr merged 1 commit into
mainfrom
t2t-reference-names
Nov 9, 2026
Merged

iskandr merged 1 commit into
mainfrom
t2t-reference-names

Conversation

@iskandr

@iskandr iskandr commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

Closes #204. Bumps to 0.51.0.

varcode will infer T2T-CHM13v2.0 from file names and VCF headers (openvax/varcode#723). For that it needs one list of names, contig aliases and mitochondria that both packages share. Until now ORFdata had only a private, hint-only alias dict, and load_genome accepted only "t2t-chm13".

Change

The table lives beside the pin in orfdata/data/genomes.json, so a second pinned assembly is a registry entry rather than new code.

  • orfdata.reference_names() (orfdata genomes names) returns a DataFrame with columns name, genome, mitochondrion and note:
Name Genome Mitochondrion
t2t-chm13, T2T-CHM13v2.0, GCA_009914755.4, hs1, chm13v2.0, chm13v2.0_maskedY, chm13v2.0_noY t2t-chm13 CP068254.1 (CHM13's own)
chm13v2.0_maskedY_rCRS, chm13v2.0_maskedY.rCRS t2t-chm13 NC_012920.1 (the rCRS)
GCF_009914755.1 t2t-chm13 none (RefSeq gives MT no accession)
T2T-CHM13v1.1, GCA_009914755.3, chm13.draft_v1.1 t2t-chm13 CP068254.1
T2T-CHM13v1.0, GCA_009914755.2, chm13.draft_v1.0, chm13.draft_v0.9, T2T-CHM13v0.7, GCA_009914755.1, chm13.draft_v0.7 none, with the reason
  • orfdata.contig_aliases(name) (orfdata genomes contigs NAME) lists the 25 sequences from NCBI's assembly report. Each row has the annotation's name (1), the UCSC name (chr1), the GenBank and RefSeq accessions, and the length. It leaves out sequences that the named files lack, or carry as a different molecule:
    • no Y for _noY and v1.1;
    • no MT for the _rCRS set, whose chrM is the rCRS;
    • no MT for GCF_009914755.1.
  • load_genome, install_genome and orfdata genomes install accept any listed name, ignoring case. NotInstalledError names orfdata genomes install t2t-chm13 whichever name was given: "The t2t-chm13 annotation (for hs1) is not installed; …".
  • catalog._assembly_hint takes T2T names from the table, so bare chm13 (which names every version) no longer resolves. A v1.0 name explains why it doesn't resolve.

Finding names inside paths stays with the caller; the table holds exact names only.

Sources

Checked 2026-11-09:

  • NCBI's assembly reports for GCA_009914755.4, .3 and .2, plus NCBI Datasets for the assembly names (.1 is v0.7, .2 is v1.0, .3 is v1.1).
    • v1.1 has the same 1–22, X and MT accessions and lengths as v2.0, and no Y.
    • In v1.0, 23 of 24 lengths differ (chr1 is 248,387,497 bp vs 248,387,328). The marbl/CHM13 release notes say v1.1 filled the rDNA gaps and re-polished telomeres.
  • UCSC's hs1.chromAlias.txt, which agrees with NCBI's report on every row.
  • The marbl/CHM13 README: _noY is "identical to T2T-CHM13v1.1", and _maskedY_rCRS replaces the mitochondrion with NC_012920.1.

The two reports and the chromAlias file are in tests/data/t2t/, so the contig table and the v1.0 claim are tested offline against their sources. The report's SHA-256 is pinned beside the table.

Not changed

Tests

tests/test_genomes.py covers:

  • every name in the table resolves to its genome and mitochondrion, ignoring case;
  • older versions raise their reason from _pinned, contig_aliases and load_genome, and bare chm13 doesn't resolve;
  • the contig table matches NCBI's report and UCSC's aliases;
  • each name lists only its own contigs;
  • the not-installed message for an alias;
  • an installed slice genome opens under its aliases;
  • the catalogue hints;
  • the new CLI commands.

tests/test_cli_audit.py runs genomes names and genomes contigs with human and JSON output.

Verification

  • ./lint.sh: passes.
  • pytest tests -n 8: 1527 passed, 6 skipped.
  • mkdocs build --strict: passes.

https://claude.ai/code/session_01JHJhwfx4um52Nczrv3G814

reference_names() lists every name the pinned genomes answer to, the genome
each opens and its file's mitochondrion: hs1, GCA/GCF accessions, the T2T
analysis sets (the _rCRS set's chrM is NC_012920.1, not CHM13's own
CP068254.1) and T2T-CHM13v1.1. T2T-CHM13v1.0 and the v0.7/v0.9 drafts are
listed with no genome and say why. contig_aliases(name) gives the 25
sequences under their annotation, UCSC, GenBank and RefSeq names with
NCBI's lengths, leaving out what that name's files lack or carry as another
molecule. load_genome/install_genome accept any listed name; the catalogue
hint no longer reads bare chm13 as v2.0. New CLI: orfdata genomes names,
orfdata genomes contigs NAME.

Closes #204.

Claude-Session: https://claude.ai/code/session_01JHJhwfx4um52Nczrv3G814
@iskandr
iskandr merged commit 9cca4c2 into main Nov 9, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Publish the t2t-chm13 pin's reference names, contig aliases and mitochondrion, so varcode and ORFdata accept the same T2T names

1 participant