Abstract
Designing molecules with desirable properties, such as drug-likeliness and high binding affinities towards protein targets, is a challenging problem. In this paper, we propose the Dual-Space Optimization (DSO) method that integrates latent space sampling and data space selection to solve this problem. DSO iteratively updates a latent space generative model and a synthetic dataset in an optimization process that gradually shifts the generative model and the synthetic data towards regions of desired property values. Our generative model takes the form of a Latent Prompt Transformer (LPT) where the latent vector serves as the prompt of a causal transformer. Our extensive experiments demonstrate the effectiveness of the proposed method, which sets new performance benchmarks across single-objective, multi-objective, and constrained molecule design tasks.
Introduction
Designing new drugs is a "needle in a haystack" problem: the space of potential drug-like molecules is estimated at $10^{60}$, yet only a tiny fraction are useful. Current machine learning approaches often rely on Latent Space Optimization (LSO), a two-stage process where a Variational Auto-Encoder (VAE) maps molecules into a continuous latent space, followed by a search using a separate surrogate model.
However, this decoupled approach has significant flaws: the latent space is learned independently of the optimization goal, and the reliance on auxiliary encoder networks increases model complexity. We introduce the Latent Prompt Transformer (LPT) and the Dual-Space Optimization (DSO) framework to unify molecule generation and property optimization into a single, end-to-end model.
The Latent Prompt Transformer (LPT)
The LPT replaces the traditional two-stage process with a unified probabilistic model. It consists of three tightly integrated components:
- Learnable Prior: A 1D UNet that transforms white noise into an expressive latent vector ($z$).
- Molecule Generator: A causal Transformer that treats the latent vector $z$ as a "prompt" via cross-attention, guiding the autoregressive generation of molecule sequences (SMILES/SELFIES).
- Property Predictor: A simple MLP that estimates a molecule's properties directly from the same latent prompt $z$.
By forcing both the generator and the property predictor to share the same latent vector $z$, the model creates an information bottleneck. This ensures that $z$ captures the essential features needed for both structural generation and property prediction.
Dual-Space Optimization Strategy
Unlike VAEs, LPT does not use an encoder. Instead, it employs Langevin dynamics (a type of Markov chain Monte Carlo) to sample the optimal latent vector for a given molecule during training. This allows the model to be trained directly via Maximum Likelihood Estimation (MLE).
The DSO framework uses an online learning algorithm where the model generates molecules, an "oracle" evaluates them, and the model is retrained on this new data. This process iteratively shifts the model's distribution toward chemical regions with superior property values.
Key Results
LPT was evaluated on its ability to design binders for protein targets such as ESR1, ACAA1, and PHGDH. In single-objective tasks, LPT significantly outperformed existing baselines.
As shown in the performance table, LPT achieved a dissociation constant ($K_D$) of 0.004 for ESR1, compared to the best baseline (SGDS) at 0.03. For the PHGDH target, LPT reached a $K_D$ of 0.07, whereas the best baseline only reached 3.65 (lower is better).
Beyond raw performance, LPT demonstrated remarkable sample efficiency on the PMO benchmark, matching specialized Bayesian Optimization methods with fewer oracle queries. It also succeeded in multi-objective tasks, balancing binding affinity with drug-likeliness (QED) and synthetic accessibility (SA).
Conclusion
The Latent Prompt Transformer offers a streamlined approach to molecule design by treating latent representations as continuous instructions. By unifying generation and optimization, LPT achieves state-of-the-art results in drug discovery tasks with high efficiency. Future work will explore extending this framework to graph-based architectures and broader scientific sequence optimization problems.
Summary updated