BarcodeBERT: transformers for biodiversity analyses
Pablo Millán Arias, Niousha Sadjadi, Monireh Safari, ZeMing Gong, Austin T. Wang, Joakim Bruslund Haurum, Iuliia Zarubiieva, Dirk Steinke,
University of Waterloo · Simon Fraser University
Key points
From the paper's conclusion- We evaluate BarcodeBERT on taxonomic identification tasks against a spectrum of machine learning approaches, including supervised training of classical neural architectures and fine-tuning of general DNA foundation models.
Abstract
Motivation: In the global effort to characterize biodiversity, short species-specific genomic sequences known as DNA barcodes enable fine-grained comparisons among organisms within the same kingdom of life. Although machine learning algorithms specifically designed for the analysis of DNA barcodes are becoming more popular, most existing methodologies rely on generic supervised training algorithms. Results: We introduce BarcodeBERT, a family of models tailored to biodiversity analysis and trained exclusively on data from a reference library of 1.5 M invertebrate DNA barcodes. We evaluate BarcodeBERT on taxonomic identification tasks against a spectrum of machine learning approaches, including supervised training of classical neural architectures and fine-tuning of general DNA foundation models. Our self-supervised pretraining strategies on domain-specific data outperform fine-tuned foundation models, especially in identification tasks involving lower taxa such as genera and species. Compared with BLAST, a widely used sequence-search tool, BarcodeBERT achieves comparable species-level classification accuracy while being 55× faster. Our analysis of masking and tokenization strategies also provides practical guidance for building customized DNA language models, emphasizing the importance of aligning model training strategies with dataset characteristics and domain knowledge. Availability and implementation: The code repository is available at https://github.com/bioscan-ml/BarcodeBERT.
Read the paper
Discussion
Science Skim's AI key points, plus readers' public thoughts
Readers' thoughts
No reader thoughts yet.
Related papers
- DNACSE: Enhancing Genomic LLMs with Contrastive Learning for DNA Barcode IdentificationJournal of Chemical Information and Modeling · 2026
- Transductive Learning From a Transformer Foundation Model Improves the Taxonomic Classification of eDNA Metabarcodes.Molecular ecology resources · 2026
- BarcodeMAE+: Rethinking Masked Pretraining and Global Representations for DNA Barcode Foundation ModelsarXiv · 2026
- Benchmarking DNA foundation models for genomic and genetic tasksNature Communications · 2025
- Performance and Limitations of Out‐Of‐Distribution Detection for Insect DNA BarcodingEcology and Evolution · 2026
- MicrobeRT: A Framework and Suite of Fine-tuned Language Models for Genomic SequencesbioRxiv · 2026