Skip to content

AI Drug Discovery: A Compute Pipeline from Molecule Generation to ADMET Prediction ​

Note: This is a review article (no first-hand experimental data), based on public literature and industry practice.

Experiment Objective ​

AI drug discovery is a typical industry where "AI-compute × scientific computing" meet: molecular dynamics (supercomputing) provides conformational data; generative models and ADMET prediction (AI-compute) provide candidates and screening; the two iterate in a loop. Goal: dissect a complete drug-discovery compute pipeline — molecular representation → generation → virtual screening (docking/dynamics) → ADMET prediction → wet-lab loop — clarifying the model type, compute footprint, and data source of each stage, plus how to engineer around the "pitfalls of virtual screening" (unreliable docking scores, data bias, public-benchmark overfitting).

Code Walkthrough ​

Part 1: Molecular representation and data loading ​

python
# RDKit: SMILES → graph/features (pipeline entry)
from rdkit import Chem
from rdkit.Chem import Descriptors, rdMolDescriptors

def smiles_to_features(smiles):
    mol = Chem.MolFromSmiles(smiles)
    if mol is None:
        return None                      # filter invalid SMILES immediately
    return {
        'n_atoms': mol.GetNumAtoms(),
        'mw': Descriptors.MolWt(mol),
        'logp': Descriptors.MolLogP(mol),        # lipophilicity
        'tpsa': rdMolDescriptors.CalcTPSA(mol), # polar surface area
        'rotb': rdMolDescriptors.CalcNumRotatableBonds(mol),
    }

Key points:

  1. SMILES is the entry; RDKit is the standard tool: a SMILES string encodes a molecule in one line; RDKit parses it and computes descriptors; MolFromSmiles returning None means dirty data — the pipeline's first job is filtering.
  2. Descriptors are "rule features": MW/logP/TPSA are classical QSAR features, complementary to deep-learning representations (graph/3D conformer) — good pipelines use both.
  3. Three molecular representation forms: string (SMILES, for generative models), graph (atoms/bonds, for GNNs), 3D conformer (for geometric models and docking) — each form maps to a model class; the pipeline must maintain three data views.

Part 2: Virtual screening and scoring ​

python
# Docking scoring (illustrative): ligand-target binding, commonly AutoDock/Vina
def docking_score(smiles, pdb_id):
    # Real docking: prepare ligand/receptor → search conformations → score function
    # Illustrated: binding free-energy approximation
    return -8.3   # kcal/mol level, illustrative

# Multi-stage funnel: rule(ADMET) → docking → dynamics
candidates = load_smiles('enumerated_library.csv')   # up to millions
rules_hit = [s for s in candidates if smiles_to_features(s)['logp'] < 5]
docked = sorted(rules_hit, key=docking_score)[:500]   # top 500 by docking
# Final 20-50 go to molecular dynamics refinement (supercomputing, expensive)

Key points:

  • Funnel screening: the candidate space converges from millions down step by step — rule filtering (seconds) → docking scoring (minutes) → molecular dynamics (days). Compute cost grows by orders of magnitude, so each stage only passes the top-ranked.
  • Docking scores are notoriously unreliable: score functions are approximations (cheap proxies of binding free energy); good for ranking, not for absolute values. Industry consensus: docking ranks and enriches, it does not judge absolutely.
  • Dynamics refinement is expensive but accurate: molecular dynamics (ch04's ML-potential technique) simulates binding stability, the computational verification closest to wet lab — but days of compute per molecule, so only for the final tens.

Principles ​

The four model classes and their compute profile ​

StageModel typeDataCompute profile
Molecule generationRNN/Transformer/diffusionknown-drug SMILES librariesAI-compute: heavy training, light inference
Property/ADMETGNN/Transformerpublic + proprietary labelsAI-compute: medium
Dockingscore functions/geometrytarget structuressupercomputing: parallel enumeration
Molecular dynamicspotentials (classical/ML)force fields/DFT datasupercomputing: heaviest

Clear dual-stack division: generation + ADMET (data-driven AI-compute) alternates with docking + dynamics (physics-driven supercomputing), forming a closed loop of "AI generates hypotheses → physics verifies → feedback corrects AI" — the concrete embodiment of "AI-compute × supercomputing reinforcement" in pharma.

Three pitfalls and engineering avoidance ​

  1. Data bias: public datasets (e.g. ChEMBL) skew toward known drug space; generated molecules lean into known chemistry — supplement with diversity rewards and proprietary data.
  2. Public-benchmark overfitting: many models "top-score" on MoleculeNet-style benchmarks yet generalize poorly — acceptance must use held-out sets and activity back-testing, not benchmark scores.
  3. Wet-lab loop cost: the endpoint of computational screening is wet lab; feedback (hit rates, activity) must flow back to training — a pipeline without the loop is just a "generator," not a "discovery engine."

Results ​

(Estimated, not measured; typical pipeline scale)

StageCandidatesPer-step timeCompute
Enumerated library10⁵-10⁷seconds/moleculeAI-compute GPU
Rule filtering~10-50% leftsecondsCPU fine
Docking scoring10³-10⁴ leftminutes/moleculesupercomputing parallel
Dynamics refinement20-50 leftdays/moleculesupercomputing heaviest
Wet-lab verification3-10 leftweeks-monthsexperiment

Engineering Takeaways ​

  1. Build the funnel before choosing models: fix the convergence ratios and compute budget of each screening stage first, then choose models — "how many can you screen" decides success before "how accurate the model is."
  2. Scores rank, never judge absolutely: treat docking/ADMET scores as ranking tools; absolute judgment belongs to dynamics and wet lab.
  3. Manage the three molecular views uniformly: SMILES/graph/3D conformer are different projections of the same molecule; keep the three views consistent (one ID system) or upstream/downstream data misaligns.
  4. The closed loop is the moat: wet-lab back-test data flowing back to training set and model updates is what separates an AI-drug pipeline from a "paper demo" — the data flywheel is worth more than the model itself.

Next article preview: the drug pipeline cannot live without quality data; next we build the foundation — "Scientific Data Pipelines: Engineering from Experimental Data to Training Sets."

AI-HPC Expert · Contact: openaihpc@gmail.com