Skip to content

RF Diffusion Contigmap Config

Builds a contigmap configuration JSON for RF Diffusion runs. It parses and validates string ranges describing which residues or secondary-structure regions to mask/unmask, and optionally the overall sequence length or length range.
Preview

Usage

Use this node to define advanced sequence/structure masking for RF Diffusion. Connect its output to the contigmap_config input of the RF Diffusion node. For unconditional generation, only set length and leave other fields empty. For conditional or inpainting workflows, specify inpaint_* and/or provide_seq ranges that align with your input structure.

Inputs

FieldRequiredTypeDescriptionExample
inpaint_seqTrueSTRINGResidue ranges whose sequence should be masked for inpainting. Use the same contig format (chains and ranges).A10-25,B5-12
inpaint_strTrueSTRINGResidue indices to mask in 3D structure space. Include chain IDs when applicable.B165-178
inpaint_str_helixTrueSTRINGResidue ranges to mask specifically for helix secondary structure.10-20,30-40
inpaint_str_strandTrueSTRINGResidue ranges to mask specifically for beta strand secondary structure.50-60,70-80
inpaint_str_loopTrueSTRINGResidue ranges to mask specifically for loop secondary structure.25-29,65-69
provide_seqTrueSTRINGResidue ranges to unmask (i.e., keep fixed/provided sequence) during design. Use inclusive ranges; multiple ranges can be comma-separated.172-177,200-205
lengthTrueSTRINGDesired total sequence length or length range for unconditional generation.100 or 100-150

Outputs

FieldTypeDescriptionExample
contigmap_configJSONValidated contigmap configuration object to pass into the RF Diffusion node.{"inpaint_seq": [["A",10,25],["B",5,12]], "inpaint_str": [["B",165,178]], "inpaint_str_helix": [[10,20],[30,40]], "inpaint_str_strand": [[50,60],[70,80]], "inpaint_str_loop": [[25,29],[65,69]], "provide_seq": [[172,177],[200,205]], "length": [100,150]}

Important Notes

  • Unconditional runs: Only set length; all other inpainting fields should be empty. The RF Diffusion node enforces this and will error if other fields are provided.
  • Conditional/inpainting runs: Provide proper chain-labeled ranges (e.g., A10-25) that align with your input structure.
  • Format validation: All fields except length are validated as contig/range lists; length is validated as a single length or a numeric range.
  • Index consistency: Ranges must correspond to actual residues in your input PDB when used with conditional or partial diffusion workflows.
  • Secondary structure masks: The helix/strand/loop masking fields target specific secondary structure classes and are optional.

Troubleshooting

  • Invalid range format: Ensure ranges use inclusive numeric spans with optional chain IDs (e.g., A10-25, 50-60). Separate multiple ranges with commas.
  • Error during unconditional generation: If you see errors about unexpected fields, clear inpaint_* and provide_seq, and only specify length.
  • Misaligned indices: If diffusion fails or results look incorrect, verify that the provided ranges match residues and chain IDs in the input PDB.
  • Empty configuration not applied: Leave fields blank (empty string) rather than placeholders; the node interprets empty as None.
  • Unexpected behavior with secondary structure masks: Confirm the ranges target the intended regions and avoid overlaps that contradict provide_seq.