docs: DocIr = composition layer over the OGAR object graph (operator ruling, D-DOCIR-COMPOSITION)#217
Merged
Merged
Conversation
…ruling)
Canonize the 2026-07-20 operator ruling that moves the boundary: DocIr is not
merely the OCR document model — it becomes the composition layer over the
OGAR object graph. Documents become lenses through the object world, never
boxes where copies decay.
The doctrine (docs/DOCIR-COMPOSITION-LAYER.md, verbatim-preserving):
- ObjectSlot = ActionText's attachment doctrine transplanted as typed
projection portals (target + class_view + FieldMask + WideFieldMask +
ResolutionMode{Live,Revision,Snapshot} + snapshot fallback), with
ogar://app/class/id@{live|revision:N|sha256:...} as the SGID equivalent —
the beyond-Rails move: dashboards live, signed/GoBD artifacts pinned.
- Sharp responsibilities: ClassView = named semantic projection; FieldMask =
immediate fields; WideFieldMask = GraphQL-shaped traversal selection
compiled into the radix/path machinery; FieldView = renderer-neutral
presentation intent. The hinge: Askama/Typst/Blitz/Vello render FieldView
and never query domains.
- DocNode is composition-only (no domain variants — those belong to OGAR);
the existing observation IR (doc.v1 retina) is untouched, referenced via
slots.
- Trix donates editor authority (DocOp -> DocIr -> rerender); Typst owns the
paged projection generated from render nodes; Blitz stays behind the
ProjectionRenderer trait; Parley/Vello = precision canvas with inline-box
object slots; ogar-bim lands as semantic objects + ClassViews.
- First vertical slice: OpenProject WorkPackage.description, 3 attachables x
2 named ClassViews, rendered twice (Askama HTML + Typst PDF), then one
BimObject.
Grounded against shipped bricks (WideFieldMask, ogar-render-askama
field_view, ogar-a2ui-frame, document 0x080B, content-addressed Lance KV) and
gated on the OGAR-AS-IR read before any composition types land. DISCOVERY-MAP
entry D-DOCIR-COMPOSITION appended.
Generated by Claude Code
AdaWorldAPI
pushed a commit
that referenced
this pull request
Jul 20, 2026
Per the DocIr composition grounding (#217/#218) + operator ruling A1 ("one ogar-doc crate; split axis is STATE not direction"): DocIr here is the observation retina; the composition DocNode is a MODULE in this crate family (never a sibling ogar-doc-compose) that references this observation IR through an ObjectSlot (the A3 Klickwege ClassView x WideFieldMask brick + ObjectRef + ResolutionMode). Observation IR untouched — referenced, never retyped in place. Doc-comment only. Generated with Claude Code
AdaWorldAPI
added a commit
that referenced
this pull request
Jul 20, 2026
…re-jjzlig docs: ground the DocIr composition layer (#217) + record the geometry chunk [S]
AdaWorldAPI
pushed a commit
that referenced
this pull request
Jul 20, 2026
…ionMode/ogar:// (W1, canon-free) The first compilable brick of the DocIr composition layer (#217 doctrine, #218 grounding), placed per operator ruling A1 ("one ogar-doc crate; split axis is STATE not direction"): a `compose` MODULE beside the observation IR, never a sibling crate. The observation IR is untouched. - Closed 5-kind `DocNode` vocabulary — Document/Section/Paragraph/Text/ ObjectSlot, exactly the doctrine §7 slice scope; Figure/Table/PageBreak are a `doc-compose.v2` bump, never a silent widening. Exhaustive enums (renderer gets a compile error on an unhandled kind). NO domain variants — a Wall/WorkPackage enters only through a slot (§3). - `ObjectSlot{target, class_view (named view), field_mask: u64, wide_mask_words: Vec<u64>, resolution, fallback}` — the A3 brick (ClassView x WideFieldMask) made addressable. Masks travel in wire form (word w bit b => position w*64+b, positions >= 64 native — the ogar-a2ui-frame precedent), typed at the contract membrane; the module stays serde-only, zero canon dependency (lands ahead of mints, like the observation IR did). - `ResolutionMode{Live, Revision(u64), Snapshot([u8;32])}` + strict `ogar://app/class/id@{live|revision:N|sha256:hex64}` parse/format — every malformed input is a refusal; a missing resolution suffix has NO default. - Load gate + structural validation: version marker `doc-compose.v1`, closed-vocab serde rejection, out-of-range id refusal, cycle refusal (iterative DFS, no recursion). - RBAC posture pinned per grounding SA4: slot masks are a REQUEST; the fail-closed `requested & role` intersection is the resolver's job (ClassRbac enforcement is probe-gated, never assumed). 9 new tests incl. the doctrine-§7 proof shape (WorkPackage.description composing Text + User/WorkPackage/Attachment slots), all three ogar:// arms round-tripping, seven URI refusals, wide-position and snapshot- fallback serde round-trips. 16/16 crate tests green; clippy/fmt clean. Deferred, named: DocOp (§4 editor authority — next brick); the FieldView enum widening + (ClassId, mode) named-view registry (ogar-render-askama / ogar-class-view side); ogar-render-typst. Ledger: W1 status appended to D-DOCIR-COMPOSITION (same commit, board hygiene). Generated with Claude Code
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Canonizes the 2026-07-20 operator ruling that moves the DA-4 editor boundary: DocIr is not merely the document model — it becomes the composition layer over the OGAR object graph. Documents become lenses through the object world, never boxes where copies of that world go to slowly decay.
New:
docs/DOCIR-COMPOSITION-LAYER.md(verbatim-preserving doctrine) +DISCOVERY-MAP.mdentry D-DOCIR-COMPOSITION[G].The doctrine in brief
ObjectSlot— ActionText's attachment doctrine transplanted as typed projection portals:target: ObjectRef+class_view+FieldMask+WideFieldMask+ResolutionMode{Live, Revision, Snapshot}+ snapshot fallback.ogar://app/class/id@{live|revision:N|sha256:…}is the SGID equivalent — the beyond-Rails move (dashboards live; signed/GoBD artifacts pinned; deleted objects fall back to snapshots).WorkPackage.{compact-card, document-inline, inspector, print-summary, bim-overlay}); FieldMask = immediate fields; WideFieldMask = GraphQL-shaped traversal selection compiled into the radix/path machinery; FieldView = renderer-neutral presentation intent — Askama/Typst/Blitz/Vello render FieldView and never query domains (the hinge).DocNodeis composition-only — noWall/WorkPackage/Patientvariants; those belong to OGAR. The existing observation IR (ogar-doc-irdoc.v1 retina) is untouched and referenced through slots.DocOp→ DocIr → rerender; DOM/Typst/HTML never authoritative; CRDT-compatible later). Typst owns the paged projection (generated from render nodes — arbitrary Typst syntax never enters canon). Blitz stays behind theProjectionRenderertrait (experimental, not load-bearing). Parley/Vello = precision canvas, inline boxes carrying object slots as references, never text.ogar-bimlands as semantic objects + ClassViews — one identity, several faces.WorkPackage.description— 5 node kinds, 3 attachables (WorkPackage/User/Attachment) × 2 named ClassViews each, the same document rendered twice (Askama HTML + Typst PDF), then ONEBimObject.Grounding + gates
Grounded against shipped bricks (
WideFieldMaskCODED per the #204/#205 arc,ogar-render-askama::field_view,ogar-a2ui-frame,document 0x080B#216, content-addressed Lance KV in medcare-rs). Implementation is explicitly gated on theOGAR-AS-IR.mdread (this is an IR-surface change) and the named gaps are listed (ObjectSlot/ogar://· composition DocNode · DocOp · FieldView + ProjectionRenderer · named multi-views per class ·ogar-render-typst). Docs-only — no code change.🤖 Generated with Claude Code
https://claude.ai/code/session_01Mwq1QKpw4zRd6oaGRoJhF2
Generated by Claude Code