
License: CodonFM (Encodon) uses Apache-2.0 for code and Custom (NVIDIA Open Model License) for model weights. Please refer to the code license and model weights license for full terms.
This constraint is open source. Any third-party models, product names, or trademarks referenced are the property of their respective owners, and Proto is not affiliated with them.

@articlecodonfm2025
Constraint contributors
bviggiano
Score proposals by Encodon’s upstream non-padding-token mean log-likelihood.
This follows predict_fitness exactly: the mean includes visible codons and the CLS/SEP
special tokens, while excluding padding.
API Reference
Configuration for the CodonFM coding-sequence fitness constraint.
enum
default:"encodon_80m"
Encodon checkpoint: encodon_80m | encodon_600m | encodon_1b | encodon_1b_cdwt.Options:
encodon_80m, encodon_600m, encodon_1b, encodon_1b_cdwtenum
default:"max"
Whether to maximize (‘max’) or minimize (‘min’) the coding-sequence fitness.Options:
max, minnumber
default:"-2.0"
Upstream non-padding-token mean log-likelihood mapped to energy 0.5 (tunable; negative).
number
default:"1.0"
Positive float32-safe width of the sigmoid transform; larger is gentler.
string
default:"cuda"
CUDA device used for CodonFM inference; the upstream xFormers path is GPU-only.
integer
default:"1"
Number of sequences scored per CodonFM GPU batch.
ReturnsConstraintOutput
One result per proposal. score is in [0.0, 1.0] (lower
is better in the requested direction); metadata carries the raw fitness.Usage
python