[Paper Review] Ligandformer: A Graph Neural Network for Predicting Compound Property with Robust Interpretation
Ligandformer is a multi-layer self-attention graph neural network that predicts compound properties with robust, interpretable attention maps highlighting structurally relevant molecular fragments. It outperforms SAMPN and MPNN in accuracy (AUROC up to 0.98) and ensures prediction stability across training rounds by integrating attention coefficients across blocks.
Robust and efficient interpretation of QSAR methods is quite useful to validate AI prediction rationales with subjective opinion (chemist or biologist expertise), understand sophisticated chemical or biological process mechanisms, and provide heuristic ideas for structure optimization in pharmaceutical industry. For this purpose, we construct a multi-layer self-attention based Graph Neural Network framework, namely Ligandformer, for predicting compound property with interpretation. Ligandformer integrates attention maps on compound structure from different network blocks. The integrated attention map reflects the machine's local interest on compound structure, and indicates the relationship between predicted compound property and its structure. This work mainly contributes to three aspects: 1. Ligandformer directly opens the black-box of deep learning methods, providing local prediction rationales on chemical structures. 2. Ligandformer gives robust prediction in different experimental rounds, overcoming the ubiquitous prediction instability of deep learning methods. 3. Ligandformer can be generalized to predict different chemical or biological properties with high performance. Furthermore, Ligandformer can simultaneously output specific property score and visible attention map on structure, which can support researchers to investigate chemical or biological property and optimize structure efficiently. Our framework outperforms over counterparts in terms of accuracy, robustness and generalization, and can be applied in complex system study.
Motivation & Objective
- To address the black-box nature of deep learning models in QSAR by enabling interpretable, local prediction rationales on molecular structures.
- To improve prediction robustness across training rounds, overcoming the instability common in deep learning models.
- To develop a generalizable framework capable of predicting diverse chemical and biological properties with high performance.
- To integrate attention mechanisms across multiple network blocks to generate stable, interpretable attention maps reflecting machine interest on molecular substructures.
Proposed method
- Ligandformer uses a bidirectional 2D molecular graph representation with 7 atomic attributes as initial node features.
- It applies a multi-layer self-attention mechanism based on query, key, and value transformations to learn attention scores between atoms.
- The attention map from each block is computed using softmax of dot-product attention: $ Y_h = \text{softmax}(Q_h K_h^T) V_h $.
- Attention coefficients from all blocks are averaged to produce an integrated attention map, enhancing robustness and interpretability.
- The model uses Adam optimizer with learning rate 0.001 and weight decay 0.0001, and applies early stopping after 50 epochs of no improvement in AUROC.
- SMILES strings are converted to molecular graphs using RDKit and processed via DeepChem/Chemprop pipelines for consistent input representation.
Experimental results
Research questions
- RQ1Can a GNN-based model provide stable, interpretable attention maps that highlight specific molecular substructures influencing property predictions?
- RQ2How does integrating attention coefficients across multiple network blocks improve prediction robustness compared to single-model or non-integrated attention approaches?
- RQ3To what extent can Ligandformer generalize across different chemical and biological properties with high accuracy and interpretability?
- RQ4Can attention maps generated by Ligandformer align with expert chemical intuition, enabling structure-based optimization in drug discovery?
Key findings
- Ligandformer achieved an AUROC of 0.98 on aqueous solubility, surpassing MPNN (0.93) and SAMPN (0.92).
- For Caco-2 cell permeability, Ligandformer maintained an AUROC of 0.89, matching SAMPN but exceeding MPNN (0.89).
- On Ames mutagenesis, Ligandformer achieved an AUROC of 0.92, outperforming both MPNN (0.90) and SAMPN (0.91).
- Despite different random initializations, the integrated attention maps from Ligandformer remained consistent across two training rounds, demonstrating robustness.
- Visualization of attention maps revealed that deeper blocks highlight larger molecular fragments, while shallow blocks focus on individual atoms or local functional groups.
- The integration of multi-scale attention coefficients significantly improved model stability and interpretability compared to non-integrated attention mechanisms.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.