DEV.co
AI Frameworks · MolecularAI

REINVENT4

REINVENT4 is an AI-powered Python tool for generating and optimizing small molecules in drug discovery. It uses reinforcement learning and transfer learning to design molecules meeting specified chemical properties, supporting tasks like scaffold hopping and de novo design.

Source: GitHub — github.com/MolecularAI/REINVENT4
811
GitHub stars
221
Forks
Python
Primary language
Apache-2.0
License (OSI-approved)

Key facts

Objective fields from the source. Values we can't verify are shown as “Unknown” rather than guessed.

FieldValue
RepositoryMolecularAI/REINVENT4
OwnerMolecularAI
Primary languagePython
LicenseApache-2.0 — OSI-approved
Stars811
Forks221
Open issues3
Latest releasev4.8 (2026-06-16)
Last updated2026-06-22
Sourcehttps://github.com/MolecularAI/REINVENT4

What REINVENT4 is

REINVENT4 implements RL-driven molecular generation with multi-component scoring, transfer learning for prior training, and GPU acceleration (NVIDIA/AMD/Intel/Apple). It requires Python ≥3.11, runs on Linux (fully validated) with partial Windows/macOS support, and uses PyTorch with optional integrations like OpenEye ROCS and Chemprop v2.

Quickstart

Get the REINVENT4 source

Clone the repository and explore it locally.

terminalbash
git clone https://github.com/MolecularAI/REINVENT4.gitcd REINVENT4# follow the project's README for install & configuration

Need it deployed, integrated, or customized instead? DEV.co ships production installs.

Best use cases

De novo small molecule design with property constraints

Generate novel molecules from scratch optimized against multi-objective scoring (e.g., potency, selectivity, ADMET). RL-driven approach enables exploration of chemical space constrained by user-defined property profiles.

Scaffold hopping and R-group replacement

Leverage transfer learning on known actives to rapidly explore structural analogs maintaining desired properties while escaping existing IP space. Suitable for lead series expansion in drug discovery.

Linker design and molecule optimization

Optimize existing molecular scaffolds by replacing linkers or R-groups via RL-guided sampling. Use cases include improving drug-like properties or synthesizability while maintaining binding affinity.

Implementation considerations

  • GPU setup is critical path: PyTorch configuration must match OS driver (NVIDIA CUDA versions, AMD ROCm, Intel XPU, Apple MPS). Mismatch will cause silent fallback to CPU with dramatic slowdown.
  • Scoring component design dictates results quality. Default internal priors available via dot notation, but domain-specific objectives require custom Python plugins following @add_tag decorator pattern and namespace package conventions.
  • Configuration files (TOML/JSON/YAML) are mandatory; no Python API documented. Site-specific paths, model selection, and run mode (sampling vs. RL vs. TL) must be hand-authored from templates in /configs.
  • Transfer learning requires curated input molecule sets; pre-trained prior models are available on Zenodo but selection and fine-tuning strategy are user responsibility.
  • Jupyter notebooks provided in jupytext format; requires jupytext + mols2grid + seaborn for interactive exploration; conversion to standard .ipynb needed.

When to avoid it — and what to weigh

  • Rigorous regulatory compliance auditing required — No explicit information on validation pipelines, model reproducibility certifications, or FDA 21 CFR Part 11 compliance. Requires internal governance review before clinical-stage adoption.
  • Windows/macOS as primary production platform — Linux is the fully validated environment. Windows support is documented as 'less well tested' with 'limited support.' macOS GPU support depends on Apple Silicon adoption and has unspecified stability guarantees.
  • Immediate out-of-the-box inference at scale — Requires environment setup (conda/uv, PyTorch tuning for GPU/CPU, CUDA/ROCm/XPU compatibility), configuration file authoring (TOML/JSON/YAML), and custom scoring plugins for domain-specific objectives. Not a zero-config service.
  • Low computational overhead or CPU-only deployments — GPU strongly recommended, especially for transfer learning. CPU-only runs are possible but performance characteristics undefined. ~8 GB CPU/GPU memory typical; RL scoring offloaded to CPU may bottleneck.

