Skip to main content

    Workflow Recipes

    Step-by-step drug discovery tutorials combining multiple CLI commands into complete workflows.

    recipestutorialsdrug-discoveryworkflowdockingadmet

    These recipes chain multiple CLI commands into complete, end-to-end drug discovery workflows — from structure prediction and docking to library screening. Reach for them when you want a worked, copy-and-adapt example rather than piecing commands together yourself, and when you're ready to turn a workflow into a reproducible script or CI/CD pipeline. Every step runs on the same backend and job history as the rest of the CLI, so intermediate results carry forward across commands. For the full command set, see the CLI overview.

    Difficulty

    intermediate

    Workflow Recipes

    Step-by-step drug discovery tutorials combining multiple CLI commands into complete workflows.


    Recipe 1: Structure-Based Drug Discovery

    Start from a protein sequence, predict its structure, prepare it for docking, find binding sites, dock a ligand, and evaluate drug-likeness.

    Sequence → ESMFold → ProteinPrep → Sites → DiffDock → ADMET
    ivybloom run esmfold protein_sequence=MKLVFFAEDVGSNKGAIIGLMVGGVVIA --follow

    Output:

    Job submitted: job_fold_001
    Status: pending → running → completed (2m 15s)
    pLDDT: 87.3 (Good confidence)

    Download the predicted structure:

    ivybloom jobs download job_fold_001 --output ./structures/
    ivybloom proteinprep run ./structures/predicted_structure.pdb \
      --ph 7.4 \
      --detect-sites \
      --wait

    Output:

    Quality check: PASSED (no missing atoms, no clashes)
    Hydrogens added: 1,234
    Binding sites detected: 3
    ivybloom proteinprep sites ./structures/predicted_structure.pdb \
      --method p2rank \
      --top-n 3

    Output:

    Site 1: Score 0.92, Center (12.3, 45.6, 78.9), Volume 823 ų
    Site 2: Score 0.78, Center (34.5, 67.8, 12.3), Volume 615 ų
    Site 3: Score 0.61, Center (56.7, 89.0, 34.5), Volume 498 ų
    ivybloom run diffdock \
      receptor=./structures/prepared.pdb \
      ligand="CC(=O)Oc1ccccc1C(=O)O" \
      --follow
    ivybloom run admet smiles='CC(=O)Oc1ccccc1C(=O)O' --follow

    Output:

    Absorption: High intestinal absorption (94%)
    Distribution: BBB penetrant
    Metabolism: Low CYP inhibition
    Excretion: t½ = 3.2h
    Toxicity: Low risk (ProTox class IV)

    Recipe 2: Ligand-Based Lead Optimization

    Generate new molecular candidates based on a lead compound, evaluate their properties, and dock the best ones.

    Lead SMILES → GenMol → ADMET Filter → Dock Top Hits
    ivybloom orchestrate "Generate 50 molecules similar to aspirin (CC(=O)Oc1ccccc1C(=O)O) with improved solubility" --sync

    Or via direct tool submission:

    ivybloom run genmol \
      seed_smiles="CC(=O)Oc1ccccc1C(=O)O" \
      num_molecules=50 \
      --follow

    Create a batch file admet-screen.yaml:

    name: "Lead Optimization ADMET"
    tool: admet
    jobs:
      - name: "candidate-1"
        parameters: { smiles: "GENERATED_SMILES_1" }
      - name: "candidate-2"
        parameters: { smiles: "GENERATED_SMILES_2" }
    options:
      parallel: 8
      stop_on_error: false
    ivybloom batch submit admet-screen.yaml --wait
    ivybloom batch collect BATCH_ID --format csv --output admet-results.csv

    Filter the ADMET results for drug-like compounds, then dock them:

    # Dock each hit against the target
    ivybloom run diffdock \
      receptor=target.pdb \
      ligand="TOP_HIT_SMILES" \
      --follow

    Recipe 3: Target Validation

    Validate a protein target by checking sequence conservation, predicting structure, and analyzing binding site druggability.

    Sequence → BLAST → ESMFold → ProteinPrep → Quality → Sites
    ivybloom run blast \
      query_sequence=MKLVFFAEDVGSNKGAIIGLMVGGVVIA \
      database=nr \
      --follow

    Review homologs and conservation scores to confirm the target is well-conserved across species.

    ivybloom run esmfold \
      protein_sequence=MKLVFFAEDVGSNKGAIIGLMVGGVVIA \
      --follow

    Check the pLDDT score — values above 70 indicate reliable structure prediction.

    ivybloom proteinprep quality ./predicted_structure.pdb

    Verify no missing atoms, clashes, or unusual residues.

    ivybloom proteinprep sites ./predicted_structure.pdb \
      --method p2rank \
      --top-n 5 \
      --min-score 0.6

    Sites with scores above 0.8 are considered highly druggable.


    Recipe 4: Compound Library Screening

    Import a compound library, screen it through ADMET, and export the filtered hits.

    CSV Import → Batch ADMET → Filter → Export Hits
    # Create a collection
    ivybloom compounds create "Vendor Library" --description "2024 vendor catalog"
    
    # Import compounds from CSV
    ivybloom compounds import COLL_ID library.csv --skip-duplicates

    Supported formats: CSV, SDF, SMILES. A CSV file needs a smiles column. The ivybloom mcp import tool also accepts smiles_column and name_column for non-standard headers.

    Export the library to a format suitable for batch processing:

    ivybloom compounds export COLL_ID --format csv --output library-export.csv

    Create screen.yaml:

    name: "Library ADMET Screen"
    tool: admet
    jobs:
      - name: "compound-001"
        parameters: { smiles: "CCO" }
      - name: "compound-002"
        parameters: { smiles: "CC(=O)Oc1ccccc1C(=O)O" }
    options:
      parallel: 8
      stop_on_error: false
    ivybloom batch submit screen.yaml --wait

    Monitor progress:

    ivybloom batch status BATCH_ID
    # Collect all results
    ivybloom batch collect BATCH_ID --format csv --output admet-results.csv
    
    # Create a new collection with hits
    ivybloom compounds create "ADMET Hits" --description "Drug-like compounds from vendor screen"

    Running Recipes as Scripts

    Any recipe can be converted into a shell script for automation:

    #!/bin/bash
    set -euo pipefail
    
    export IVYBLOOM_API_KEY="${IVYBLOOM_API_KEY:?Set IVYBLOOM_API_KEY}"
    
    # Fold → Prep → Dock pipeline
    FOLD_RESULT=$(ivybloom run esmfold protein_sequence="$SEQUENCE" --agent --wait)
    FOLD_JOB=$(echo "$FOLD_RESULT" | jq -r '.data.job_id')
    ivybloom jobs download "$FOLD_JOB" --output ./structures/
    
    ivybloom proteinprep run ./structures/predicted_structure.pdb \
      --ph 7.4 --detect-sites --wait
    
    ivybloom run diffdock \
      receptor=./structures/prepared.pdb \
      ligand="$LIGAND_SMILES" \
      --agent --wait

    See Agent Mode for structured JSON output in scripts.


    Was this page helpful?

    On this page

    On this page

    Loading...