Generic Interpretable Reaction Condition Predictions with Open Reaction Condition Datasets and Unsupervised Learning of Reaction Center

Xiaorui Wang, Chang‐Yu Hsieh, Xiaodan Yin, Jike Wang, Yuquan Li, Yafeng Deng, Dejun Jiang, Zhenhua Wu, Hongyan Du, Hongming Chen, Yun Li, Huanxiang Liu, Yuwei Wang, Pei Luo, Tingjun Hou, Xiaojun YaoResearch 2023

TL;DR

This paper introduces "Parrot," a novel Transformer-based model for predicting reaction conditions (catalysts, solvents, reagents, and temperature) in chemical synthesis. By creating new standardized datasets and leveraging unsupervised pretraining, Parrot achieves state-of-the-art accuracy and offers valuable interpretability, making it a significant step towards more reliable computer-aided synthesis planning.

What Problem Does This Paper Address?

Designing chemical syntheses often involves predicting the optimal "reaction conditions" (RCs) – the specific catalysts, solvents, reagents, and temperatures needed for a reaction to proceed efficiently. While deep learning (DL) has shown promise in predicting synthetic routes, most existing DL tools offer limited or no capability to recommend these crucial RCs. This gap is due to several challenges: a lack of standardized, open-source datasets for benchmarking RC prediction models, the difficulty in developing generalizable prediction models that can handle diverse reactions, and a general lack of interpretability in how these models arrive at their predictions. Without accurate RC prediction, even the best-predicted synthetic routes remain impractical.

Methods

The core of this work is the "Parrot" model, a Transformer-based architecture designed for predicting reaction conditions. Parrot employs a two-stage process:

  1. Feature Learning: It uses a BERT-like encoder to learn rich representations of chemical reactions directly from their SMILES strings. This encoder is pretrained using unsupervised learning techniques, including Masked Language Modeling (MLM) and a novel Masked Reaction Center Modeling (MRCM) approach, which helps the model learn domain-specific knowledge about chemical reactions.
  2. Condition Prediction: A Transformer decoder then uses these learned representations to predict the necessary reaction conditions. The model treats RC prediction as a causal multitask problem, predicting chemical context conditions (catalyst, solvents, reagents) sequentially and then predicting temperature via regression.

A key aspect of Parrot is its interpretability, achieved through attention mechanisms. The authors analyze how the model's attention weights correlate with crucial reaction centers and functional groups, providing insights into why certain RCs are predicted.

Datasets

The authors curated two new standardized reaction condition (RC) datasets:

  • USPTO-Condition: Derived from the USPTO patent database, this dataset contains approximately 680,000 reaction entries focusing on chemical context conditions (catalyst, solvents, reagents).
  • Reaxys-TotalSyn-Condition: Extracted from Reaxys, this dataset includes about 180,000 entries and crucially adds temperature information, making it more comprehensive.

These datasets are made publicly available to serve as benchmarks for future research.

Key Insights and Ideas

  • The Power of Pretraining for Chemistry: Unsupervised pretraining, especially with domain-specific objectives like Masked Reaction Center Modeling (MRCM), significantly boosts the performance of DL models for chemical tasks, even with limited labeled data.
  • Interpretable AI in Chemistry is Crucial: Simply predicting RCs isn't enough; understanding why a prediction is made is vital for chemists. Parrot's attention mechanisms provide this transparency, linking predictions to specific molecular substructures and reaction centers.
  • Standardized Benchmarks Drive Progress: The creation of open-source, standardized datasets like USPTO-Condition and Reaxys-TotalSyn-Condition is essential for fair comparison and accelerating research in the field.
  • Transformer Architecture Adapts Well: The Transformer architecture, with its attention mechanisms, proves highly effective for capturing complex relationships within chemical reaction data and predicting multiple reaction conditions simultaneously.

Key Results

Parrot demonstrates significant improvements over existing methods:

  • Accuracy Boost: Parrot achieved a top-3 prediction accuracy of up to 13.44% higher than the previous best model (RCR) on a newly curated dataset.
  • Temperature Prediction: The mean absolute error (MAE) for predicted temperatures was reduced by approximately 4 °C.
  • Generalization: The model shows strong generalization capabilities, performing well even on reactions outside its direct training distribution (cross-chemical-space prediction).
  • Interpretability: Attention analysis confirmed that Parrot effectively identifies crucial chemical information, including reaction centers and relevant functional groups, providing scientific insights.

Limitations and Future Work

The authors acknowledge several limitations:

  • Data Quality: The USPTO-Condition dataset, derived from patents, may have inherent data quality issues, particularly with temperature accuracy.
  • Rare Reactions: The datasets omit reactions with more than five RCs, potentially limiting the model's scope for highly complex conditions.
  • Data Dependency: Like other classification-based models, Parrot's performance relies heavily on the quality and coverage of the training data. Novel RCs not seen during training may pose challenges.

Future work includes integrating chemical reaction yield into prediction models, further enhancing the model's ability to handle complex RC combinations, and exploring the use of large language models (LLMs) to extract more RC data from scientific literature. The authors also plan to seamlessly integrate Parrot into existing synthesis planning algorithms to optimize entire synthesis routes.

Summary updated

BibTeX
@inproceedings{wang2023generic,
  author = {Xiaorui Wang and Chang‐Yu Hsieh and Xiaodan Yin and Jike Wang and Yuquan Li and Yafeng Deng and Dejun Jiang and Zhenhua Wu and Hongyan Du and Hongming Chen and Yun Li and Huanxiang Liu and Yuwei Wang and Pei Luo and Tingjun Hou and Xiaojun Yao},
  title = {{Generic Interpretable Reaction Condition Predictions with Open Reaction Condition Datasets and Unsupervised Learning of Reaction Center}},
  booktitle = {Research},
  year = {2023},
  doi = {10.34133/research.0231},
}
Figure