Skip to content

The meta-model is drawn a unit at a time - #173

Merged
robertblust merged 1 commit into
mainfrom
the-meta-model-is-drawn-a-unit-at-a-time
Oct 13, 2026
Merged

robertblust merged 1 commit into
mainfrom
the-meta-model-is-drawn-a-unit-at-a-time

Conversation

@robertblust

Copy link
Copy Markdown
Contributor

A picture of the schemas was refused once a model declared more types than one picture holds, with the hint to name a type. CompanyGraph's own model passed that limit when it took the requirements pack, so the meta-model, the first row its chat offers a visitor, has drawn nothing since. Raising the limit would hold until the next pack and draw a picture too dense to read.

diagram with shape: "schema" now takes unit, core or a pack the instance takes, and draws that unit's own types and what they declare: each reference a type of the unit declares, with the type it reaches, and each nesting of a type of the unit. A pack is drawn with the core types it rests on and core is drawn alone, since a pack declares into core and core never into a pack. Asked for whole, a meta-model past the limit is drawn as core rather than refused. Every schema answer carries units, each unit with how many types it declares, core first, and one narrowed to a unit carries that unit and has it as its title. A meta-model within the limit is drawn whole as before, a type narrows as before, unit and type together are refused, and a unit the instance does not have is refused with the units it has.

What it costs downstream: the tool's input gains an optional argument and its answer two optional fields, which a strict client validating answers against a cached output schema has to refresh for. The chat server reads the tool list from the host and refreshes it when an answer no longer fits. Its released version draws core on this host and does not yet say that packs were left out; companygraph/chat-server carries that in a pull request of its own. The connectors that cache the tool list want a refresh after the hosts take this. Release notes to write at tagging: diagram draws the meta-model a unit at a time, unit narrows the schema shape to core or a pack, a meta-model too large to draw whole is drawn as core, and the answer names every unit in units.

Verified: the five new tests failed before the change; npm test, npm run typecheck, npm run build:check, conventions-check and conventions-format pass; served from this branch over companygraph/mental-model, the whole meta-model drew core with the four packs named, and the requirements and landscape packs drew by name; a local chat on chat-server v0.35.0 against it drew the meta-model where it drew nothing before.

🤖 Generated with Claude Code

A picture of the schemas was refused once a model took enough packs to declare more types than one picture holds, and the only way out was to name a single type. CompanyGraph's own model passed that point with the requirements pack, so the first thing its chat offers a visitor, the meta-model, drew nothing.

The schema shape now takes a unit, core or a pack the instance takes, and draws that unit's own types and what they declare, so a pack stands with the core types it rests on and core stands alone, since a pack declares into core and core never into a pack. Asked for whole, a meta-model past the limit is drawn as core rather than refused. Every schema answer carries units, each unit with how many types it declares, and one narrowed to a unit says which, so a caller sees what was left out and asks for it by name. A meta-model within the limit is drawn whole as before, and a type narrows as before.

Verified: the five new tests failed before the change; npm test, npm run typecheck, npm run build:check, conventions-check and conventions-format pass; served from this branch over companygraph/mental-model, the whole meta-model drew core with the four packs named, and the requirements and landscape packs drew by name.

Process: Delivery
Phase: Implement
Track: Code
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@robertblust
robertblust merged commit 9319b12 into main Oct 13, 2026
3 checks passed
@robertblust
robertblust deleted the the-meta-model-is-drawn-a-unit-at-a-time branch October 13, 2026 05:51
@robertblust robertblust mentioned this pull request Oct 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant