Commit 68aa1b3
committed
validate: charged ligand → warning (with biologist-actionable advice), not error
Previously a charged ligand (formal_charge != 0) hard-FAILED
validation, which blocked any bench run on ionic carboxylates,
ammoniums, etc. — a huge swath of real medicinal chemistry. The
'Phase-2 item' message offered no path forward.
The actual physics: PME on a net-charged box adds a uniform
neutralising background, which is a finite-size artefact that
corrects out via the Rocklin 2013 5-term correction (EMP + NET
+ RIP + DSC + ANA). Without that correction, ABSOLUTE ΔG_bind
on a charged ligand carries a 5-15 kcal/mol systematic error
that depends on box size and protein charge. BUT — and this is
the biologist-actionable point — it CANCELS in ΔΔG within a
same-charge congeneric series. So Kendall-τ rank-correlation
gates remain valid for ionic ligand series; only absolute MAE
is meaningful when the correction is applied.
New validator behaviour:
? acetate: formal charge -1 — absolute ΔG_bind carries a
5-15 kcal/mol PBC self-interaction error (Rocklin 2013
J Chem Phys 139:184103). For ΔΔG within a same-charge
congeneric series the error cancels; for absolute ΔG
apply Rocklin post-hoc.
Warning, exit 0 — biologist proceeds informed.
Also added a stub comment block where the analytical
_rocklin_pbc_correction would live, documenting the 5 terms
and why the full implementation is Phase-3 (needs protein
charge + ion-pairing distribution as auxiliary state).
Test test_charged_ligand_flagged updated to assert the new
warning shape including the 'ΔΔG cancels' caveat — that
sentence is the load-bearing biologist-actionability claim.
19/19 validator smoke tests still PASS.1 parent 4c76625 commit 68aa1b3
2 files changed
Lines changed: 50 additions & 11 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
396 | 396 | | |
397 | 397 | | |
398 | 398 | | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
399 | 421 | | |
400 | 422 | | |
401 | 423 | | |
| |||
1795 | 1817 | | |
1796 | 1818 | | |
1797 | 1819 | | |
1798 | | - | |
1799 | | - | |
1800 | | - | |
| 1820 | + | |
| 1821 | + | |
| 1822 | + | |
| 1823 | + | |
| 1824 | + | |
| 1825 | + | |
| 1826 | + | |
1801 | 1827 | | |
1802 | | - | |
| 1828 | + | |
1803 | 1829 | | |
1804 | | - | |
1805 | | - | |
1806 | | - | |
| 1830 | + | |
| 1831 | + | |
| 1832 | + | |
| 1833 | + | |
| 1834 | + | |
| 1835 | + | |
| 1836 | + | |
1807 | 1837 | | |
1808 | 1838 | | |
1809 | 1839 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
203 | 203 | | |
204 | 204 | | |
205 | 205 | | |
206 | | - | |
207 | | - | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
208 | 211 | | |
209 | 212 | | |
210 | 213 | | |
| |||
215 | 218 | | |
216 | 219 | | |
217 | 220 | | |
218 | | - | |
219 | | - | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
220 | 229 | | |
221 | 230 | | |
222 | 231 | | |
| |||
0 commit comments