bioRxivBioinformaticsPreprint
What does it take to learn the rules of RNA base pairing? A lot less than you may think
Abstract
Amidst the fast-developing trend of RNA large language models with millions of parameters, we asked what would be the minimum required to rediscover the rules of RNA canonical base pairing, mainly the Watson-Crick-Franklin A:U, G:C and the wobble G:U base pairs (the secondary structure). Here, we conclude that it does not require much at all. It does not require knowing secondary structures; it does not require aligning the sequences; and it does not require many parameters. We selected a probabilistic model of palindromes (a stochastic context-free grammar or SCFG) with a total of just 21 parameters. Using standard deep learning techniques, we estimate its parameters by implementing the generative process in an automatic differentiation (autodiff) framework and applying stochastic gradient descent (SGD). We define and minimize a loss function that does not use any structural or alignment information. Trained on as few as fifty RNA sequences, the rules of RNA base pairing emerge after only a few iterations of SGD. Crucially, the sole inputs are RNA sequences. When optimizing for sequences corresponding to structured RNAs, SGD also yields the rules of RNA base-pair aggregation into helices. Trained on shuffled sequences, the system optimizes by avoiding base pairing altogether. Trained on messenger RNAs, it reveals interactions that are different from those of structural RNAs, and specific to each mRNA. Our results show that the emergence of canonical base-pairing can be attributed to sequence-level signals that are robust and detectable even without labeled structures or alignments, and with very few parameters. Autodiff algorithms for probabilistic models, such as, but not restricted to SCFGs, have significant potential as they allow these models to be incorporated into end-to-end RNA deep learning methods for discerning transcripts of different functionalities. Availabilityrivaslab.org, https://github.com/EddyRivasLab/R-scape/tree/master/python/d-SCFG
- Citations
- 1
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
- Deep generalizable prediction of RNA secondary structure via base pair motif energy
Heqin Zhu, Fenghe Tang, … S. Kevin Zhou·Nature CommunicationsPeer-reviewed·Jul 1, 2025
- An open structure-guided RNA foundation model for generalizable prediction
Heqin Zhu, Ruifeng Li, … S Kevin Zhou·bioRxiv·Aug 6, 2025
- UFold: Fast and Accurate RNA Secondary Structure Prediction with Deep Learning
Laiyi Fu, Yingxin Cao, … Xiaohui S. Xie·Nucleic Acids ResearchPeer-reviewed·Oct 20, 2021
- RNAbpFlow: Base pair-augmented SE(3)-flow matching for conditional RNA 3D structure generation
Sumit Tarafder, Debswapna Bhattacharya·Nature MethodsPeer-reviewed·Jun 30, 2026
- De Novo Prediction of RNA 3D Structures with Deep Learning
Julius Ramakers, Christopher Frederik Blum, … Markus Kollmann·bioRxiv·Aug 30, 2021
- NucleicBERT: Deciphering the language of nucleic acids
Utkarsh Upadhyay, Julian M. Herold, … Alexander H. Schug·bioRxiv·Sep 2, 2025