License & commercial use

Apache License 2.0 (Apache-2.0). Permissive OSI-approved license allowing commercial use, modification, and distribution with standard Apache 2.0 terms (attribution, liability disclaimer, patent grant).

Apache 2.0 explicitly permits commercial use without runtime fees or license agreements. However, optional third-party dependencies (OpenEye ROCS) require separate commercial licenses. No internal constraints on derivative works or proprietary use; standard Apache 2.0 patent indemnity and IP clearance provisions apply. Internal governance should review if integrating proprietary scoring components or deploying as a commercial service.

DEV.co evaluation signals

Editorial assessment — not user reviews. Directional, with an explicit confidence level.

SignalAssessment
MaintenanceActive
DocumentationAdequate
License clarityClear
Deployment complexityHigh
DEV.co fitGood
Assessment confidenceHigh
Security considerations

No explicit security audit, threat model, or vulnerability disclosure process documented. Python dependencies and PyTorch versions inherit upstream security posture; pin versions per your governance. CLI accepts arbitrary TOML/JSON/YAML and environment variables (dotenv file); validate configuration inputs if accepting untrusted user configurations. No mention of code signing, reproducible builds, or container image provenance.

Alternatives to consider

DeepChem (UC Berkeley, OSS)

General-purpose deep learning for molecular property prediction and generation. Broader ML toolkit but less specialized for de novo design workflows; weaker RL/TL integration.

RDKit + custom RL (in-house)

RDKit for cheminformatics + DIY PyTorch/TensorFlow RL loop. Full control but requires internal expertise; slower to production than pre-built REINVENT4.

Proprietary/SaaS tools (e.g., Schrödinger, Exscientia platforms)

Managed, validated, with commercial support. Higher cost and vendor lock-in; less transparency than open-source REINVENT4.

Software development agency

Build on REINVENT4 with DEV.co software developers

REINVENT4 is a battle-tested, Apache 2.0-licensed platform backed by Astra Zeneca research. Start with our tutorials and pre-trained models on Zenodo. Contact us to discuss integration into your drug discovery workflow.

Talk to DEV.co

Related open-source tools

Surfaced by semantic similarity across the DEV.co open-source index.

Related on DEV.co

Explore the category and the services that help you build with it.

REINVENT4 FAQ

Do I need a GPU?
Not strictly required, but GPU is strongly recommended. Transfer learning and model training benefit significantly. RL scoring runs on CPU by default, so RL workflows are less GPU-dependent than TL. Code auto-falls back to CPU if no GPU detected.
Which GPUs are supported?
NVIDIA (CUDA), AMD (ROCm), Intel ARC (XPU), and Apple Silicon (MPS) as of this release. Requires PyTorch-compatible driver and toolkit version matching your OS/hardware. CUDA version must align with NVIDIA driver.
Can I use REINVENT4 on Windows or macOS?
Yes, but with caveats. Linux is fully validated. Windows support is less well tested with limited support. macOS GPU support depends on Apple chip; stability not explicitly guaranteed. Production deployments should assume Linux.
How do I add custom scoring objectives?
Write Python scoring component plugins in /reinvent_plugins/components/ using @add_tag decorator. Namespace package convention (no __init__.py in top dirs). Plugins are auto-discovered; no core REINVENT code modification needed.

Custom software development services

DEV.co is a software development agency delivering custom software development services to companies building on open source. Our software developers and web developers design, integrate, and ship production systems — spanning web development, APIs, AI, data, and cloud. If REINVENT4 is part of your ai frameworks roadmap, our team can implement, customize, migrate, and maintain it.

Ready to accelerate your molecular design pipeline?

REINVENT4 is a battle-tested, Apache 2.0-licensed platform backed by Astra Zeneca research. Start with our tutorials and pre-trained models on Zenodo. Contact us to discuss integration into your drug discovery workflow.