ChemPrompt: a genetic algorithm-based prompt engineering framework for enhanced QSAR prediction with large language models
Quantitative structure–activity relationship (QSAR) prediction remains a challenging problem in drug discovery, yet it offers a promising avenue to reduce time- and cost-intensive experimental workloads. Recently, studies utilizing large language models (LLMs) to process molecular structure data, such as the simplified molecular-input line-entry system (SMILES), have gained attention; however, such approaches still struggle to improve prediction accuracy owing to the absence of physicochemical property information, which is difficult to infer from structural information alone. To address this issue, we propose ChemPrompt, a framework that employs prompt engineering to integrate physicochemical information into SMILES strings. Furthermore, we present a genetic algorithm to search for the molecular prompt best suited to each prediction task. We evaluated the proposed method on four regression benchmark datasets (FreeSolv, ESOL, Lipophilicity, and Caco-2) and one classification benchmark (ClinTox). Compared with using SMILES alone as input, ChemPrompt reduced the root mean square error (RMSE) on the regression tasks and improved F1-scores on the classification task, and it also outperformed prompts that simply appended all available descriptors. Across the five datasets, it achieved the best mean rank among the compared fingerprint- and SMILES-based methods under both five-fold cross-validation and a scaffold split. In addition, optimized prompts showed no measurable performance loss at 16-bit (Float16) precision, indicating that ChemPrompt is practical in research settings with limited high-performance computing resources. These results indicate that optimizing the descriptor content of molecular prompts is an effective and computationally practical strategy for molecular property prediction with LLMs, and that it can be applied without fine-tuning in resource-constrained settings. While chemistry-specialized LLMs and molecular foundation models require task-specific training, ChemPrompt adapts a general-purpose pretrained LLM to each QSAR task by optimizing the descriptor content of its prompt via a genetic algorithm. Ablation studies showed that jointly encoding SMILES and GA-selected descriptors in an LLM embedding outperformed concatenating the same descriptors with ECFP4 or ChemBERTa representations, demonstrating that descriptors alone cannot explain its gains. Furthermore, the GA-selected descriptors corresponded to the physical determinants of the target properties, indicating that prompt optimization converges on chemically meaningful information.
- Link
- https://www.semanticscholar.org/paper/171abd513709cb79e141fc3d6cd62c7862f1a078
- Found by
- Semantic Scholar
- Authors
- Tae-Jeong Song, Jeong Tae Lee, Jonghwan Choi
- Categories
- benchmark, evaluation, dataset
- Published
- 2026-11-27
- Last seen by the radar
- 2026-11-29
- Citations
- 0
- Influential citations
- 0
- Radar score
- 44.25 / 100 (how it is scored)
- Why it scored so
- Matched: benchmark, dataset, evaluat; Primary record: Semantic Scholar
- Related links
- https://doi.org/10.1186/s13321-026-01341-z