๐Ÿ”ฅ A Symmetric Self-play Online Preference Optimization Framework for Protein Inverse Folding

May 6, 2026 ยท View on GitHub

SSP

๐Ÿ›๏ธ Installation:

  • 1.Download the source code in this repository.
  • 2.Download the weights of all SSP models at here or https://huggingface.co/XXX/SSP. For ESM3, we use the peft; for ESM-IF1, we use the minlora; for ProteinMPNN, we provide complete weights.
  • 3.Unzip all .zip packages.
  • 4.Prepare the environment. Please note that this environment is prepared for ESM3. If you need to use ProteinMPNN and ESM-IF1, please create their proprietary environment..
pip install requirements.txt

๐Ÿ” Inference

Once you have prepared the pdb/cif files, you can run the inference script directly.

$ python run_design.py \
          --pdb example/1a7l.A.pdb \
          --temperature 1 \
          --num_samples 10 \
          --lora_dir "YOUR LOCAL MODEL WEIGHT PATH" \
          --output "SAVE FASTA PATH" \
          --device cuda:0

โš”๏ธ Training

  • 1.Before starting the training, you should first generate the Structure Token.
  • 2.Configure your PDB, token, and weight path.
  • 3.Run the following command depend on the number of GPUs available to you.
bash run_ddp.sh NUM_GPU