cs.LGNov 6, 2026

Controllable Molecule Generation via Sparse Representation Editing: An Interpretability-Driven Perspective

Authors: Zhuoran Li, Xu Sun, Chang Wen Chen, Wanyu Lin

Organizations: Department of Computing, The Hong Kong Polytechnic University, Hong Kong SAR, China

Abstract

Controllable molecule generation is crucial for diverse scientific applications, such as drug discovery and materials design. While large language models (LLMs) show great promise, their dense and entangled representations impede precise control over the generation of molecules with bespoke substructures or properties. To address this, we propose Sparse Representation Editing (SpaRE), an interpretability-driven framework for fine-grained and precise control in LLM-based molecule generation. The crux of SpaRE is to learn an overcomplete sparse feature space that disentangles LLM representations into a compact set of latent features corresponding to chemically meaningful concepts. Within this space, we can directly manipulate these concept-aligned latent features to achieve (1) local control, by generating target atoms and functional groups at specified positions; and (2) global control, by customizing the overall structural and physicochemical properties within defined ranges. In this way, our framework advances interpretability from post-hoc analysis to actionable generative control. Experiments show that SpaRE can generate chemically desirable molecules under complex constraints in real-world scenarios, while offering mechanistic insights for quantitative structure-property analysis. The code and demo are available at https://github.com/WanyuGroup/ICML2026_SpaRE.

Figures & tables

Appendix figures & tables51 assets

Supplementary material from the paper’s appendix.

Appendix

Explore similar work

CardsList
  1. SLIM: Sparse Latent Steering for Interpretable and Property-Directed LLM-Based Molecular Editing

    May 11, 2026Mingxu Zhang, Yuhan Li, Lujundong Li +3Molecular OptimizationLLM Interpretability

  2. Coder as Editor: Code-driven Interpretable Molecular Editing

    Oct 16, 2025Wenyu Zhu, Chengzhu Li, Xiaohe Tian +8Molecule DesignChemical Reasoning in LLMs