Skip to main content
Docs

Search guides and API endpoints, for example “Idempotency-Key” or “submit job”.

    Tools · Computational Biology

    DrugFlow

    Generate candidate ligands from a protein target and reference ligand using flow matching
    On this page

    Prices, workflows, and method papersOpen in the app

    Run it from the API

    Submit with Submit a job and the job_type below. Price it first with Estimate job reservation cost: submitting reserves that amount from your wallet, and the charge settles at the actual runtime.

    DrugFlow drugflow

    Job type
    drugflow
    Hardware
    t4 (default)l4a10l40sa100-40gba100-80gbh100h200b200
    Typical runtime
    15 min on Nvidia T4

    Payload

    Payload fields
    FieldTypeDescription
    proteinrequiredfile_object
    protein.namestring

    Limits: min length 1

    protein.filenamestring

    Limits: min length 1

    protein.content_b64string

    Limits: min length 1

    protein.contentany
    protein.bytesany
    reference_ligandrequiredfile_object
    reference_ligand.namestring

    Limits: min length 1

    reference_ligand.filenamestring

    Limits: min length 1

    reference_ligand.content_b64string

    Limits: min length 1

    reference_ligand.contentany
    reference_ligand.bytesany
    checkpointstring

    Default: "drugflow"One of: "drugflow", "drugflow_ood", "flexflow", "drugflow_pa_comb"

    n_samplesinteger

    Default: 10Limits: ≥ 1

    batch_sizeinteger

    Default: 1Limits: ≥ 1

    pocket_distance_cutoffnumber

    Default: 8Limits: > 0

    molecule_sizeinteger | string
    n_stepsinteger | null

    Limits: ≥ 1

    seedinteger

    Limits: ≥ 0

    drugflow_argsobject
    drugflow_args.seedinteger

    Limits: ≥ 0

    File fields take {"name": "x.pdb", "content_b64": "…"} or a stored artifact, {"$artifact": {"id": "art-…", "port": "…"}}. Files are up to 25 MiB each.

    Example

    from cognichem_client import CogniChem
    
    client = CogniChem.from_env()  # reads COGNICHEM_API_KEY
    payload = {
        "protein": {
            "name": "protein.pdb",
            "content_b64": "<file contents, base64>",
        },
        "reference_ligand": {"name": "ligand.sdf", "content_b64": "<file contents, base64>"},
        "n_samples": 1,
        "batch_size": 1,
        "checkpoint": "flexflow",
    }
    
    estimate = client.jobs.estimate(job_type="drugflow", payload=payload, resource="t4")
    print(f"Reserves ${estimate.cost:.2f}")
    
    job = client.jobs.submit(
        job_name="my-drugflow-run",
        job_type="drugflow",
        payload=payload,
        resource="t4",
    )
    status = client.jobs.wait(job.process_id)
    if status.status == "completed":
        client.jobs.result(job.process_id, save_path=".")

    Sample data from the job catalog; long values are shortened here. Each job_name must be unique among your jobs.

    Workflow inputs

    • Protein structurePDB
    • MoleculesSDF

    Workflow outputs

    • ArchiveZIP
    • MoleculesSDF