MolAct: An Agentic RL Framework for Molecular Editing and Property Optimization

Zhuo Yang, Yeyun Chen, Jiaqing Xie, Ben Gao, Shuaike Shen, Wanhao Liu, Liujia Yang, Beilun Wang, Tianfan Fu, Yuqiang LiarXiv 2025 · DOI

Abstract

MolAct is a novel agentic reinforcement learning (RL) framework that conceptualizes molecular design as a multi-step, tool-guided conversation. By employing a two-stage training paradigm—first mastering basic editing skills and then tackling complex property optimization—it produces Large Language Model (LLM) agents capable of iteratively refining molecules while maintaining near-perfect chemical validity. This approach bridges the gap between static generation and the iterative nature of real-world medicinal chemistry.

Introduction

Traditional molecular design typically relies on "one-shot" generation processes or rigid, domain-specific pipelines. While Large Language Models (LLMs) have shown potential in this domain, they frequently suffer from "hallucinations," producing chemically impossible structures that violate valence rules due to a lack of feedback from physical laws. Furthermore, the challenge of optimizing a molecule for specific properties (e.g., solubility) while preserving the structural integrity of a starting "lead" compound remains a significant hurdle for static models.

Methodology

MolAct formalizes molecular design as an Agentic Reinforcement Learning problem, integrating reasoning with external tool interaction. The framework's architecture is centered around a policy model that engages in a "Think $\rightarrow$ Tool Call $ ightarrow$ Observation" loop.

Two-Stage Training Paradigm

The authors implement a curriculum-based training strategy to ensure agent stability:

  1. Stage 1 (MolEditAgent): The model learns fundamental "atomic" operations—adding, deleting, or substituting functional groups—guided by feedback on chemical validity and structural similarity.
  2. Stage 2 (MolOptAgent): Building upon these editing skills, the model learns to optimize complex properties such as LogP, QED, and bioactivity while adhering to multi-objective constraints.

Optimization and Reasoning

The framework utilizes Group-Relative Policy Optimization (GRPO) to stabilize training. GRPO runs multiple parallel rollouts for each prompt, computing advantages relative to the group. Gradients are applied exclusively to the agent's reasoning and action tokens, while tool outputs are masked to focus the learning on the agent's decision-making logic.

Datasets and Evaluation

The framework was trained and evaluated using two specialized resources:

  • ChemCoTDatasets: Annotated chain-of-thought data for multi-step molecule modification.
  • ChemCoTBench: A primary evaluation benchmark covering elementary editing tasks and six optimization objectives, including LogP, solubility, QED, and bioactivity targets like DRD2, JNK3, and GSK3$\beta$.

Key Insights and Results

The Importance of Curriculum

A critical finding is that one-stage training fails. Models trained directly on optimization without first mastering basic editing achieved near-zero success rates. Learning the "how" (editing) before the "why" (optimization) is essential for agentic stability.

Performance Benchmarks

  • Molecular Editing: MolEditAgent-7B achieved high accuracy across tasks (90% for Add, 80% for Delete, 78.3% for Substitute), outperforming larger models like DeepSeek-R1.
  • Chemical Validity: While base models often produced valid molecules only 55–75% of the time, MolAct maintained 95–100% validity by using tool feedback as a real-time constraint.
  • Property Optimization: MolOptAgent-7B set new benchmarks, achieving a 92% success rate on LogP optimization, surpassing closed-source models like Claude 3.7-sonnet.

The "Executability" Gap

While smaller models (3B) can achieve similar reward signals during training, they often fail during inference. They struggle with the "bookkeeping" of multi-turn conversations, frequently failing to terminate loops or use tool feedback effectively to correct their strategies.

Conclusion and Future Work

MolAct demonstrates the power of agentic RL in molecular design, yet several limitations remain. The agent's performance is inherently tied to the accuracy of external oracles; biased property estimators can lead to sub-optimal designs. Additionally, while the model ensures chemical validity, it does not yet account for synthetic feasibility. Future work will focus on integrating synthesis-aware tools and expanding the interaction budget beyond the current 16-turn limit to explore more complex molecular transformations.

Summary updated

BibTeX
@misc{yang2025molact,
  author = {Zhuo Yang and Yeyun Chen and Jiaqing Xie and Ben Gao and Shuaike Shen and Wanhao Liu and Liujia Yang and Beilun Wang and Tianfan Fu and Yuqiang Li},
  title = {{MolAct: An Agentic RL Framework for Molecular Editing and Property Optimization}},
  year = {2025},
  eprint = {2512.20135},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2512.20135},
}
Figure