AfDesign
v1.1.3Protein design by backpropagation through AlphaFold
AlphaFold is differentiable. AfDesign uses that to design a protein backwards: it starts from a random sequence, asks AlphaFold what it would fold into, and moves the sequence along the gradient of a loss such as high pLDDT, low PAE, many contacts, or a match to a backbone you supply. The result is a sequence and the structure AlphaFold predicts for it.
This page covers the AfDesign notebooks of the ColabDesign project (release v1.1.3) on one page with a task selector. Hallucination generates a protein of a chosen length. Fixed backbone design searches for a sequence that folds into a backbone you provide. Partial hallucination keeps positions of a structure and hallucinates the rest, with optional rewiring of the kept segments.
Disulfide design hallucinates a sequence around a random pattern of cysteine pairs. For the sequence design step that most pipelines use instead of fixed backbone design, see ProteinMPNN, and for cyclic peptides use AfCycDesign.
AfDesign is billed by the minute of runtime: 15 credits per minute on an NVIDIA T4 GPU. Completed runs are charged in proportion to elapsed time, rounded up to a whole credit, with a minimum charge of 20 credits, so a run of up to 80 seconds costs 20. A run that fails is not charged, and unused reserved credits are returned. Set a spending limit before submission.
The quote before submission is an estimate from the task, the number of residues and the iteration counts. The final charge follows the measured runtime. The table uses the default iterations of each task: 100 pre-design, 50 soft, 50 temperature and 10 hard for hallucination, 50 soft, 50 temperature and 10 hard for disulfide design, and 300 soft, 100 temperature and 10 hard for fixed backbone design and partial hallucination.
| Residues | Hallucination | Fixed backbone | Partial hallucination | Disulfide design |
|---|---|---|---|---|
| 35 | 31 | 44 | 44 | 24 (default) |
| 50 | 41 | 63 | 63 | 30 |
| 100 | 124 (default) | 212 | 212 | 80 |
| 150 | 286 | 503 | 503 | 178 |
| 200 | 537 | 954 | 954 | 329 |
| 300 | 1,338 | 2,393 | 2,393 | 811 |
Residues are the Length for hallucination and disulfide design, the residues of the selected chain for fixed backbone design, and the Total length for partial hallucination, or the residues of the input structure when that is blank. Cost grows faster than the length, so a 200-residue hallucination costs about four times as much as a 100-residue one.
Each hard iteration costs five times as much as the others because it evaluates five AlphaFold models. Hallucination with Copies is quoted for the residues of all copies together, so two copies of 100 residues quote 537 credits, the same as one chain of 200. The loss weights, the contact settings, the partial hallucination positions and rewiring options, and Random seed do not change the quote.
| Input | Tasks | Accepted | Description |
|---|---|---|---|
Input structure | Fixed backbone, Partial hallucination | .pdb, .ent, or a PDB ID fetched from RCSB, up to 50 MiB | The backbone to design for, or the structure whose positions are kept. Only the first model of the file is read. |
Hallucination and Disulfide design take no structure.
| Parameter | Type | Default | Description |
|---|---|---|---|
Task | enum | Hallucination | Hallucination, Fixed backbone, Partial hallucination or Disulfide design. Chosen with the Task cards above the inputs. |
Chain | string | blank | Fixed backbone and partial hallucination. Chain to use, such as A. Blank uses every chain. |
Length | integer | 100 | Hallucination. Number of residues. |
Copies | integer | 1 | Hallucination. Number of identical copies of the sequence; more than 1 designs a homo-oligomer. |
Positions to constrain | string | blank | Partial hallucination. Positions of the input structure to keep, in its numbering, such as 4-9,13-26. Blank keeps every position. |
Total length | integer | blank | Partial hallucination. Length of the designed protein when it differs from the input. |
Fix the sequence | boolean | off | Partial hallucination. Keeps the sequence of the constrained positions. |
Use templates | boolean | off | Partial hallucination. Constrains the positions with the template input. |
Segment order | string | blank | Partial hallucination. Zero-based order of the kept segments after rewiring, such as 1,2,3,0,7,4,5,6. |
Loop lengths | string | blank | Partial hallucination. Loop length between each pair of neighbouring segments, such as 3,3,3,4,3,3,4. |
N-terminal offset | integer | blank | Partial hallucination. Loop length at the N terminus. |
Start from the input sequence | boolean | off | Partial hallucination. Initialises the kept positions with the input sequence. |
Length | integer | 35 | Disulfide design. Number of residues. |
Disulfide pairs | integer | 3 | Disulfide design. Cysteine pairs placed at random, more than five residues apart. |
Random seed | string | blank | Whole number from 0 to 4294967295. Blank draws a new seed each run. |
Rewiring happens only when Segment order, Loop lengths or N-terminal offset is set. Leaving all three blank keeps the segments where the input structure has them.
| Parameter | Type | Default | Description |
|---|---|---|---|
PAE weight | number | 0.1 | One of 0.01, 0.1, 0.5, 1.0. |
pLDDT weight | number | 0.1 | One of 0.01, 0.1, 0.5, 1.0. |
Contact weight | number | 1.0 | One of 0.01, 0.1, 0.5, 1.0. |
Minimum sequence separation | integer | 9 | One of 0, 5, 9. Only contacts between residues at least this far apart in sequence count. |
Contact cutoff | enum | 14 Å | 8 Å, 14 Å or Maximum (21.6875 Å), measured between Cβ atoms. |
Contacts per position | enum | 2 | 1, 2, 4, 8 or Maximum (the sequence length). |
Binary contacts | boolean | off | Counts a contact as present or absent. |
Minimising PAE or maximising pLDDT alone often produces a single helix, which is why the notebook optimises a number of contacts per position instead.
| Parameter | Type | Default | Description |
|---|---|---|---|
Restraint weight | number | 1.0 | Weight of the distogram restraint on the kept positions. |
Hallucination weight | number | 1.0 | Weight of the contact loss that hallucinates the rest. The notebook example sets 0. |
| Parameter | Type | Default | Description |
|---|---|---|---|
Pre-design iterations | integer | 100 | Hallucination. Softmax pre-design from a Gumbel-initialised sequence. |
Soft iterations | integer | 50 for hallucination and disulfide design, 300 for fixed backbone and partial hallucination | Iterations that turn the sequence logits into a softmax. |
Temperature iterations | integer | 50 for hallucination and disulfide design, 100 for fixed backbone and partial hallucination | Iterations that sharpen the softmax toward one-hot. |
Hard iterations | integer | 10 | Iterations with one-hot sequences. The result comes from the lowest-loss iteration of this stage. |
| File | Description |
|---|---|
hallucination.pdb, fixbb.pdb or partial.pdb | The best structure, with pLDDT in the B-factor column. Disulfide design writes hallucination.pdb. |
sequences.fasta | The designed sequence. |
scores.json | The model's log for the structure you received, with the designed sequence. |
trajectory.json | The log of every optimisation step. |
trajectory.png | Fixed backbone and partial hallucination. RMSD to the input and sequence identity over the run. |
animation.html | The trajectory as a video, except for disulfide design. |
disulfide_pattern.json | Disulfide design. The cysteine pairs chosen at random (zero-based) and the sequence pattern that seeded the design. |
provenance.json, run.log | Settings, source release, library versions and the run log. |
The scores in scores.json keep the library's units.
plddt runs from 0 to 1. Multiply by 100 for the usual pLDDT scale.pae is the predicted aligned error as a fraction of AlphaFold's 31 angstrom maximum. Multiply by 31 for angstroms, and see PAE for how to read it.ptm is the predicted TM-score, a score for the arrangement of the whole chain.con is the contact loss, which the optimiser lowers to pull residues into contact.loss is the weighted sum the run minimised. It changes with the task and the weights, so compare losses only between runs with the same settings.rmsd and dgram_cce appear for fixed backbone design and partial hallucination. They measure how closely AlphaFold's output follows the structure you supplied.pLDDT is a local score, while pae and ptm describe how the parts of the chain sit relative to each other. A design needs good values in all three. The standard pLDDT bands apply: above 90 (0.9 in scores.json) is very high confidence and 70 to 90 is confident. A hallucinated sequence is optimised to raise pLDDT, so a high value there is expected and is weaker evidence than the same value on a sequence AlphaFold was not tuned for.
Hallucination of 100 residues with default settings and random seed 0 returns a protein with plddt 0.92, pae 0.137, which is 4.2 angstroms, ptm 0.72 and loss 1.66. With the default weights, the loss is 0.1 * pae + 0.1 * (1 - plddt) + 1.0 * con. The contact term con is 1.63 and makes up almost all of the loss, while the pLDDT and PAE terms add 0.02 between them. The pLDDT is in the very high band, and the mean PAE of 4.2 angstroms and pTM of 0.72 say that the arrangement of the chain is less certain than its local geometry.
plddt and a low pae only say that AlphaFold is confident in it, not that it folds.rmsd shows that AlphaFold reproduces your structure from the designed sequence, and it does not require the sequence to resemble the native one.disulfide_pattern.json records the pairs each run used. The notebook's optional PyRosetta side-chain refinement is not part of this tool.design.ipynb, hallucination.ipynb, partial_hallucination_rewire.ipynb and disulfide_design.ipynb. Code under the Beer-Ware licence.All-atom SE(3)-equivariant diffusion for unconditional generation, motif scaffolding, and binder design.
De novo protein design by relaxed sequence optimisation
Design all-atom protein binders with controlled target sites, lengths, and interaction parameters.
Family-conditioned protein sequence generation from FASTA, A2M, or A3M input
Generate de novo protein sequences from plain-text prompts with sampling controls.
Design proteins from a text description
Design antibody CDRs with Proteo-R1 reasoning, diffusion, and optional framework inpainting.
Optimize protein binder, cyclic peptide and ligand binder designs with RF3, Boltz-2 and MPNN
Cyclic peptide design with AlphaFold
Learn from measured fitness and prioritize protein variants.