Documentation Index
Fetch the complete documentation index at: https://mintlify.com/google-deepmind/alphafold3/llms.txt
Use this file to discover all available pages before exploring further.
Overview
Thefolding_input module defines the data structures for AlphaFold 3 inputs, including protein chains, RNA chains, DNA chains, ligands, and templates. It handles JSON serialization/deserialization and mmCIF conversion.
Input Class
Main dataclass representing an AlphaFold 3 prediction input.The name of the target structure.
List of molecular chains (protein, RNA, DNA, or ligands).
Random number generator seeds, one for each model execution. Must have at least one seed.
List of bonded atom pairs. Each atom defined by
(chain_id, res_id, atom_name). Residue IDs are 1-indexed.User-defined chemical component dictionary in CIF format for custom ligands.
Properties
Filtered list of protein chains only.
Filtered list of RNA chains only.
Filtered list of DNA chains only.
Filtered list of ligands only.
Class Methods
from_json
alphafold3 and alphafoldserver dialects.
JSON string in AlphaFold 3 format.
Path to JSON file for resolving relative paths.
from_mmcif
mmCIF formatted structure string.
Chemical components dictionary.
from_alphafoldserver_fold_job
Instance Methods
to_json
to_structure
sanitised_name
fill_missing_fields
ProteinChain Class
Represents a protein chain input.Unique protein chain identifier (must be uppercase letter).
Amino acid sequence (single-letter codes, only letters).
Post-translational modifications as list of
(modification_type, residue_index). Indices are 1-based.Optional textual description of the protein chain.
Paired A3M-formatted MSA. If None, must be filled by data pipeline. Empty string means custom MSA with no sequences.
Unpaired A3M-formatted MSA. If None, must be filled by data pipeline. Empty string means custom MSA with no sequences.
List of structural templates (max 20). If None, must be filled by data pipeline. Empty list means no templates.
Properties
Single-letter sequence taking modifications into account (uses ‘X’ for unknown residues).
Post-translational modifications.
Paired MSA in A3M format.
Unpaired MSA in A3M format.
Structural templates.
Methods
to_ccd_sequence
to_dict
RnaChain Class
Represents an RNA chain input.Unique RNA chain identifier (must be uppercase letter).
RNA sequence (single-letter codes, only letters).
RNA modifications as list of
(modification_type, residue_index). Indices are 1-based.Optional textual description.
Unpaired A3M-formatted MSA. If None, must be filled by data pipeline.
Properties
Single-letter sequence taking modifications into account (uses ‘N’ for unknown residues).
RNA modifications.
Unpaired MSA in A3M format.
DnaChain Class
Represents a single-strand DNA chain input.Unique DNA chain identifier (must be uppercase letter).
DNA sequence (single-letter codes, only letters).
DNA modifications as list of
(modification_type, residue_index). Indices are 1-based.Optional textual description.
Properties
Single-letter sequence taking modifications into account (uses ‘N’ for unknown residues).
Ligand Class
Represents a ligand (small molecule) input.Unique ligand “chain” identifier.
Chemical Component Dictionary IDs. Either
ccd_ids or smiles must be set (not both).SMILES representation of ligand. Either
ccd_ids or smiles must be set (not both).Optional textual description.
Template Class
Represents a structural template for protein chains.Structural template in mmCIF format (should have only one protein chain).
Mapping from query residue index to template residue index.
Properties
mmCIF string of the template structure.
Query-to-template residue mapping.
Usage Examples
Creating a Simple Protein Input
Creating a Complex with Ligand
Loading from JSON
Saving to JSON
JSON Format
AlphaFold 3 JSON Dialect
Constants
Type Aliases
See Also
- run_alphafold.py - Main prediction script
- DataPipeline Class - MSA and template processing
- Model Class - Core model architecture