fasta_lake.proteomics.cascade#
fasta_lake.proteomics.cascade
#
Layered tier builder for proteomics mode (Point 2) — canonical-anchored by construction.
Builds 'canonical + smart-isoforms + Ig + variants', healed to real gene symbols. Guarantees: * FULL canonical SwissProt backbone is always present (fixes the lost-backbone bug). * Isoform layer = only TrEMBL entries that (a) roll up to a real gene AND (b) add >=1 tryptic peptide NOT already in the canonical proteome (genuine new sequence). This trims the low-confidence redundant-TrEMBL bulk that drives FDR-boundary clogging. * Ig repertoire kept as its own class (not force-mapped, not counted as fake genes). * Personal WGS variants (ens|) kept as the specificity class. All entries emitted with a corrected GN= (real symbol where determinable), so gene counts and protein grouping are honest. Deterministic; dedup by sequence.
build_smart_tier
#
build_smart_tier(canonical_fasta, candidate_fasta, output_fasta, mapping_tsv=None, min_len=7, max_missed=1) -> dict
canonical backbone + smart isoforms + Ig + variants, gene-healed.
candidate_fasta = the de-novo-evidence-supported pool (TrEMBL isoforms, ens| variants, Ig entries) to layer on top of the full canonical backbone.