ProkBERT
A BERT-style genomic language model that reads DNA as overlapping k-mers, designed for microbiome applications.
Molecules, proteins and genomics · 262 operations Checked
Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.
At a glance
- Parameters
- 20.5M
- Operations
- 262
- Framework
- PyTorch
- Recurrent
- No
- Published
- 2024, Frontiers in Microbiology
- Cited by
- 30 (as of 24 October 2026)
- Authors
- Balázs Ligeti, István Szepesi-Nagy, Babett Bodnár and others
- License
- MIT
- Checked
- Passed: the trace was replayed operation by operation and matched the model's own output for this input.
Files
The file opened in a new tab. Use your browser's Save command there to keep it.
The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.
Details
- Stable ID
- m19498
- Graph hash
- f5fcc9cce038355eb3a6d6dc639572a13037e2128895998acbd6697756f9683d
- Skeleton hash
- d048e3de5adc7c63d078106202779847d0a5fb1673aa08abbf11706abe0822a4
- Architecture hash
- b976cfaa7c9e1a64547d57beeb2c1badb58e2fd288d1981f618c4be5e76e8c69
- Diagram SHA-256
- 84711dad64243ae5f88d9a14398da8ebe313dda4b47c22774747bdb92f6dce39
- TorchLens version
- 2.36.0
- Renderer
- graphviz 2.43.0+pyvips 3.2.0+libvips 8.18.7+render-opts@06c1f0d3
- Check
- Forward pass replayed in PyTorch
What it is
ProkBERT is a family of genomic language models designed for microbiome applications. The models learn a general representation of nucleotide sequences from unlabeled genome data.
DNA is split with Local Context-Aware (LCA) tokenization, in which the tokens are overlapping k-mers governed by two parameters, k-mer size and shift. ProkBERT-mini uses a 6-mer tokenizer with a shift of 1. The architecture is MegatronBert, a variant of BERT optimized for large-scale training. All models use a learnable relative key-value positional embedding that maps input vectors into a 384-dimensional space. The mini model has 6 layers and 6 attention heads, and its developers list its size as 20.6 million parameters. Pretraining uses masked language modeling, adjusted so that when a 6-mer is masked at least six tokens are masked with it, which prevents trivial restoration from context.
On the E-coli sigma70 promoter dataset, the paper reports an accuracy of 0.87 for all three ProkBERT models. ProkBERT-mini and ProkBERT-mini-long reach an MCC of 0.74 there, against 0.73 for ProkBERT-mini-c. For phage identification, the paper reports an MCC of 0.85 and better results than VirSorter2 and DeepVirFinder.
Key idea. ProkBERT introduces Local Context-Aware tokenization, which feeds a BERT-style genomic language model overlapping k-mers to retain local context while covering more sequence.
- ProkBERT
- ProkBERT-mini
- prokbert-mini-k6s1
- genomic language model
- DNA language model
- Local Context-Aware tokenization
- k-mer tokenization
- microbiome
- promoter prediction
- phage identification
AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.
Cite the paper
@article{Ligeti_2024, title={ProkBERT family: genomic language models for microbiome applications}, volume={14}, ISSN={1664-302X}, url={http://dx.doi.org/10.3389/fmicb.2023.1331233}, DOI={10.3389/fmicb.2023.1331233}, journal={Frontiers in Microbiology}, publisher={Frontiers Media SA}, author={Ligeti, Balázs and Szepesi-Nagy, István and Bodnár, Babett and Ligeti-Nagy, Noémi and Juhász, János}, year={2024}, month=Jan }