Thanks so much, Bharat K. C. Patel I really appreciate you taking some time to give ideas. I'll give your suggestions a try. My pipeline was standard (EDTA for TEs, Maker, and Blast2GO) so it seems many people would face these problems when trying to format for NCBI.
I’ve just spent a number of years assembling, annotating, and analyzing genomes. Now I’m battling table2asn to produce sqn files fit for submission to NCBI. Of course, there are errors, but no clear way of dealing with the errors, so any ideas will be more than welcomed:
- My gff3 files have “Ontology_term” and the sqn files want “product”, so all my carefully added ontology goes out the window and all the thousands of genes are called “hypothetical protein”. I thought maybe funannotate could help fix a gff3 that’s already annotated but I don’t yet see if this is possible. Also, my TE annotations have “classification”.
- There are errors such as SEQ_FEAT.Range, etc. You can find a list of what they mean here, but the point is that there should be a tool that fixes them. The -c f tag in table2sqn does not seem to, as far as I can tell. Is there a tool to help with this?
Thanks for any ideas!
1 answer
The Problem: Vocabulary Mismatch & Rigid Coordinate Validation:
Your hard work isn't lost. table2asn is notoriously rigid because international submission databases (NCBI/EBI/DDBJ) do not accept raw GFF3 files.
"Hypothetical Protein" Error: NCBI ignores
Ontology_term. It strictly reads theproductattribute tag in the 9th column. Without it, everything defaults to "hypothetical protein.TE Error: NCBI rejects custom
classification. It requiresmobile_element_type=retrotransposon:LINEsyntax.SEQ_FEAT. Range Error: A fatal coordinate mismatch where a child feature (CDS/exon) extends outside its parent feature (mRNA/gene) by even 1 base. The
-c fflag cannot fix structural biology errors.
The Solution: Do Not Feed Raw GFF3 to table2asn
You need to pass your annotation through a cleanup pipeline to translate your vocabulary and structurally fix the coordinates. Choose the path that matches your current files:
1. Option A: You ONLY have the annotated GFF3 file:
- The Strategy: Use a rapid Python text-swap trick to duplicate your existing text labels into valid NCBI tags.
- The Pipeline: AGAT (to fix coordinate bounds/
SEQ_FEAT.Range) --> Python regex script (to duplicateOntology_termintoproduct) --> GAG (Genome Annotation Generator) (to convert the cleaned GFF3 into NCBI’s required 5-column.tblformat).
- The Pipeline: AGAT (to fix coordinate bounds/
2. Option B: You still have the raw output logs (InterProScan .xml / eggNOG .annotations)
- The Strategy: Use structural evidence files to automatically translate ontology to NCBI nomenclature without rerunning any slow calculations.
- The Pipeline: AGAT (to fix coordinate bounds) -->
funannotate annotate(reads your existing log files to auto-populate officialproducttags) \ --> GAG (to generate the final submission.tblfile).
- The Pipeline: AGAT (to fix coordinate bounds) -->
Bioinformatician's Tip: Use Pixi instead of Conda
- Installing complex legacy Perl and Python tools like AGAT and
funannotatevia standard Conda often triggers massive dependency conflicts that take hours to resolve. - Consider using Pixi. It is a modern, lightweight environment manager that builds an un-breakable, isolated environment container directly inside your project folder. It handles conflicting bioconda dependencies seamlessly in seconds.
- Reply with whether you are using Option A or Option B, and the community could provide the exact terminal syntax or
pixi.tomlconfiguration to automate the table conversion for you!
This workflow idea worked! I ended up troubleshooting until I replaced AGAT etc. with Python scripts, but I did use a pixi.toml with roughly the same steps. It worked great! Turns out that part of my issue was that cleaning the assemblies with NCBI's own FCS-GX broke the coordinates relative to the annotations, so I had to redo the cleaning.
Log in to answer this question.