Skip to content

UniPEFF: isoform entries lack ModResPsi, Processed and variant tags #10643

Done

Description

@timosachsenberg

Follow-up to #9830, which was resolved by #9966 (isoform expansion from splice-variant features). Reported by @dtabb73 in #9830 (comment).

Problem

When UniPEFF expands isoforms, only the canonical entry carries the annotation tags. For A0AVT1 (https://rest.uniprot.org/uniprotkb/A0AVT1.xml) UniPEFF emits:

>sp:A0AVT1
>sp:A0AVT1-2
>sp:A0AVT1-3
>sp:A0AVT1-4

Only sp:A0AVT1 has tags after \ID (e.g. \ModResPsi, \Processed); the isoform entries have none.

Why it is not trivial

Isoforms usually skip exons present in the canonical sequence, so UniProt feature positions (PTMs, sequence variants, processing sites) refer to canonical coordinates. Carrying them over requires remapping each position through the splice-variant edits, and dropping features that fall into removed or replaced regions.

Suggested scope

  • Remap \ModResPsi/\ModResUnimod, \Variant/\VariantSimple and \Processed positions from canonical to isoform coordinates using the VSP_* splice-variant features already parsed for UniPEFF: Implement isoform expansion from splice-variant features #9966.
  • Drop (or report) features whose position lies inside a deleted/replaced segment.
  • Also worth checking, as noted by the reporter: that the isoform sequence variants themselves are reflected correctly.

Activity

  1. aliviahossain commented on Oct 21, 2026

    @aliviahossain
    Contributor

    @timosachsenberg Can I work on this ?
    I checked A0AVT1 on current develop. The rebuilt sequences for -2, -3 and -4 match UniProt's isoform FASTA exactly, so the reconstruction from #9966 looks right. What's missing now is carrying the canonical features over.
    So my plan is to build a canonical-to-isoform position map from the same VSP edits used in buildIsoformSequence(). I'll run the canonical (not isoform-scoped) ModRes, Variant/VariantSimple and Processed features through it, and drop anything that falls inside a deleted or replaced segment accordingly.

    I'd like just one suggestio before I start : So the ranges that cross an edit, like the 1–1052 chain on every isoform, should I drop them, or clip them to the isoform? I would prefer clipping Processed ranges and dropping anything else that crosses an edit.
    I'd add class tests with a small fixture plus the A0AVT1 case.

  2. timosachsenberg commented on Oct 21, 2026

    @timosachsenberg
    ContributorAuthor

    Yes please :)

  3. aliviahossain commented on Oct 22, 2026

    @aliviahossain
    Contributor

    Yes please :)

    Sure, I will do, @timosachsenberg . Currently at uni, will do it within a few hours. Meanwhile, please assign me the issue !

  4. timosachsenberg commented on Oct 22, 2026

    @timosachsenberg
    ContributorAuthor

    no issue assignment needed

  5. added a commit that references this issue on Oct 26, 2026
    7555ed0
  6. dtabb73 commented on Oct 28, 2026

    @dtabb73

    I tested UniPEFF from 3.7.0-pre-nightly-2026-10-27 with A0AVT1 and with the more challenging P15692. Neither contains any "Processed", sequence variant, or PTM information after the initial entry. The isoform annotation continues to end with \ID. The binary seems to be entirely unchanged in its behavior from before the pull request.

  7. timosachsenberg commented on Oct 28, 2026

    @timosachsenberg
    ContributorAuthor

    @aliviahossain can you check?

  8. aliviahossain commented on Oct 28, 2026

    @aliviahossain
    Contributor

    @dtabb73 @timosachsenberg The mapping is in the nightly, it's just opt-in: it runs with -map_canonical_features, as described in #10699. Without the flag the output is unchanged by design, since UniProt doesn't assert canonical annotations for isoforms.

    UniPEFF -in P15692.xml -out P15692.peff -map_canonical_features

    With it, all 16 isoforms of P15692 carry their annotations, and all 3 of A0AVT1. For eg. , VEGF165 (P15692-4) gets the half-cystines at 52 to 130 with their disulfide bonds, the N-glycan at 101 and the chain 1 to 191. Only the N-VEGF and VEGFA chains are left out, since UniProt gives their boundaries as unknown (the canonical entry doesn't write them either).

    If you'd rather have it on by default, I can switch it to match the other annotation types, with -omit_canonical_features to turn it off.

  9. dtabb73 commented on Oct 28, 2026

    @dtabb73

    Ah! Thank you for explaining. Yes, I think we should carry over the annotation by default, with an available switch to omit. Merci!

  10. aliviahossain commented on Oct 28, 2026

    @aliviahossain
    Contributor

    @dtabb73 No problem, I'll open a follow-up PR that maps the annotations by default, with -omit_canonical_features to turn it off. @timosachsenberg I'll update the affected UniPEFF test outputs and check each changed value by hand, unless you'd rather keep it opt-in.

  11. aliviahossain commented on Oct 29, 2026

    @aliviahossain
    Contributor

    @timosachsenberg Should I open up another PR as per discussed ?

  12. timosachsenberg commented on Oct 29, 2026

    @timosachsenberg
    ContributorAuthor

    Please ask @dtabb73 he is our unipeff expert :)

  13. dtabb73 commented on Oct 29, 2026

    @dtabb73

    I'm trying to keep up with the different issues and pull requests with UniPEFF, but I find GitHub a bit confusing. If you set the option to omit annotation from other isoforms in a different pull request, I will try to follow along and test it, as soon as it appears in a "nightly."

    I haven't checked the documentation very carefully, but I believe it is currently the default to expand isoforms but can be disabled through a command line flag. I note that this is the opposite of typical usage in the proteomics community. Most people download a reference proteome but omit isoforms (often they omit unreviewed accessions, which they should definitely include). I think it is actually a very good thing to make the default behavior to report isoforms.

    Thanks!

  14. aliviahossain commented on Oct 29, 2026

    @aliviahossain
    Contributor

    @dtabb73 No problem, I'll open the follow-up PR. Yes, isoform entries are written by default and -omit_isoforms turns them off, and that stays as it is.

    The PR makes the isoform entries carry the canonical annotations by default, with -omit_canonical_features to leave those out. Annotations UniProt makes on an isoform itself are written either way. I'll link the PR here and post again once it's in a nightly, so it's easier to understand which one to test.

  15. timosachsenberg commented on Nov 25, 2026

    @timosachsenberg
    ContributorAuthor

    Fixed in develop. #10699 added mapping of the canonical annotations onto isoform entries, and #10887 (2026-11-13) turned it on by default; -omit_canonical_features turns it off. Positions inside splice-variant regions are dropped, and \Processed regions are kept only when their cleavage sites survive. The test TOPP_UniPEFF_20 checks that an isoform entry carries \ModResPsi, \VariantSimple and \Processed. The test from Oct 28 predates the new default, so if a nightly built after Nov 13 still misses tags, please reopen.


    Generated by Claude Code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions