IDEAS home Printed from https://ideas.repec.org/a/nat/natcom/v16y2025i1d10.1038_s41467-025-58588-7.html
   My bibliography  Save this article

CodonTransformer: a multispecies codon optimizer using context-aware neural networks

Author

Listed:
  • Adibvafa Fallahpour

    (Vector Institute for Artificial Intelligence
    University of Toronto Scarborough; Department of Biological Science)

  • Vincent Gureghian

    (Quantitative and Synthetic Biology
    Institut de Biologie Paris-Seine)

  • Guillaume J. Filion

    (University of Toronto Scarborough; Department of Biological Science)

  • Ariel B. Lindner

    (Quantitative and Synthetic Biology
    Institut de Biologie Paris-Seine
    Biofoundry Alliance Sorbonne Université)

  • Amir Pandi

    (Quantitative and Synthetic Biology
    Institut de Biologie Paris-Seine
    Biofoundry Alliance Sorbonne Université)

Abstract

Degeneracy in the genetic code allows many possible DNA sequences to encode the same protein. Optimizing codon usage within a sequence to meet organism-specific preferences faces combinatorial explosion. Nevertheless, natural sequences optimized through evolution provide a rich source of data for machine learning algorithms to explore the underlying rules. Here, we introduce CodonTransformer, a multispecies deep learning model trained on over 1 million DNA-protein pairs from 164 organisms spanning all domains of life. The model demonstrates context-awareness thanks to its Transformers architecture and to our sequence representation strategy that combines organism, amino acid, and codon encodings. CodonTransformer generates host-specific DNA sequences with natural-like codon distribution profiles and with minimum negative cis-regulatory elements. This work introduces the strategy of Shared Token Representation and Encoding with Aligned Multi-masking (STREAM) and provides a codon optimization framework with a customizable open-access model and a user-friendly Google Colab interface.

Suggested Citation

  • Adibvafa Fallahpour & Vincent Gureghian & Guillaume J. Filion & Ariel B. Lindner & Amir Pandi, 2025. "CodonTransformer: a multispecies codon optimizer using context-aware neural networks," Nature Communications, Nature, vol. 16(1), pages 1-12, December.
  • Handle: RePEc:nat:natcom:v:16:y:2025:i:1:d:10.1038_s41467-025-58588-7
    DOI: 10.1038/s41467-025-58588-7
    as

    Download full text from publisher

    File URL: https://www.nature.com/articles/s41467-025-58588-7
    File Function: Abstract
    Download Restriction: no

    File URL: https://libkey.io/10.1038/s41467-025-58588-7?utm_source=ideas
    LibKey link: if access is restricted and if your library uses this service, LibKey will redirect you to where you can use your library subscription to access this item
    ---><---

    More about this item

    Statistics

    Access and download statistics

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:nat:natcom:v:16:y:2025:i:1:d:10.1038_s41467-025-58588-7. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    We have no bibliographic references for this item. You can help adding them by using this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: Sonal Shukla or Springer Nature Abstracting and Indexing (email available below). General contact details of provider: http://www.nature.com .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.