Pipeline Steps
April 15, 2026 ยท View on GitHub
This document describes every step class under steps/ and how it is used by pipeline.py.
Execution Context
The pipeline imports and orchestrates these step classes:
PPIFlowStepMPNNStepAbMPNNStepFlowpackerStepAF3scoreStepFilterStepRosettaFixStepPartialStepReFoldStepDockQStepRosettaRelaxStepRankStepReportStep
1. PPIFlowStep
Purpose:
- Generates initial backbone structures with PPIFlow
- Supports
binder,antibody, andnanobodymodes
Back-end scripts:
tools/PPIFlow/sample_binder.pytools/PPIFlow/sample_antibody_nanobody.py
Main inputs:
gentypeoutput_dirmodel_weightsconfigname- Binder mode:
input_pdbtarget_chainbinder_chainspecified_hotspotssample_hotspot_rate_minsample_hotspot_rate_maxsamples_min_lengthsamples_max_lengthsamples_per_target
- Antibody/nanobody mode:
antigen_pdbantigen_chainframework_pdbheavy_chainlight_chainfor antibodycdr_lengthsamples_per_target
Used in pipeline:
- Stage 1 only
Typical output:
stage1/ppiflow_output
2. MPNNStep
Purpose:
- Runs ProteinMPNN sequence design for binder workflows
Supported protocols:
base: standard designbias: design with amino-acid biasfix: design with fixed positions
Back-end scripts:
tools/ProteinMPNN/helper_scripts/parse_multiple_chains.pytools/ProteinMPNN/helper_scripts/assign_fixed_chains.pytools/ProteinMPNN/helper_scripts/make_bias_AA.pytools/ProteinMPNN/helper_scripts/make_fixed_positions_dict.pytools/ProteinMPNN/protein_mpnn_run.py
Main inputs:
protocolfolder_with_pdbsoutput_dirnum_seq_per_targetsampling_tempbatch_sizechains_to_designomit_AAsuse_soluble_modelbias_AA_listandbias_listforbiasfixed_positionsforfix
Used in pipeline:
MPNNStep_stage1for binder stage 1MPNNStep_stage2for binder stage 2
Important behavior:
- Stage 2 automatically switches between
baseandfixdepending on whether fixed positions are found for a given partial sample.
Typical outputs:
stage1/mpnn_outputstage2/mpnn_output- FASTA files later collected into
mpnn_pdbs/mpnn_seqs.csv
3. AbMPNNStep
Purpose:
- Runs AbMPNN sequence design for antibody and nanobody workflows
Back-end scripts:
tools/AbMPNN/make_fix_csv.pytools/AbMPNN/protein_mpnn_run.py
Main inputs:
folder_with_pdbsoutput_dircheckpoint_dirmodel_namechain_listnum_seq_per_targetsampling_tempseedbatch_sizeomit_AAsfix_positions
Used in pipeline:
AbMPNNStep_stage1AbMPNNStep_stage2
Important behavior:
- Builds a
fixed_positions.csv - Can merge extra fixed positions passed from stage 2
Typical outputs:
stage1/abmpnn_outputstage2/abmpnn_output
4. FlowpackerStep
Purpose:
- Packs side chains for designed sequences based on
mpnn_seqs.csv
Back-end script:
tools/flowpacker/sampler_pdb_antibody.py
Main inputs:
config_pathoutput_dircsv_pathpdb_dirpython_executableuse_gt_masks
Used in pipeline:
FlowpackerStep_stage1FlowpackerStep_stage2
Expected upstream inputs:
pdb_dir: symlinked PDB directory assembled by the schedulercsv_path: generatedmpnn_pdbs/mpnn_seqs.csv
Typical output:
flowpacker_output/run_1
5. AF3scoreStep
Purpose:
- Evaluates structures with the AF3Score workflow
- Produces AF3-style metrics used for downstream filtering
Main inputs:
input_pdb_diroutput_dirdb_dirmodel_dirnum_workers
Typical internal workflow:
- Prepare single-chain CIF files and JSON inputs
- Convert PDB inputs to JAX/H5 representations
- Run AF3Score inference
- Collect metrics into CSV
Used in pipeline:
AF3scoreStep_stage1AF3scoreStep_stage2
Important output:
af3score_metrics.csv
6. FilterStep
Purpose:
- Filters structures according to numeric metric thresholds in a CSV file
- Creates symlinks for passing candidates into the next stage
Main inputs:
pdb_dircsv_fileoutdirfiltersoutput_csvfilename_col
Filter syntax:
- Exact numeric value:
iptm: 0.7
- Single rule string:
iptm: "> 0.7"
- Multiple rule string:
pae: "<= 10, > 1"
Used in pipeline:
FilterStep_stage1FilterStep_stage2
Important pipeline detail:
- The scheduler passes
filename_col="description"because AF3Score outputs use that column name for structure IDs.
Typical outputs:
stage1/filtered_iptm07stage2/filtered_iptm08
7. RosettaFixStep
Purpose:
- Runs Rosetta-based fix/relax preparation on filtered structures
- Extracts interface energy information that is later converted to fixed positions
Supported modes:
bindernanobodyantibody
Main inputs:
gentypeoutput_dirrosetta_binnative_xmlinterface_distplot_toggleoverwrite
Used in pipeline:
- Stage 2, before
PartialStep
Important outputs:
- Per-PDB Rosetta work directories
- Interface energy files used to generate
stage2/fixed_positions.csv
8. PartialStep
Purpose:
- Performs partial redesign guided by fixed positions generated from Rosetta analysis
Supported modes:
bindernanobodyantibody
Back-end scripts:
tools/PPIFlow/sample_binder_partial.pytools/PPIFlow/sample_antibody_nanobody_partial.py
Main inputs:
gentypepdb_dirfixed_positions_csvoutput_dirmodel_weightsconfigsamples_per_targetstart_t
Binder-specific parameters:
target_chainbinder_chainsample_hotspot_rate_minsample_hotspot_rate_max
Antibody/nanobody-specific parameters:
antigen_chainheavy_chainlight_chainretry_Limit
Used in pipeline:
- Stage 2 only
Important behavior:
- Loads per-PDB fixed positions from CSV
- Extracts hotspot-like residues from B-factors when needed
Typical output:
stage2/partial_output
9. ReFoldStep
Purpose:
- Refolds filtered stage 2 structures using an AlphaFold3-based workflow
Main inputs:
pdb_diroutput_diraf3_pythondb_dirmodel_dirhmmer_pathrun_MSAremove_templaterun_AF3_inferenceseed_numcuda_bincuda_libxla_client_mem_fraction
Workflow summary:
- Convert PDBs to FASTA
- Generate AF3 JSON jobs
- Run MSA/data preparation
- Optionally strip templates
- Run AF3 inference
- Export metrics
Used in pipeline:
- Stage 2 after
FilterStep_stage2
Important output:
af3_iptm@1.csvused later byRankStep
10. DockQStep
Purpose:
- Compares refolded models against the filtered reference complexes using DockQ
Main inputs:
reference_dirmodel_diroutput_csvdockq_exedockq_argsrecursive
Used in pipeline:
- Stage 2 after
ReFoldStep
Important output:
dockq_results.csv
Pipeline note:
- The scheduler first reformats refold outputs into a DockQ-friendly model directory structure.
11. RosettaRelaxStep
Purpose:
- Runs Rosetta complex relaxation on filtered stage 2 structures
Back-end script:
steps/rosetta/relax_complex.py
Main inputs:
pdb_diroutput_dirbatch_idxdump_pdb
Used in pipeline:
- Stage 2 after
FilterStep_stage2
Important output:
rosetta_complex_0.csvor another batch-indexed CSV, consumed byRankStep
12. RankStep
Purpose:
- Merges DockQ, Rosetta, and AF3 results
- Keeps the best model per target above a DockQ threshold
- Computes final ranking fields
- Copies selected PDBs into a final design output directory
Main inputs:
gentypedockq_csvrosetta_csvaf3_csvfiltered_pdb_diroutput_dirdockq_thresholdoutput_csv_name
Used in pipeline:
- Late Stage 2
Important outputs:
design_output/<output_csv_name>design_output/pdbs/
Ranking note:
- Binder mode ranks using
iptm - Antibody/nanobody mode looks for
iptm_A_Corchain_A_iptm
13. ReportStep
Purpose:
- Generates an HTML report for the final design set
Main inputs:
gentypenameoutput_dirstage1_dirstage2_diraf3score_stage1_csvaf3score_stage2_csvaf3_refold_csvranked_csvoutput_csv_namereport_filename
Used in pipeline:
- Final Stage 2 step
Report contents:
- Stage counts
- Metric histograms
- Top-ranked PDB viewer
- Ranked design table
Typical output:
design_output/design_report.html
Typical Step Chains
Binder
PPIFlowStep -> MPNNStep -> FlowpackerStep -> AF3scoreStep -> FilterStep -> RosettaFixStep -> PartialStep -> MPNNStep -> FlowpackerStep -> AF3scoreStep -> FilterStep -> ReFoldStep -> DockQStep -> RosettaRelaxStep -> RankStep -> ReportStep
Antibody / Nanobody
PPIFlowStep -> AbMPNNStep -> FlowpackerStep -> AF3scoreStep -> FilterStep -> RosettaFixStep -> PartialStep -> AbMPNNStep -> FlowpackerStep -> AF3scoreStep -> FilterStep -> ReFoldStep -> DockQStep -> RosettaRelaxStep -> RankStep -> ReportStep