PPIFlow Pipeline
June 18, 2026 · View on GitHub
Update
- Fix
RankSteprank_socore bug. issue - Fix
MPNNStep_stage2key residue merge bug. issue - Add support for Binder design with motif scaffolding. issue

This repository provides a two-stage protein design pipeline built around PPIFlow. It supports three design modes:
binderantibodynanobody
The pipeline orchestrates structure generation, sequence design, side-chain packing, AF3score scoring, filtering, partial redesign, AF3 refolding, ranking, and report generation through pipeline.py.
For a given design task, the pipeline generates a directory named design_output, which contains the PDB files of the designed structures, sequences, computed evaluation metrics for each design, and a design report. See Design Demo.
See tool/PPIFlow/README.md for PPIFlow only.
Environment Installation
git clone https://github.com/Mingchenchen/PPIFlow.git
cd PPIFlow
bash Install.sh
# Install Rosetta
wget https://downloads.rosettacommons.org/downloads/academic/2024/wk09/rosetta.binary.linux.release-371.tar.bz2
tar -xvf rosetta.binary.linux.release-371.tar.bz2
Download the PPIFlow checkpoints from Google Drive
| Task Type | Checkpoint Path |
|---|---|
| Binder | binder.ckpt |
| Antibody | antibody.ckpt |
| Nanobody | nanobody.ckpt |
| Monomer or Motif Scaffolding | monomer.ckpt |
Pipeline Overview
pipeline.py reads two YAML files:
task.yaml: task-level metadata, input structures, generation mode, output location, and step enable/disable switchessteps.yaml: executable paths and per-step parameters
The scheduler always creates:
output_base_dir/stage1output_base_dir/stage2
and can run either stage independently or both stages in sequence.
Stage 1
Typical Stage 1 flow:
PPIFlowStepMPNNStep_stage1orAbMPNNStep_stage1FlowpackerStep_stage1AF3scoreStep_stage1FilterStep_stage1
Stage 2
Typical Stage 2 flow:
RosettaFixStepPartialStepMPNNStep_stage2orAbMPNNStep_stage2FlowpackerStep_stage2AF3scoreStep_stage2FilterStep_stage2ReFoldStepDockQStepRosettaRelaxStepRankStepReportStep
The exact order and output directories are implemented directly in pipeline.py.
Run pipeline.py
Full run
python pipeline.py --task example/task_binder.yaml --steps example/steps_config/steps_binder.yaml
Before running the pipeline, you need to download the Flowpacker model weights(Flowpacker), AF3 model weights and database(AlphaFold3). Many paths in the example steps.yaml files must be replaced with your local paths.
Note
-
The pipeline runs on a single GPU.
For large-scale inference, it is recommended to perform batch processing across multiple GPUs, with each GPU handling approximately 1000–2000 designs. -
The following steps(Stage 2) are CPU-intensive and time-consuming:
ReFoldStep (MSA)DockQStepRosettaRelaxStep
To accelerate computation, it is recommended to run these steps separately on high-performance CPUs.
Stage 1 only
python pipeline.py \
--task example/task_binder.yaml \
--steps example/steps_config/steps_binder.yaml \
--stage 1
Stage 2 only
python pipeline.py \
--task example/task_binder.yaml \
--steps example/steps_config/steps_binder.yaml \
--stage 2
CLI arguments:
--task: path to task configuration YAML--steps: path to step configuration YAML--stage: optional;1or2
If --stage is omitted, the pipeline runs both stages.
task.yaml Configuration
task.yaml contains two top-level sections:
tasksteps
task stores run metadata and biological inputs. steps is a map of booleans that enables or disables each pipeline step inside the scheduler.
Minimal Structure
task:
name: "example"
gentype: "binder"
output_base_dir: "./outputs/example"
steps:
PPIFlowStep: true
MPNNStep_stage1: true
FlowpackerStep_stage1: true
AF3scoreStep_stage1: true
FilterStep_stage1: true
RosettaFixStep: false
PartialStep: false
MPNNStep_stage2: false
FlowpackerStep_stage2: false
AF3scoreStep_stage2: false
FilterStep_stage2: false
ReFoldStep: false
DockQStep: false
RosettaRelaxStep: false
RankStep: false
ReportStep: false
Common task Fields
name: run name used as the design prefixgentype: one ofbinder,antibody,nanobodyoutput_base_dir: root output directory for this runsamples_per_target: number of structures sampled by PPIFlowspecified_hotspots: optional comma-separated hotspot residues such asB67,B78,B99
Binder-Specific Fields
These are consumed by PPIFlowStep when gentype: binder:
input_pdb: input complex PDBtarget_chain: target protein chain ID in input_pdbbinder_chain: binder chain ID in input_pdb (remove this filed for target chain only)sample_hotspot_rate_minsample_hotspot_rate_maxsamples_min_lengthsamples_max_length
Example:
task:
name: "CD3d"
gentype: "binder"
input_pdb: "example/target_and_framework_pdb/CD3d.pdb"
target_chain: "B"
binder_chain: "A"
specified_hotspots: "B67,B78,B99"
samples_min_length: 50
samples_max_length: 60
samples_per_target: 10000
output_base_dir: "../test_pipeline_binder"
Antibody-Specific Fields
These are used when gentype: antibody:
antigen_pdbantigen_chainframework_pdbheavy_chainlight_chaincdr_length
Example:
task:
name: "IL13"
gentype: "antibody"
antigen_pdb: "example/target_and_framework_pdb/1IJZ_IL13.pdb"
antigen_chain: "C"
specified_hotspots: "C10,C13,C14,C100,C106,C107"
framework_pdb: "example/target_and_framework_pdb/6nou_scfv_framework.pdb"
heavy_chain: "A"
light_chain: "B"
cdr_length: "CDRH1,8-8,CDRH2,8-8,CDRH3,10-20,CDRL1,6-9,CDRL2,3-3,CDRL3,9-11"
samples_per_target: 10
output_base_dir: "../test_pipeline_antibody"
Nanobody-Specific Fields
These are used when gentype: nanobody:
antigen_pdbantigen_chainframework_pdbheavy_chaincdr_length
Example:
task:
name: "IL13"
gentype: "nanobody"
antigen_pdb: "example/target_and_framework_pdb/1IJZ_IL13.pdb"
antigen_chain: "C"
specified_hotspots: "C10,C13,C14,C100,C106,C107"
framework_pdb: "example/target_and_framework_pdb/7eow_nanobody_framework.pdb"
heavy_chain: "A"
cdr_length: "CDRH1,8-8,CDRH2,8-8,CDRH3,9-21"
samples_per_target: 10
output_base_dir: "../test_pipeline_nanobody"
steps.yaml Configuration
steps.yaml stores per-step runtime parameters and external tool paths. The scheduler loads one config block per step name and passes it into the corresponding step class.
Recommended Pattern
Start from one of:
example/steps_config/steps_binder.yamlexample/steps_config/steps_antibody.yamlexample/steps_config/steps_nanobody.yaml
These files show the expected keys for each design mode.
See steps/README.md for a step-by-step description of every pipeline component.
Output Directories
The scheduler uses fixed directory names under output_base_dir. The main layout is documented in the file header of pipeline.py, including:
stage1/ppiflow_outputstage1/mpnn_pdbsstage1/mpnn_outputorstage1/abmpnn_outputstage1/flowpacker_outputstage1/af3score_outputstage1/filtered_iptm07stage2/rosetta_fix_outputstage2/fixed_positions.csvstage2/before_partial_pdbsstage2/partial_outputstage2/mpnn_pdbsstage2/mpnn_outputorstage2/abmpnn_outputstage2/flowpacker_outputstage2/af3score_outputstage2/filtered_iptm08stage2/refold_outputstage2/dockq_outputstage2/rosetta_relax_outputdesign_output
Notes
- Stage 2 expects Stage 1 outputs unless you manually prepare the required intermediate files.
- Many paths in the example
steps.yamlfiles must be replaced with your local paths. - The repository examples are the best starting templates for new runs.
Cite
@article {yu2026ppiflow,
author = {Yu, Qilin and Guo, Liangyue and Qin, Xiayan and Huang, Xikun and Tian, Baihui and Wang, Hongzhun and Liu, Yu and Lang, Yunzhi and Wang, Di and Shen, Zhouhanyu and Lin, Jie and Chen, Mingchen},
title = {High-Affinity Protein Binder Design via Flow Matching and In Silico Maturation},
year = {2026},
doi = {10.64898/2026.01.19.700484},
journal = {bioRxiv}
}