Expand description
Authoring vocabulary + render planner (Phase 5): a qapp declares 3D + 2D views over one
manifold; the planner enforces attestation gates, rights-bounded contexts, and budget-driven
3D→2D degradation before drawing. Gated like place_time (needs crate::modalities).
Phase 5 — the authoring vocabulary (ns/ui) + render planner (the qapps upgrade; §6/§7).
Upgrades the qapps model ([docs/manuals/qapps_specification.md]) from 2D-pane CSS-grid layouts
to manifold worlds: a qapp declares views over one manifold (a 3D scene and a 2D pane
from the SAME source), each carrying governance + budget annotations the engine
enforces at plan time — before anything is drawn.
This module is the in-memory vocabulary + planner. The wire-form (yaml-ld-q42 →
RDF → CBOR-LD → NQuin @context expansion) is task #8; ShEx describes the contract and
SHACL enforces the shape (ADR 0009) — one source. Those are deliberately not duplicated
here; this is the runtime the parsed document drives.
§The rails (RENDERER_DEFINITION §8) — enforced, not reinvented
- Governance primitives are the §8 substrate surfaced. Rights-bounded refusal reuses the
inherited
logic::deonticgate (the same one Phases 3–4 use); this module authors no new normative rules — it only applies caller-supplied norms. - Wisdom-out-of-band (attestation gates). A view marked
requires_attestationis withheld until an attestation is present — the human ratifies by attesting (a DID-signature trigger). Signature verification is the identity/key-vault layer’s job (it fails closed there); this gate enforces the presence of an attestation, the out-of-band hook. - Affordability at authoring time. Budget is declared, not hoped-for: on a constrained
device tier a
Scene3Dview degrades to 2D ([ViewDisposition::Collapsed2D]) rather than failing — graceful 3D→2D, so the qapp still works on hardware people own. - Fail closed. Rights-bounded render in a shared/civic standpoint defaults to refuse.
Structs§
- Qapp
View - One declared view in a qapp: a projection of
manifold, with governance + budget annotations. - Render
Standpoint - The standpoint a qapp is being rendered into.
Enums§
- Sensitivity
- Sensitivity class — surfaces the §8 rights-bounded context primitive (not new doctrine).
- View
Disposition - What the planner decides for a view (before any drawing happens).
- View
Kind - A view onto the manifold within a qapp.
Constants§
- MAX_
GOV_ NORMS - Max governance norms evaluated per rights-bounded check (stack-bounded, zero-heap).
- MAX_
QAPP_ VIEWS - Max views planned in one
plan_qapppass (stack-bounded, zero-heap). - P_
ATTESTS - Predicate stamp for an attestation
(attester) attests (manifold). - P_
VIEW_ RENDER - Property-path for a view-render action governed by a deontic norm.
Functions§
- attestation_
quin - Build an attestation quin
(attester) attests (manifold)in aframe. Real DID-signature verification belongs to the identity/key-vault layer; this is the presence hook the gate checks. - has_
attestation - Whether some attestation in
attestationsratifies this view’smanifold. - plan_
qapp - Plan a whole qapp: write each view’s disposition into
out. Zero-heap (caller slices). Returns the number of dispositions written (min(views.len(), out.len())). - plan_
view - Resolve one view’s disposition, applying the gates in order: attestation → rights-bounded → budget. (Governance refusals take precedence over budget degradation — a refused view is not “degraded”, it is withheld/refused.)
- rights_
render_ permitted - Whether sensitive content for
manifoldmay render intostandpoint. - sample_
world_ qapp - A sample qapp: a
Scene3D+ aPane2Dover the same manifold — “one manifold, two views”. - supports_
3d - Whether the device tier supports the full 3D scene — delegates to the single-source budget rule
OperationalMode::supports_3d(shared with the portal facade).Eco/Reservedegrade 3D → 2D — the affordability rail. - view_
render_ norm - Build a civic-render consent norm
(standpoint) OPCODE render(manifold)in aframe.