Spaces:
Runtime error
Runtime error
File size: 2,149 Bytes
89d9c28 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 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 | # API Response Specification — EGFR AI Backend Bundle
This document describes the expected response shape for the backend/frontend integration.
## 1. Generate endpoint
### Request
```json
{
"preset": "egfr_generator",
"num_molecules": 100,
"return_top_k": 20,
"docking_mode": "off"
}
Allowed docking modes
off
top_k
all
Meaning:
off: no docking is run. Docking columns are returned as empty/null.
top_k: docking is run only for the top-k generated molecules after property + affinity scoring.
all: docking is run for all returned molecules. This is slower.
##
2. Response
**Review ai_artifacts_release\examples\generate_response.example.json
{
"job_id": "gen_001",
"preset": "egfr_generator",
"status": "completed",
"docking_mode": "off",
"summary": {
"num_generated": 100,
"num_valid": 100,
"num_returned": 20
},
"columns": [
"SMILES",
"SMILES_state",
"NLL",
"valid",
"canonical_smiles",
"mw",
"logp",
"tpsa",
"hbd",
"hba",
"rot_bonds",
"qed",
"sa_score",
"pred_pAff_mean",
"docking_score",
"docking_status",
"docking_pose_file"
],
"results": [
{
"SMILES": "CNCCC(=O)Nc1ccc2nncc(-c3ccc4cncnc4c3)c2c1",
"SMILES_state": 1,
"NLL": 5.71,
"valid": true,
"canonical_smiles": "CNCCC(=O)Nc1ccc2nncc(-c3ccc4cncnc4c3)c2c1",
"mw": 358.405,
"logp": 2.788,
"tpsa": 92.69,
"hbd": 2,
"hba": 6,
"rot_bonds": 5,
"qed": 0.5698,
"sa_score": 2.5204,
"pred_pAff_mean": 11.0104,
"docking_score": null,
"docking_status": "not_run",
"docking_pose_file": null
}
],
"warnings": [
"Outputs are computational predictions only.",
"Docking was not run for this job." ## depend on the user's preference
]
}
2. Score SMILES endpoint
Request
{
"smiles": [
"CCO",
"c1ccccc1"
],
"docking_mode": "off"
}
4. Frontend/filter recommendations
Recommended filters:
valid == true
mw between 250 and 600
logp between 0 and 6
tpsa between 40 and 140
qed >= 0.3
pred_pAff_mean available
docking_status in ["not_run", "completed"] |