Commit 5264cff
Gate retained fused parents on ambiguity, not on a substituent allow-list
A retained fused parent was abandoned whenever the molecule carried any
substituent outside a curated list of 26 names. `pentyl` was on it and
`hexyl` was not, so 2-pentyl-7H-purine named itself and its hexyl homologue
fell back to 3-hexyl-2,4,7,9-tetraazabicyclo[4.3.0]nona-1,3,5,8-tetraene.
The list gated the wrong thing: a substituent is named by its own recursive
call, so what it is cannot affect whether the parent's locants are right.
It was a rollout throttle standing in for a hazard nobody had named.
The hazard is real but different. A lactam like 4-oxoquinoline-3-carboxamide
saturates two ring positions beyond what quinoline supports, and which two
cannot be recovered from the name -- OPSIN puts the hydrogen on C3 and reads
a different molecule. Those positions have to be cited as
4-oxo-1,4-dihydroquinoline-3-carboxamide, and only parents wired into the
indicated-hydrogen machinery can do it.
So gate on that instead: count the parent's saturated positions, and keep the
retained name only when they fit its indicated hydrogen or it can spell the
rest out. Anything else keeps the von Baeyer name, which states its
saturation positionally and stays unambiguous.
Measured on 200k molecules, every name this changes was checked against OPSIN
independently of the self-audit: 519 changed, 518 resolve back to their input,
and the one that does not is a garbled spiro name whose previous form was
equally unparseable -- the known spiro renderer gap, untouched here.
Refutations stay at 27; without the ambiguity guard this same change
introduced 29 wrong names.
zinc22 is unchanged at 97.63%. pubchem drops 96.33% -> 96.21%: 119 names
stop being confirmed, every one because the audit models neither added
hydrogen (70) nor more than one indicated hydrogen (42), not because any
name got worse. Teaching the audit those two constructs is the next step,
and would also recover the ~200 lactams the new guard still holds back.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>1 parent 8b68a0e commit 5264cff
2 files changed
Lines changed: 59 additions & 22 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
17 | 18 | | |
18 | 19 | | |
19 | 20 | | |
20 | 21 | | |
21 | 22 | | |
22 | 23 | | |
23 | 24 | | |
24 | | - | |
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| |||
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
| 88 | + | |
| 89 | + | |
88 | 90 | | |
89 | 91 | | |
90 | 92 | | |
| |||
97 | 99 | | |
98 | 100 | | |
99 | 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 | + | |
100 | 128 | | |
101 | 129 | | |
102 | 130 | | |
| |||
167 | 195 | | |
168 | 196 | | |
169 | 197 | | |
170 | | - | |
171 | | - | |
| 198 | + | |
| 199 | + | |
172 | 200 | | |
173 | | - | |
174 | | - | |
175 | | - | |
176 | | - | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
177 | 204 | | |
178 | 205 | | |
179 | | - | |
180 | | - | |
181 | | - | |
182 | | - | |
183 | | - | |
184 | | - | |
185 | | - | |
186 | | - | |
187 | | - | |
188 | | - | |
189 | | - | |
190 | | - | |
191 | | - | |
192 | | - | |
193 | | - | |
| 206 | + | |
194 | 207 | | |
195 | 208 | | |
196 | 209 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
116 | 116 | | |
117 | 117 | | |
118 | 118 | | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
0 commit comments