Online triplet contrastive learning enables efficient cliff awareness in molecular activity prediction

29 May 2023, Version 1
This content is a preprint and has not undergone peer review at the time of posting.


Predicting molecular activity and quantitative structure-activity relationship (QSAR) is important for drug discovery and optimization. With molecular structures as frames, graph neural networks (GNNs) are suited for activity prediction but tend to overlook activity-cliffs (ACs) where structurally-similar molecules have vastly different activity values. To address this, we introduced a new online triplet contrastive learning framework ACANet that incorporates a unique activity-cliff-awareness (ACA) loss function, enabling efficient AC-awareness during training. The ACA loss enhances metric learning in the latent space and task learning in the target space simultaneously to make networks aware of ACs. ACANet outperformed the state-of-the-art machine learning and deep learning models in activity prediction and AC awareness on 39 benchmark datasets. ACA loss function is superior in AC-awareness than the mean absolute error and mean squared error loss functions. This innovative approach opens new avenues and provides valuable tools for applications in drug discovery and chemical engineering.


Activity cliff
molecular activity prediction
Contrastive Learning
Graph neural network
Machine learning
Deep learning

Supplementary materials

Supplementary Tables S1-S4 and Supplementary Figures S1-S4


Comments are not moderated before they are posted, but they can be removed by the site moderators if they are found to be in contravention of our Commenting Policy [opens in a new tab] - please read this policy before you post. Comments should be used for scholarly discussion of the content in question. You can find more information about how to use the commenting feature here [opens in a new tab] .
This site is protected by reCAPTCHA and the Google Privacy Policy [opens in a new tab] and Terms of Service [opens in a new tab] apply.