cofactors Module
The cofactors module handles the detection and modeling of inorganic cofactors and metal ions within protein structures.
Overview
Many proteins require metal ions (like Zn²⁺, Ca²⁺, or Mg²⁺) for structural stability or catalytic function. This module automatically identifies coordination motifs—such as Zinc Fingers—and inserts the appropriate ions with correct geometric coordination.
Key Features
- Motif Detection: Scans the structure for residues capable of coordinating metals (Cys, His, Asp, Glu).
- Geometric Coordination: Places metal ions at the geometric centroid of their coordinating ligands.
- Automated Insertion: Integrates with the generation pipeline to produce holoproteins (proteins with cofactors).
API Reference
cofactors
Cofactor and Metal Ion Coordination Module.
THE "AI TRINITY" PHASE 15: Inorganic Coordination.
Biological proteins aren't just chains of amino acids; they often require inorganic "cofactors" or metal ions to function. Zinc (Zn2+) is one of the most common, found in "Zinc Finger" motifs where it stabilizes the fold by coordinating with Cysteine (C) and Histidine (H) residues.
Educational Note - Coordination Chemistry:
- Ligands: The atoms that donate electrons to the metal (e.g., Cys Sulfur, His Nitrogen).
- Coordination Number: The number of ligands (Zinc is usually 4 - Tetrahedral).
- Geometric Centroid: The ideal position for the metal is the center of its ligands.
This module automatically detects these motifs and inserts the appropriate ions.
Functions
find_metal_binding_sites(structure, distance_threshold=20.0)
Scans the structure for clusters of residues that could coordinate a metal ion.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
structure
|
AtomArray
|
Biotite AtomArray. |
required |
distance_threshold
|
float
|
Max distance between any two coordinating atoms in a cluster. |
20.0
|
Returns:
| Type | Description |
|---|---|
list[dict]
|
List[Dict]: A list of detected sites, each with 'type' and 'ligand_indices'. |
Source code in synth_pdb/cofactors.py
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 | |
add_metal_ion(structure, site)
Adds a metal ion (HETATM) to the structure at the centroid of its ligands.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
structure
|
AtomArray
|
Original AtomArray. |
required |
site
|
dict
|
Identification of the site (from find_metal_binding_sites). |
required |
Returns:
| Type | Description |
|---|---|
AtomArray
|
struc.AtomArray: New AtomArray with the ion appended. |
Source code in synth_pdb/cofactors.py
Scientific Principles
Coordination Chemistry
In biological systems, metal ions are coordinated by specific amino acid side chains (ligands). For example, a Zinc Finger typically coordinates a Zn²⁺ ion using two Cysteines and two Histidines (\(C_2H_2\)).
The module calculates the ideal position for the metal ion as the centroid (\(\mathbf{C}\)) of the coordinating atoms:
where \(\mathbf{x}_i\) are the coordinates of the ligand atoms (e.g., SG for Cys, NE2/ND1 for His).
Usage Example
from synth_pdb.generator import PeptideGenerator
from synth_pdb.cofactors import find_metal_binding_sites, add_metal_ion
# 1. Generate a sequence known to bind Zinc (e.g., a simple Zinc Finger)
seq = "CPYCGKSFSDSSALRNHVRTH"
gen = PeptideGenerator(seq)
structure = gen.generate(conformation="alpha")
# 2. Detect potential binding sites
sites = find_metal_binding_sites(structure)
# 3. Add the metal ion if a site is found
if sites:
structure_with_metal = add_metal_ion(structure, sites[0])