Run this model with HF Jobs
Run aurekaresearch/OpenDDE on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs to fine-tune https://huggingface.co/aurekaresearch/OpenDDE. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/aurekaresearch/OpenDDE on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Instructions to use aurekaresearch/OpenDDE with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- OpenDDE
How to use aurekaresearch/OpenDDE with OpenDDE:
# pip install 'opendde[gpu]' # Checkpoints are fetched from the Hub into $OPENDDE_ROOT_DIR (default ~/.cache/opendde) opendde doctor opendde pred -i examples/input.json -o ./output -n opendde_v1
- Notebooks
- Google Colab
- Kaggle
Download docs/constraints.md from aurekaresearch/OpenDDE: direct link, hf CLI and curl.
- Browser
- Download file 8.86 kB
-
https://huggingface.co/aurekaresearch/OpenDDE/resolve/main/docs/constraints.md
- Command line
-
hf download hf://aurekaresearch/OpenDDE/docs/constraints.md
-
curl -L -o constraints.md https://huggingface.co/aurekaresearch/OpenDDE/resolve/main/docs/constraints.md
Constraints
OpenDDE supports two independent constraint mechanisms, both declared per job in the input JSON:
| Mechanism | JSON key | Supported models | CLI flag | Constraint kinds |
|---|---|---|---|---|
constraint_embedder |
distance_constraint |
opendde_v2 only (opendde_v1 raises an error) |
None | site, pair |
| Training-Free Guidance (TFG) | constraint |
opendde_v2 and opendde_v1 (opendde_v1 supports TFG only) |
--use_tfg_guidance true |
contact, movable_chains, epitope |
opendde_v2supports bothconstraint_embedderconditioning and TFG guidance.opendde_v1has no constraint embedder and supports TFG (constraint) only; passingdistance_constrainttoopendde_v1raises an error.- Neither mechanism creates covalent bonds; use
covalent_bondsfor those (see infer_json_format.md).
1. constraint_embedder (distance_constraint, opendde_v2 only)
distance_constraint conditions the pair representation inside the trunk
through the trained constraint embedder. It requires no extra CLI flag and
applies only to opendde_v2.
site: asks that each residue insitelies withinmax_distanceof its nearest residue insource.pair: asks that every residue inleftand every residue inrightlies within[min_distance, max_distance](min_distancedefaults to0.0).- Selectors:
entityis the 1-based index insequences(required); optionalcopy(1-based) andpositions(1-based residue numbers) narrow the selection. Omittingpositionsselects the entire entity. - Distances: measured in Å between representative atoms (
CAfor amino acids,C1'for nucleotides, each atom for ligands), up to 32 Å. Values ofmax_distancein6–12Å match the trained range.
Case 1: Antibody–antigen epitope (site) constraint
Tell opendde_v2 that chain 2 (binder) should sit within 8.0 Å of antigen
residue 69 on entity 1, without naming any binder-side residue (from
examples/constraint/example_constraint_msa.json):
[
{
"name": "7st3_site_8",
"modelSeeds": [101],
"sequences": [
{
"proteinChain": {
"sequence": "YMLDLQPETTDLYCGGGGSGGGGSGGGGSIQRTPKIQVYSRHPAENGKSNFLNCYVSGFHPSDIEVDLLKNGERIEKVEHSDLSFSKDWSFYLLYYTEFTPTEKDEYACRVNHVTLSQPKIVKWDRDMGGGGSGGGGSGGGGSGGGGSGSHSMRYFFTSVSRPGRGEPRFIAVGYVDDTQFVRFDSDAASQRMEPRAPWIEQEGPEYWDGETRKVKAHSQTHRVDLGTLRGCYNQSEAGSHTVQRMYGCDVGSDWRFLRGYHQYAYDGKDYIALKEDLRSWTAADMCAQTTKHKWEAAHVAEQLRAYLEGTCVEWLRRYLENGKETLQRTDAPKTHMTHHAVSDHEATLRCWALSFYPAEITLTWQRDGEDQTQDTELVETRPAGDGTFQKWAAVVVPSGQEQRYTCHVQHEGLPKPLTLRWEHHHHHH",
"count": 1,
"id": ["A"],
"msa": {"precomputed_msa_dir": "./examples/constraint/msa/7st3/1/", "pairing_db": "uniref100"}
}
},
{
"proteinChain": {
"sequence": "EVKLVESGGGLVQPGGSLRLSCAASGSIFSINTMGWYRQTPGKQRDLVADISSGGSTKYGDSVKGRFTISRDNTKNTVYLQMNSLKPEDTAVYYCYGLSYSNDDYWGQGTQVTVSS",
"count": 1,
"id": ["B"],
"msa": {"precomputed_msa_dir": "./examples/constraint/msa/7st3/2/", "pairing_db": "uniref100"}
}
}
],
"distance_constraint": {
"site": [
{
"source": [{"entity": 2}],
"site": [{"entity": 1, "positions": [69]}],
"max_distance": 8.0
}
]
}
}
]
Case 2: Residue–residue (pair) constraint
Constrain residue 72 of entity 1 to be within 15.0 Å of residue 103 of
entity 2:
"distance_constraint": {
"pair": [
{
"left": [{"entity": 1, "positions": [72]}],
"right": [{"entity": 2, "positions": [103]}],
"max_distance": 15.0
}
]
}
Case 3: Protein–ligand pocket (pair) constraint
Place ligand CCD_ZRY (entity 2) within 3.0–5.0 Å of residue 311 on
protein entity 1 (from
examples/constraint/example_constraint_msa.json):
[
{
"name": "5sak_residue_ligand_pair_3_5",
"modelSeeds": [101],
"sequences": [
{
"proteinChain": {
"sequence": "MSSPLKNALVTAMLAGGALSSPTKQHVGIPVNASPEVGPGKYSFKQVRNPNYKFNGPLSVKKTYLKYGVPIPAWLEDAVQNSTSGLAERSTGSATTTPIDSLDDAYITPVQIGTPAQTLNLDFDTGSSDLWVFSSETTASEVDGQTIYTPSKSTTAKLLSGATWSISYGDGSSSSGDVYTDTVSVGGLTVTGQAVESAKKVSSSFTEDSTIDGLLGLAFSTLNTVSPTQQKTFFDNAKASLDSPVFTADLGYHAPGTYNFGFIDTTAYTGSITYTAVSTKQGFWEWTSTGYAVGSGTFKSTSIDGIADTGTTLLYLPATVVSAYWAQVSGAKSSSSVGGYVFPCSATLPSFTFGVGSARIVIPGDYIDFGPISTGSSSCFGGIQSSAGIGINIFGDVALKAAFVVFNGATTPTLGFASK",
"count": 1,
"id": ["A"],
"msa": {"precomputed_msa_dir": "./examples/constraint/msa/5sak/1/", "pairing_db": "uniref100"}
}
},
{
"ligand": {
"ligand": "CCD_ZRY",
"count": 1,
"id": ["L"]
}
}
],
"distance_constraint": {
"pair": [
{
"left": [{"entity": 1, "positions": [311]}],
"right": [{"entity": 2}],
"min_distance": 3.0,
"max_distance": 5.0
}
]
}
}
]
Run all bundled distance_constraint examples (7ST3 site/pair and 5SAK
residue–ligand, paired with unconstrained baselines):
python runner/batch_inference.py pred \
-i examples/constraint/example_constraint_msa.json \
-o ./output_constraint \
-n opendde_v2 \
--use_msa true
2. Training-Free Guidance (constraint, opendde_v2 and opendde_v1)
TFG steers the sampled coordinates during diffusion without modifying trunk
representations or weights. It requires --use_tfg_guidance true and works with
both opendde_v2 and opendde_v1 (for opendde_v1, TFG is the only
supported constraint mode).
Case 4: Rigid-body contact restraint (movable_chains + contact)
Move antibody chains ["H", "L"] as a rigid body to satisfy a contact between
heavy-chain CA at position 102 and antigen CA at position 20:
[
{
"name": "abag_tfg_contact",
"modelSeeds": [101],
"sequences": [
{"proteinChain": {"sequence": "EVQLVESGGG...", "count": 1, "id": ["H"]}},
{"proteinChain": {"sequence": "DIQMTQSPSS...", "count": 1, "id": ["L"]}},
{"proteinChain": {"sequence": "MKTIIALSYI...", "count": 1, "id": ["A"]}}
],
"constraint": {
"movable_chains": ["H", "L"],
"contact": [
{
"entity1": "1", "copy1": 1, "position1": "102", "atom1": "CA",
"entity2": "3", "copy2": 1, "position2": "20", "atom2": "CA",
"min_distance": 3.5,
"max_distance": 8.0
}
]
}
}
]
Run with opendde_v2 or opendde_v1:
# opendde_v2
python runner/batch_inference.py pred \
-i abag_tfg_contact.json \
-o ./output_tfg_v2 \
-n opendde_v2 \
--use_tfg_guidance true
# opendde_v1 (supports TFG constraints only)
python runner/batch_inference.py pred \
-i abag_tfg_contact.json \
-o ./output_tfg_v1 \
-n opendde_v1 \
--use_tfg_guidance true
Case 5: Epitope guidance (movable_chains + epitope)
Guide antibody CDRs onto a set of antigen epitope residues without specifying antibody-side contacts:
[
{
"name": "abag_tfg_epitope",
"modelSeeds": [101],
"sequences": [
{"proteinChain": {"sequence": "EVQLVESGGG...", "count": 1, "id": ["H"]}},
{"proteinChain": {"sequence": "DIQMTQSPSS...", "count": 1, "id": ["L"]}},
{"proteinChain": {"sequence": "MKTIIALSYI...", "count": 1, "id": ["A"]}}
],
"constraint": {
"movable_chains": ["H", "L"],
"epitope": {
"residues": [
{"entity": "3", "copy": 1, "position": "248", "residue": "P"},
{"entity": "3", "copy": 1, "position": "249", "residue": "N"},
{"entity": "3", "copy": 1, "position": "251", "residue": "D"}
],
"paratope": "cdr",
"min_fraction": 0.5
}
}
}
]
paratopeaccepts"all"(default),"cdr"(positions 24–40, 50–66, 88–115 of each movable chain), or explicit windows such as{"windows": {"H": [[95, 108]], "L": [[89, 97]]}}.min_fractionsets the minimum fraction of listed epitope residues within 5 Å (heavy-atom distance) of the paratope.
Run with the tuned TFG settings (--dtype bf16 --enable_tf32 false at 200
diffusion steps):
python runner/batch_inference.py pred \
-i abag_tfg_epitope.json \
-o ./output_tfg_epitope \
-n opendde_v2 \
--use_tfg_guidance true \
--dtype bf16 \
--enable_tf32 false
See tfg_constraint_guidance.md for the search
algorithm, default schedules, and --tfg_rigid KEY=VALUE overrides.