Commit cf70774
* docs(adr): ADR-0037 refinement — behavior-based subtype test + @kind charter
Generalizes the vocabulary-expansion framework so it transfers to ANY future
decision, not just the cases that prompted it:
- The guiding question is SEMANTIC BEHAVIOR, not surface storage: ask what X
DOES, not whether it's a string.
- Subtype test is now behavioral: a concept is a subtype if it has its own
native type OR behavior OR attributes (the extension point for custom logic) —
not merely 'distinct native type'.
- @kind chartered as the ONE structural-variant-within-a-subtype axis (source
table/view, uri url/urn); never a catch-all, never on a plain string, never
swallowing native-type-distinct concepts / boolean flags / validation.
- The 'string formats' set splits by behavior: url/uri→field.uri, ip→field.inet
(native types + behavior), only email/hostname→@stringformat (plain validated
strings); uuid was already field.uuid.
ADR-0036 decision #2 updated to the split (uri/inet subtypes + @stringformat
email/hostname). CLAUDE.md Design Judgment updated. Agent-context decision docs
generalized in a follow-on commit on this branch.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GF9xLEQZaPus5Y6opk398n
* docs(agent-context): generalize the metadata-shape decision procedure (ADR-0037)
Replace the field-specific "choosing the right field shape" guidance with a
general, mechanical decision procedure an LLM can re-derive for ANY concept —
not a lookup table of specific answers.
The guiding question is semantic behavior, not surface storage ("what does X
do?", never "is X a string/number/date?"). The ordered routing from ADR-0037:
(0) derivable -> derive, add nothing; (1) physical-only -> @dbColumnType escape
hatch; (2a) own native type/behavior/attributes -> subtype; (2b) structural
variant within a subtype -> @kind; (2c) modifies/validates/configures -> attribute.
Adds the self-documentation-over-economy and no-same-name-overload corollaries,
a compact decision table, and an ADR-0037 authority pointer.
Examples use only currently-registered vocab (field.uuid/currency/decimal,
source.rdb @kind, template.output @kind, @localTime, @maxLength/@precision) so
the capability-grounding + drift gates stay green; the general rule for native-
type-vs-validated-string is stated abstractly without naming un-built Wave 3
vocab. Codegen skill cross-reference updated to point at the renamed section.
Conformance fixtures regenerated for all four stacks.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GF9xLEQZaPus5Y6opk398n
---------
Co-authored-by: Doug Mealing <noreply@anthropic.com>
1 parent 91f11ce commit cf70774
13 files changed
Lines changed: 438 additions & 167 deletions
File tree
- agent-context/skills
- metaobjects-authoring
- metaobjects-codegen
- fixtures/agent-context-conformance
- java-kotlin-react-tanstack/expected/.claude/skills
- metaobjects-authoring
- metaobjects-codegen
- java-react/expected/.claude/skills
- metaobjects-authoring
- metaobjects-codegen
- python/expected/.claude/skills
- metaobjects-authoring
- metaobjects-codegen
- ts-react-tanstack/expected/.claude/skills
- metaobjects-authoring
- metaobjects-codegen
- spec/decisions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
465 | 465 | | |
466 | 466 | | |
467 | 467 | | |
468 | | - | |
| 468 | + | |
469 | 469 | | |
470 | 470 | | |
471 | 471 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
161 | 161 | | |
162 | 162 | | |
163 | 163 | | |
164 | | - | |
165 | | - | |
166 | | - | |
167 | | - | |
168 | | - | |
169 | | - | |
170 | | - | |
171 | | - | |
172 | | - | |
173 | | - | |
174 | | - | |
175 | | - | |
176 | | - | |
177 | | - | |
178 | | - | |
179 | | - | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
180 | 224 | | |
181 | 225 | | |
182 | 226 | | |
| |||
205 | 249 | | |
206 | 250 | | |
207 | 251 | | |
208 | | - | |
209 | | - | |
210 | | - | |
211 | | - | |
212 | | - | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
213 | 263 | | |
214 | 264 | | |
215 | 265 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
159 | 159 | | |
160 | 160 | | |
161 | 161 | | |
162 | | - | |
163 | | - | |
164 | | - | |
165 | | - | |
166 | | - | |
167 | | - | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
168 | 168 | | |
169 | 169 | | |
170 | 170 | | |
| |||
Lines changed: 71 additions & 21 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
161 | 161 | | |
162 | 162 | | |
163 | 163 | | |
164 | | - | |
165 | | - | |
166 | | - | |
167 | | - | |
168 | | - | |
169 | | - | |
170 | | - | |
171 | | - | |
172 | | - | |
173 | | - | |
174 | | - | |
175 | | - | |
176 | | - | |
177 | | - | |
178 | | - | |
179 | | - | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
180 | 224 | | |
181 | 225 | | |
182 | 226 | | |
| |||
205 | 249 | | |
206 | 250 | | |
207 | 251 | | |
208 | | - | |
209 | | - | |
210 | | - | |
211 | | - | |
212 | | - | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
213 | 263 | | |
214 | 264 | | |
215 | 265 | | |
| |||
0 commit comments