bioRxivBioinformaticsPreprint
Optimized k-mer search across millions of bacterial genomes on laptops
Abstract
Comprehensive bacterial collections have reached millions of genomes, opening new opportunities for point-of-care diagnostics and epidemiological surveillance. However, local real-time search over such collections on commodity hardware remains difficult. Currently, only LexicMap and Phylign enable local search and alignment at such a scale; among them, only Phylign is designed to run on laptops, via a subindex approach informed by phylogenetic compression. However, Phyligns performance deteriorates on long and divergent queries because it uses COBS as a k-mer-based prefilter before alignment with Minimap2. Meanwhile, recent k-mer indexes such as Fulgor and Themisto have emerged, but there is no practical methodology for selecting, combining, and parameterizing them for phylogenetically partitioned million-genome search under constraints. Here, we develop an end-to-end methodology for k-mer matching in phylogenetically compressed bacterial collections. We formalize a matching strategy defined by matching mode, query type, and reference characteristics, and use this to shortlist candidate indexes and benchmark them under space-time trade-offs. As a case study, we address plasmid search over AllTheBacteria, compare multiple index types, and identify configurations optimizing the Pareto frontier of space and speed. Guided by these results, we implement a phylogenetically compressed variant of Fulgor, integrate it into Phylign, and obtain Phylign-Fulgor, a laptop-ready pipeline for million-genome search. On the 661k collection, Phylign-Fulgor makes the prefiltering step [~]4x faster than Phylign-COBS at the cost of a 1.2x larger index. On AllTheBacteria, its k-mer filter is 20x-300x faster in real time than LexicMaps alignment-based search and uses [~]20x smaller disk space. The full Phylign-Fulgor workflow including Minimap2 alignments is slower than LexicMap for a single plasmid but competitive or faster for batched plasmid queries. Phylign-Fulgor has comparable matching sensitivity to LexicMap, is less sensitive at the alignment level, but always stays within a laptop RAM budget ([~]5x-20x lower memory than LexicMap).
- organism: bacteria (other)
- assay: whole-genome sequencing
- research focus: benchmarking
- research focus: database / resource
- research focus: software / tool
- research focus: variant calling
- approach: experimental assay
- Citations
- 0
Reproducibility ledger
Nobody has reported trying to reproduce this paper yet. Did you replicate an experiment or run the code? Your report saves the next lab a week.
Sign in to file a reproducibility report.
Related papers
- Efficient and Robust Search of Microbial Genomes via Phylogenetic Compression
Karel Břinda, Leandro Lima, … Michael Baym·Nature MethodsPeer-reviewed·Apr 1, 2025
- Fulgor: A fast and compact k-mer index for large-scale matching and color queries
Jason Fan, Noor Singh, … Rob Patro·Algorithms for Molecular BiologyPeer-reviewed·Jan 22, 2024
- Themisto: a scalable colored k-mer index for sensitive pseudoalignment against hundreds of thousands of bacterial genomes
Jarno Alanko, Jaakko Vuohtoniemi, … Simon J. Puglisi·BioinformaticsPeer-reviewed·May 24, 2023
- LexicMap: efficient sequence alignment against millions of prokaryotic genomes
Wei Shen, John A. Lees, Zamin Iqbal·Nature BiotechnologyPeer-reviewed·Sep 10, 2025
- Kaminari: a resource-frugal index for approximate colored k-mer queries
Victor Levallois, Yoshihiro Shibuya, … Giulio Ermanno Pibiri·Bioinformatics AdvancesPeer-reviewed·Jan 1, 2026
- A k-mer-based maximum likelihood method for estimating distances of reads to genomes enables genome-wide phylogenetic placement.
Ali Osman Berk Şapcı, Siavash Mirarab·Genome biologyPeer-reviewed·Feb 21, 2026