@almadar/core 11.0.1 → 11.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (63) hide show
  1. package/dist/{builders-BdgbY7Th.d.ts → builders-C4TIhiks.d.ts} +292 -292
  2. package/dist/builders.d.ts +5 -5
  3. package/dist/builders.js +3 -3
  4. package/dist/{bus-C0hFDNFR.d.ts → bus-do1P9luP.d.ts} +4 -4
  5. package/dist/{chunk-ENOCKYGA.js → chunk-2NKK2X53.js} +3 -3
  6. package/dist/{chunk-ENOCKYGA.js.map → chunk-2NKK2X53.js.map} +1 -1
  7. package/dist/{chunk-TDNQT3M3.js → chunk-3DZOFI53.js} +4 -4
  8. package/dist/{chunk-TDNQT3M3.js.map → chunk-3DZOFI53.js.map} +1 -1
  9. package/dist/{chunk-5YTPYMPZ.js → chunk-6H3UIZR2.js} +3 -3
  10. package/dist/{chunk-5YTPYMPZ.js.map → chunk-6H3UIZR2.js.map} +1 -1
  11. package/dist/{chunk-FGT5OS2Y.js → chunk-7B4JRMRL.js} +15 -3
  12. package/dist/chunk-7B4JRMRL.js.map +1 -0
  13. package/dist/{chunk-5WQ3U7NJ.js → chunk-IE6WCCJP.js} +14 -2
  14. package/dist/chunk-IE6WCCJP.js.map +1 -0
  15. package/dist/{chunk-PNGFWLHD.js → chunk-LPJ7GKRM.js} +18 -8
  16. package/dist/chunk-LPJ7GKRM.js.map +1 -0
  17. package/dist/{chunk-SNZYN7UA.js → chunk-N3CK4AYW.js} +106 -16
  18. package/dist/{chunk-SNZYN7UA.js.map → chunk-N3CK4AYW.js.map} +1 -1
  19. package/dist/{chunk-E4T2MQAV.js → chunk-PYYHDYTD.js} +3 -3
  20. package/dist/{chunk-E4T2MQAV.js.map → chunk-PYYHDYTD.js.map} +1 -1
  21. package/dist/{chunk-Z7BI7DE7.js → chunk-VIHQKKTZ.js} +45 -15
  22. package/dist/chunk-VIHQKKTZ.js.map +1 -0
  23. package/dist/{chunk-GF7KCLNR.js → chunk-VOFHP52Z.js} +29 -4
  24. package/dist/chunk-VOFHP52Z.js.map +1 -0
  25. package/dist/{chunk-66Q5VX2F.js → chunk-ZDIHVDTW.js} +6 -6
  26. package/dist/chunk-ZDIHVDTW.js.map +1 -0
  27. package/dist/{effect-DZaXwSAz.d.ts → effect-Dr--GXRe.d.ts} +59 -51
  28. package/dist/{effect-result-1HpXgeBc.d.ts → effect-result-geymPT9w.d.ts} +39 -5
  29. package/dist/factory/index.d.ts +2 -2
  30. package/dist/factory/index.js +4 -4
  31. package/dist/factory-runtime/index.d.ts +3 -3
  32. package/dist/factory-runtime/index.js +10 -10
  33. package/dist/fixtures.d.ts +3 -3
  34. package/dist/fixtures.js +2 -2
  35. package/dist/i18n/index.js +1 -1
  36. package/dist/{index-D7SxwNdv.d.ts → index-C8mF8btS.d.ts} +39 -28
  37. package/dist/index.d.ts +14 -14
  38. package/dist/index.js +15 -15
  39. package/dist/kernel-wire.d.ts +2 -2
  40. package/dist/kernel-wire.js +1 -1
  41. package/dist/language/validation-codes.json +25 -0
  42. package/dist/language/vocabulary.json +2 -0
  43. package/dist/language-data.js +1 -1
  44. package/dist/patterns/component-mapping.json +1 -1
  45. package/dist/patterns/definitions.d.ts +1 -1
  46. package/dist/patterns/definitions.js +1 -1
  47. package/dist/patterns/event-contracts.json +1 -1
  48. package/dist/patterns/index.d.ts +2 -2
  49. package/dist/patterns/index.js +2 -2
  50. package/dist/patterns/patterns-registry.json +104 -14
  51. package/dist/patterns/registry.json +104 -14
  52. package/dist/{trait-sRjIivFq.d.ts → trait-D9MjuwGC.d.ts} +86 -86
  53. package/dist/types/index.d.ts +8 -8
  54. package/dist/types/index.js +7 -7
  55. package/dist/{types-C6_yPMpn.d.ts → types-Bi-KSa0a.d.ts} +2 -2
  56. package/package.json +4 -4
  57. package/dist/chunk-5WQ3U7NJ.js.map +0 -1
  58. package/dist/chunk-66Q5VX2F.js.map +0 -1
  59. package/dist/chunk-FGT5OS2Y.js.map +0 -1
  60. package/dist/chunk-GF7KCLNR.js.map +0 -1
  61. package/dist/chunk-PNGFWLHD.js.map +0 -1
  62. package/dist/chunk-Z7BI7DE7.js.map +0 -1
  63. package/dist/{domain-Cpmja5ak.d.ts → domain-JuWUUeJ3.d.ts} +51 -51
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/types/observability.ts","../src/types/bindings.ts","../src/row-query.ts","../src/types/row-set.ts","../src/types/binding.ts","../src/types/user.ts","../src/types/agent.ts","../src/types/plan.ts","../src/types/pattern.ts","../src/types/changeset.ts","../src/service-types.ts","../src/row-predicate.ts","../src/types/visit-key.ts","../src/types/guard-holds.ts","../src/types/effect-result.ts","../src/types/verification-ids.json","../src/types/verification.ts","../src/generated/language/validation-codes.json","../src/types/validation.ts","../src/types/living.ts","../src/types/a11y.ts","../src/types/surface.ts","../src/types/canvas-theme.ts","../src/types/eval-spec.ts","../src/types/tab-port.ts","../src/types/client-manifest.ts","../src/types/program-machine.ts","../src/types/program-inspection.ts"],"names":["z","row","index"],"mappings":";;;;;;;AAaO,IAAM,aAAkC,CAAC,QAAA,EAAU,QAAA,EAAU,IAAA,EAAM,SAAS,UAAU;AAuBtF,IAAM,cAAA,GAAyC,CAAC,OAAA,EAAS,MAAA,EAAQ,WAAW,OAAO;AAY1F,SAAS,WAAW,KAAA,EAAiD;AACnE,EAAA,OAAO,OAAO,UAAU,QAAA,IAAY,UAAA,CAAW,KAAK,CAAC,CAAA,KAAM,MAAM,KAAK,CAAA;AACxE;AAEA,SAAS,WAAW,KAAA,EAAoD;AACtE,EAAA,OAAO,OAAO,UAAU,QAAA,IAAY,cAAA,CAAe,KAAK,CAAC,CAAA,KAAM,MAAM,KAAK,CAAA;AAC5E;AAEA,SAAS,eAAe,KAAA,EAAuC;AAC7D,EAAA,OAAO,KAAA,KAAU,MAAA,IAAa,OAAO,KAAA,KAAU,QAAA;AACjD;AAGO,SAAS,aAAa,KAAA,EAAgE;AAC3F,EAAA,IAAI,UAAU,MAAA,IA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EAAG,OAAA,EAAS,iBAAiB,MAAA,EAAQ,2BAAA,CAA4B,QAAA,EAAS,EAAG,CAAC,CAAA;AAAA,EAChQ,SAAA,EAAWA,CAAAA,CAAE,KAAA,CAAM,yBAAyB,CAAA;AAAA,EAC5C,OAAA,EAASA,EAAE,KAAA,CAAMA,CAAAA,CAAE,OAAO,EAAE,IAAA,EAAMA,EAAE,MAAA,EAAO,EAAG,WAAWA,CAAAA,CAAE,MAAA,IAAU,OAAA,EAASA,CAAAA,CAAE,QAAO,EAAG,eAAA,EAAiB,mBAAA,EAAqB,CAAC,CAAA;AAAA,EACjI,IAAA,EAAMA,CAAAA,CAAE,KAAA,CAAM,eAAe,CAAA;AAAA,EAC7B,IAAA,EAAMA,EAAE,MAAA,EAAO;AAAA,EACf,OAAA,EAASA,EAAE,MAAA,EAAO,CAAE,KAAI,CAAE,WAAA,GAAc,QAAA,EAAS;AAAA,EACjD,cAAA,EAAgBA,CAAAA,CAAE,OAAA,CAAQ,gBAAgB,CAAA;AAAA,EAC1C,cAAA,EAAgBA,CAAAA,CAAE,OAAA,CAAQ,aAAa,CAAA;AAAA,EACvC,QAAA,EAAUA,CAAAA,CAAE,OAAA,CAAQ,CAAC,CAAA;AAAA,EACrB,UAAA,EAAYA,CAAAA,CAAE,OAAA,CAAQ,CAAC;AAC3B,CAAC","file":"chunk-VOFHP52Z.js","sourcesContent":["/**\n * Observability contract for a running app: one structured log line per entry (Cloud Logging's\n * JSON shape), optionally carrying a call record for one call the app made. `@almadar/logger`\n * writes these; a deployment's topology is read back from them.\n *\n * @packageDocumentation\n */\n\nimport { isJsonObject, type JsonObject, type JsonValue } from './json.js';\n\n/** What a call reached: a browser client, another server, a data store, a queue, or an external service. */\nexport type CallKind = 'client' | 'server' | 'db' | 'queue' | 'external';\n\nexport const CALL_KINDS: readonly CallKind[] = ['client', 'server', 'db', 'queue', 'external'];\n\n/** One call an app made, with its outcome. `error` is present only on a failed call. */\nexport interface CallRecord {\n kind: CallKind;\n /** The service reached: a data backend (`firestore`), an integration (`stripe`), a route prefix. */\n service: string;\n /** The operation: `list:Order`, `charge`, `POST /api/orbitals/:orbital/events`. */\n op: string;\n durationMs: number;\n ok: boolean;\n error?: string;\n}\n\n/** Which deployment a line came from. */\nexport interface LogContext {\n appId?: string;\n deploymentCommit?: string;\n}\n\n/** Cloud Logging severities used by structured lines. */\nexport type LogSeverity = 'DEBUG' | 'INFO' | 'WARNING' | 'ERROR';\n\nexport const LOG_SEVERITIES: readonly LogSeverity[] = ['DEBUG', 'INFO', 'WARNING', 'ERROR'];\n\n/** One structured log line. */\nexport interface StructuredLogEntry extends LogContext {\n severity: LogSeverity;\n time: string;\n namespace: string;\n message: string;\n data?: JsonObject;\n call?: CallRecord;\n}\n\nfunction isCallKind(value: JsonValue | undefined): value is CallKind {\n return typeof value === 'string' && CALL_KINDS.some((k) => k === value);\n}\n\nfunction isSeverity(value: JsonValue | undefined): value is LogSeverity {\n return typeof value === 'string' && LOG_SEVERITIES.some((s) => s === value);\n}\n\nfunction optionalString(value: JsonValue | undefined): boolean {\n return value === undefined || typeof value === 'string';\n}\n\n/** True when `value` is a complete call record; a successful call never carries an error. */\nexport function isCallRecord(value: JsonValue | undefined): value is JsonObject & CallRecord {\n if (value === undefined || !isJsonObject(value)) return false;\n const { kind, service, op, durationMs, ok, error } = value;\n if (!isCallKind(kind) || typeof service !== 'string' || typeof op !== 'string') return false;\n if (typeof durationMs !== 'number' || !Number.isFinite(durationMs) || durationMs < 0) return false;\n if (typeof ok !== 'boolean' || !optionalString(error)) return false;\n return !(ok && error !== undefined);\n}\n\n/** True when `value` is a structured log line, with a well-formed call record if it carries one. */\nexport function isStructuredLogEntry(value: JsonValue): value is JsonObject & StructuredLogEntry {\n if (!isJsonObject(value)) return false;\n const { severity, time, namespace, message, data, call, appId, deploymentCommit } = value;\n if (!isSeverity(severity) || typeof time !== 'string' || typeof namespace !== 'string' || typeof message !== 'string') return false;\n if (data !== undefined && !isJsonObject(data)) return false;\n if (call !== undefined && !isCallRecord(call)) return false;\n return optionalString(appId) && optionalString(deploymentCommit);\n}\n","/**\n * S-Expression Bindings\n *\n * Defines binding types and utilities for S-expression context.\n * Bindings are references to values that are resolved at runtime.\n *\n * Core Bindings:\n * - @entity - The linked entity for this trait (e.g., @entity.health)\n * - @payload - Event payload data (e.g., @payload.amount)\n * - @state - Current state machine state\n * - @now - Current timestamp (Date.now())\n *\n * Entity Bindings:\n * - @EntityName.field - Reference to singleton/runtime entity (e.g., @GameConfig.gravity)\n *\n * @packageDocumentation\n */\n\nimport { z } from 'zod';\n\n// Re-export core binding utilities from expression.ts\nexport {\n isBinding,\n parseBinding,\n isValidBinding,\n CORE_BINDINGS,\n type CoreBinding,\n type ParsedBinding,\n} from './expression.js';\nimport type { SExpr } from './expression.js';\nimport type { RuntimeValue } from './json.js';\n\n// ============================================================================\n// Binding Schema\n// ============================================================================\n\n/**\n * Schema for a binding string.\n * Validates that the string starts with @ and has valid format.\n */\nexport const BindingSchema = z.string().refine(\n (val) => {\n if (!val.startsWith('@')) return false;\n const parts = val.slice(1).split('.');\n if (parts.length === 0 || parts[0] === '') return false;\n // All parts must be valid identifiers (letters, numbers, underscore)\n // supporting unicode characters for i18n\n return parts.every((part) => /^[\\p{L}_][\\p{L}0-9_]*$/u.test(part));\n },\n { message: 'Invalid binding format. Must be @name or @name.path.to.field' }\n);\n\n// ============================================================================\n// Binding Constants\n// ============================================================================\n\n/**\n * Binding documentation for LLM prompts and validation messages.\n * \n * IMPORTANT: Keep synchronized with CORE_BINDINGS in expression.ts\n */\nexport const BINDING_DOCS = {\n entity: {\n description: 'Reference to the linked entity for this trait',\n examples: ['@entity.health', '@entity.x', '@entity.status'],\n requiresPath: true,\n },\n payload: {\n description: 'Reference to the event payload data',\n examples: ['@payload.amount', '@payload.targetId', '@payload.action'],\n requiresPath: true,\n },\n state: {\n description: 'Current state machine state name',\n examples: ['@state'],\n requiresPath: false,\n },\n now: {\n description: 'Current timestamp in milliseconds',\n examples: ['@now'],\n requiresPath: false,\n },\n config: {\n description: 'Trait configuration values',\n examples: ['@config.apiEndpoint', '@config.theme'],\n requiresPath: true,\n },\n computed: {\n description: 'Computed/calculated values',\n examples: ['@computed.total', '@computed.isValid'],\n requiresPath: true,\n },\n trait: {\n description: 'Trait context data',\n examples: ['@trait.name', '@trait.category'],\n requiresPath: true,\n },\n user: {\n description: 'Authenticated user / agent context for ownership and role-based gating',\n examples: ['@user.id', '@user.role'],\n requiresPath: true,\n },\n callsitePayload: {\n description:\n 'Call-site-captured event payload — emitted by the compiler\\'s inline-trait hoisting when an extracted render block captured @payload; resolved at the composing effect by the runtime BindingResolver',\n examples: ['@callsitePayload.error', '@callsitePayload.row'],\n requiresPath: true,\n },\n pages: {\n description:\n 'Render-resolved schema sigil — the host orbital\\'s pages as a NavItem[] array (href = page.path, label = page.name). Substituted from the OrbitalSchema before codegen; never survives as a live binding.',\n examples: ['@pages'],\n requiresPath: false,\n },\n currentTheme: {\n description:\n 'Render-resolved schema sigil — the host orbital\\'s active data-theme key, derived from Orbital.theme. Substituted from the OrbitalSchema before codegen; never survives as a live binding.',\n examples: ['@currentTheme'],\n requiresPath: false,\n },\n locale: {\n description: 'The active locale code (`en`, `ar`, `sl`, …) — the locale whose catalog `i18n/t` reads, set by the host from the route.',\n examples: ['@locale'],\n requiresPath: false,\n },\n event: {\n description: 'The delivery being processed: { event, payload, source } — for a listens delivery the source emit, with its BusEventSource envelope (Runtime Spec Clause 5.5)',\n examples: ['@event.event', '@event.payload.n', '@event.source.trait', '@event.source.tick'],\n requiresPath: false,\n },\n prevEvents: {\n description: 'The deliveries this trait already received in this dispatch, in order, each shaped like @event',\n examples: ['@prevEvents'],\n requiresPath: false,\n },\n prevStates: {\n description: 'The states this trait left in this dispatch, in order',\n examples: ['@prevStates'],\n requiresPath: false,\n },\n fromState: {\n description: \"The transition's source state\",\n examples: ['@fromState'],\n requiresPath: false,\n },\n toState: {\n description: \"The transition's target state (null in a listens `when`, where no transition is chosen yet)\",\n examples: ['@toState'],\n requiresPath: false,\n },\n} as const;\n\n/**\n * Validation rules for bindings in different contexts.\n */\nexport const BINDING_CONTEXT_RULES = {\n guard: {\n allowed: ['entity', 'payload', 'state', 'now', 'config', 'user', 'event', 'prevEvents', 'prevStates', 'fromState', 'toState'] as const,\n description:\n 'Guards can read the delivery being processed and this dispatch\\'s log (@event, @prevEvents, @prevStates) and the transition\\'s ends (@fromState, @toState; Runtime Spec Clause 5.5). Guards can access entity fields, event payload, current state, time, the call-site trait config (@config.X), and the authenticated user context (@user.id, @user.role) for ownership / role gates. Config access lets atoms write mode-aware guards — e.g. std-modal\\'s OPEN can require @payload.row only when @config.mode equals \"edit\", letting create-mode legitimately fire OPEN with no row. Like effects, @config.X is substituted at molecule/organism inline time with the literal call-site value; at atom-scope validate, @config is allowed-but-unresolved.',\n },\n effect: {\n allowed: ['entity', 'payload', 'state', 'now', 'trait', 'config', 'user', 'callsitePayload', 'pages', 'currentTheme', 'locale', 'event', 'prevEvents', 'prevStates', 'fromState', 'toState'] as const,\n description:\n 'Effects can access and modify entity fields, use payload data, embed another trait\\'s live frame via @trait.X inside render-ui children, read trait config values (@config.X) for atoms parameterized by their call-site, and read the authenticated user context (@user.id, @user.role). At molecule/organism inline time, @config.X is substituted with the literal value from the call-site config block; at atom-scope validate, @config is allowed-but-unresolved. @callsitePayload.X is the call-site-captured event payload emitted by the compiler\\'s inline-trait hoisting (a hoisted render block that captured @payload); it is resolved at the composing effect by the runtime BindingResolver.',\n },\n tick: {\n allowed: ['entity', 'state', 'now', 'config', 'user'] as const,\n description: 'Ticks can access entity fields, current state, time, trait config (@config.X) for parameterized atoms, and the authenticated user context (@user.id, @user.role). Same substitution semantics as guards/effects.',\n },\n} as const;\n\nexport type BindingContext = keyof typeof BINDING_CONTEXT_RULES;\n\n// ============================================================================\n// Render-Time Binding Markers\n// ============================================================================\n\n/**\n * Tag property of a `RenderBindingMarker`. `$`-prefixed so it can never\n * collide with a pattern prop key (prop keys are camelCase identifiers).\n */\nexport const RENDER_BINDING_MARKER = '$renderBinding' as const;\n\n/**\n * A render-ui prop leaf that is evaluated at RENDER time, not at flush time.\n *\n * The interpreted path's executor carries `@entity`-dependent leaves into\n * slot content as these markers instead of resolving them eagerly; the\n * renderer (`@almadar/ui`'s SlotContentRenderer) resolves each marker\n * against the live entity store on every render — the same model the\n * compiled shell uses (state-based JSX reading `fields?.X` per React\n * render). Payload-dependent leaves are never deferred: `@payload` is\n * event-scoped and does not exist at render time.\n *\n * A `type` (not `interface`) so it carries an implicit index signature and\n * stays assignable to the `SExpr` record branch at guard call sites.\n */\nexport type RenderBindingMarker = {\n readonly [RENDER_BINDING_MARKER]: true;\n /** The raw prop expression: a binding string (`'@entity.hp'`, embedded\n * form `'HP: @entity.hp'`) or an S-expression tree. */\n readonly expression: SExpr;\n};\n\n/** Narrow an arbitrary prop value to a `RenderBindingMarker`. */\nexport function isRenderBindingMarker(value: RuntimeValue): value is RenderBindingMarker {\n return (\n typeof value === 'object' &&\n value !== null &&\n !Array.isArray(value) &&\n RENDER_BINDING_MARKER in value &&\n value[RENDER_BINDING_MARKER] === true\n );\n}\n\n/** Matches a whole `@entity` token (path or bracket suffix allowed). */\nconst ENTITY_BINDING_RE = /@entity(?=[.\\[\\]]|$)/;\n\n/** Matches a whole `@payload` / `@callsitePayload` token. */\nconst PAYLOAD_BINDING_RE = /@(?:callsitePayload|payload)(?=[.\\[\\]]|$)/;\n\n/**\n * Does this raw prop expression reference `@entity` anywhere (pure binding,\n * embedded-binding string, nested S-expression, or object tree)? Marker\n * objects count as entity-referencing by construction.\n */\nexport function containsEntityBinding(value: SExpr): boolean {\n if (typeof value === 'string') return ENTITY_BINDING_RE.test(value);\n if (Array.isArray(value)) return value.some(containsEntityBinding);\n if (value !== null && typeof value === 'object') {\n if (isRenderBindingMarker(value)) return true;\n return Object.values(value as Record<string, SExpr>).some(containsEntityBinding);\n }\n return false;\n}\n\n/**\n * Does this raw prop expression reference the event payload (`@payload` /\n * `@callsitePayload`) anywhere? Such leaves stay flush-time evaluated —\n * the payload does not exist at render time.\n */\nexport function containsPayloadBinding(value: SExpr): boolean {\n if (typeof value === 'string') return PAYLOAD_BINDING_RE.test(value);\n if (Array.isArray(value)) return value.some(containsPayloadBinding);\n if (value !== null && typeof value === 'object') {\n return Object.values(value as Record<string, SExpr>).some(containsPayloadBinding);\n }\n return false;\n}\n\n// ============================================================================\n// Binding Validation Helpers\n// ============================================================================\n\n/**\n * Check if a binding is valid in a given context.\n *\n * @param binding - Parsed binding\n * @param context - Context where binding is used\n * @returns Error message if invalid, null if valid\n */\nexport function validateBindingInContext(\n binding: { type: 'core' | 'entity'; root: string },\n context: BindingContext\n): string | null {\n const rules = BINDING_CONTEXT_RULES[context];\n\n if (binding.type === 'core') {\n if (!(rules.allowed as readonly string[]).includes(binding.root)) {\n return `Binding @${binding.root} is not allowed in ${context} context. Allowed: ${rules.allowed.join(', ')}`;\n }\n }\n\n // Entity bindings are always allowed (they reference singletons/runtime entities)\n return null;\n}\n\n/**\n * Get all valid binding examples for a context.\n *\n * @param context - Context to get examples for\n * @returns Array of example binding strings\n */\nexport function getBindingExamples(context: BindingContext): string[] {\n const rules = BINDING_CONTEXT_RULES[context];\n const examples: string[] = [];\n\n for (const binding of rules.allowed) {\n const doc = BINDING_DOCS[binding];\n examples.push(...doc.examples);\n }\n\n // Add entity binding example\n examples.push('@GameConfig.gravity', '@Filter.searchTerm');\n\n return examples;\n}\n","/**\n * The one TypeScript definition of `RowPredicate` / `RowQuery` semantics. Every store that runs a\n * query in process (the memory adapter, the IndexedDB cursor pass, test oracles) goes through here;\n * stores that translate the query (SQL, Mango, Firestore) are tested against the same shared cases.\n */\nimport { z } from 'zod';\nimport { EntityRowSchema, FieldValueSchema, type EntityRow, type FieldValue } from './types/entity.js';\nimport type {\n QueryCapabilities,\n RowIdPage,\n RowPredicate,\n RowQuery,\n RowQueryPage,\n RowWriteBatch,\n RowWriteOp,\n RowWriteOutcome,\n WriteCapabilities,\n RowCommit,\n} from './service-types.js';\n\nconst CompareOpSchema = z.enum(['==', '!=', '<', '<=', '>', '>=']);\n\nexport const RowPredicateSchema: z.ZodType<RowPredicate> = z.lazy(() =>\n z.discriminatedUnion('kind', [\n z.object({ kind: z.literal('compare'), field: z.string(), op: CompareOpSchema, value: FieldValueSchema }),\n z.object({ kind: z.literal('member'), field: z.string(), values: z.array(FieldValueSchema) }),\n z.object({ kind: z.literal('hasElement'), field: z.string(), value: FieldValueSchema }),\n z.object({ kind: z.literal('contains'), field: z.string(), text: z.string(), caseSensitive: z.boolean() }),\n z.object({ kind: z.literal('isNull'), field: z.string(), isNull: z.boolean() }),\n z.object({ kind: z.literal('all'), of: z.array(RowPredicateSchema) }),\n z.object({ kind: z.literal('any'), of: z.array(RowPredicateSchema) }),\n z.object({ kind: z.literal('not'), of: RowPredicateSchema }),\n z.object({ kind: z.literal('const'), value: z.boolean() }),\n ]),\n);\n\nexport const RowQuerySchema: z.ZodType<RowQuery> = z.object({\n policy: RowPredicateSchema.optional(),\n filter: RowPredicateSchema.optional(),\n order: z.object({ field: z.string(), direction: z.enum(['asc', 'desc']) }).optional(),\n offset: z.number().int().nonnegative().optional(),\n limit: z.number().int().nonnegative().optional(),\n total: z.enum(['exact', 'none']).optional(),\n nearest: z.object({ field: z.string(), vector: z.array(z.number()), k: z.number().int().positive() }).optional(),\n});\n\nexport const RowIdPageSchema: z.ZodType<RowIdPage> = z.object({\n ids: z.array(z.string()),\n total: z.number().int().nonnegative(),\n});\n\nexport const RowWriteOpSchema: z.ZodType<RowWriteOp> = z.discriminatedUnion('kind', [\n z.object({ kind: z.literal('create'), entityType: z.string(), data: EntityRowSchema }),\n z.object({ kind: z.literal('upsert'), entityType: z.string(), data: EntityRowSchema }),\n z.object({ kind: z.literal('update'), entityType: z.string(), id: z.string(), data: EntityRowSchema, guard: RowPredicateSchema.optional() }),\n z.object({ kind: z.literal('delete'), entityType: z.string(), id: z.string(), guard: RowPredicateSchema.optional() }),\n z.object({ kind: z.literal('rekey'), entityType: z.string(), id: z.string(), newId: z.string().min(1), guard: RowPredicateSchema.optional() }),\n]);\n\nexport const RowWriteOutcomeSchema: z.ZodType<RowWriteOutcome> = z.discriminatedUnion('kind', [\n z.object({ kind: z.literal('created'), row: EntityRowSchema }),\n z.object({ kind: z.literal('updated'), row: EntityRowSchema, before: EntityRowSchema.optional() }),\n z.object({ kind: z.literal('deleted'), before: EntityRowSchema.optional() }),\n z.object({ kind: z.literal('not-found') }),\n z.object({ kind: z.literal('duplicate-id') }),\n z.object({ kind: z.literal('refused') }),\n z.object({ kind: z.literal('failed'), message: z.string() }),\n z.object({ kind: z.literal('rolled-back') }),\n]);\n\nexport const RowWriteBatchSchema: z.ZodType<RowWriteBatch> = z.object({\n ops: z.array(RowWriteOpSchema),\n onFailure: z.enum(['atomic', 'stop']),\n});\n\nconst LeafKindSchema = z.enum(['compare', 'member', 'hasElement', 'contains', 'isNull']);\nconst CombinatorSchema = z.enum(['all', 'any', 'not']);\nconst RowOperatorSchema = z.enum(['==', '!=', '<', '<=', '>', '>=', 'member', 'hasElement', 'contains']);\nconst RowValueKindSchema = z.enum(['string', 'number', 'boolean', 'date', 'null']);\n\nexport const RowCommitSchema: z.ZodType<RowCommit> = z.object({\n entityType: z.string(),\n id: z.string(),\n expected: EntityRowSchema.nullable(),\n write: z.discriminatedUnion('kind', [\n z.object({ kind: z.literal('keep') }),\n z.object({ kind: z.literal('put'), row: EntityRowSchema }),\n z.object({ kind: z.literal('delete') }),\n ]),\n});\n\nexport const QueryCapabilitiesSchema: z.ZodType<QueryCapabilities> = z.object({\n leaves: z.array(LeafKindSchema),\n combinators: z.array(CombinatorSchema),\n compareOps: z.array(CompareOpSchema),\n operatorValueKinds: z.array(z.object({ operator: RowOperatorSchema, valueKinds: z.array(RowValueKindSchema) })).optional(),\n orderableFields: z.discriminatedUnion('kind', [\n z.object({ kind: z.literal('every-field') }),\n z.object({ kind: z.literal('listed'), fields: z.array(z.string()) }),\n ]),\n window: z.boolean(),\n exactTotal: z.boolean(),\n idsOnly: z.boolean().optional(),\n nearest: z.boolean().optional(),\n});\n\nexport const WriteCapabilitiesSchema: z.ZodType<WriteCapabilities> = z.object({\n guards: z.object({ leaves: z.array(LeafKindSchema), combinators: z.array(CombinatorSchema), compareOps: z.array(CompareOpSchema) }),\n conditional: z.boolean(),\n returnsRow: z.boolean(),\n stopRuns: z.boolean(),\n atomicBatch: z.boolean(),\n rekey: z.boolean().optional(),\n commitRows: z.boolean().optional(),\n});\n\nexport const RowQueryPageSchema: z.ZodType<RowQueryPage> = z.object({\n rows: z.array(EntityRowSchema),\n total: z.number().int().nonnegative(),\n});\n\ntype Comparable = string | number | boolean;\n\nfunction isMissing(value: FieldValue | undefined): value is null | undefined {\n return value === null || value === undefined;\n}\n\nfunction comparable(value: FieldValue | undefined): value is Comparable {\n return typeof value === 'string' || typeof value === 'number' || typeof value === 'boolean';\n}\n\nfunction codePointOrder(a: string, b: string): number {\n const x = Array.from(a);\n const y = Array.from(b);\n const n = Math.min(x.length, y.length);\n for (let i = 0; i < n; i++) {\n const cx = x[i].codePointAt(0) ?? 0;\n const cy = y[i].codePointAt(0) ?? 0;\n if (cx !== cy) return cx < cy ? -1 : 1;\n }\n return x.length === y.length ? 0 : x.length < y.length ? -1 : 1;\n}\n\n/** Order of two present values of one kind (binary order for strings); null when the kinds differ. */\nfunction orderValues(a: Comparable, b: Comparable): number | null {\n if (typeof a === 'string' && typeof b === 'string') return codePointOrder(a, b);\n if (typeof a === 'number' && typeof b === 'number') return a === b ? 0 : a < b ? -1 : 1;\n if (typeof a === 'boolean' && typeof b === 'boolean') return a === b ? 0 : a ? 1 : -1;\n return null;\n}\n\nfunction sameValue(a: FieldValue | undefined, b: FieldValue | undefined): boolean {\n return a === b;\n}\n\nfunction compareLeaf(value: FieldValue | undefined, op: RowPredicate & { kind: 'compare' }): boolean {\n const target = op.value;\n if (isMissing(value)) return op.op === '!=' && !isMissing(target);\n switch (op.op) {\n case '==': return sameValue(value, target);\n case '!=': return !sameValue(value, target);\n default: {\n if (!comparable(value) || !comparable(target)) return false;\n const c = orderValues(value, target);\n if (c === null) return false;\n if (op.op === '<') return c < 0;\n if (op.op === '<=') return c <= 0;\n if (op.op === '>') return c > 0;\n return c >= 0;\n }\n }\n}\n\n/** Full Unicode case folding as `toUpperCase` then `toLowerCase` gives it: `ß` = `SS` = `ss`, `ς` = `σ`. */\nfunction foldCase(text: string): string {\n return text.toUpperCase().toLowerCase();\n}\n\ntype MemberLookup = Set<FieldValue>;\n\n// A member list is scanned once per predicate, not once per row.\nconst memberLookups = new WeakMap<RowPredicate & { kind: 'member' }, MemberLookup>();\n\nfunction memberLookup(predicate: RowPredicate & { kind: 'member' }): MemberLookup {\n const cached = memberLookups.get(predicate);\n if (cached !== undefined) return cached;\n const lookup: MemberLookup = new Set(predicate.values);\n memberLookups.set(predicate, lookup);\n return lookup;\n}\n\nexport function rowMatchesPredicate(row: EntityRow, predicate: RowPredicate): boolean {\n switch (predicate.kind) {\n case 'const': return predicate.value;\n case 'all': return predicate.of.every((p) => rowMatchesPredicate(row, p));\n case 'any': return predicate.of.some((p) => rowMatchesPredicate(row, p));\n case 'not': return !rowMatchesPredicate(row, predicate.of);\n case 'compare': return compareLeaf(row[predicate.field], predicate);\n case 'isNull': return isMissing(row[predicate.field]) === predicate.isNull;\n case 'member': {\n const value = row[predicate.field];\n if (isMissing(value)) return false;\n const lookup = memberLookup(predicate);\n return !Number.isNaN(value) && lookup.has(value);\n }\n case 'hasElement': {\n const value = row[predicate.field];\n return Array.isArray(value) && value.some((v) => sameValue(v, predicate.value));\n }\n case 'contains': {\n const value = row[predicate.field];\n if (typeof value !== 'string') return false;\n return predicate.caseSensitive\n ? value.includes(predicate.text)\n : foldCase(value).includes(foldCase(predicate.text));\n }\n }\n}\n\nexport interface RowWriteResult {\n rows: EntityRow[];\n outcome: RowWriteOutcome;\n}\n\nfunction rowIdOf(row: EntityRow): string | null {\n return typeof row.id === 'string' ? row.id : null;\n}\n\n/** The reference run of one write over a full row set; the input is not mutated. */\nexport function runRowWrite(rows: readonly EntityRow[], op: RowWriteOp): RowWriteResult {\n if (op.kind === 'rekey') return { rows: [...rows], outcome: { kind: 'failed', message: 'rekey is unsupported by this store' } };\n if (op.kind === 'create') {\n const id = rowIdOf(op.data);\n if (id === null) return { rows: [...rows], outcome: { kind: 'failed', message: 'create needs a string id' } };\n if (rows.some((r) => r.id === id)) return { rows: [...rows], outcome: { kind: 'duplicate-id' } };\n const row: EntityRow = { ...op.data };\n return { rows: [...rows, row], outcome: { kind: 'created', row } };\n }\n if (op.kind === 'upsert') {\n const id = rowIdOf(op.data);\n if (id === null) return { rows: [...rows], outcome: { kind: 'failed', message: 'upsert needs a string id' } };\n const index = rows.findIndex((r) => r.id === id);\n if (index < 0) {\n const row: EntityRow = { ...op.data };\n return { rows: [...rows, row], outcome: { kind: 'created', row } };\n }\n const kept = rows[index].createdAt;\n const row: EntityRow = kept === undefined ? { ...op.data } : { ...op.data, createdAt: kept };\n return { rows: rows.map((r, i) => (i === index ? row : r)), outcome: { kind: 'updated', row } };\n }\n const index = rows.findIndex((r) => r.id === op.id);\n if (index < 0) return { rows: [...rows], outcome: { kind: 'not-found' } };\n const before = rows[index];\n if (op.guard !== undefined && !rowMatchesPredicate(before, op.guard)) return { rows: [...rows], outcome: { kind: 'refused' } };\n const guarded = op.guard !== undefined ? { before } : {};\n if (op.kind === 'delete') {\n return { rows: rows.filter((_, i) => i !== index), outcome: { kind: 'deleted', ...guarded } };\n }\n const row: EntityRow = { ...before, ...op.data, id: op.id };\n return { rows: rows.map((r, i) => (i === index ? row : r)), outcome: { kind: 'updated', row, ...guarded } };\n}\n\nfunction applied(outcome: RowWriteOutcome): boolean {\n return outcome.kind === 'created' || outcome.kind === 'updated' || outcome.kind === 'deleted';\n}\n\nexport interface RowWriteBatchResult {\n rows: EntityRow[];\n outcomes: RowWriteOutcome[];\n}\n\n/** Capabilities of a store that runs every query form, vector search included; a store that cannot rank by similarity overrides `nearest: false`. */\nconst FULL_QUERY_CAPABILITIES: QueryCapabilities = {\n leaves: ['compare', 'member', 'hasElement', 'contains', 'isNull'],\n combinators: ['all', 'any', 'not'],\n compareOps: ['==', '!=', '<', '<=', '>', '>='],\n orderableFields: { kind: 'every-field' },\n window: true,\n exactTotal: true,\n nearest: true,\n};\n\n/** Capabilities for conditional writes, ordered runs and transactional batches; rekey requires an explicit declaration. */\nexport const FULL_WRITE_CAPABILITIES: WriteCapabilities = {\n guards: { leaves: FULL_QUERY_CAPABILITIES.leaves, combinators: FULL_QUERY_CAPABILITIES.combinators, compareOps: FULL_QUERY_CAPABILITIES.compareOps },\n conditional: true,\n returnsRow: true,\n stopRuns: true,\n atomicBatch: true,\n};\n\nexport type QueryUnsupportedReason =\n | 'leaf-unsupported'\n | 'combinator-unsupported'\n | 'value-kind-unsupported'\n | 'order-field'\n | 'window'\n | 'exact-total'\n | 'nearest';\n\nexport type QueryDeclinedReason = QueryUnsupportedReason | 'ids-only';\n\n/** What a store throws when it declines a pushed-down query it cannot run; nothing was read. */\nexport class QueryDeclinedError extends Error {\n readonly reason: QueryDeclinedReason;\n\n constructor(reason: QueryDeclinedReason, message?: string) {\n super(message ?? `query declined: ${reason}`);\n this.name = 'QueryDeclinedError';\n this.reason = reason;\n }\n}\n\nexport type WriteDeclinedReason = 'atomic-batch' | 'no-transaction' | 'guard-value-kind';\n\n/** What a store throws when it declines a pushed-down write shape it did not declare; nothing was written. */\nexport class WriteDeclinedError extends Error {\n readonly reason: WriteDeclinedReason;\n\n constructor(reason: WriteDeclinedReason, message?: string) {\n super(message ?? `write declined: ${reason}`);\n this.name = 'WriteDeclinedError';\n this.reason = reason;\n }\n}\n","import { z } from \"zod\";\nimport { RowQuerySchema } from \"../row-query.js\";\nimport type { RowQuery } from \"../service-types.js\";\nimport type { RuntimeValue } from \"./json.js\";\n\n/**\n * A fetched page by reference: `ids` = the window in order, `total` = matches before the window at\n * dispatch time, `query` = what produced it (its predicates, incl. the @read policy, re-count `total`; order and window are ignored).\n */\nexport type RowSetRef = {\n entityType: string;\n ids: string[];\n total: number;\n query: RowQuery;\n};\n\nexport const RowSetRefSchema: z.ZodType<RowSetRef> = z.object({\n entityType: z.string(),\n ids: z.array(z.string()),\n total: z.number().int().nonnegative(),\n query: RowQuerySchema,\n});\n\n/** Tag property of a `RowSetMarker`; `$`-prefixed so it never collides with a pattern prop key. */\nexport const ROW_SET_MARKER = \"$rowSet\" as const;\n\n/** A render prop leaf resolved to rows at paint time by the kernel (`@read` applied there). */\nexport type RowSetMarker = {\n readonly [ROW_SET_MARKER]: true;\n readonly ref: RowSetRef;\n};\n\nexport function rowSetMarker(ref: RowSetRef): RowSetMarker {\n return { [ROW_SET_MARKER]: true, ref };\n}\n\nexport function isRowSetMarker(value: RuntimeValue): value is RowSetMarker {\n return (\n typeof value === \"object\" &&\n value !== null &&\n !Array.isArray(value) &&\n ROW_SET_MARKER in value &&\n value[ROW_SET_MARKER] === true &&\n \"ref\" in value &&\n RowSetRefSchema.safeParse(value.ref).success\n );\n}\n","/**\n * Binding root classification\n *\n * The prefix of an `@X.path` binding expression identifies which runtime\n * context resolves the rest of the path. This type is the TS-side mirror\n * of `OirBindingRoot` in `orbital-core`'s IR; publishing it from\n * `@almadar/core` lets the codegen, the runtime binding resolver, and\n * the verifier's schema walker all refer to the same narrow union.\n *\n * Distinct from {@link ParsedBinding.root} (which is a plain string): use\n * `BindingRoot` whenever you need exhaustiveness over the known prefixes.\n *\n * - `entity`: `@entity.field` — the trait's linked entity (first row on\n * the client, `getById` result on the server).\n * - `payload`: `@payload.x` — the last event's payload.\n * - `state`: `@state.x` — the state machine's `state` slot (rare;\n * mostly used for guard/effect contexts).\n * - `config`: `@config.x` — the trait ref's merged config from the\n * molecule call site.\n * - `user`: `@user.x` — authenticated user / agent context.\n * - `trait`: `@trait.x` — render-time reference to another trait's\n * mounted view. Resolved by `<TraitFrame>` at runtime, not by the\n * SExpression compiler.\n * - `now`: `@now` — the dispatch's one timestamp (Runtime Spec Clause 8.5).\n * - `callsitePayload`: `@callsitePayload.x` — a composing transition's\n * payload captured for an inlined child trait (compiler-produced).\n * - `pages` / `currentTheme`: render-resolved schema sigils (no path).\n * - `event`, `prevEvents`, `prevStates`, `fromState`, `toState`: the delivery\n * being processed and this dispatch's log (Runtime Spec Clause 5.5).\n * - `other`: not a root — a lambda/let local (`@item`) or an\n * entity-reference binding (`@User.name`).\n *\n * The author-facing roots are the i18n `sigils` table; the orbital-compiler\n * validator's `CORE_BINDING_ROOTS` is the same set as `BINDING_ROOTS` minus `other`.\n *\n * @packageDocumentation\n */\n\nimport { z } from 'zod';\nimport type { RuntimeValue } from './json.js';\n\nexport type BindingRoot =\n | 'entity'\n | 'payload'\n | 'state'\n | 'now'\n | 'config'\n | 'trait'\n | 'user'\n | 'callsitePayload'\n | 'pages'\n | 'currentTheme'\n | 'locale'\n | 'event'\n | 'prevEvents'\n | 'prevStates'\n | 'fromState'\n | 'toState'\n | 'fromEntity'\n | 'other';\n\n/** Every known binding root, in a stable order — useful for exhaustiveness checks. */\nexport const BINDING_ROOTS: readonly BindingRoot[] = [\n 'entity',\n 'payload',\n 'state',\n 'now',\n 'config',\n 'trait',\n 'user',\n 'callsitePayload',\n 'pages',\n 'currentTheme',\n 'locale',\n 'event',\n 'prevEvents',\n 'prevStates',\n 'fromState',\n 'toState',\n 'fromEntity',\n 'other',\n] as const;\n\nconst KNOWN_ROOTS = new Set<string>(BINDING_ROOTS.filter((r) => r !== 'other'));\n\n/**\n * Narrow a raw binding-root string (e.g. the `root` field of\n * `ParsedBinding` from `./expression.ts`) to a `BindingRoot`. Returns\n * `'other'` for entity-reference roots like `@User.name` or unknown\n * prefixes.\n */\nexport function toBindingRoot(root: string): BindingRoot {\n return KNOWN_ROOTS.has(root) ? (root as BindingRoot) : 'other';\n}\n\n/**\n * A trait reference string of the form `@trait.<TraitName>`. Used as the\n * value type for `trait`-typed config fields. The runtime + compiled codegen\n * both substitute this with embedded trait UI at render time.\n *\n * Branded as a literal-template type so TS narrows on use; consumers should\n * call {@link isTraitFieldRef} to validate runtime values before assignment.\n */\nexport type TraitFieldRef = `@trait.${string}`;\n\nconst TRAIT_REF_PATTERN = /^@trait\\.[A-Z][a-zA-Z0-9]*$/;\n\n/** Type guard: narrow an unknown value to {@link TraitFieldRef}. */\nexport function isTraitFieldRef(value: RuntimeValue): value is TraitFieldRef {\n return typeof value === 'string' && TRAIT_REF_PATTERN.test(value);\n}\n\n/** Zod schema for {@link TraitFieldRef} values. Useful when validating analyzer\n * JSON or recipe overrides at runtime boundaries. */\nexport const TraitFieldRefSchema = z\n .string()\n .regex(TRAIT_REF_PATTERN, 'expected `@trait.<TraitName>` reference');\n","/**\n * Authenticated user context — what `@user.x` resolves against.\n *\n * The canonical shape for the `user` binding root, shared by both execution\n * paths: the JS interpreter resolves `@user.id` through\n * `EvaluationContext.user`, and the compiled shell emits `user?.id` against the\n * `UserContext` its `@app/shared` re-exports from here.\n *\n * `id` is the field the behavior library reads for ownership scoping and `role`\n * the field it reads for capability gating. Auth providers that name the subject\n * `uid` must normalize at their boundary — {@link normalizeUserContext} does that.\n *\n * @packageDocumentation\n */\n\nimport { z } from 'zod';\nimport { FieldValueSchema, type FieldValue } from './entity.js';\nimport { JsonValueSchema } from './json.js';\nimport type { Claim, Viewer } from '../generated/kernel-wire.js';\n\nexport type { Claim, Viewer };\n\n/**\n * What a host's auth provider has resolved the viewer to be — from session\n * resolution only, never from an interactive sign-in action: `pending` until\n * the session is known; `anonymous` / `authenticated` once it is; `failed`\n * when connecting or resolving the session failed; `unavailable` when the host\n * has no sign-in configured. An `access: authenticated` page mounts only on\n * `authenticated`.\n */\nexport type ViewerAuthority = 'pending' | 'anonymous' | 'authenticated' | 'failed' | 'unavailable';\n\n/**\n * The `@user` binding: a {@link Viewer} held flat. Its named fields are the viewer's; each claim is a key holding its\n * JSON value, readable as `@user.<claim>`. The Rust twin of the conversion is `orbital_core_base::viewer`\n * (`Viewer::from_user` / `Viewer::to_user`).\n */\nexport type UserContext = Omit<Viewer, 'claims'> & { [key: string]: FieldValue };\n\nconst ClaimSchema: z.ZodType<Claim> = z.object({ name: z.string(), value: JsonValueSchema });\n\n/** Zod twin of the generated {@link Viewer}: the record a `.lolo` program names as `Viewer`. */\nexport const ViewerSchema: z.ZodType<Viewer> = z.object({\n id: z.string(),\n email: z.string().nullish(),\n name: z.string().nullish(),\n role: z.string().optional(),\n permissions: z.array(z.string()).optional(),\n claims: z.array(ClaimSchema),\n});\n\n/**\n * The identity of an unauthenticated viewer. A resolvable object rather than\n * `undefined` so a role predicate evaluates to a definite `false` instead of\n * comparing against nothing.\n */\nexport const ANONYMOUS_USER: UserContext = {\n id: 'anonymous',\n role: 'anonymous',\n permissions: [],\n};\n\n/** Provider-shaped identity claims, before normalization. */\nexport type RawUserClaims = {\n id?: string;\n uid?: string;\n email?: string | null;\n name?: string | null;\n displayName?: string | null;\n /** Absent or `null` when the token carries none, as the kernel's `Viewer.role` (`Option`). */\n role?: string | null;\n permissions?: string[] | null;\n} & { [key: string]: FieldValue };\n\n/** Zod twin of `RawUserClaims` — the wire shape of `EventRequest.user`. */\nexport const RawUserClaimsSchema: z.ZodType<RawUserClaims> = z\n .object({\n id: z.string().optional(),\n uid: z.string().optional(),\n email: z.string().nullable().optional(),\n name: z.string().nullable().optional(),\n displayName: z.string().nullable().optional(),\n role: z.string().nullable().optional(),\n permissions: z.array(z.string()).nullable().optional(),\n })\n .catchall(FieldValueSchema);\n\n/** Claim keys a `null` leaves absent, as the kernel's `Viewer` reads them (`Option`). */\nconst NONE_WHEN_NULL_CLAIM_KEYS: readonly string[] = ['role', 'permissions'];\n\n/** Claim keys {@link normalizeUserContext} derives rather than copies verbatim. */\nconst DERIVED_CLAIM_KEYS: readonly string[] = ['id', 'name', 'displayName', 'email'];\n\n/**\n * Normalize provider claims into a {@link UserContext}.\n *\n * Firebase (and most OIDC providers) name the subject `uid` and the display name\n * `displayName`, while every `.lolo` behavior reads `@user.id` / `@user.name`.\n * Without this normalization `@user.id` is `undefined` against a fully\n * authenticated request and every ownership filter silently matches no rows.\n * `uid` is preserved so `@user.uid` keeps working.\n *\n * Returns `undefined` for absent or subject-less claims so callers can\n * distinguish \"no auth ran\" from \"anonymous\"; use {@link ANONYMOUS_USER} where a\n * definite identity is required.\n */\nexport function normalizeUserContext(\n claims: RawUserClaims | null | undefined,\n): UserContext | undefined {\n if (!claims) return undefined;\n const id = claims.id ?? claims.uid;\n if (typeof id !== 'string' || id.length === 0) return undefined;\n\n const user: UserContext = { id };\n for (const [key, value] of Object.entries(claims)) {\n if (value === undefined || DERIVED_CLAIM_KEYS.includes(key)) continue;\n if (value === null && NONE_WHEN_NULL_CLAIM_KEYS.includes(key)) continue;\n user[key] = value;\n }\n\n const name = claims.name ?? claims.displayName;\n if (typeof name === 'string' && name.length > 0) user.name = name;\n if (typeof claims.email === 'string' && claims.email.length > 0) user.email = claims.email;\n\n return user;\n}\n\n/**\n * Turn a row of an app's `[identity]` entity into a viewer.\n *\n * There is no separate persona shape: an identity row IS the persona\n * (`Almadar_LOLO_Identity.md` §4.3), so this only guards the one field the\n * behavior library requires — a non-empty string `id` — and passes every other\n * declared field through as a `@user.<field>` claim. Rows without a usable id\n * yield `undefined` rather than a persona nobody can own rows as.\n */\nexport function personaFromIdentityRow(\n row: Record<string, FieldValue | undefined>,\n): UserContext | undefined {\n const id = row['id'];\n if (typeof id !== 'string' || id.length === 0) return undefined;\n const persona: UserContext = { id };\n for (const [key, value] of Object.entries(row)) {\n if (key === 'id' || value === undefined) continue;\n persona[key] = value;\n }\n return persona;\n}\n\n/** Look a persona up in a roster by id, or by role when no id matches. */\nexport function findPersonaInRoster(\n roster: readonly UserContext[],\n idOrRole: string,\n): UserContext | undefined {\n return (\n roster.find((p) => p.id === idOrRole) ??\n roster.find((p) => p.role === idOrRole)\n );\n}\n\n/**\n * Resolve a persona spec — a bare id/role (`Person Id 3`, `moderator`) or a full\n * JSON `UserContext` — into a viewer. This is the `ALMADAR_PERSONA` contract,\n * shared by every host that presents an app as somebody.\n *\n * The roster is the app's OWN declared personas — the seeded rows of its\n * `[identity]` entity (`Almadar_LOLO_Identity.md` §4.3) — supplied by the host\n * that has them in hand (the runtime's live store on the interpreter path, the\n * schema-derived seed rows on the compiled path). There is no global roster:\n * an app without an `[identity]` entity resolves only JSON-form specs.\n *\n * Throws on anything unresolvable rather than returning `undefined`: \"no persona\"\n * and \"persona silently ignored\" look identical on screen, so a bad spec must\n * fail at boot instead of rendering as nobody.\n */\nexport function resolvePersonaSpec(spec: string, roster: readonly UserContext[]): UserContext {\n const raw = spec.trim();\n if (!raw.startsWith('{')) {\n const declared = findPersonaInRoster(roster, raw);\n if (!declared) {\n const known = roster.map((p) => `${p.id}/${p.role ?? '-'}`).join(', ');\n throw new Error(\n `Persona \"${raw}\" is not a declared persona id or role. ` +\n (roster.length > 0\n ? `Known: ${known}`\n : 'This app declares no [identity] entity, so only the JSON persona form is accepted.'),\n );\n }\n return declared;\n }\n let claims: RawUserClaims;\n try {\n claims = JSON.parse(raw);\n } catch {\n throw new Error(`Persona is not valid JSON: ${raw}`);\n }\n const user = normalizeUserContext(claims);\n if (!user) {\n throw new Error(`Persona needs an \"id\" (or \"uid\"): ${raw}`);\n }\n return user;\n}\n","/**\n * Agent Types\n *\n * Defines the AgentContext interface and related types for the agent/* operator namespace.\n * These types are the contract between operators (language) and implementation (runtime).\n *\n * @packageDocumentation\n */\n\nimport type { ServiceParams } from './service.js';\nimport type { EventPayloadValue } from './expression.js';\nimport type { FieldValue } from './entity.js';\nimport type { JsonSchema } from '../factory/types.js';\nimport type { ValidationError } from './validation.js';\nimport type { Orbital } from './orbital.js';\nimport type { OrbitalSchema } from './schema.js';\nimport type { JsonValue, RuntimeValue } from './json.js';\nimport type { AnalysisResult, PlanSnapshot } from './plan.js';\n\n// ============================================================================\n// Agent Memory Types\n// ============================================================================\n\n/**\n * Categories for agent memories.\n */\nexport type AgentMemoryCategory =\n | 'preference'\n | 'correction'\n | 'pattern-affinity'\n | 'entity-template'\n | 'error-resolution';\n\n/**\n * A single memory record stored by the agent.\n */\nexport interface AgentMemoryRecord {\n /** Unique memory identifier */\n id: string;\n /** Memory content (natural language) */\n content: string;\n /** Memory category */\n category: AgentMemoryCategory;\n /** Strength value (0.0-1.0), decays over time unless pinned */\n strength: number;\n /** Whether this memory is pinned (immune to decay) */\n pinned: boolean;\n /** Memory scope */\n scope: 'global' | 'project';\n /** ISO timestamp of last access */\n lastAccessedAt: string;\n /** ISO timestamp of creation */\n createdAt: string;\n}\n\n// ============================================================================\n// Agent Context Types\n// ============================================================================\n\n/**\n * Strategy for context compaction.\n */\nexport type AgentCompactStrategy = 'hybrid' | 'summarize' | 'truncate' | 'extract';\n\n/**\n * Result of a context compaction operation.\n */\nexport interface AgentCompactResult {\n /** Token count before compaction */\n before: number;\n /** Token count after compaction */\n after: number;\n /** Strategy used */\n strategy: AgentCompactStrategy;\n /** Optional summary generated during compaction */\n summary?: string;\n}\n\n// ============================================================================\n// Agent LLM Types\n// ============================================================================\n\n/**\n * Options for agent/generate calls.\n */\nexport interface AgentGenerateOptions {\n /** LLM provider override */\n provider?: string;\n /** Model override */\n model?: string;\n /** Maximum tokens to generate */\n maxTokens?: number;\n}\n\n// ============================================================================\n// LLM Tool-Calling Contract Types\n// ============================================================================\n//\n// These are the LANGUAGE-LEVEL contract types for the llm/* substrate\n// operators. The provider chat-completion types are the WIRE FORMAT; the\n// runtime handler maps between them. Defined here so\n// the dependency direction stays core → nothing.\n\n/**\n * A message in an LLM tool-calling conversation.\n */\nexport interface LlmMessage {\n role: 'system' | 'user' | 'assistant' | 'tool';\n content: string;\n /** Present on assistant messages that called tools. */\n toolCalls?: ReadonlyArray<LlmToolCall>;\n /** Present on tool-role messages — matches the preceding toolCall's id. */\n toolCallId?: string;\n}\n\n/**\n * A tool call requested by the assistant.\n */\nexport interface LlmToolCall {\n id: string;\n name: string;\n /** JSON-encoded arguments string (as returned by the LLM). */\n arguments: string;\n}\n\n/**\n * A tool definition passed to llm/call-tools.\n */\nexport interface LlmToolDef {\n name: string;\n description: string;\n /** JSON Schema describing the tool's parameters. */\n parameters: JsonSchema;\n}\n\n/**\n * Result of llm/call-tools.\n */\nexport interface LlmCallToolsResult {\n /** The assistant's text response (may be empty when only tool_calls fired). */\n content: string;\n /** Tool calls the assistant requested, if any. */\n toolCalls?: ReadonlyArray<LlmToolCall>;\n /** Token usage from the call. */\n usage: LlmTokenUsage;\n}\n\n/**\n * Token usage from an LLM call.\n */\nexport interface LlmTokenUsage {\n prompt: number;\n completion: number;\n total: number;\n}\n\n// ============================================================================\n// Agent Search Types\n// ============================================================================\n\n/**\n * Result from agent/search-code.\n */\nexport interface AgentCodeSearchResult {\n /** Repository name (owner/repo) */\n repo: string;\n /** File path within the repository */\n path: string;\n /** URL to the file */\n url: string;\n}\n\n// ============================================================================\n// Substrate Result Types\n// ============================================================================\n//\n// Language-level contracts for compose/behavior/validate operator returns.\n// Defined in @almadar/core (not @almadar-io/rabit) because the compiled path\n// also needs them — emitted TS code references these types without depending\n// on rabit. rabit's TS implementations produce/consume these shapes.\n\n/** Result of validate/validate for a single orbital or the composed schema. */\nexport interface ValidateResult {\n valid: boolean;\n errorCount: number;\n errors: ValidationError[];\n orbitalName?: string;\n}\n\n/** Result of the repair service. */\nexport interface RepairResult {\n orbitalName: string;\n success: boolean;\n attempt: number;\n paramsChanged: boolean;\n error?: string;\n}\n\n/** Result of the planner service. */\nexport interface PlannerResult {\n organism: string;\n operationCount: number;\n pendingQuestions: boolean;\n cached: boolean;\n success: boolean;\n error?: string;\n}\n\n/** Result of the executor (spawn-subagents). */\nexport interface ExecutePlanResult {\n dispatchedOrbitals: string[];\n noopForBuild: boolean;\n success: boolean;\n error?: string;\n}\n\n/** Result of dispatch-updates. */\nexport interface DispatchUpdatesResult {\n updatedOrbitals: string[];\n updateCount: number;\n success: boolean;\n}\n\n/** Discriminated union of all substrate service-call results. */\nexport type ServiceCallResult =\n | ValidateResult\n | RepairResult\n | PlannerResult\n | ExecutePlanResult\n | DispatchUpdatesResult;\n\n// ============================================================================\n// Session History\n// ============================================================================\n\n/** A single entry in an orbital's session history (build/conversation log). */\nexport interface SessionHistoryEntry {\n /** Role of the entry's author (e.g. 'user', 'assistant', 'system') */\n role: string;\n /** Entry content (natural language or structured description) */\n content: string;\n /** Epoch milliseconds when the entry was recorded */\n timestamp: number;\n}\n\n/**\n * Runtime guard for `SessionHistoryEntry` — narrows interpreter-produced\n * `unknown` values at the `SessionContext.appendHistory` boundary.\n */\nexport function isSessionHistoryEntry(value: RuntimeValue): value is SessionHistoryEntry {\n if (typeof value !== 'object' || value === null) return false;\n return (\n 'role' in value && typeof value.role === 'string' &&\n 'content' in value && typeof value.content === 'string' &&\n 'timestamp' in value && typeof value.timestamp === 'number'\n );\n}\n\n// ============================================================================\n// Agent Context Interface\n// ============================================================================\n\n/**\n * AgentContext is the runtime contract for agent/* operators.\n *\n * The evaluator dispatches agent/* operators to methods on this interface.\n * Pure methods (usable in guards) return synchronously.\n * Effect methods return Promises.\n *\n * When ctx.agent is undefined, operators return safe defaults ([], 0, false, \"\").\n * Implementations live in @almadar-io/agent-runtime (Phase 2B).\n */\nexport interface AgentContext {\n // Memory (pure)\n recall(query: string, limit?: number): AgentMemoryRecord[];\n memories(category?: AgentMemoryCategory): AgentMemoryRecord[];\n memoryStrength(id: string): number;\n isPinned(id: string): boolean;\n\n // Memory (effects)\n memorize(content: string, category: AgentMemoryCategory, scope?: 'global' | 'project'): Promise<string>;\n forget(id: string): Promise<void>;\n pin(id: string): Promise<void>;\n reinforce(id: string): Promise<void>;\n decay(): Promise<number>;\n\n // LLM (pure)\n provider(): string;\n model(): string;\n\n // LLM (effects)\n generate(prompt: string, options?: AgentGenerateOptions): Promise<string>;\n switchProvider(provider: string, model?: string): void;\n\n // Tools (pure)\n tools(): string[];\n\n // Tools (effects)\n invoke(toolName: string, args: ServiceParams): Promise<EventPayloadValue>;\n\n // Context (pure)\n tokenCount(): number;\n contextUsage(): number;\n\n // Context (effects)\n compact(strategy?: AgentCompactStrategy): Promise<AgentCompactResult>;\n\n // Session (pure)\n sessionId(): string;\n\n // Session (effects)\n fork(label?: string): Promise<string>;\n label(text: string): void;\n\n // Search (effects)\n searchCode(query: string, language?: string): Promise<AgentCodeSearchResult[]>;\n}\n\n// ============================================================================\n// Substrate Context Interfaces\n// ============================================================================\n//\n// Focused runtime contracts for the substrate operator namespaces. Each\n// interface backs one module of operators (llm/*, workspace/*, etc.). The\n// evaluator reads from ctx.<namespace>; the runtime (rabit) supplies\n// concrete implementations via contextExtensions. When a context is\n// undefined, operators return safe defaults (matching the agent/* pattern).\n\n/** Backs the llm/* operators (6 ops). */\nexport interface LlmContext {\n generate(prompt: string, options?: { json?: boolean; maxTokens?: number; provider?: string; model?: string }): Promise<string>;\n callTools(messages: LlmMessage[], tools: LlmToolDef[]): Promise<LlmCallToolsResult>;\n embed(texts: string[]): Promise<number[][]>;\n tokenCount(): number;\n switchProvider(provider: string, model?: string): void;\n compact(strategy?: string): Promise<{ before: number; after: number }>;\n}\n\n/** Backs the workspace/* operators (11 ops). */\nexport interface WorkspaceContext {\n readOrbital(name: string): Promise<Orbital>;\n writeOrbital(name: string, content: Orbital): Promise<void>;\n readFile(path: string): Promise<string>;\n writeFile(path: string, content: string): Promise<void>;\n exists(path: string): boolean;\n listOrbitals(): string[];\n readSchema(): Promise<OrbitalSchema>;\n writeSchema(schema: OrbitalSchema): Promise<void>;\n readPlan(): Promise<PlanSnapshot>;\n writePlan(plan: PlanSnapshot): Promise<void>;\n archiveOrbital(name: string): Promise<void>;\n}\n\n/** Backs the session/* operators (9 ops). */\nexport interface SessionContext {\n readSpec(orbitalName: string): Promise<Orbital>;\n writeSpec(orbitalName: string, spec: Orbital): Promise<void>;\n readMemory(orbitalName: string): Promise<AgentMemoryRecord[]>;\n writeMemory(orbitalName: string, memory: AgentMemoryRecord[]): Promise<void>;\n readHistory(orbitalName: string): Promise<SessionHistoryEntry[]>;\n appendHistory(orbitalName: string, entry: SessionHistoryEntry): Promise<void>;\n readErrors(orbitalName: string): Promise<string[]>;\n writeErrors(orbitalName: string, errors: string[]): Promise<void>;\n readAnalysis(orbitalName: string): Promise<AnalysisResult>;\n}\n\n/** Backs the memory/* operators (3 ops). */\nexport interface MemoryContext {\n recall(query: string, limit?: number): AgentMemoryRecord[];\n store(content: string, category?: string, strength?: number): Promise<string>;\n list(category?: string): AgentMemoryRecord[];\n}\n\n/** Backs the trace/* operators (2 ops). */\nexport interface TraceContext {\n emit(event: string, payload?: EventPayloadValue): void;\n log(message: string, level?: 'log' | 'warn' | 'error', data?: EventPayloadValue): void;\n}\n","/**\n * Plan & Analysis Types\n *\n * Lifted from @almadar-io/rabit's coordinator types. These are the\n * language-level contracts for the planner/analysis pipeline — the\n * session/* and workspace/* substrate operators produce and consume\n * these shapes. Defined here (not in rabit) so both the compiled path\n * (orbital-rust codegen → @almadar/server) and the interpreted path\n * (@almadar/runtime) reference the same types without depending on rabit.\n *\n * @packageDocumentation\n */\n\nimport type { EntityField } from './field.js';\nimport type { EntityPersistence } from './entity.js';\nimport type { RuntimeValue } from './json.js';\nimport type { OrbitalSchema } from './schema.js';\nimport type { PageTraitRef } from './page.js';\nimport type { TraitReference, TraitConfigObject } from './trait.js';\nimport type { ThemeDefinition } from './domain.js';\nimport type { RuleOverlay, TraitOverlay } from '../factory/overlays.js';\nimport type {\n EventWiringEntry,\n LayoutStrategy,\n MakeTraitRefOpts,\n} from '../builders/index.js';\n\n// ============================================================================\n// Clarification System\n// ============================================================================\n\nexport type ClarificationLevel = 'organism' | 'molecule' | 'atom_trait';\n\nexport interface ClarificationCandidate {\n id: string;\n label: string;\n description: string;\n whyThisFits: string;\n}\n\nexport interface Clarification {\n level: ClarificationLevel;\n scope: { orbitalName?: string; traitName?: string };\n question: string;\n candidates: ClarificationCandidate[];\n skipDefault: string;\n skippable: true;\n}\n\n// ============================================================================\n// Orbital Analysis Params\n// ============================================================================\n\nexport interface AnalysisPageOverride {\n name: string;\n path?: string;\n linkedEntity?: string;\n traits?: PageTraitRef[];\n}\n\nexport interface ExtraTraitRef\n extends Pick<\n TraitReference,\n 'ref' | 'name' | 'linkedEntity' | 'config' | 'events' | 'listens' | 'emitsScope'\n > {\n from: string;\n as: string;\n}\n\nexport interface AnalysisOrbitalParams {\n fields?: EntityField[];\n pagePath?: string;\n persistence?: EntityPersistence;\n entityName?: string;\n collection?: string;\n traitOverrides?: Record<\n string,\n Pick<MakeTraitRefOpts, 'config' | 'linkedEntity' | 'events' | 'name' | 'emitsScope' | 'listens'>\n >;\n extraTraits?: ExtraTraitRef[];\n pages?: AnalysisPageOverride[];\n}\n\n// ============================================================================\n// Analysis Result\n// ============================================================================\n\nexport interface AnalysisOrbital {\n orbitalName: string;\n suggestedBehavior: string | null;\n entityName?: string;\n pageNames?: ReadonlyArray<string>;\n params?: AnalysisOrbitalParams;\n traitOverlay?: TraitOverlay;\n paletteTopics?: string[];\n primitiveHints?: string[];\n}\n\nexport interface AnalysisRename {\n oldName: string;\n newName: string;\n}\n\nexport interface ComplexityAssessment {\n score: number;\n category: 'simple' | 'moderate' | 'complex';\n reasoning: string;\n detectedEntities?: string[];\n detectedFeatures?: string[];\n}\n\nexport interface AnalysisResult {\n userRequest: string;\n complexity: ComplexityAssessment;\n route: 'direct' | 'direct_with_questions' | 'decompose';\n organism: string;\n appName: string;\n organismReason: string;\n orbitals: AnalysisOrbital[];\n renames?: AnalysisRename[];\n deletedOrbitals?: string[];\n ruleOverlay?: RuleOverlay;\n estimatedMinutes?: number;\n schema: OrbitalSchema;\n wiring?: EventWiringEntry[];\n layout?: LayoutStrategy | 'detect';\n themeOverrides?: Partial<ThemeDefinition>;\n pendingClarifications?: Clarification[];\n}\n\n// ============================================================================\n// Plan Snapshot\n// ============================================================================\n\nexport interface SpawnResult {\n orbitalName: string;\n ok: boolean;\n traitNames: ReadonlyArray<string>;\n error?: string;\n durationMs: number;\n}\n\nexport type PlanSnapshotStatus = 'proposed' | 'confirmed' | 'built' | 'failed';\n\nexport interface PlanSnapshot {\n schemaVersion: 1;\n status: PlanSnapshotStatus;\n builtAt: string;\n organism: string | null;\n appName: string | null;\n organismReason: string | null;\n complexity: ComplexityAssessment | null;\n themeOverrides: Partial<ThemeDefinition>;\n ruleOverlay: RuleOverlay | null;\n orbitals: ReadonlyArray<AnalysisOrbital>;\n renames: ReadonlyArray<AnalysisRename>;\n deletedOrbitals: ReadonlyArray<string>;\n priorBuiltOrbitals: ReadonlyArray<AnalysisOrbital>;\n spawnedOrbitalResults: ReadonlyArray<SpawnResult>;\n skippedOrbitalNames: ReadonlyArray<string>;\n pendingClarifications: ReadonlyArray<Clarification>;\n paletteTopics?: string[];\n}\n\n/**\n * Runtime guard for `PlanSnapshot` — narrows interpreter-produced `unknown`\n * values at the `WorkspaceContext.writePlan` boundary. Discriminates on the\n * snapshot envelope (schemaVersion, status, roster arrays), not deep contents.\n */\nexport function isPlanSnapshot(value: RuntimeValue): value is PlanSnapshot {\n if (typeof value !== 'object' || value === null) return false;\n const statuses: ReadonlyArray<PlanSnapshotStatus> = ['proposed', 'confirmed', 'built', 'failed'];\n return (\n 'schemaVersion' in value && value.schemaVersion === 1 &&\n 'status' in value && statuses.some((s) => s === value.status) &&\n 'builtAt' in value && typeof value.builtAt === 'string' &&\n 'orbitals' in value && Array.isArray(value.orbitals) &&\n 'renames' in value && Array.isArray(value.renames) &&\n 'deletedOrbitals' in value && Array.isArray(value.deletedOrbitals)\n );\n}\n\n// ============================================================================\n// Compose Options\n// ============================================================================\n\nexport interface ComposeOptions {\n appName?: string;\n wiring?: EventWiringEntry[];\n layout?: LayoutStrategy | 'auto';\n themeOverrides?: Partial<ThemeDefinition>;\n}\n\n","/**\n * Pattern Type for Orbital Units\n *\n * Re-exports pattern type definitions from @almadar/core/patterns,\n * which is the single source of truth for all pattern types.\n *\n * @packageDocumentation\n */\n\nimport { z } from 'zod';\n\n// ============================================================================\n// Pattern Type - Re-exported from @almadar/core/patterns\n// ============================================================================\n\n/**\n * All valid pattern type names, imported from the @almadar/core/patterns registry.\n * The authoritative list is auto-generated from patterns-registry.json.\n */\nexport {\n PATTERN_TYPES,\n isValidPatternType,\n} from '../patterns/index.js';\nexport type { PatternType } from '../patterns/index.js';\n\n/**\n * Zod schema for pattern types.\n * Accepts any string - validation against full registry happens at runtime.\n */\nexport const PatternTypeSchema = z.string();\n","/**\n * Changeset & Snapshot Types\n *\n * Unified types for schema change tracking, snapshots, and removal categorization.\n * Used by @almadar/server for Firestore storage and by consumers for type safety.\n */\n\nimport type { OrbitalSchema } from './schema.js';\nimport type { Orbital } from './orbital.js';\nimport type { Trait } from './trait.js';\nimport type { Entity } from './entity.js';\nimport type { Page } from './page.js';\nimport type { EventPayloadValue } from './expression.js';\n\n// ============================================================================\n// Schema Change Types\n// ============================================================================\n\n/**\n * Value attached to a SchemaChange entry's `before` / `after`.\n *\n * Either a JSON-shaped LLM payload (`EventPayloadValue`), a single schema\n * fragment (`Orbital`, `Trait`, `Entity`, `Page`, `OrbitalSchema`), or an\n * array of such fragments. Mirrors the exact shapes the builder's changeset\n * writers actually persist when adding/replacing a slice of the schema.\n */\nexport type ChangesetValue =\n | EventPayloadValue\n | OrbitalSchema\n | Orbital\n | Trait\n | Entity\n | Page\n | Orbital[]\n | Trait[]\n | Entity[]\n | Page[];\n\n/**\n * A single change within a changeset.\n */\nexport interface SchemaChange {\n id: string;\n operation: 'add' | 'modify' | 'remove' | 'rename';\n target: string;\n path: (string | number)[];\n before?: ChangesetValue;\n after?: ChangesetValue;\n description: string;\n reason?: string;\n dependsOn?: string[];\n}\n\n/**\n * Author of a changeset.\n */\nexport interface ChangeAuthor {\n type: 'agent' | 'user';\n id?: string;\n name?: string;\n}\n\n/**\n * Summary statistics for a changeset.\n */\nexport interface ChangeSummary {\n added: number;\n modified: number;\n removed: number;\n description: string;\n}\n\n/**\n * Complete changeset document.\n * Stored at: users/{uid}/apps/{appId}/changesets/{changeSetId}\n */\nexport interface ChangeSetDocument {\n id: string;\n version: number;\n timestamp: number;\n source: 'requirements-agent' | 'builder-agent' | 'user' | 'auto-fix';\n author: ChangeAuthor;\n trigger?: string;\n changes: SchemaChange[];\n summary: ChangeSummary;\n status: 'applied' | 'reverted' | 'pending';\n description: string;\n}\n\n// ============================================================================\n// Snapshot Types\n// ============================================================================\n\n/**\n * Schema snapshot document.\n * Stored at: users/{uid}/apps/{appId}/snapshots/{snapshotId}\n */\nexport interface SnapshotDocument {\n id: string;\n timestamp: number;\n schema: OrbitalSchema;\n reason: string;\n version?: number;\n}\n\n// ============================================================================\n// Schema Protection Types\n// ============================================================================\n\n/**\n * Removals categorized by severity.\n */\nexport interface CategorizedRemovals {\n /** States, pages, entities — always require confirmation */\n critical: SchemaChange[];\n /** Fields, actions — auto-snapshotted */\n standard: SchemaChange[];\n /** Transitions, guards — tracked */\n minor: SchemaChange[];\n /** Implicit content removal within pages */\n pageContentReductions: PageContentReduction[];\n}\n\n/**\n * Detected reduction in page content (components, actions, displays removed).\n */\nexport interface PageContentReduction {\n pageName: string;\n componentsRemoved: number;\n actionsRemoved: number;\n displaysRemoved: number;\n before: { sections: number; actions: number };\n after: { sections: number; actions: number };\n isSignificant: boolean;\n}\n\n// ============================================================================\n// History Metadata Types\n// ============================================================================\n\n/**\n * History metadata stored in main app document for quick access.\n */\nexport interface HistoryMeta {\n latestSnapshotId?: string;\n latestChangeSetId?: string;\n snapshotCount: number;\n changeSetCount: number;\n}\n\n/**\n * Validation metadata stored in main app document for quick access.\n */\nexport interface ValidationMeta {\n errorCount: number;\n warningCount: number;\n validatedAt: number;\n}\n\n// ============================================================================\n// Semantic Schema Change (concept-level diffing)\n// ============================================================================\n\n/**\n * What kind of .orb concept changed between two schema versions.\n * Used by canvas focus derivation, CLI narration, selective re-verification.\n */\nexport const SEMANTIC_CHANGE_KINDS = [\n 'orbital-added',\n 'orbital-removed',\n 'entity-fields-changed',\n 'trait-added',\n 'trait-removed',\n 'trait-config-changed',\n 'state-machine-changed',\n 'guard-changed',\n 'effect-changed',\n 'render-ui-changed',\n 'event-wiring-changed',\n 'page-changed',\n 'theme-changed',\n 'behavior-composed',\n] as const;\n\nexport type SemanticChangeKind = (typeof SEMANTIC_CHANGE_KINDS)[number];\n\n/**\n * A semantic change between two OrbitalSchema versions.\n * Identifies WHAT concept changed and WHERE in the schema.\n */\nexport interface SemanticSchemaChange {\n kind: SemanticChangeKind;\n orbitalName: string;\n traitName?: string;\n transitionEvent?: string;\n fieldName?: string;\n}\n","/**\n * Service Contract Types\n *\n * Formalizes the two public surfaces of an Almadar service:\n * 1. Call-Service Contract — what the .orb schema can invoke on the TypeScript package\n * 2. Event Contract — what events enter/leave the service\n *\n * Plus internal-but-standardized patterns:\n * 3. StoreContract — database abstraction boundary\n * 4. LazyService — singleton lifecycle pattern\n *\n * @packageDocumentation\n */\n\nimport type { EventPayload, EventPayloadValue, LogMeta } from './types/expression.js';\nimport type { ServiceParams } from './types/service.js';\nimport type { EntityRow, FieldValue } from './types/entity.js';\n\n// ============================================================================\n// Service Action Names (generated from services-registry.json)\n// ============================================================================\n\n/**\n * All known service action names across all contracts.\n * Kept in sync with `tools/almadar-service-sync/services-registry.json`.\n *\n * Persist operations are listed separately because they also appear\n * as `EffectResult.action` for persist effects.\n */\nexport type PersistActionName =\n | \"create\"\n | \"update\"\n | \"delete\"\n | \"list\"\n | \"query\";\n\n/**\n * Union of all service action names across the registered service contracts.\n */\nexport type ServiceActionName =\n | PersistActionName\n // Data service\n | \"get\"\n | \"getById\"\n | \"set\"\n | \"remove\"\n | \"size\"\n // LLM\n | \"generate\"\n | \"classify\"\n | \"extract\"\n | \"summarize\"\n // Messaging\n | \"send\"\n | \"sendMessage\"\n | \"sendSMS\"\n | \"sendWhatsApp\"\n // Auth / Identity\n | \"authorize\"\n | \"revoke\"\n | \"token\"\n | \"refresh\"\n | \"userinfo\"\n | \"register\"\n // Git / VCS\n | \"cloneRepo\"\n | \"commit\"\n | \"createBranch\"\n | \"createPR\"\n | \"getPRComments\"\n | \"pull\"\n | \"push\"\n // CI / Build\n | \"build\"\n | \"compile\"\n | \"compileSchema\"\n | \"run\"\n | \"validate\"\n | \"validateSchema\"\n | \"publish\"\n // Queue / Jobs\n | \"enqueue\"\n | \"dequeue\"\n | \"cancel\"\n // Storage / Assets\n | \"upload\"\n | \"download\"\n | \"getSignedUrl\"\n // Search / Issues\n | \"search\"\n | \"getIssue\"\n | \"listIssues\"\n // Agent / Generation\n | \"generateAll\"\n | \"generateDomainLanguage\"\n | \"generateFix\"\n | \"generateOrbitals\"\n | \"cancelGeneration\"\n | \"getGenerationHistory\"\n | \"recordGeneration\"\n // Telemetry / Metrics\n | \"startSpan\"\n | \"endSpan\"\n | \"getSpan\"\n | \"recordMetric\"\n | \"getMetrics\"\n | \"increment\"\n | \"logs\"\n // Events / Channels\n | \"addEvent\"\n | \"emit\"\n | \"findEmitters\"\n | \"findListeners\"\n | \"getListenerCounts\"\n | \"getChannel\"\n | \"subscribe\"\n // User / Preferences\n | \"getUserPreferences\"\n | \"updateUserPreferences\"\n | \"getThreadHistory\"\n // Migration / Import\n | \"listDocuments\"\n | \"fetchDocument\"\n // Media\n | \"getVideo\"\n // Payments\n | \"createPaymentIntent\"\n | \"confirmPayment\"\n | \"refund\"\n // Lifecycle\n | \"complete\"\n | \"fail\"\n | \"expire\"\n | \"resume\"\n | \"status\"\n | \"stop\"\n | \"lock\"\n | \"unlock\"\n | \"clear\";\n\n// ============================================================================\n// Call-Service Contract\n// ============================================================================\n\n/**\n * Action definition for a service contract.\n *\n * - `params` is bus-payload-shaped (`ServiceParams`): JSON-serializable\n * key/value bag with optional nesting. Service contracts override this\n * with stricter shapes via the generic position on `ServiceContract`.\n *\n * - `result` is JSON-serializable too (`EventPayloadValue`): a primitive,\n * `null`/`undefined`, an array of values, or an `EventPayload` object.\n * This is the same recursive shape the bus accepts when an effect's\n * `success` event fires with the call-service result, so no boundary\n * widening is needed when the runtime forwards the value.\n */\nexport interface ServiceAction {\n params: ServiceParams;\n result: EventPayloadValue;\n}\n\n/**\n * What `[\"call-service\", \"name\", \"action\", {...}]` actually calls at runtime.\n * Each service defines its action map as a Record<string, ServiceAction>.\n *\n * @example\n * ```typescript\n * type LLMActions = {\n * generate: {\n * params: { userPrompt: string; model: string; maxTokens: number };\n * result: { content: string; tokensUsed: number; latencyMs: number };\n * };\n * };\n *\n * class LLMService implements ServiceContract<LLMActions> {\n * async execute(action, params) { ... }\n * }\n * ```\n */\nexport interface ServiceContract<\n Actions extends Record<string, ServiceAction>,\n> {\n execute<A extends keyof Actions & string>(\n action: A,\n params: Actions[A][\"params\"],\n ): Promise<Actions[A][\"result\"]>;\n}\n\n// ============================================================================\n// Event Contract\n// ============================================================================\n\n/**\n * Event contract — what events the service emits/listens with typed payloads.\n * Derived from the `.orb` schema's `emits` and `listens` declarations.\n *\n * @example\n * ```typescript\n * type LLMEventMap = {\n * AGENT_LLM_REQUEST: { requestId: string; prompt: string };\n * LLM_RESPONSE: { requestId: string; content: string; tokensUsed: number };\n * LLM_ERROR: { requestId: string; error: string };\n * };\n *\n * const events: ServiceEvents<LLMEventMap> = getEventBus();\n * events.emit('LLM_RESPONSE', { requestId: '1', content: '...', tokensUsed: 42 });\n * ```\n */\nexport interface ServiceEvents<\n EventMap extends Record<string, EventPayload>,\n> {\n emit<E extends keyof EventMap & string>(\n event: E,\n payload: EventMap[E],\n ): void;\n on<E extends keyof EventMap & string>(\n event: E,\n handler: (payload: EventMap[E]) => void,\n ): () => void;\n}\n\n/**\n * Create a typed view of an untyped EventBus. Wraps the raw EventBus\n * with compile-time type checking while keeping runtime behavior identical.\n *\n * @example\n * ```typescript\n * type LLMEventMap = {\n * LLM_RESPONSE: { requestId: string; content: string };\n * LLM_ERROR: { requestId: string; error: string };\n * };\n *\n * const typedBus = createTypedEventBus<LLMEventMap>(getServerEventBus());\n * typedBus.emit('LLM_RESPONSE', { requestId: '1', content: '...' }); // type-safe\n * typedBus.on('LLM_ERROR', (payload) => { payload.error; }); // payload is typed\n * ```\n */\n/**\n * Creates a typed event bus from an untyped bus implementation.\n * \n * This wrapper adds TypeScript type safety to event emission and listening.\n * The generic `EventMap` defines the shape of all events and their payloads.\n * \n * @template EventMap - Type mapping event names to their payload types\n * @param {Object} bus - Untyped event bus implementation\n * @param {Function} bus.emit - Function to emit events\n * @param {Function} bus.on - Function to listen to events\n * @returns {ServiceEvents<EventMap>} Typed event bus interface\n * \n * @example\n * interface MyEvents {\n * 'user.created': { id: string; name: string };\n * 'user.deleted': { id: string };\n * }\n * \n * const typedBus = createTypedEventBus<MyEvents>(rawBus);\n * typedBus.emit('user.created', { id: '123', name: 'Alice' });\n */\nexport function createTypedEventBus<\n EventMap extends Record<string, EventPayload>,\n>(bus: {\n emit(event: string, payload?: unknown, meta?: LogMeta): void;\n on(event: string, handler: (payload: unknown, meta?: LogMeta) => void): () => void;\n}): ServiceEvents<EventMap> {\n return {\n emit<E extends keyof EventMap & string>(event: E, payload: EventMap[E]): void {\n bus.emit(event, payload);\n },\n on<E extends keyof EventMap & string>(\n event: E,\n handler: (payload: EventMap[E]) => void,\n ): () => void {\n return bus.on(event, handler as (payload: unknown) => void);\n },\n };\n}\n\n// ============================================================================\n// Store Contract\n// ============================================================================\n\n/** Filter operator for store queries. */\nexport type StoreFilterOp =\n | \"==\"\n | \"!=\"\n | \"<\"\n | \"<=\"\n | \">\"\n | \">=\"\n | \"in\"\n | \"not-in\"\n | \"contains\"\n | \"array-contains\"\n | \"array-contains-any\";\n\n/** A single filter clause for store queries. */\nexport interface StoreFilter<T> {\n field: keyof T & string;\n op: StoreFilterOp;\n value: FieldValue | undefined;\n}\n\n/** One page of rows from a store: filters, then search, then sort, then the page. */\nexport type RowPageRequest<T> = {\n /** 1-indexed. */\n page: number;\n pageSize: number;\n filters?: readonly StoreFilter<T>[];\n /** Case-insensitive substring match over `searchFields` (every field when absent). */\n search?: string;\n searchFields?: readonly string[];\n sortBy?: string;\n sortOrder?: \"asc\" | \"desc\";\n};\n\nexport type RowPage<T> = {\n rows: T[];\n /** Rows matching the filters and search, across all pages. */\n total: number;\n};\n\n/** The comparison members of `StoreFilterOp`. */\nexport type RowCompareOp = Extract<StoreFilterOp, \"==\" | \"!=\" | \"<\" | \"<=\" | \">\" | \">=\">;\n\n/**\n * A row predicate with two-valued logic: a missing or null field satisfies only `!=` against a\n * non-null value and `isNull: true`, and fails every other leaf, so `not` of a failing leaf holds.\n * Leaves reuse the `StoreFilterOp` meanings: `member` is `in`, `hasElement` is `array-contains`,\n * `contains` is a substring test.\n */\nexport type RowPredicate =\n | { kind: \"compare\"; field: string; op: RowCompareOp; value: FieldValue }\n | { kind: \"member\"; field: string; values: FieldValue[] }\n | { kind: \"hasElement\"; field: string; value: FieldValue }\n | { kind: \"contains\"; field: string; text: string; caseSensitive: boolean }\n | { kind: \"isNull\"; field: string; isNull: boolean }\n | { kind: \"all\"; of: RowPredicate[] }\n | { kind: \"any\"; of: RowPredicate[] }\n | { kind: \"not\"; of: RowPredicate }\n | { kind: \"const\"; value: boolean };\n\n/** One sort key. Missing and null values sort last in both directions; ties break by `id` ascending. A query with no `order` is ordered by `createdAt` ascending, then `id` (EXEC-FETCH-1). */\nexport type RowOrder = {\n field: string;\n direction: \"asc\" | \"desc\";\n};\n\n/**\n * A vector-similarity query: up to `k` rows ordered by descending cosine similarity of `field` to `vector`\n * (EXEC-FETCH-2). A row whose field is absent, null or of zero norm is skipped; a stored vector that is not a\n * `[number]` of the query's length, a zero-norm query or a non-positive `k` fails.\n */\nexport type RowNearest = {\n field: string;\n vector: number[];\n k: number;\n};\n\n/**\n * A pushed-down query: rows matching `policy` AND `filter`, ordered, then windowed. `policy` is the\n * entity's `@read` predicate already specialised to the viewer; `filter` is the call-site filter.\n */\nexport type RowQuery = {\n policy?: RowPredicate;\n filter?: RowPredicate;\n /** Absent = `createdAt` ascending, then `id` ascending (EXEC-FETCH-1). */\n order?: RowOrder;\n offset?: number;\n /** Absent = no limit. */\n limit?: number;\n /** Absent = `exact`. With `none` the store need not count; `total` is then only the window's size. */\n total?: RowTotalMode;\n /** The nearest `k` rows among those `policy` and `filter` admit. Excludes `order`, `offset` and `limit`; `total` is the count returned. */\n nearest?: RowNearest;\n};\n\n/** The answer to a `RowQuery`: the window, and `total` = every match before the window. */\nexport type RowQueryPage = RowPage<EntityRow>;\n\n/** Value kinds a store can compare, in `compare`/`member`/`hasElement` operands. */\nexport type RowValueKind = \"string\" | \"number\" | \"boolean\" | \"date\" | \"null\";\n\n/** Every operator a `RowPredicate` leaf can carry. */\nexport type RowOperator = RowCompareOp | \"member\" | \"hasElement\" | \"contains\";\n\n/** The value kinds one operator accepts on a store; an operator not listed accepts every kind. */\nexport type OperatorValueKinds = {\n operator: RowOperator;\n valueKinds: RowValueKind[];\n};\n\n/** Whether `total` counts every match (`exact`, the default) or the store may skip the count (`none`). */\nexport type RowTotalMode = \"exact\" | \"none\";\n\n/** What an adapter's `queryPage` honours for one entity type. */\nexport type QueryCapabilities = {\n leaves: (\"compare\" | \"member\" | \"hasElement\" | \"contains\" | \"isNull\")[];\n combinators: (\"all\" | \"any\" | \"not\")[];\n compareOps: RowCompareOp[];\n /** Per operator x value kind restrictions; absent = every kind for every declared operator. */\n operatorValueKinds?: OperatorValueKinds[];\n orderableFields: { kind: \"every-field\" } | { kind: \"listed\"; fields: string[] };\n /** offset and limit. */\n window: boolean;\n /** `total` counts every match, not the window. Needed only for `total: exact` queries. */\n exactTotal: boolean;\n /** `queryIds` is implemented. */\n idsOnly?: boolean;\n /** `nearest` is pushed down: the store ranks by cosine similarity itself (EXEC-FETCH-2). */\n nearest?: boolean;\n};\n\n/** The answer to a `queryIds`: the window's ids in order, and `total` as in `RowQueryPage`. */\nexport type RowIdPage = {\n ids: string[];\n total: number;\n};\n\n/**\n * One write. `create` fails (`duplicate-id`) when its id is taken. `upsert` creates the row or replaces it\n * whole by id (`created` / `updated`), keeping the existing `createdAt`. `update` changes an existing row only\n * (never an upsert) and merges `data` over it with `id` stamped last; `guard` is tested against the pre-image.\n * `delete` likewise. Native `rekey` moves an existing id with insertion-order collision semantics; support is explicit.\n */\nexport type RowWriteOp =\n | { kind: \"create\"; entityType: string; data: EntityRow }\n | { kind: \"upsert\"; entityType: string; data: EntityRow }\n | { kind: \"update\"; entityType: string; id: string; data: EntityRow; guard?: RowPredicate }\n | { kind: \"delete\"; entityType: string; id: string; guard?: RowPredicate }\n | { kind: \"rekey\"; entityType: string; id: string; newId: string; guard?: RowPredicate };\n\n/**\n * What one write did. `before` (the pre-image) is present exactly when the op carried a guard.\n * `rolled-back` is only produced inside an `atomic` batch that failed: the op had succeeded and was undone.\n */\nexport type RowWriteOutcome =\n | { kind: \"created\"; row: EntityRow }\n | { kind: \"updated\"; row: EntityRow; before?: EntityRow }\n | { kind: \"deleted\"; before?: EntityRow }\n | { kind: \"not-found\" }\n | { kind: \"duplicate-id\" }\n | { kind: \"refused\" }\n | { kind: \"failed\"; message: string }\n | { kind: \"rolled-back\" };\n\n/**\n * `atomic`: all ops apply or none do (a `persist batch`); on failure the outcomes are `rolled-back` for\n * every earlier op, then the failing outcome, and nothing is written.\n * `stop`: ops apply in order and stop at the first failure; earlier ops stay applied, later ones are\n * not attempted and have no outcome (a run of plain `persist` effects).\n */\nexport type RowWriteFailureMode = \"atomic\" | \"stop\";\n\nexport type RowWriteBatch = {\n ops: RowWriteOp[];\n onFailure: RowWriteFailureMode;\n};\n\n/** What an adapter's `writeWhere`/`writeBatch` honours for one entity type. */\nexport type WriteCapabilities = {\n /** The guard predicates the store can test; a `Pick` of the query capabilities. */\n guards: Pick<QueryCapabilities, \"leaves\" | \"combinators\" | \"compareOps\">;\n /** `writeWhere` tests the guard and the existence of the row in one step. */\n conditional: boolean;\n /** Outcomes carry the written row. */\n returnsRow: boolean;\n /** `writeBatch` with `onFailure: \"stop\"`. */\n stopRuns: boolean;\n /** `writeBatch` with `onFailure: \"atomic\"`; needs transactions. */\n atomicBatch: boolean;\n /** Native id moves; absent means unsupported. */\n rekey?: boolean;\n /** The store commits rows the kernel decided (`commitRows`) and holds no write semantics (EXEC-STORE-5). */\n commitRows?: boolean;\n};\n\n/** What a compare-and-commit does to one row the kernel read. */\nexport type RowCommitWrite = { kind: \"keep\" } | { kind: \"put\"; row: EntityRow } | { kind: \"delete\" };\n\n/** One row of a compare-and-commit: the version the kernel read (`null` when absent) and what it writes (EXEC-STORE-5). */\nexport type RowCommit = {\n entityType: string;\n id: string;\n expected: EntityRow | null;\n write: RowCommitWrite;\n};\n\n/**\n * Storage contract for CRUD operations on entity rows. The runtime's effect\n * handlers and every database backend (`@almadar/db`) speak this interface.\n */\nexport interface PersistenceAdapter {\n create(entityType: string, data: EntityRow): Promise<{ id: string }>;\n update(entityType: string, id: string, data: EntityRow): Promise<void>;\n delete(entityType: string, id: string): Promise<void>;\n getById(entityType: string, id: string): Promise<EntityRow | null>;\n list(entityType: string): Promise<EntityRow[]>;\n /** Number of rows of `entityType`, without reading them; needed by a row quota. */\n countRows?(entityType: string): Promise<number>;\n /** Rows matching every filter, pushed down to the store where it can; absent = filter over `list`. */\n query?(entityType: string, filters: readonly StoreFilter<EntityRow>[]): Promise<EntityRow[]>;\n /** One page, pushed down to the store where it can; absent = page over `list`. */\n listPage?(entityType: string, request: RowPageRequest<EntityRow>): Promise<RowPage<EntityRow>>;\n /** The page of rows matching `query.policy AND query.filter`, ordered and windowed; only queries within `queryCapabilities`. */\n queryPage?(entityType: string, query: RowQuery): Promise<RowQueryPage>;\n /** What `queryPage` honours; absent = the host cannot push a query down. */\n queryCapabilities?(entityType: string): QueryCapabilities;\n /** The ids of the page `queryPage` would return, without the rows; only when `queryCapabilities.idsOnly`. */\n queryIds?(entityType: string, query: RowQuery): Promise<RowIdPage>;\n /** One conditional write; only ops within `writeCapabilities`. */\n writeWhere?(op: RowWriteOp): Promise<RowWriteOutcome>;\n /** Ordered writes with the batch's failure mode; one outcome per attempted op. */\n writeBatch?(batch: RowWriteBatch): Promise<RowWriteOutcome[]>;\n /** What `writeWhere`/`writeBatch` honour; absent = the host cannot push a write down. */\n writeCapabilities?(entityType: string): WriteCapabilities;\n /** Apply every row's write in one storage transaction only if each row still equals its `expected` version; `false` (nothing applied) on a conflict. */\n commitRows?(rows: readonly RowCommit[]): Promise<boolean>;\n /** Bind `entityType` to its declared `[persistent: tbl]` collection: a store that keys rows by collection stores the entity's rows under that name. Absent = the store keys by entity name alone. */\n bindCollection?(entityType: string, collection: string): void;\n}\n\n/**\n * Database abstraction boundary. Services receive `StoreContract<T>`,\n * not raw database clients. Swappable per database engine.\n *\n * @example\n * ```typescript\n * interface LLMRequest { id: string; prompt: string; status: string }\n *\n * class FirestoreLLMRequestStore implements StoreContract<LLMRequest> {\n * async getById(id) { ... }\n * async create(data) { ... }\n * async update(id, data) { ... }\n * async delete(id) { ... }\n * async query(filters) { ... }\n * }\n * ```\n */\nexport interface StoreContract<T extends { id: string }> {\n getById(id: string): Promise<T | null>;\n create(data: Omit<T, \"id\">): Promise<T>;\n update(id: string, data: Partial<T>): Promise<T>;\n delete(id: string): Promise<void>;\n query(filters: StoreFilter<T>[]): Promise<T[]>;\n}\n\n// ============================================================================\n// Lazy Service (Singleton Pattern)\n// ============================================================================\n\n/**\n * Standardized singleton lifecycle. Replaces ad-hoc\n * `let x = null; export function getX()` patterns.\n *\n * @example\n * ```typescript\n * const llmClient = createLazyService(() => new LLMClient({ apiKey: process.env.LLM_KEY }));\n *\n * // In request handler:\n * const client = llmClient.get(); // created on first call, cached after\n *\n * // In test teardown:\n * llmClient.reset(); // next get() creates a fresh instance\n * ```\n */\nexport interface LazyService<T> {\n /** Get the singleton instance (creates on first call). */\n get(): T;\n /** Reset the singleton (next get() creates fresh). For test isolation. */\n reset(): void;\n}\n\n/**\n * Create a lazy singleton from a factory function.\n * \n * Creates a service that lazily initializes on first access and caches the instance.\n * Useful for expensive resources like database connections or API clients.\n * \n * @template T - The type of service to create\n * @param {() => T} factory - Factory function that creates the service instance\n * @returns {LazyService<T>} Lazy service with get() and reset() methods\n * \n * @example\n * const dbService = createLazyService(() => new DatabaseClient(config));\n * const db = dbService.get(); // Initializes on first call\n */\nexport function createLazyService<T>(factory: () => T): LazyService<T> {\n let instance: T | null = null;\n return {\n get(): T {\n if (instance === null) {\n instance = factory();\n }\n return instance;\n },\n reset(): void {\n instance = null;\n },\n };\n}\n","/**\n * Row-predicate helpers the TS shell keeps. Compiling a `filter` or `@read` to a `RowPredicate` is the kernel's\n * (`compile_predicate`; `kernelEvaluator().readPolicy`); this module holds only the binding-fold result shape the\n * kernel answers and the fetch-order parse.\n */\nimport type { RowOrder } from './service-types.js';\n\nexport type RowBindingScalar = string | number | boolean | null;\n\nexport type RowBindingResult =\n | { kind: 'value'; value: RowBindingScalar }\n | { kind: 'list'; values: RowBindingScalar[] }\n | { kind: 'unspecialised'; detail: string }\n | { kind: 'inexpressible'; detail: string };\n\n/** A fetch's `orderBy` (`\"field\"` or `\"field:asc|desc\"`): ascending unless `desc`. */\nexport function parseFetchOrder(orderBy: string | undefined): RowOrder | undefined {\n if (typeof orderBy !== 'string' || orderBy === '') return undefined;\n const [field, direction] = orderBy.split(':');\n const dir: RowOrder['direction'] = direction === 'desc' ? 'desc' : 'asc';\n return { field, direction: dir };\n}\n","// The one identity of a cascade delivery (Runtime Spec Clause 5.3); twin of orbital-core `dispatch_visit_key`.\nimport type { EventPayload, EventPayloadValue } from './expression.js';\n\nfunction isPayloadList(value: EventPayloadValue | undefined): value is EventPayloadValue[] {\n return Array.isArray(value);\n}\n\n/** An absent payload (`undefined`) writes `null`, as an explicit `null` does. */\nexport function canonicalJson(value: EventPayloadValue | undefined): string {\n if (value === undefined || value === null) return 'null';\n if (isPayloadList(value)) return `[${value.map((item: EventPayloadValue) => canonicalJson(item)).join(',')}]`;\n if (typeof value === 'object') {\n const fields = Object.keys(value)\n .sort()\n .map((k) => `${JSON.stringify(k)}:${canonicalJson(value[k])}`);\n return `{${fields.join(',')}}`;\n }\n return JSON.stringify(value);\n}\n\n/**\n * `(trait, event, from, payload, frame)`: only an exact repeat of all five is a cycle. The frame is the\n * trait's entity row as it stands when the step is taken — a loop whose row moved on is progress even\n * when an effect hands back the same result twice; `null` when the trait has no row.\n */\nexport function dispatchVisitKey(\n trait: string,\n event: string,\n from: string,\n payload: EventPayload | null | undefined,\n frame: EventPayload | null,\n): string {\n return `${trait}\\u0000${event}\\u0000${from}\\u0000${canonicalJson(payload)}\\u0000${canonicalJson(frame)}`;\n}\n\nconst COMPOSITE: unique symbol = Symbol('composite');\n\n/** The JSON leaf `canonicalJson` writes for a scalar (an absent value and a non-finite number both write `null`). */\nfunction canonicalLeaf(value: EventPayloadValue | undefined): string | number | boolean | null | typeof COMPOSITE {\n if (value === undefined || value === null) return null;\n if (typeof value === 'number') return Number.isFinite(value) ? value : null;\n if (typeof value === 'object') return COMPOSITE;\n return value;\n}\n\n/** `canonicalJson(a) === canonicalJson(b)`, without building either string. */\nfunction sameCanonical(a: EventPayloadValue | undefined, b: EventPayloadValue | undefined): boolean {\n if (a === b) return true;\n const leafA = canonicalLeaf(a);\n const leafB = canonicalLeaf(b);\n if (leafA !== COMPOSITE || leafB !== COMPOSITE) return leafA === leafB;\n if (isPayloadList(a) || isPayloadList(b)) {\n if (!isPayloadList(a) || !isPayloadList(b) || a.length !== b.length) return false;\n return a.every((item, i) => sameCanonical(item, b[i]));\n }\n if (typeof a !== 'object' || typeof b !== 'object' || a === null || b === null) return false;\n const keysA = Object.keys(a);\n const keysB = Object.keys(b);\n return keysA.length === keysB.length && keysA.every((k) => k in b && sameCanonical(a[k], b[k]));\n}\n\ninterface Visit {\n payload: EventPayload | null;\n frame: EventPayload | null;\n}\n\n/**\n * A set of deliveries under the `dispatchVisitKey` identity. Steps are filed by `(trait, event, from)`;\n * payload and frame are compared only against earlier visits of that same step, so a large entity\n * frame is not serialized on every cascade step. Payload and frame are kept as their top-level fields\n * stood when recorded: a step reassigns entity fields in place, nested values are never mutated.\n */\nexport class DispatchVisits {\n private readonly steps = new Map<string, Visit[]>();\n\n has(trait: string, event: string, from: string, payload: EventPayload | null | undefined, frame: EventPayload | null): boolean {\n const seen = this.steps.get(`${trait}\\u0000${event}\\u0000${from}`);\n return seen !== undefined && seen.some((v) => sameCanonical(v.payload, payload) && sameCanonical(v.frame, frame));\n }\n\n add(trait: string, event: string, from: string, payload: EventPayload | null | undefined, frame: EventPayload | null): void {\n if (this.has(trait, event, from, payload, frame)) return;\n const step = `${trait}\\u0000${event}\\u0000${from}`;\n const visit: Visit = {\n payload: payload === undefined || payload === null ? null : { ...payload },\n frame: frame === null ? null : { ...frame },\n };\n const seen = this.steps.get(step);\n if (seen === undefined) this.steps.set(step, [visit]);\n else seen.push(visit);\n }\n}\n","/**\n * Whether a guard holds. A guard that throws does not hold: it blocks its transition exactly\n * like a false guard, and the error is handed to `onError` (one rule on every path — the JS\n * runtime, the code the TypeScript shell generates, and the Rust kernel).\n */\nexport function guardHolds(check: () => boolean, onError: (error: Error) => void): boolean {\n try {\n return check();\n } catch (error) {\n onError(error instanceof Error ? error : new Error(String(error)));\n return false;\n }\n}\n","/**\n * Server-side effect result — the wire shape a server-executed effect\n * (`SERVER_REPORTED_EFFECTS` in `effect.ts`) reports back to the client,\n * closing the circuit on `EventResponse.effectResults`.\n *\n * Promoted from `@almadar/runtime`'s `ServerEffectHandlers.ts` (the JS\n * interpreter's own definition, canonical per `CLAUDE.md`'s \"converge on\n * the TypeScript implementation\" ruling) so `@almadar/core` owns the one\n * shape both execution paths report against.\n *\n * @packageDocumentation\n */\n\nimport { z } from 'zod';\nimport { EntityRowSchema, type EntityRow } from './entity.js';\nimport { SERVER_REPORTED_EFFECTS, type ServerReportedEffect, type NamespacedEffectName } from './effect.js';\nimport { EventPayloadValueSchema, type EventPayloadValue } from './expression.js';\n\n/**\n * Result entry recorded for each effect invocation. Mirrors the server\n * runtime's `EffectResult`. Callers who want telemetry pass an array that\n * the factory appends to; otherwise it's unused.\n */\nexport type ServerBatchSummary = {\n operations: EntityRow[];\n completedCount: number;\n totalCount: number;\n};\n\n/** Zod twin of `ServerBatchSummary`. */\nexport const ServerBatchSummarySchema: z.ZodType<ServerBatchSummary> = z.object({\n operations: z.array(EntityRowSchema),\n completedCount: z.number(),\n totalCount: z.number(),\n});\n\nexport type ServerEffectResult = {\n /**\n * The reported effect's head (`SERVER_REPORTED_EFFECTS`, derived from the\n * effect union in `effect.ts`), or `\"substrate\"` — the one wire grouping\n * for the namespaced operators (`trace/*`, `memory/*`, `session/*`,\n * `behavior/*`, `compose/*`), whose head rides `name`.\n */\n effect: ServerReportedEffect | \"substrate\";\n action?: string;\n entityType?: string;\n /** The invoked namespaced operator (e.g. `\"llm/generate\"`), set only on `effect: \"substrate\"`. */\n name?: NamespacedEffectName;\n /** Entity row for CRUD/set/swap, the batch summary for `persist batch`, the raw service/substrate result. */\n data?: EntityRow | ServerBatchSummary | EventPayloadValue;\n success: boolean;\n /**\n * Set when a persist failed because an access policy rejected it or the\n * write resolved no row key — mirrors `OrbitalServerRuntime.EffectResult`\n * so the offline-preview and real-server persist paths report the same\n * denial discriminator to the verification trace.\n */\n denied?: true;\n error?: string;\n /** Coded failure reason for a persist that resolved no target row (`not-found`, `no-row-key`), created on a taken id (`duplicate-id`), or was refused by a declared policy (`denied`), or a `@derived` field could not be computed (`derived-failed`, EXEC-STEP-8). */\n code?: \"not-found\" | \"no-row-key\" | \"duplicate-id\" | \"denied\" | \"derived-failed\";\n /** What the effect addressed: an `http` effect's `<METHOD> <origin><path>`, an `emit` entry's event name. */\n target?: string;\n /** The declared `emit.failure` event the program routed this effect's failure to; absent when it declares none. */\n routed?: string;\n};\n\n/** Zod twin of `ServerEffectResult`. */\nexport const ServerEffectResultSchema: z.ZodType<ServerEffectResult> = z.object({\n effect: z.union([z.enum(SERVER_REPORTED_EFFECTS), z.literal(\"substrate\")]),\n action: z.string().optional(),\n entityType: z.string().optional(),\n name: z.custom<NamespacedEffectName>((v) => typeof v === \"string\" && /^[^/]+\\/.+$/.test(v)).optional(),\n data: z.union([EntityRowSchema, ServerBatchSummarySchema, EventPayloadValueSchema]).optional(),\n success: z.boolean(),\n denied: z.literal(true).optional(),\n error: z.string().optional(),\n code: z.enum([\"not-found\", \"no-row-key\", \"duplicate-id\", \"denied\", \"derived-failed\"]).optional(),\n target: z.string().optional(),\n routed: z.string().optional(),\n});\n","{\n \"actionPrefix\": \"action-\",\n \"overflowKey\": \"overflow\",\n \"gestureEventProps\": {\n \"longPressEvent\": \"long-press\",\n \"swipeLeftEvent\": \"swipe-left\",\n \"swipeRightEvent\": \"swipe-right\"\n },\n \"nativeIdPrefix\": {\n \"pattern\": \"pattern-\",\n \"row\": \"row-\",\n \"field\": \"field-\",\n \"slot\": \"slot-\"\n },\n \"nativeIdSeparator\": \" \"\n}\n","/**\n * Verification Types (framework concept)\n *\n * The `window.__orbitalVerification` bridge is the single observation\n * point Playwright-based verifiers (`orbital-verify`, `runtime-verify`,\n * `@almadar-io/verify`) use to read runtime state out of a live app.\n * Its shape was previously duplicated between `@almadar/ui`'s\n * `verificationRegistry.ts` (producer) and `@almadar-io/verify`'s\n * `state-bridge.ts` (consumer). Every added field had to be mirrored\n * by hand; one side drifting silently broke the other.\n *\n * Hoisting the wire types into `@almadar/core` closes that gap the same\n * way {@link BusEvent} closed the UI/runtime event-shape drift. The\n * registry still owns the state machine, the schedule, and the window\n * exposure — this module owns only the shapes both sides agree on.\n *\n * @packageDocumentation\n */\n\nimport type { TraitConfig } from \"./trait.js\";\nimport type { EntityRow } from \"./entity.js\";\nimport type { EvalTrace, EventPayload, SExpr } from \"./expression.js\";\nimport type { BusEventSource } from \"./bus.js\";\nimport type { HopObservation } from \"../generated/kernel-wire.js\";\nimport verificationIds from \"./verification-ids.json\";\n\n// ── Checks ────────────────────────────────────────────────────────────\n\n/**\n * Outcome of a single verification check. `warn` is non-fatal in the\n * overall pass/fail tally; `pending` means the check has been registered\n * but not yet resolved.\n */\nexport type CheckStatus = \"pass\" | \"fail\" | \"pending\" | \"warn\";\n\nexport interface VerificationCheck {\n id: string;\n label: string;\n status: CheckStatus;\n details?: string;\n /** Timestamp (ms since epoch) when the status last changed. */\n updatedAt: number;\n}\n\n// ── Transition timeline ──────────────────────────────────────────────\n\n/**\n * Trace of a single effect as it ran on a transition. `args` are the\n * effect tuple's trailing S-expressions; consumers narrow via `type`\n * before inspecting.\n */\nexport interface EffectTrace {\n type: string;\n /** For fetch/persist effects: the entity the effect addresses. */\n entityName?: string;\n /** For persist effects: the mutation performed. */\n action?: \"create\" | \"upsert\" | \"update\" | \"delete\" | \"batch\";\n /** For a persist that wrote a row: its id. */\n resultId?: string;\n /**\n * The effect's real outcome, distinct from `status`. `denied` means the\n * write was rejected by an access policy or resolved no row key —\n * `status` reports `\"failed\"` for it too (kept for back-compat with\n * consumers that only branch on `status`); `outcome` is the one field\n * that tells a denial apart from any other kind of failure.\n */\n outcome?: \"success\" | \"denied\" | \"failed\";\n args: SExpr[];\n status: \"executed\" | \"failed\" | \"skipped\";\n error?: string;\n /** What the effect addressed: an `http` effect's `<METHOD> <origin><path>`, an `emit` entry's event name. */\n target?: string;\n /** The declared `emit.failure` event the program routed this effect's failure to; absent when it declares none. */\n routed?: string;\n durationMs?: number;\n /** The effect expression's evaluation, node by node, when the producer traced it. */\n evalTrace?: EvalTrace;\n}\n\n/** What the server returned for a forwarded event. */\nexport interface ServerResponseTrace {\n orbitalName: string;\n success: boolean;\n /**\n * The runtime's own verdict on whether ANY arm accepted this dispatch\n * (`EventResponse.transitioned`). `false` = the event was\n * delivered but no transition fired — guard false, or no arm in the\n * current state — which a self-loop's unchanged state cannot reveal on\n * its own. Undefined only where the producing path does not report it\n * yet (the compiled client bridge's lifecycle payload).\n */\n transitioned?: boolean;\n /**\n * Server-side emits with their EVALUATED payloads (`EventResponse.\n * emittedEvents[].payload`). `emittedEvents` keeps the names for existing\n * consumers; observers that judge what an emit CARRIES read this — a\n * server-side `(emit SAVE {…})` never reaches the client bus log, and the\n * effect trace holds the declared args, not the values.\n */\n emitted?: ReadonlyArray<{ event: string; payload?: EventPayload }>;\n clientEffects: number;\n dataEntities: Record<string, number>;\n emittedEvents: string[];\n error?: string;\n timestamp: number;\n}\n\nexport interface TransitionTrace {\n id: string;\n traitName: string;\n from: string;\n to: string;\n event: string;\n /** The arm that fired, by its position among the state's arms for the event (the kernel's hop). */\n firedArm?: number;\n guardExpression?: string;\n guardResult?: boolean;\n effects: EffectTrace[];\n /** Populated when the event round-tripped to the server. */\n serverResponse?: ServerResponseTrace;\n /** The hop's payload and the trait's `@entity` before and after it, when a verifier asked the kernel\n * to record them (`setRecordEntityAfter`): what the hop's `@ensures` is judged on. */\n observed?: HopObservation;\n timestamp: number;\n}\n\n// ── Bridge health / summary ───────────────────────────────────────────\n\nexport interface BridgeHealth {\n connected: boolean;\n eventsForwarded: number;\n eventsReceived: number;\n lastError?: string;\n lastHeartbeat: number;\n}\n\nexport interface VerificationSummary {\n totalChecks: number;\n passed: number;\n failed: number;\n warnings: number;\n pending: number;\n}\n\n// ── Trait reducer snapshot ────────────────────────────────────────────\n\n/**\n * Per-trait state snapshot exposed to the verifier so it can assert\n * that reducer data (populated by fetch/persist transitions) and the\n * last dispatched payload land in the DOM correctly (VG4/VG6/VG11a/b/c).\n *\n * Mirrors what `useTraitStateMachine` / generated trait logic hooks\n * keep internally, without the verifier having to parse rendered text.\n */\nexport interface TraitStateSnapshot {\n /** Trait name as declared in the schema. */\n traitName: string;\n /** Current state machine state. */\n currentState: string;\n /** Declared state names for this trait (non-empty for healthy refs). */\n states: string[];\n /** Declared event keys for this trait (non-empty for healthy refs). */\n events: string[];\n /**\n * Entity data keyed by entity name. Uses {@link EntityRow} — the\n * canonical persisted-entity shape the server returns and the trait\n * reducer stores. Consumers that need full field-level types can cast\n * down to the generated entity (e.g. `data['CartItem'] as CartItem[]`).\n * Snapshot-on-read; mutating the returned arrays does not affect the\n * live reducer.\n */\n data: Record<string, EntityRow[]>;\n /** Payload of the last event the state machine processed, if any. */\n lastPayload?: EventPayload;\n /**\n * Last event the walker (or a UI click) dispatched into this trait.\n * Used by VG11a to resolve `@payload.X` expected values.\n */\n lastEventDispatched?: {\n event: string;\n payload?: EventPayload;\n source?: BusEventSource;\n timestamp: number;\n };\n /**\n * Bus events received from the server's `emittedEvents` cascade\n * since the last user dispatch. VG4 compares the length against the\n * number of `emit: { success/failure: ... }` entries on the\n * triggering transition.\n */\n cascadeReceived: Array<{\n event: string;\n payload?: EventPayload;\n timestamp: number;\n }>;\n}\n\n// ── Top-level snapshot ────────────────────────────────────────────────\n\nexport interface VerificationSnapshot {\n checks: VerificationCheck[];\n transitions: TransitionTrace[];\n bridge: BridgeHealth | null;\n summary: VerificationSummary;\n /**\n * Per-trait reducer snapshots. Empty on older runtimes that predate\n * the Foundation 1 expansion; non-empty once any trait hook has\n * registered a snapshot getter.\n */\n traits: TraitStateSnapshot[];\n}\n\n// ── Side-channel observation surfaces ────────────────────────────────\n\n/** Asset load status exposed for canvas-based game verification. */\nexport type AssetLoadStatus = \"loaded\" | \"failed\" | \"pending\";\n\n/**\n * Entry recorded on the verification event log. The registry ring-buffers\n * the log to the last `MAX_EVENT_LOG` entries (evicting the oldest, never\n * the recent tail) so long runs don't grow unbounded — see\n * `verificationRegistry` and `eventLogDropped`.\n */\nexport interface EventLogEntry {\n type: string;\n payload?: EventPayload;\n source?: BusEventSource;\n timestamp: number;\n}\n\n/** One guarded arm evaluated while choosing which `from --event-->` arm fires. */\nexport interface GuardEvaluation {\n /** Position of the arm among the trait's `from --event-->` arms, in declaration order. */\n arm: number;\n guard: SExpr;\n passed: boolean;\n trace: EvalTrace;\n error?: string;\n}\n\n/** One played circuit step: Event → Guard → Transition → Effects. */\nexport interface CircuitStepResult {\n trait: string;\n event: string;\n /** A guard-fail always means no transition, even for a self-loop. */\n transitionFired: boolean;\n guard: \"pass\" | \"fail\" | \"none\";\n /** Position of the chosen arm among the trait's `from --event-->` arms; absent when every guard failed. */\n firedArm?: number;\n state: { before: string | null; after: string | null };\n effects: ReadonlyArray<EffectTrace>;\n emitted: ReadonlyArray<EventLogEntry>;\n /** Guarded arms evaluated during arm selection, in order, when the guard hook traced them. */\n guards?: ReadonlyArray<GuardEvaluation>;\n}\n\n// ── Window bridge contract ───────────────────────────────────────────\n\n/**\n * A drawable descriptor as exposed over the verification bridge. The\n * concrete `DrawableNode` union lives downstream in `@almadar/ui`\n * (`lib/drawable/paintDispatch.ts`) and cannot be imported here without\n * inverting the dependency axis; the bridge contract carries the `type`\n * discriminant (`draw-sprite`, `draw-shape`, …) that verifiers narrow on.\n */\nexport interface DrawableDescriptor {\n type: string;\n}\n\n/**\n * The object attached to `window.__orbitalVerification`. Every optional\n * member is wired up by a corresponding `bind*` / `register*` call on\n * the registry (e.g. `bindEventBus` populates `sendEvent`). Consumers\n * should null-check before calling — an older bundle might expose only\n * the core readers.\n */\nexport interface OrbitalVerificationAPI {\n applyConfig?: (traitName: string, config: TraitConfig) => void | Promise<void>;\n getSnapshot: () => VerificationSnapshot;\n getChecks: () => VerificationCheck[];\n getTransitions: () => TransitionTrace[];\n getBridge: () => BridgeHealth | null;\n getSummary: () => VerificationSummary;\n /** Wait for a specific event to be processed. Resolves to null on timeout. */\n waitForTransition: (\n event: string,\n timeoutMs?: number,\n ) => Promise<TransitionTrace | null>;\n /**\n * Send an event into the runtime. Requires {@link bindEventBus} (in\n * `@almadar/ui`) to have run at least once. Payload typed as\n * {@link EventPayload} so callers can't slip non-bus-shaped data in.\n *\n * `traitScope` is the qualified `Orbital.Trait` (or `App.Trait`)\n * scope that bus listeners subscribe under. The bridge constructs\n * `UI:${traitScope}.${event}` and emits that on the bus, matching\n * the codegen-emitted subscription keys (gap #13). When omitted,\n * the legacy bare-prefix form `UI:${event}` is used — kept only\n * for system-scope events like `UI:NAVIGATE`; trait-driven dispatch\n * MUST pass a `traitScope`.\n */\n sendEvent?: (\n event: string,\n payload?: EventPayload,\n traitScope?: string,\n ) => void;\n /** Current state name for a given trait, if known. */\n getTraitState?: (traitName: string) => string | undefined;\n /** Per-trait reducer snapshots (VG4/VG6/VG11a/b/c). */\n getTraitSnapshots?: () => TraitStateSnapshot[];\n /** Canvas frame capture. Populated by game organisms on mount. */\n captureFrame?: () => string | null;\n /** Last neutral drawables list received by the active canvas host. */\n getLastDrawables?: () => DrawableDescriptor[] | null;\n /** Asset-url → load-status map. Populated by game organisms. */\n assetStatus?: Record<string, AssetLoadStatus>;\n /** Rolling event bus log. Populated by `bindEventBus`. */\n eventLog?: EventLogEntry[];\n /**\n * Per-page-load nonce, set once when `bindEventBus` creates the log\n * (and bumped by `clearEventLog`). A verifier reading the log across\n * hermetic page reloads uses this — not the array length — to detect a\n * reset: the length can coincidentally refill to the same count after a\n * reload, which silently drops the post-reload delta. The epoch changing\n * is the only reliable reset signal.\n */\n eventLogEpoch?: string;\n /**\n * Count of entries evicted from the FRONT of the ring-buffered log this\n * page (see `MAX_EVENT_LOG`). The absolute index of `eventLog[i]` is\n * `eventLogDropped + i`, so a verifier can cursor by absolute position\n * even after eviction — the recent (driven) tail is never silently lost.\n */\n eventLogDropped?: number;\n /** Clear the event log in place (also bumps `eventLogEpoch`). */\n clearEventLog?: () => void;\n}\n\n/** `data-testid` of the box UISlotRenderer draws when a pattern prop's value\n * has a shape no declared type accepts; verifiers count each as a failure. */\nexport const PATTERN_PROP_TYPE_ERROR_TESTID = \"pattern-prop-type-error\";\n\n/** `data-testid` of the error a trait's card shows when its lifecycle step\n * (INIT/LOAD/$MOUNT) throws; verifiers count each as a failure. */\nexport const TRAIT_MOUNT_ERROR_TESTID = \"trait-mount-error\";\n\n/** DOM attribute on an empty-state view's root, so a verifier finds empty collections by structure, never by text. */\nexport const EMPTY_STATE_MARKER = \"data-empty-state\";\n\n/** DOM attribute on a loading view's root (spinner, loading state). */\nexport const LOADING_STATE_MARKER = \"data-loading-state\";\n\n/** Web DOM attributes the verifier selects on; one owner for @almadar/ui (producer) and @almadar-io/verify (consumer). */\nexport const VERIFICATION_DOM_ATTRS = {\n pattern: \"data-pattern\",\n rowId: \"data-row-id\",\n entityRow: \"data-entity-row\",\n entityId: \"data-entity-id\",\n fieldName: \"data-field-name\",\n event: \"data-event\",\n} as const;\n\nexport const ACTION_TESTID_PREFIX = verificationIds.actionPrefix;\n\nexport const ACTION_OVERFLOW_TESTID = `${ACTION_TESTID_PREFIX}${verificationIds.overflowKey}`;\n\n/** Pattern name of the form container a verifier fills. */\nexport const FORM_PATTERN = \"form-section\";\n\n/** `data-testid` (web) / native identifier of an element that dispatches `eventKey`. */\nexport function actionTestId(eventKey: string): string {\n return `${ACTION_TESTID_PREFIX}${eventKey}`;\n}\n\n/** True when `testId` dispatches `event`: the exact form, or a qualified `Orbital.Trait.EVENT` form. */\nexport function actionTestIdMatches(testId: string, event: string): boolean {\n if (!testId.startsWith(ACTION_TESTID_PREFIX)) return false;\n const key = testId.slice(ACTION_TESTID_PREFIX.length);\n return key === event || key.endsWith(`.${event}`);\n}\n\n/** How an affordance dispatches its event: a tap, or a gesture its pattern declares. */\nexport type ActionGesture = \"tap\" | \"long-press\" | \"swipe-left\" | \"swipe-right\";\n\nconst GESTURES: readonly ActionGesture[] = [\"tap\", \"long-press\", \"swipe-left\", \"swipe-right\"];\n\n/** Pattern props whose event fires on a gesture, not a tap (`calendar-grid`, `data-list`). */\nfunction gestureOf(name: string): Exclude<ActionGesture, \"tap\"> {\n const gesture = GESTURES.find((g): g is Exclude<ActionGesture, \"tap\"> => g !== \"tap\" && g === name);\n if (gesture === undefined) throw new Error(`verification-ids.json names an unknown gesture \"${name}\"`);\n return gesture;\n}\n\nexport const GESTURE_EVENT_PROPS: Readonly<Record<string, Exclude<ActionGesture, \"tap\">>> = Object.fromEntries(\n Object.entries(verificationIds.gestureEventProps).map(([prop, gesture]) => [prop, gestureOf(gesture)]),\n);\n\n/** The identifier of an element whose `gesture` dispatches `eventKey`; a tap is the plain {@link actionTestId}. */\nexport function gestureActionTestId(eventKey: string, gesture: ActionGesture): string {\n return gesture === \"tap\" ? actionTestId(eventKey) : `${ACTION_TESTID_PREFIX}${gesture}:${eventKey}`;\n}\n\n/** The gesture `testId` dispatches `event` with, or null when it does not dispatch `event`. */\nexport function gestureOfActionTestId(testId: string, event: string): ActionGesture | null {\n if (!testId.startsWith(ACTION_TESTID_PREFIX)) return null;\n const rest = testId.slice(ACTION_TESTID_PREFIX.length);\n const colon = rest.indexOf(\":\");\n const gesture = colon < 0 ? \"tap\" : GESTURES.find((g) => g !== \"tap\" && g === rest.slice(0, colon));\n if (gesture === undefined) return null;\n const key = colon < 0 ? rest : rest.slice(colon + 1);\n return key === event || key.endsWith(`.${event}`) ? gesture : null;\n}\n\n/** Single-identifier prefixes for native shells (accessibilityIdentifier / testTag); row scope is hierarchical. */\nexport const NATIVE_ID_PREFIX = verificationIds.nativeIdPrefix;\n\n/** Separates the ids of one native element that dispatches several actions (a tap and a gesture). */\nexport const NATIVE_ID_SEPARATOR = verificationIds.nativeIdSeparator;\n\n/** The identifier of a native element carrying every non-empty id in `ids`. */\nexport function nativeIds(...ids: readonly string[]): string {\n return ids.filter((id) => id !== \"\").join(NATIVE_ID_SEPARATOR);\n}\n\n/** The ids a native identifier carries. */\nexport function splitNativeIds(identifier: string): string[] {\n return identifier.split(NATIVE_ID_SEPARATOR).filter((id) => id !== \"\");\n}\n\nexport function nativePatternId(name: string): string {\n return `${NATIVE_ID_PREFIX.pattern}${name}`;\n}\n\nexport function nativeRowId(id: string): string {\n return `${NATIVE_ID_PREFIX.row}${id}`;\n}\n\nexport function nativeFieldId(name: string): string {\n return `${NATIVE_ID_PREFIX.field}${name}`;\n}\n\nexport function nativeSlotId(name: string): string {\n return `${NATIVE_ID_PREFIX.slot}${name}`;\n}\n","[\n {\n \"code\": \"ORB_T_MISSING_RENDER_UI\",\n \"category\": \"trait\",\n \"description\": \"Interaction trait missing render_ui effects\"\n },\n {\n \"code\": \"ORB_T_BEHAVIOR_REF_UNRESOLVED\",\n \"category\": \"trait\",\n \"description\": \"A trait-value literal (`<spec>.traits.<Trait>`) whose behavior or trait does not resolve against the installed behavior packages.\"\n },\n {\n \"code\": \"ORB_T_BEHAVIOR_REF_NOT_LITERAL\",\n \"category\": \"trait\",\n \"description\": \"A `behavior/ref` whose argument is computed at run time: a behavior from data must arrive as a `behavior` value, never re-parsed from text.\"\n },\n {\n \"code\": \"ORB_T_UNQUOTE_OUTSIDE_QUASIQUOTE\",\n \"category\": \"trait\",\n \"description\": \"An `[\\\"unquote\\\", …]` call outside a quasiquote body in an `.orb` input.\"\n },\n {\n \"code\": \"ORB_T_EVENT_REF_UNRESOLVED\",\n \"category\": \"trait\",\n \"description\": \"An event-typed config value addresses a trait the program does not have.\"\n },\n {\n \"code\": \"ORB_T_EVENT_REF_NOT_EXTERNAL_INPUT\",\n \"category\": \"trait\",\n \"description\": \"An event-typed config value addresses an event its trait does not declare as an external input.\"\n },\n {\n \"code\": \"ORB_T_CONFIG_SHAPE_MISMATCH\",\n \"category\": \"trait\",\n \"description\": \"Config field's default value doesn't match its declared structural shape (array vs scalar, object vs string, missing required, etc.). Fires after the typed-config carriers (`items` / `properties` / `values`) make the declared shape concrete enough to check against.\"\n },\n {\n \"code\": \"ORB_T_TYPE_UNKNOWN\",\n \"category\": \"trait\",\n \"description\": \"A type reference names no declared type, entity or primitive\"\n },\n {\n \"code\": \"ORB_T_TYPE_CYCLE\",\n \"category\": \"trait\",\n \"description\": \"A type composition chain refers back to itself\"\n },\n {\n \"code\": \"ORB_T_TYPE_KIND_MISMATCH\",\n \"category\": \"trait\",\n \"description\": \"Composed types do not share a kind (all Entity, all Trait, …)\"\n },\n {\n \"code\": \"ORB_T_TYPE_COMPOSITION_CONFLICT\",\n \"category\": \"trait\",\n \"description\": \"A field is declared in more than one composed entity\"\n },\n {\n \"code\": \"ORB_T_TYPE_ANNOTATION_MISMATCH\",\n \"category\": \"trait\",\n \"description\": \"A type body does not match its `::` type annotation\"\n },\n {\n \"code\": \"ORB_T_TYPE_UNKNOWN_PARAM\",\n \"category\": \"trait\",\n \"description\": \"A type alias body uses a type parameter the alias does not declare\"\n },\n {\n \"code\": \"ORB_T_TYPE_WRONG_ARG_COUNT\",\n \"category\": \"trait\",\n \"description\": \"A type alias is applied with the wrong number of type arguments\"\n },\n {\n \"code\": \"ORB_T_EVENT_TYPE_WRONG_KIND\",\n \"category\": \"trait\",\n \"description\": \"An `emits` entry names a declared type that is not an Event type\"\n },\n {\n \"code\": \"ORB_T_TYPE_UNION_ARM_COLLISION\",\n \"category\": \"trait\",\n \"description\": \"Two arms of one union name the same model arm (two lists, two maps, two objects)\"\n },\n {\n \"code\": \"ORB_P_UNKNOWN_PROTOCOL\",\n \"category\": \"page\",\n \"description\": \"A page names a protocol that is no row of the protocol table\"\n },\n {\n \"code\": \"ORB_P_ENDPOINT_GRANT_MISSING\",\n \"category\": \"page\",\n \"description\": \"An `http` endpoint has no covering `net` listen grant\"\n },\n {\n \"code\": \"ORB_P_ADDRESS_INVALID\",\n \"category\": \"page\",\n \"description\": \"A protocol page's address does not type-check against the protocol's address record\"\n },\n {\n \"code\": \"ORB_RUI_INVALID_ROW_ROUTE\",\n \"category\": \"render_ui\",\n \"description\": \"A data-grid/data-list row action `navigatesTo` is neither a literal path nor a quoted single-row lambda.\"\n },\n {\n \"code\": \"ORB_RUI_UNKNOWN_ITEM_ACTION_PROP\",\n \"category\": \"render_ui\",\n \"description\": \"Unknown itemAction prop (e.g., hallucinated 'condition')\"\n },\n {\n \"code\": \"ORB_RUI_BINDING_TYPE_MISMATCH\",\n \"category\": \"render_ui\",\n \"description\": \"L2.1 keystone: render-ui prop bound to a `@payload.X` / `@entity.X` / `@config.X` / SExpression operator whose resolved type doesn't match any of the prop's declared `types` in the patterns registry. Distinct from `RenderUIPropTypeMismatch` (literal-only); this rule uses the F3 binding resolver to walk through bindings and SExpression operator return types (sharpened by F2's `returnSemantics` for input-dependent operators). Gap #6 in `docs/Almadar_Std_Verification.md`.\"\n },\n {\n \"code\": \"ORB_RUI_EVENT_BINDING_PAYLOAD_MISMATCH\",\n \"category\": \"render_ui\",\n \"description\": \"L2.2: render-ui prop with `kind: \\\"event-ref\\\"` or `kind: \\\"callback\\\"` bound to an event-name string whose declared payload schema in the trait's `emits {}` block doesn't match the component's documented bus emit shape (registry's `emitPayloadSchema` for event-ref props; `callbackArgs` for callback props). Gap #32 in `docs/Almadar_Std_Verification.md`.\"\n },\n {\n \"code\": \"ORB_CANCEL_CALL_NO_KEYED_CALL\",\n \"category\": \"effect\",\n \"description\": \"the app runs `cancel-call` but no `call-service` anywhere carries a `key`\"\n },\n {\n \"code\": \"ORB_CANCEL_CALL_KEY_NEVER_CALLED\",\n \"category\": \"effect\",\n \"description\": \"`--final`: a `cancel-call` on a `CallKey` (or a list of them) in a finished program where no keyed call has a `CallKey`-typed `key:`, so nothing the program runs is named by a key made with `as`\"\n },\n {\n \"code\": \"ORB_PAGE_FACTS_UNREQUESTED_READ\",\n \"category\": \"effect\",\n \"description\": \"an event reads a page fact the `browser/page-facts` call did not request\"\n },\n {\n \"code\": \"ORB_TAB_REQUEST_REFUSED\",\n \"category\": \"effect\",\n \"description\": \"a literal `browser/tab-*` request whose keys the op declares but whose values the kernel's tab-call parser refuses\"\n },\n {\n \"code\": \"ORB_X_DISPATCH_MIXED_RESIDENCE\",\n \"category\": \"effect\",\n \"description\": \"one dispatch's delegated effects reach browser-stored rows and server work\"\n },\n {\n \"code\": \"ORB_EFF_SLOT_CONFLICT\",\n \"category\": \"effect\",\n \"description\": \"Multiple render_ui effects targeting same slot\"\n },\n {\n \"code\": \"ORB_EFF_NOTIFY_RETIRED\",\n \"category\": \"effect\",\n \"description\": \"`notify` is sugar for `render-ui toast { type: alert, … }`, desugared at `.lolo` lowering (owner ruling 2026-09-11) — the `.orb` IR never carries a `notify` effect kind. A `notify` tuple reaching L2 means a hand-authored `.orb` or a registry not yet re-emitted.\"\n },\n {\n \"code\": \"ORB_EMIT_DECLARED_BUT_UNFIRED\",\n \"category\": \"effect\",\n \"description\": \"Trait declares an event in its `emits[]` block but no transition fires it via `(emit X)` or operator emit-config success/failure. Usually a copy-paste leftover or a stale declaration after a rename; gap #2 defense in `docs/Almadar_Std_Verification.md`.\"\n },\n {\n \"code\": \"ORB_EFF_MISSING_REQUIRED_EMIT\",\n \"category\": \"effect\",\n \"description\": \"Operator declares `requiresEmitSuccess: true` in canonical-operators.json but the effect call site is missing the trailing options object or its `emit.success` event key. Applies to fetch / persist / call-service by default; any future operator can opt in via the same JSON flag.\"\n },\n {\n \"code\": \"SEXPR_ARITY_MISMATCH\",\n \"category\": \"sexpr\",\n \"description\": \"Wrong number of arguments for operator\"\n },\n {\n \"code\": \"SEXPR_LAMBDA_ARG_POSITION\",\n \"category\": \"sexpr\",\n \"description\": \"A `(fn …)` form in an argument position the operator does not take its lambda in — decidable wrong argument order, e.g. `(array/reduce arr (fn …) init)`\"\n },\n {\n \"code\": \"SEXPR_EFFECT_IN_GUARD\",\n \"category\": \"sexpr\",\n \"description\": \"Effect operator used in guard context\"\n },\n {\n \"code\": \"ORB_X_UNRESOLVED_PATTERN_FIELD_REF\",\n \"category\": \"cross\",\n \"description\": \"A pattern prop tagged `kind: 'field-ref'` (scalar) or `itemKind: 'field-ref'` (array element) carries a value that does not resolve to any field on the linked entity. Error severity. See Phase 3.2/3.3 in docs/Almadar_Agent_Behaviors_Plan.md.\"\n },\n {\n \"code\": \"ORB_CONFIG_FIELD_REF_UNKNOWN\",\n \"category\": \"binding\",\n \"description\": \"A `field @entity` config knob names something that is not a field of the trait's bound entity\"\n },\n {\n \"code\": \"ORB_CONFIG_FIELD_REF_TYPE_MISMATCH\",\n \"category\": \"binding\",\n \"description\": \"A `field @entity T` config knob names a field whose type is not `T`\"\n },\n {\n \"code\": \"ORB_BINDING_INVALID_PATH\",\n \"category\": \"binding\",\n \"description\": \"Invalid binding path\"\n },\n {\n \"code\": \"ORB_X_SET_VALUE_TYPE_MISMATCH\",\n \"category\": \"effect\",\n \"description\": \"`(set @entity.X ?payloadField)` writes a payload field whose declared type does not match the target entity field's declared type. The lolo crate catches this at author time for `.lolo`; this is the raw-`.orb` defense-in-depth backstop. Payload field types are sourced from the trait's `emits[].payload_schema` and `listens` payload metadata.\"\n },\n {\n \"code\": \"ORB_X_SET_RETURN_TYPE_MISMATCH\",\n \"category\": \"effect\",\n \"description\": \"`(set @entity.X (op …))` assigns an operator/expression value whose inferred result type is incompatible with the target field's declared type (e.g. `(set @entity.count (str/concat …))` into a `number` field). The value's type is inferred *through* the S-expression via the canonical operator `return_semantics` lattice; an unknowable result (`Json`) never rejects (Gap G-LOLO-SET-OP-RETURN).\"\n },\n {\n \"code\": \"ORB_X_COMPARISON_OPERAND_TYPE_MISMATCH\",\n \"category\": \"effect\",\n \"description\": \"An ordering comparison (`<`, `<=`, `>`, `>=`) whose operands infer to a number on one side and a string on the other. The JS runtime coerces, the compiled TypeScript does not typecheck, and Rust compares kinds — the paths disagree. Convert one side so both are the same kind.\"\n },\n {\n \"code\": \"ORB_X_OPERATOR_ARG_TYPE_MISMATCH\",\n \"category\": \"effect\",\n \"description\": \"An operator argument whose static type contradicts the type the operator table declares for its position — `(str/upper @entity.count)` with `count: number`, `(+ \\\"a\\\" 1)`. Both evaluators raise the same typed mismatch at run time (D-12), so the program can never do what it says.\"\n },\n {\n \"code\": \"ORB_OBJECT_PATH_UNDECLARED\",\n \"category\": \"effect\",\n \"description\": \"A literal path read through `object/get` (or another `key-of` operator) names a segment its first argument's declared type does not have: an empty segment, a record field the record does not declare, a non-numeric segment on a list or tuple, or a segment past a scalar. A Map takes any non-empty key segment. The read could only ever answer null or its default; a default does not excuse it. To read a key that contains a dot, escape the dot (`a\\\\.b`) or read the map with `object/pick`.\"\n },\n {\n \"code\": \"ORB_X_OPERATOR_ARG_UNDETERMINED\",\n \"category\": \"effect\",\n \"description\": \"A value handed to an operator has no determined type — an unresolved expression, an expression value, json, a loose union, a list whose items share no type — so it cannot be checked against the type the operator declares (or, at a type variable, what the variable stands for and the type of the result are unknown). Narrow it with `(as value T)` (checked, null on a misfit), or give it a real type (a declared payload or entity shape, a named union alias for a list of differently-shaped items).\"\n },\n {\n \"code\": \"ORB_X_ORDERING_OPTIONAL_OPERAND\",\n \"category\": \"effect\",\n \"description\": \"An ordering comparison (`<`, `<=`, `>`, `>=`) over an operand that can be missing or null — an optional entity field with no default, an optional payload field — that the program neither guards with a presence check (`(and (validate/required x) (< x 3))`, an `if`/`when` on presence) nor declares a default for. Both evaluators read a missing value as below any number; every push-down store fails the comparison, so the meaning is the program's to state.\"\n },\n {\n \"code\": \"ORB_X_OPERATOR_NULL_OPERAND\",\n \"category\": \"effect\",\n \"description\": \"An operand that can be missing or null — an optional entity field with no default, an optional payload field — handed to a position the kernel raises on when it is null (`rejectsNull` in the operator table), with no presence check or default in front of it. The program says what a missing value means: a guard, a default, or a required field.\"\n },\n {\n \"code\": \"ORB_X_OPERATOR_OPTION_NEWER\",\n \"category\": \"effect\",\n \"description\": \"A call states an operator option that the installed operator table introduces in an orb release newer than the one running (`optionSince`), so this orb would refuse or ignore it at the host. Upgrade orb, or drop the option.\"\n },\n {\n \"code\": \"ORB_X_SET_REQUIRED_FIELD_FROM_OPTIONAL_KNOB\",\n \"category\": \"effect\",\n \"description\": \"`(set @entity.X @config.<knob>)` where the value is STILL the literal `@config.<knob>` token post-inline (no default resolved it, no call-site override supplied one) and `X` is a REQUIRED entity field. The emitter has nothing honest to assign — a required TS slot gets `undefined`. Give the knob a default or make the field optional.\"\n },\n {\n \"code\": \"ORB_EMIT_PAYLOAD_MISSING_REQUIRED\",\n \"category\": \"binding\",\n \"description\": \"`(emit EVT {...})` literal payload is missing a field the event's declared payload marks as required. Error severity.\"\n },\n {\n \"code\": \"ORB_EMIT_PAYLOAD_EXTRA_FIELD\",\n \"category\": \"binding\",\n \"description\": \"`(emit EVT {...})` literal carries a field that is not declared on the event's payload schema. Error severity.\"\n },\n {\n \"code\": \"ORB_EMIT_PAYLOAD_FIELD_TYPE_MISMATCH\",\n \"category\": \"binding\",\n \"description\": \"`(emit EVT {...})` literal provides a value whose primitive type does not match the declared `PayloadField.field_type`. Error severity.\"\n },\n {\n \"code\": \"ORB_EMIT_REPEATS_IDENTICALLY\",\n \"category\": \"binding\",\n \"description\": \"An `emit` repeats an earlier one of the same transition identically: the dispatch loop collapses the second.\"\n },\n {\n \"code\": \"ORB_X_ENTITY_PROP_CONTRACT\",\n \"category\": \"render_ui\",\n \"description\": \"A render-ui pattern prop typed `EntityWith<K>` declares required entity fields (`requiredFields` in the registry), but the bound entity does not provide them and no remap/field-map supplies them. The component would render blank rows. Remap-aware (runs post-inline). Error severity.\"\n },\n {\n \"code\": \"ORB_EMIT_PAYLOAD_NOT_PRODUCED\",\n \"category\": \"binding\",\n \"description\": \"**The payload invariant.** An event's declared payload type IS its access path: declaring `Survey` means the payload is the row (read `?name`); declaring `{ row : Survey }` means read `?row.name`. This fires when an event declares a field that the effect firing it does not actually emit — so every read of that field is `undefined` at runtime, even though `orb validate` and `orb verify` otherwise pass. Checked as width subtyping (`declared ⊆ produced`): declaring FEWER fields than are emitted is legal, declaring one that is never emitted is not. Replaces the narrower `EmitSuccessPayloadWrapped` (persist-only) and `EmitSuccessPayloadReturnMismatch` (empty-payload-only) checks. Error severity.\"\n },\n {\n \"code\": \"ORB_EFFECT_IN_LAMBDA\",\n \"category\": \"binding\",\n \"description\": \"An effect (`emit`, `persist`, `set`, `notify`, …) inside the `fn` body of a collection operator: a lambda is evaluated for its value, an effect there never runs. Error severity.\"\n },\n {\n \"code\": \"CIRCUIT_DEAD_END_COMPONENT\",\n \"category\": \"circuit\",\n \"description\": \"Interactive component missing itemActions\"\n },\n {\n \"code\": \"ORB_GEN_INVALID_REFERENCE\",\n \"category\": \"generic\",\n \"description\": \"Generic invalid reference format\"\n },\n {\n \"code\": \"ORB_GEN_MISSING_FIELD\",\n \"category\": \"generic\",\n \"description\": \"Generic missing required field\"\n },\n {\n \"code\": \"ORB_GEN_DUPLICATE\",\n \"category\": \"generic\",\n \"description\": \"Generic duplicate entity/item\"\n },\n {\n \"code\": \"CIRCUIT_ACTION_COMPONENT_MISMATCH\",\n \"category\": \"circuit\",\n \"description\": \"An item action is used on a component type that does not support that action\"\n },\n {\n \"code\": \"CIRCUIT_DEAD_END_STATE\",\n \"category\": \"circuit\",\n \"description\": \"A state has no outgoing transitions, so it is a dead end\"\n },\n {\n \"code\": \"CIRCUIT_DEAD_HANDLER\",\n \"category\": \"circuit\",\n \"description\": \"An item action fires an event into a state where no transition handles that event\"\n },\n {\n \"code\": \"CIRCUIT_DUPLICATE_EVENT\",\n \"category\": \"circuit\",\n \"description\": \"The same event is emitted by more than one action within a single render-ui effect\"\n },\n {\n \"code\": \"CIRCUIT_MODAL_EXIT_INCOMPLETE\",\n \"category\": \"circuit\",\n \"description\": \"A transition leaving a modal state does not close the modal overlay it opened\"\n },\n {\n \"code\": \"CIRCUIT_NO_OVERLAY_EXIT\",\n \"category\": \"circuit\",\n \"description\": \"A state renders into an overlay slot but has no exit transition, leaving users stuck\"\n },\n {\n \"code\": \"CIRCUIT_ORPHAN_EVENT\",\n \"category\": \"circuit\",\n \"description\": \"An action or emit raises an event that has no transition handler\"\n },\n {\n \"code\": \"CIRCUIT_UNREACHABLE_STATE\",\n \"category\": \"circuit\",\n \"description\": \"A state has no incoming transitions and cannot be reached\"\n },\n {\n \"code\": \"LINT_NODE_UNCHECKED\",\n \"category\": \"lint\",\n \"description\": \"A lint rule met a schema node of an unexpected shape and could not check it\"\n },\n {\n \"code\": \"ORB_A11Y_UNNAMED\",\n \"category\": \"a11y\",\n \"description\": \"A render-ui control has no accessible name, so screen readers announce it as unlabeled\"\n },\n {\n \"code\": \"ORB_ASSET_INLINE_URL\",\n \"category\": \"asset\",\n \"description\": \"A literal http(s) url sits in the config defaults or seed rows of an orbital that composes std-asset-pack.\"\n },\n {\n \"code\": \"ORB_AUTH_GUARD_CLIENT_ONLY\",\n \"category\": \"auth\",\n \"description\": \"A transition guards on @user but its trait dispatches client-only, so the UI transition advances before the server evaluates the guard\"\n },\n {\n \"code\": \"ORB_BEACON_OPTION_UNKNOWN\",\n \"category\": \"beacon\",\n \"description\": \"A browser beacon request carries an option key that is not a known beacon request key\"\n },\n {\n \"code\": \"ORB_BEACON_TEXT_REQUIRED\",\n \"category\": \"browser\",\n \"description\": \"browser/beacon needs a request carrying a text field\"\n },\n {\n \"code\": \"ORB_BEACON_URL_NOT_ABSOLUTE\",\n \"category\": \"browser\",\n \"description\": \"A browser beacon effect targets a URL that is not an absolute http(s) URL\"\n },\n {\n \"code\": \"ORB_BINDING_DISPATCH_ROOT_IN_TICK\",\n \"category\": \"binding\",\n \"description\": \"A dispatch-only binding root is read inside a tick, where a firing has no delivery\"\n },\n {\n \"code\": \"ORB_BINDING_EMBED_READS_ARM_WRITE\",\n \"category\": \"binding\",\n \"description\": \"A transition writes a value and renders a child that reads it on mount, so the child shows the stale value\"\n },\n {\n \"code\": \"ORB_BINDING_ENTITY_FIELD_NEVER_SET\",\n \"category\": \"binding\",\n \"description\": \"A trait reads an entity binding field but no transition ever sets it, so it stays undefined\"\n },\n {\n \"code\": \"ORB_BINDING_ENTITY_FIELD_NOT_FOUND\",\n \"category\": \"binding\",\n \"description\": \"An @entity binding names a field that the linked entity does not declare\"\n },\n {\n \"code\": \"ORB_BINDING_EVENT_INVALID_PATH\",\n \"category\": \"binding\",\n \"description\": \"An @event binding path does not follow the shape of the delivery record\"\n },\n {\n \"code\": \"ORB_BINDING_FROM_ENTITY_OUTSIDE_ENSURES\",\n \"category\": \"binding\",\n \"description\": \"@fromEntity is the row before a transition and may only be used inside an @ensures\"\n },\n {\n \"code\": \"ORB_BINDING_INVALID_FORMAT\",\n \"category\": \"binding\",\n \"description\": \"A binding string is not in a valid binding format\"\n },\n {\n \"code\": \"ORB_BINDING_NOW_NO_PATH\",\n \"category\": \"binding\",\n \"description\": \"The @now binding is given a path, but it returns the current timestamp directly\"\n },\n {\n \"code\": \"ORB_BINDING_PAYLOAD_FIELD_UNDECLARED\",\n \"category\": \"binding\",\n \"description\": \"A @payload binding reads a field that the triggering event does not declare in its payload\"\n },\n {\n \"code\": \"ORB_BINDING_PAYLOAD_IN_TICK\",\n \"category\": \"binding\",\n \"description\": \"A binding reads @payload inside a tick, where a firing has no delivery\"\n },\n {\n \"code\": \"ORB_BINDING_PERSIST_ROW_ID_NEVER_SET\",\n \"category\": \"binding\",\n \"description\": \"A persist update or delete runs on an event but no transition sets the row id, so the write never touches a row\"\n },\n {\n \"code\": \"ORB_BINDING_ROOT_NO_PATH\",\n \"category\": \"binding\",\n \"description\": \"A binding root that takes no path is written with a path\"\n },\n {\n \"code\": \"ORB_BINDING_SET_TARGET_MISSING_PATH\",\n \"category\": \"binding\",\n \"description\": \"A set effect targets a binding root without a field path\"\n },\n {\n \"code\": \"ORB_BINDING_STATE_NO_PATH\",\n \"category\": \"binding\",\n \"description\": \"A binding root that returns a bare value, such as @state, is given a path\"\n },\n {\n \"code\": \"ORB_BINDING_TRAIT_CYCLE\",\n \"category\": \"binding\",\n \"description\": \"A cycle exists in @trait references\"\n },\n {\n \"code\": \"ORB_BINDING_TRAIT_INVALID_FORMAT\",\n \"category\": \"binding\",\n \"description\": \"A trait binding or trait-typed config default is not a valid trait reference\"\n },\n {\n \"code\": \"ORB_BINDING_TRAIT_INVALID_POSITION\",\n \"category\": \"binding\",\n \"description\": \"A @trait binding appears in a position other than a children array or a node-typed prop\"\n },\n {\n \"code\": \"ORB_BINDING_TRAIT_MISSING_NAME\",\n \"category\": \"binding\",\n \"description\": \"A @trait binding does not name the trait it refers to\"\n },\n {\n \"code\": \"ORB_BINDING_TRAIT_OUTSIDE_RENDER_UI\",\n \"category\": \"binding\",\n \"description\": \"An @trait binding appears outside a render-ui effect, where it is the only place trait references are allowed\"\n },\n {\n \"code\": \"ORB_BINDING_TRAIT_SELF_REFERENCE\",\n \"category\": \"binding\",\n \"description\": \"A trait references itself through a trait binding\"\n },\n {\n \"code\": \"ORB_BINDING_TRAIT_UNKNOWN\",\n \"category\": \"binding\",\n \"description\": \"A @trait binding references a trait that is not declared in this orbital\"\n },\n {\n \"code\": \"ORB_BINDING_UNKNOWN_ENTITY\",\n \"category\": \"binding\",\n \"description\": \"A binding refers to an entity that is not declared in the program\"\n },\n {\n \"code\": \"ORB_BINDING_UNKNOWN_ROOT\",\n \"category\": \"binding\",\n \"description\": \"A binding names a root the context does not provide\"\n },\n {\n \"code\": \"ORB_CALL_KEY_UNUSED\",\n \"category\": \"effect\",\n \"description\": \"A literal (as 'k' CallKey) names a key that no keyed call in the program runs under\"\n },\n {\n \"code\": \"ORB_CALL_SERVICE_CANCELLED_WITHOUT_KEY\",\n \"category\": \"call_service\",\n \"description\": \"A call-service declares emit.cancelled but has no key, so nothing can cancel an unkeyed call\"\n },\n {\n \"code\": \"ORB_CALL_SERVICE_KEY_DUPLICATE\",\n \"category\": \"effect\",\n \"description\": \"Two call-service effects in one transition use the same key\"\n },\n {\n \"code\": \"ORB_CALL_SERVICE_KEY_TYPE\",\n \"category\": \"call_service\",\n \"description\": \"A keyed call-service effect has a key that is not a non-empty string\"\n },\n {\n \"code\": \"ORB_CALL_SERVICE_RESULT_HAS_KEY\",\n \"category\": \"effect\",\n \"description\": \"A keyed call-service returns a record that already has a key field, so the call key would collide with it\"\n },\n {\n \"code\": \"ORB_CIRCUIT_ASYNC_RESULT_DEAF_TARGET\",\n \"category\": \"circuit\",\n \"description\": \"A transition declares async result events but its target state has no arm handling them, so the requester cannot hear its own result\"\n },\n {\n \"code\": \"ORB_CIRCUIT_DEAD_BODILESS_ACTION\",\n \"category\": \"circuit\",\n \"description\": \"A transition changes state but carries no effects, so the screen keeps its paint and affordances routed to it are dead\"\n },\n {\n \"code\": \"ORB_CIRCUIT_FAILURE_ARM_MISSING\",\n \"category\": \"circuit\",\n \"description\": \"A transition starting an asynchronous client call has no failure arm to handle its error\"\n },\n {\n \"code\": \"ORB_CIRCUIT_FAILURE_ARM_RENDERS_NOTHING\",\n \"category\": \"circuit\",\n \"description\": \"A state handles a failure event but its arm neither renders nor emits a declared event, so the failure reaches no one\"\n },\n {\n \"code\": \"ORB_CIRCUIT_INIT_UNCOVERED_STATE\",\n \"category\": \"circuit\",\n \"description\": \"A page trait handles INIT in its initial state but not in another reachable state, so revisiting the page from there does nothing\"\n },\n {\n \"code\": \"ORB_CIRCUIT_LIFECYCLE_EMIT_UNDELIVERED\",\n \"category\": \"circuit\",\n \"description\": \"A transition emits a lifecycle event that the event bus never delivers\"\n },\n {\n \"code\": \"ORB_CIRCUIT_MODAL_SHELL_CLOSE_DEAF\",\n \"category\": \"circuit\",\n \"description\": \"A state mounting an overlay-slot pattern has no CLOSE or CANCEL transition to dismiss it\"\n },\n {\n \"code\": \"ORB_CIRCUIT_OWN_EMIT_UNREACHABLE\",\n \"category\": \"circuit\",\n \"description\": \"A transition emits an event its own trait handles only from other states, so the same-trait cascade never delivers it from the target state\"\n },\n {\n \"code\": \"ORB_CIRCUIT_SELF_EMIT_LOOP\",\n \"category\": \"circuit\",\n \"description\": \"A transition re-emits its own trigger event with a constant payload and a same-event arm is reachable, so it loops forever\"\n },\n {\n \"code\": \"ORB_CIRCUIT_SELF_OVERLAY_IN_SHELL\",\n \"category\": \"circuit\",\n \"description\": \"A self-overlaying pattern is rendered inside an overlay slot payload, stacking two overlay chromes\"\n },\n {\n \"code\": \"ORB_CIRCUIT_VIEWER_STRANDED\",\n \"category\": \"circuit\",\n \"description\": \"A page's content owner repaints its region on a user-triggered event with a body that offers no way on\"\n },\n {\n \"code\": \"ORB_COMPOSED_STATE_UNREACHABLE\",\n \"category\": \"circuit\",\n \"description\": \"A composed trait can never enter some states because nothing in the program sends the events that enter them\"\n },\n {\n \"code\": \"ORB_COMPOSED_TRANSITION_UNREACHABLE\",\n \"category\": \"composed\",\n \"description\": \"A composed trait handles events that nothing in the program ever sends\"\n },\n {\n \"code\": \"ORB_COMPUTED_KEY_DOT_PATH\",\n \"category\": \"lint\",\n \"description\": \"object/set, object/get or object/has on a Map field with a str/concat key containing a literal dot: the key is read as a dot path, so the value nests instead of being one map entry\"\n },\n {\n \"code\": \"ORB_CONFIG_DANGLING_REF\",\n \"category\": \"binding\",\n \"description\": \"An @config key is not declared by any config schema reachable from the trait chain\"\n },\n {\n \"code\": \"ORB_CONTROL_NO_CONSEQUENCE\",\n \"category\": \"emit\",\n \"description\": \"A rendered control fires an event whose handlers change nothing the app or the viewer can observe.\"\n },\n {\n \"code\": \"ORB_CONTROL_VALUE_DISCARDED\",\n \"category\": \"circuit\",\n \"description\": \"A composed trait's rendered control fires an event carrying a value that no other trait hears and whose own handling reads none of it: the value the user entered is discarded (a form submission nothing keeps).\"\n },\n {\n \"code\": \"ORB_CREDENTIAL_REQUEST_INVALID\",\n \"category\": \"credential\",\n \"description\": \"A credential request host effect carries options other than the ones it declares\"\n },\n {\n \"code\": \"ORB_DERIVED_FIELD_WRITTEN\",\n \"category\": \"entity_mutation\",\n \"description\": \"A set or persist writes an @derived field that the kernel computes on every write\"\n },\n {\n \"code\": \"ORB_EFFECT_OPTION_DROPPED\",\n \"category\": \"effect\",\n \"description\": \"An effect carries options that depend on a key echo, but the effect has no key so the options are dropped\"\n },\n {\n \"code\": \"ORB_EFF_CALL_SERVICE_MISSING_ACTION\",\n \"category\": \"effect\",\n \"description\": \"A call-service effect has no string action\"\n },\n {\n \"code\": \"ORB_EFF_CALL_SERVICE_MISSING_PARAM\",\n \"category\": \"effect\",\n \"description\": \"A call-service effect omits a parameter the service action requires\"\n },\n {\n \"code\": \"ORB_EFF_CALL_SERVICE_MISSING_SERVICE\",\n \"category\": \"effect\",\n \"description\": \"A call_service effect is missing its service name or action\"\n },\n {\n \"code\": \"ORB_EFF_CALL_SERVICE_PARAM_TYPE\",\n \"category\": \"effect\",\n \"description\": \"A call-service parameter has a value whose type does not match the type the service action declares\"\n },\n {\n \"code\": \"ORB_EFF_CALL_SERVICE_UNKNOWN_PARAM\",\n \"category\": \"effect\",\n \"description\": \"A call-service passes a param that the service action does not declare\"\n },\n {\n \"code\": \"ORB_EFF_CALL_SERVICE_UNKNOWN_SERVICE\",\n \"category\": \"effect\",\n \"description\": \"A call-service effect names a service that is not a registered integrator or declared service\"\n },\n {\n \"code\": \"ORB_EFF_EMIT_INVALID_NAME\",\n \"category\": \"effect\",\n \"description\": \"The event name inside an emit effect is not a valid string event name\"\n },\n {\n \"code\": \"ORB_EFF_EMIT_KEY_INVALID\",\n \"category\": \"effect\",\n \"description\": \"An emit config carries a key that the operator does not support\"\n },\n {\n \"code\": \"ORB_EFF_EMIT_UNDECLARED_EVENT\",\n \"category\": \"effect\",\n \"description\": \"An event named in emit is not declared in the trait's emits array\"\n },\n {\n \"code\": \"ORB_EFF_FETCH_BY_ID_PAYLOAD_LIST\",\n \"category\": \"effect\",\n \"description\": \"A fetch by id effect takes its id from a payload that is a list rather than a single value\"\n },\n {\n \"code\": \"ORB_EFF_FETCH_INVALID_ENTITY\",\n \"category\": \"effect\",\n \"description\": \"A fetch effect is missing an entity name or references an invalid entity\"\n },\n {\n \"code\": \"ORB_EFF_FETCH_INVALID_INCLUDE\",\n \"category\": \"effect\",\n \"description\": \"A fetch includes a relation that the fetched entity has no relation field for\"\n },\n {\n \"code\": \"ORB_EFF_FETCH_INVALID_OPTION\",\n \"category\": \"effect\",\n \"description\": \"A fetch deliver option is not one of the allowed values rows or ids\"\n },\n {\n \"code\": \"ORB_EFF_MISSING_FETCH_FOR_ENTITY\",\n \"category\": \"effect\",\n \"description\": \"A render-ui references an entity but no fetch effect for it exists in this or any predecessor transition\"\n },\n {\n \"code\": \"ORB_EFF_NAVIGATE_MISSING_PAYLOAD\",\n \"category\": \"effect\",\n \"description\": \"A navigate effect omits a payload field the target page requires for its INIT event\"\n },\n {\n \"code\": \"ORB_EFF_NAVIGATE_TARGET_UNREACHABLE\",\n \"category\": \"effect\",\n \"description\": \"A navigate target path does not resolve to any declared page\"\n },\n {\n \"code\": \"ORB_EFF_PROGRAM_EVAL_FAILURE_MISSING\",\n \"category\": \"effect\",\n \"description\": \"program/eval carries no emit.failure event, so validator errors would be dropped\"\n },\n {\n \"code\": \"ORB_EFF_RETIRED_FORM\",\n \"category\": \"effect\",\n \"description\": \"An effect is written in a retired object form instead of the array form\"\n },\n {\n \"code\": \"ORB_EFF_SET_INVALID_BINDING\",\n \"category\": \"effect\",\n \"description\": \"A set effect is missing its binding or its value\"\n },\n {\n \"code\": \"ORB_EFF_SET_PAYLOAD_NOT_ALLOWED\",\n \"category\": \"effect\",\n \"description\": \"A set effect targets @payload, which is read-only; it should target @entity\"\n },\n {\n \"code\": \"ORB_EFF_UNKNOWN_TYPE\",\n \"category\": \"effect\",\n \"description\": \"An effect has an unknown type or is malformed\"\n },\n {\n \"code\": \"ORB_EFF_UNSIGNED_NOT_ENV_GUARDED\",\n \"category\": \"effect\",\n \"description\": \"A jws/verify call with a literal allowUnsigned true sits in a transition that is not env-guarded\"\n },\n {\n \"code\": \"ORB_EMBED_CONFIG_FORWARD_MULTI_REFERRER\",\n \"category\": \"embed\",\n \"description\": \"A trait that forwards @config is embedded by more than one referrer, so the forwarded value is ambiguous\"\n },\n {\n \"code\": \"ORB_EMIT_CONFIG_REF_INVALID\",\n \"category\": \"effect\",\n \"description\": \"An emit config reference is invalid\"\n },\n {\n \"code\": \"ORB_EMIT_CONTROL_UNHANDLED\",\n \"category\": \"emit\",\n \"description\": \"A rendered control fires an event nothing handles or routes.\"\n },\n {\n \"code\": \"ORB_EMIT_UNROUTED_TO_HANDLER\",\n \"category\": \"trait_event\",\n \"description\": \"A trait emits an event another trait has an arm for, but no declared listens route delivers it\"\n },\n {\n \"code\": \"ORB_ENTITY_INTRINSIC_FIELD_PERSISTED\",\n \"category\": \"entity_mutation\",\n \"description\": \"A persist data literal names an @intrinsic field, which is trait-owned view-state and never a persisted column\"\n },\n {\n \"code\": \"ORB_ENTITY_OWNER_COLUMN_UNSCOPED\",\n \"category\": \"entity\",\n \"description\": \"An entity declares owner columns but has no access policy scoping rows to the owner\"\n },\n {\n \"code\": \"ORB_ENTITY_SPLIT_MUTATION\",\n \"category\": \"entity_mutation\",\n \"description\": \"A runtime entity is mutated by several traits on isolated per-trait copies while another trait reads a field it never writes\"\n },\n {\n \"code\": \"ORB_E_DUPLICATE_FIELD\",\n \"category\": \"entity\",\n \"description\": \"An entity declares the same field name more than once\"\n },\n {\n \"code\": \"ORB_E_EMPTY_ENUM_VALUES\",\n \"category\": \"entity\",\n \"description\": \"An enum field declares no values\"\n },\n {\n \"code\": \"ORB_E_IDENTITY_LOCAL\",\n \"category\": \"entity\",\n \"description\": \"An identity entity is declared as browser-stored, but the viewer directory is never browser-resident\"\n },\n {\n \"code\": \"ORB_E_INSTANCE_INVALID\",\n \"category\": \"entity\",\n \"description\": \"An entity instance row sets a key that is not a field of the entity\"\n },\n {\n \"code\": \"ORB_E_INVALID_FIELD_NAME\",\n \"category\": \"entity\",\n \"description\": \"An entity field or entity name is empty or not in the required naming form\"\n },\n {\n \"code\": \"ORB_E_INVALID_FIELD_TYPE\",\n \"category\": \"entity\",\n \"description\": \"An entity field declares a type that is not a valid field type\"\n },\n {\n \"code\": \"ORB_E_INVALID_RELATION\",\n \"category\": \"entity\",\n \"description\": \"A relation field is missing its relation configuration or points at an entity that does not exist\"\n },\n {\n \"code\": \"ORB_E_LITERAL_UNION_DEFAULT_MISMATCH\",\n \"category\": \"entity\",\n \"description\": \"A field default is not one of the values of its declared literal union\"\n },\n {\n \"code\": \"ORB_E_LOCALE_INSTANCES_INCOMPLETE\",\n \"category\": \"entity\",\n \"description\": \"An entity writes rows per locale but has no default instances block for its default locale\"\n },\n {\n \"code\": \"ORB_E_LOCALE_INSTANCES_NOT_LOCAL\",\n \"category\": \"entity\",\n \"description\": \"An entity writes rows per locale but its rows are not browser-stored, so every viewer shares them\"\n },\n {\n \"code\": \"ORB_E_LOCALE_INSTANCES_UNKNOWN_LOCALE\",\n \"category\": \"entity\",\n \"description\": \"An entity writes locale instances for a locale that is not among the declared locales\"\n },\n {\n \"code\": \"ORB_E_LOCAL_REQUIRES_PERSISTENT\",\n \"category\": \"entity\",\n \"description\": \"A runtime entity declares a browser storage location, which only applies to persistent entities\"\n },\n {\n \"code\": \"ORB_E_MERGED_FIELD_UNREFERENCED\",\n \"category\": \"entity\",\n \"description\": \"A field merged into an entity is never read, written, fetch-included or persisted by any trait of the orbital\"\n },\n {\n \"code\": \"ORB_E_MISSING_COLLECTION\",\n \"category\": \"entity\",\n \"description\": \"A persistent entity does not declare a collection name\"\n },\n {\n \"code\": \"ORB_E_MISSING_NAME\",\n \"category\": \"entity\",\n \"description\": \"An entity is missing its required name\"\n },\n {\n \"code\": \"ORB_E_MOCK_NOT_IN_ENUM\",\n \"category\": \"entity\",\n \"description\": \"Mock candidate values are not values of the enum field they belong to\"\n },\n {\n \"code\": \"ORB_E_NO_FIELDS\",\n \"category\": \"entity\",\n \"description\": \"An entity declares no fields and must have at least one\"\n },\n {\n \"code\": \"ORB_E_SEMANTIC_VALUE_INVALID\",\n \"category\": \"entity\",\n \"description\": \"A semantically typed field has a default value that is invalid for its kind, such as an empty string\"\n },\n {\n \"code\": \"ORB_FETCH_DELIVER_IDS_ENTITY_REFS\",\n \"category\": \"fetch\",\n \"description\": \"A fetch using deliver ids also asks for included relations, but ids delivers no rows to carry them\"\n },\n {\n \"code\": \"ORB_FETCH_DELIVER_IDS_NO_SUCCESS\",\n \"category\": \"effect\",\n \"description\": \"A fetch with deliver ids has no emit.success, so nothing carries the reference\"\n },\n {\n \"code\": \"ORB_FETCH_DELIVER_IDS_ROWS_READ\",\n \"category\": \"effect\",\n \"description\": \"A fetch with deliver ids delivers a row-set reference as the success event's data; any use other than passing it whole as a render-ui prop value reads rows that were never delivered\"\n },\n {\n \"code\": \"ORB_FETCH_NEEDS_COMPOSITE_INDEX\",\n \"category\": \"effect\",\n \"description\": \"A fetch query needs a composite index that the store driver does not create and no index declaration covers\"\n },\n {\n \"code\": \"ORB_FETCH_TOTAL_NONE_READ\",\n \"category\": \"effect\",\n \"description\": \"A fetch with total none skips the count, so the success event's totalCount is never set and may not be read\"\n },\n {\n \"code\": \"ORB_FETCH_UNINDEXED\",\n \"category\": \"query\",\n \"description\": \"A fetch filter cannot be pushed down by the store driver and no @index covers it, so the kernel scans every row\"\n },\n {\n \"code\": \"ORB_GEN_INVALID_VALUE\",\n \"category\": \"generic\",\n \"description\": \"A value is invalid for the position it is written in\"\n },\n {\n \"code\": \"ORB_GPU_BINDING_MISMATCH\",\n \"category\": \"os\",\n \"description\": \"A gpu/bind-group-create whose literal entries do not fit the bindings its traced pipeline's entry points use in its WGSL\"\n },\n {\n \"code\": \"ORB_GPU_LEAK\",\n \"category\": \"gpu\",\n \"description\": \"A device reaches a resting state on some path without being closed\"\n },\n {\n \"code\": \"ORB_GPU_SHADER_INVALID\",\n \"category\": \"os\",\n \"description\": \"A literal gpu/shader-create WGSL source that naga refuses to parse or validate\"\n },\n {\n \"code\": \"ORB_GPU_USE_AFTER_RELEASE\",\n \"category\": \"gpu\",\n \"description\": \"A gpu/ call takes a handle after it was released or its device closed on some path, or a handle is released a second time\"\n },\n {\n \"code\": \"ORB_GUARD_ON_FRAME_FIELD_AUTHORIZES\",\n \"category\": \"guard\",\n \"description\": \"A guard reads an intrinsic frame field of an entity to authorize, but intrinsic fields are not trustworthy for access\"\n },\n {\n \"code\": \"ORB_GUEST_VIEW_NOT_CLIENT\",\n \"category\": \"trait\",\n \"description\": \"A trait that does not run on the client paints a guest-view, so the kernel cannot route a click inside the guest\"\n },\n {\n \"code\": \"ORB_HOST_EFFECT_ARITY\",\n \"category\": \"effect\",\n \"description\": \"A host effect is called with the wrong number of arguments\"\n },\n {\n \"code\": \"ORB_HOST_EFFECT_OPTION_UNKNOWN\",\n \"category\": \"host_effect\",\n \"description\": \"A host effect is given an option outside the set of options it accepts\"\n },\n {\n \"code\": \"ORB_HTTP_EGRESS_ENTRY_INVALID\",\n \"category\": \"http\",\n \"description\": \"An egress allowlist entry is not of the form scheme://host[:port]\"\n },\n {\n \"code\": \"ORB_HTTP_EGRESS_UNDECLARED\",\n \"category\": \"http\",\n \"description\": \"An outbound request targets an origin that is not declared in the program egress list\"\n },\n {\n \"code\": \"ORB_HTTP_ORIGIN_NOT_STATIC\",\n \"category\": \"http\",\n \"description\": \"An http origin is not a string literal or a url-typed config knob, so egress cannot be checked\"\n },\n {\n \"code\": \"ORB_ID_AUTHORED_WITHOUT_LEDGER\",\n \"category\": \"id\",\n \"description\": \"An id is authored in source without a matching ledger entry, so it is replaced on load\"\n },\n {\n \"code\": \"ORB_ID_DUPLICATE_EVENT_ID\",\n \"category\": \"id\",\n \"description\": \"An event id is declared by more than one trait, but ids must be document-unique\"\n },\n {\n \"code\": \"ORB_ID_KIND_MISMATCH\",\n \"category\": \"id\",\n \"description\": \"An id of one kind is used in a position that requires an id of a different kind\"\n },\n {\n \"code\": \"ORB_ID_LEDGER_ORPHAN\",\n \"category\": \"id\",\n \"description\": \"An id ledger row is carried by no node in the schema and is stale\"\n },\n {\n \"code\": \"ORB_ID_NAME_MISMATCH\",\n \"category\": \"id\",\n \"description\": \"A name in the source disagrees with the current name the ledger records for the same id\"\n },\n {\n \"code\": \"ORB_ID_UNKNOWN_REF\",\n \"category\": \"id\",\n \"description\": \"An id reference matches no arena node or ledger entry\"\n },\n {\n \"code\": \"ORB_INBOUND_ANSWER_FOREIGN\",\n \"category\": \"inbound\",\n \"description\": \"A trait other than an inbound handler emits the handler's answer event, so the answer never reaches the caller\"\n },\n {\n \"code\": \"ORB_INBOUND_ANSWER_UNDECLARED\",\n \"category\": \"inbound\",\n \"description\": \"An inbound hook event answers with an event the trait does not declare in emits\"\n },\n {\n \"code\": \"ORB_INBOUND_DUPLICATE\",\n \"category\": \"inbound\",\n \"description\": \"An inbound hook has more than one handler\"\n },\n {\n \"code\": \"ORB_INBOUND_ENTRY_INVALID\",\n \"category\": \"inbound\",\n \"description\": \"An inbound entry is not a valid hook name\"\n },\n {\n \"code\": \"ORB_INBOUND_UNDECLARED\",\n \"category\": \"inbound\",\n \"description\": \"An event handles an inbound hook that the program's inbound block does not declare\"\n },\n {\n \"code\": \"ORB_INBOUND_VERIFY_INVALID\",\n \"category\": \"inbound\",\n \"description\": \"An inbound hook verifies a header against a credential, but the header is not a lower-case header name or the credential is not a credential name\"\n },\n {\n \"code\": \"ORB_INDEX_PATH_DUPLICATE\",\n \"category\": \"index\",\n \"description\": \"The same index path, with the same ordering, is declared more than once on an entity\"\n },\n {\n \"code\": \"ORB_INDEX_PATH_INVALID\",\n \"category\": \"entity\",\n \"description\": \"An index path names a field that the entity does not declare\"\n },\n {\n \"code\": \"ORB_JSON_ROUNDTRIP\",\n \"category\": \"lint\",\n \"description\": \"json/parse re-parses what json/stringify just serialized; a stringify→parse round trip launders a value's type past the checker (owner hard rule, CLAUDE.md). Narrow with `as`.\"\n },\n {\n \"code\": \"ORB_LINT_FINDING_CODE_UNDECLARED\",\n \"category\": \"lint\",\n \"description\": \"A lint rule names a finding code that its declared codes record does not carry.\"\n },\n {\n \"code\": \"ORB_LINT_INDEX_MISSING\",\n \"category\": \"lint\",\n \"description\": \"The lint input arrived without a shared program fact the rule reads (the structural index, sites, units, embeds or entities), so the rule cannot check the program\"\n },\n {\n \"code\": \"ORB_LINT_INPUT_UNREAD\",\n \"category\": \"lint\",\n \"description\": \"A lint input file could not be read or lowered, so the lint rules did not run\"\n },\n {\n \"code\": \"ORB_LINT_LANGUAGE_FACTS_UNREAD\",\n \"category\": \"lint\",\n \"description\": \"The installed language facts could not be read, so the lint rule could not check what it needs\"\n },\n {\n \"code\": \"ORB_LINT_OPERATOR_SHAPES_UNREAD\",\n \"category\": \"lint\",\n \"description\": \"The installed operator table could not be read or does not match the operator shape type, so a lint cannot run\"\n },\n {\n \"code\": \"ORB_LINT_RULE_COUNT_MISMATCH\",\n \"category\": \"lint\",\n \"description\": \"A lint engine's rules or programOnlyRules names differ from the rule names its routed rule traits answer LINT_FOUND with\"\n },\n {\n \"code\": \"ORB_LINT_RULE_FAILED\",\n \"category\": \"lint\",\n \"description\": \"A lint rule met an input its own preconditions exclude and could not check it\"\n },\n {\n \"code\": \"ORB_LINT_SERVICE_REGISTRY_UNREAD\",\n \"category\": \"lint\",\n \"description\": \"The installed services registry could not be read, so call-service services cannot be checked\"\n },\n {\n \"code\": \"ORB_LINT_UI_VOCAB_UNREAD\",\n \"category\": \"lint\",\n \"description\": \"The installed @almadar/core declares no readable UI vocabulary, so a UI lint check cannot run\"\n },\n {\n \"code\": \"ORB_LISTEN_REDUNDANT_EMBED_ROUTE\",\n \"category\": \"listen\",\n \"description\": \"A listens route is redundant because the embedded trait already receives that event\"\n },\n {\n \"code\": \"ORB_LISTEN_ROUTE_STARVES_REQUIRED_FIELD\",\n \"category\": \"trait_event\",\n \"description\": \"A listens route requires a payload field that the source event contract never produces\"\n },\n {\n \"code\": \"ORB_LISTEN_WILDCARD_UNKEYED\",\n \"category\": \"trait_event\",\n \"description\": \"A wildcard listens route hears every caller's event but its guard never reads the call key in the payload\"\n },\n {\n \"code\": \"ORB_MEM_ALIAS\",\n \"category\": \"mem\",\n \"description\": \"An exclusive borrow of a block while another borrow of it is live, or a borrow while an exclusive one is live\"\n },\n {\n \"code\": \"ORB_MEM_DOUBLE_FREE\",\n \"category\": \"mem\",\n \"description\": \"A handle is freed, dropped or released a second time on some path\"\n },\n {\n \"code\": \"ORB_MEM_LEAK\",\n \"category\": \"mem\",\n \"description\": \"An arena reaches a resting state on some path without being dropped\"\n },\n {\n \"code\": \"ORB_MEM_USE_AFTER_FREE\",\n \"category\": \"mem\",\n \"description\": \"A mem/ call takes a handle after it was freed, dropped or released on some path\"\n },\n {\n \"code\": \"ORB_NAV_TARGET_UNDECLARED\",\n \"category\": \"page\",\n \"description\": \"A navigation target stated as a literal path (a navigate effect, a navItems or link href, a navigatesTo) names no page the finished program declares\"\n },\n {\n \"code\": \"ORB_OAUTH_CLIENT_INVALID\",\n \"category\": \"oauth\",\n \"description\": \"An OAuth client block uses a key that is not a valid OAuth client key\"\n },\n {\n \"code\": \"ORB_OAUTH_OPTION_UNKNOWN\",\n \"category\": \"oauth\",\n \"description\": \"An oauth-authorize call passes an option that is not recognized\"\n },\n {\n \"code\": \"ORB_OAUTH_PROVIDER_UNKNOWN\",\n \"category\": \"oauth\",\n \"description\": \"The OAuth clients map is keyed by something other than a known provider tag\"\n },\n {\n \"code\": \"ORB_ON_DEVICE_EFFECT_ON_SERVER\",\n \"category\": \"browser\",\n \"description\": \"An on-device model effect runs in a background tick on the server, which has no on-device model\"\n },\n {\n \"code\": \"ORB_ON_DEVICE_SCHEMA_INVALID\",\n \"category\": \"browser\",\n \"description\": \"A browser prompt response schema is not valid JSON Schema text describing a JSON object\"\n },\n {\n \"code\": \"ORB_OP_INVALID_TIME_UNIT\",\n \"category\": \"operator\",\n \"description\": \"A time operator is given a unit that is not an accepted time unit\"\n },\n {\n \"code\": \"ORB_OS_EGRESS_SCHEME_UNUSED\",\n \"category\": \"os\",\n \"description\": \"An egress entry whose scheme (redis, rediss, postgres, postgresql) no operator or fetch uses since the TCP protocol-target grants were retired; its net-grant replacement is named\"\n },\n {\n \"code\": \"ORB_OS_GRANT_ENTRY_INVALID\",\n \"category\": \"os\",\n \"description\": \"A declared grant entry that can match nothing\"\n },\n {\n \"code\": \"ORB_OS_GRANT_MISSING\",\n \"category\": \"os\",\n \"description\": \"An os/ call that the grants of its orbital (app level plus its own) do not cover\"\n },\n {\n \"code\": \"ORB_OS_GRANT_UNUSED\",\n \"category\": \"os\",\n \"description\": \"A granted entry that no os/ call of the orbital (or of the program, at app level) uses; a warning\"\n },\n {\n \"code\": \"ORB_OS_TARGET_NOT_STATIC\",\n \"category\": \"os\",\n \"description\": \"An os/ call target that is computed, so its grant cannot be checked at build time\"\n },\n {\n \"code\": \"ORB_O_CONFIG_DEAD_KNOB\",\n \"category\": \"orbital\",\n \"description\": \"A declared app-level config knob is not forwarded by any trait config default, so it has no effect\"\n },\n {\n \"code\": \"ORB_O_CONFIG_UNKNOWN_KEY\",\n \"category\": \"orbital_ref\",\n \"description\": \"A call-site config key matches no config knob declared by the upstream orbital\"\n },\n {\n \"code\": \"ORB_O_DUPLICATE_NAME\",\n \"category\": \"orbital\",\n \"description\": \"Two or more orbitals in a program share the same name\"\n },\n {\n \"code\": \"ORB_O_DUPLICATE_USE_ALIAS\",\n \"category\": \"orbital\",\n \"description\": \"Two uses imports share the same alias\"\n },\n {\n \"code\": \"ORB_O_ENTITY_EXPECT_AMBIGUOUS\",\n \"category\": \"orbital_ref\",\n \"description\": \"An entity an imported orbital expects of a sibling is provided by several sibling imports and no entities entry binds it\"\n },\n {\n \"code\": \"ORB_O_ENTITY_PERSISTENCE_LOCKED\",\n \"category\": \"orbital\",\n \"description\": \"An entity persistence or collection override on an orbital reference has no effect because the primary entity locks it\"\n },\n {\n \"code\": \"ORB_O_ENTITY_TARGET_UNKNOWN\",\n \"category\": \"orbital_ref\",\n \"description\": \"An entities value names no entity the consumer schema declares\"\n },\n {\n \"code\": \"ORB_O_ENTITY_UNKNOWN_KEY\",\n \"category\": \"orbital_ref\",\n \"description\": \"An entities key names no entity in the upstream out-of-orbital closure\"\n },\n {\n \"code\": \"ORB_O_ENTITY_UNMAPPED\",\n \"category\": \"orbital_ref\",\n \"description\": \"A kept trait, relation or page references an out-of-orbital entity that entities {} never maps\"\n },\n {\n \"code\": \"ORB_O_EXTEND_FIELD_COLLISION\",\n \"category\": \"orbital_ref\",\n \"description\": \"An extend field collides with a field already declared on the upstream primary entity\"\n },\n {\n \"code\": \"ORB_O_EXTEND_FIELD_UNREAD\",\n \"category\": \"orbital\",\n \"description\": \"A field added by an extend block is never read, set, rendered or forwarded by a config knob\"\n },\n {\n \"code\": \"ORB_O_FIELD_RENAME_UNAPPLIED\",\n \"category\": \"orbital_ref\",\n \"description\": \"A fields rename left the pre-rename field name in a config default position the rewrite does not reach\"\n },\n {\n \"code\": \"ORB_O_MOCK_UNKNOWN_FIELD\",\n \"category\": \"orbital\",\n \"description\": \"A mock block names a field the entity materialized from the referenced orbital does not declare\"\n },\n {\n \"code\": \"ORB_O_OMIT_EMBEDDED_TRAIT\",\n \"category\": \"orbital\",\n \"description\": \"An orbital reference omits a trait that another kept trait embeds\"\n },\n {\n \"code\": \"ORB_O_PAGE_UNKNOWN_PATH\",\n \"category\": \"orbital_ref\",\n \"description\": \"A pages or mounts key names a page path that the upstream orbital does not declare\"\n },\n {\n \"code\": \"ORB_O_RETYPE_FIELD_CONFLICT\",\n \"category\": \"orbital\",\n \"description\": \"A field is both retyped and added by extend in the same orbital reference\"\n },\n {\n \"code\": \"ORB_O_RETYPE_UNKNOWN_FIELD\",\n \"category\": \"orbital\",\n \"description\": \"A retype block names a field the entity materialized from the referenced orbital does not declare\"\n },\n {\n \"code\": \"ORB_O_ROLE_TARGET_NOT_MEMBER\",\n \"category\": \"orbital_ref\",\n \"description\": \"A roles target is not a member of the consumer roster field vocabulary\"\n },\n {\n \"code\": \"ORB_O_ROLE_UNKNOWN_UPSTREAM\",\n \"category\": \"orbital_ref\",\n \"description\": \"A roles key names no value in any upstream identity field vocabulary\"\n },\n {\n \"code\": \"ORB_O_TRAITS_OMITTED_TRAIT\",\n \"category\": \"orbital\",\n \"description\": \"A traits override names a trait that omit or only drops from the imported orbital\"\n },\n {\n \"code\": \"ORB_O_TRAITS_UNKNOWN_TRAIT\",\n \"category\": \"orbital_ref\",\n \"description\": \"A traits key names a trait that the upstream orbital does not have\"\n },\n {\n \"code\": \"ORB_PAGE_AMBIGUOUS_CONTENT_OWNER\",\n \"category\": \"page\",\n \"description\": \"Several traits each render a content body into the main slot and none composes the others, so the page has no single content owner\"\n },\n {\n \"code\": \"ORB_PAGE_CONTROL_OUTSIDE_SHELL\",\n \"category\": \"page\",\n \"description\": \"A trait paints a control into the main slot of a page whose shell shows another trait as its content, and nothing there embeds it\"\n },\n {\n \"code\": \"ORB_PAGE_FACTS_FIELD_INVALID\",\n \"category\": \"page\",\n \"description\": \"A browser/page-facts effect declares no facts\"\n },\n {\n \"code\": \"ORB_PAGE_NOT_FOUND_DUPLICATE\",\n \"category\": \"page\",\n \"description\": \"A program declares more than one [notFound] page.\"\n },\n {\n \"code\": \"ORB_PAGE_NOT_FOUND_MISSING\",\n \"category\": \"page\",\n \"description\": \"A program with route pages declares no [notFound] page.\"\n },\n {\n \"code\": \"ORB_PAGE_SECOND_CONTENT_BODY\",\n \"category\": \"page\",\n \"description\": \"More than one trait on a page renders a content body into the main slot\"\n },\n {\n \"code\": \"ORB_PAGE_UNREACHABLE\",\n \"category\": \"page\",\n \"description\": \"A page is declared but appears in no link, navItems entry or navigate effect\"\n },\n {\n \"code\": \"ORB_PERSIST_BATCH_BAD_OP\",\n \"category\": \"persist\",\n \"description\": \"A persist batch contains an operation that is not valid in a batch\"\n },\n {\n \"code\": \"ORB_PERSIST_BATCH_MIXED_PLACEMENT\",\n \"category\": \"persist\",\n \"description\": \"A persist batch writes both browser-stored and server-stored entities in one effect, which no single executor can hold\"\n },\n {\n \"code\": \"ORB_PERSIST_BATCH_OPS_NOT_ARRAY\",\n \"category\": \"persist\",\n \"description\": \"A persist batch operations expression is missing or not array-typed\"\n },\n {\n \"code\": \"ORB_PERSIST_CREATE_LITERAL_ID\",\n \"category\": \"persist\",\n \"description\": \"A persist create names a literal id, so a second run fails with a duplicate id\"\n },\n {\n \"code\": \"ORB_PERSIST_CREATE_MISSING_POLICY_FIELD\",\n \"category\": \"persist\",\n \"description\": \"A persist create data literal omits a field its entity's create access policy compares, so the row can never satisfy the policy\"\n },\n {\n \"code\": \"ORB_PERSIST_ID_NOT_A_PATH\",\n \"category\": \"persist\",\n \"description\": \"A persist effect names its row id with an expression instead of a binding path or literal id, so no row key resolves\"\n },\n {\n \"code\": \"ORB_PERSIST_WHERE_NOT_A_PREDICATE\",\n \"category\": \"persist\",\n \"description\": \"A persist where clause is not a valid row predicate\"\n },\n {\n \"code\": \"ORB_PLACEMENT_ORBITAL_DUPLICATE\",\n \"category\": \"placement\",\n \"description\": \"An orbital is placed more than once in the deployment\"\n },\n {\n \"code\": \"ORB_PLACEMENT_ORBITAL_UNKNOWN\",\n \"category\": \"placement\",\n \"description\": \"A deployment unit lists an orbital name that is not an orbital of the program\"\n },\n {\n \"code\": \"ORB_PLACEMENT_ORBITAL_UNPLACED\",\n \"category\": \"placement\",\n \"description\": \"A deployment is declared but an orbital belongs to none of its units\"\n },\n {\n \"code\": \"ORB_PLACEMENT_UNIT_EMPTY\",\n \"category\": \"placement\",\n \"description\": \"A deployment unit lists no orbital\"\n },\n {\n \"code\": \"ORB_P_AUTH_NO_SIGN_IN\",\n \"category\": \"page\",\n \"description\": \"A page requires authenticated access but the app declares no signIn route\"\n },\n {\n \"code\": \"ORB_P_DUPLICATE_PATH\",\n \"category\": \"page\",\n \"description\": \"Two pages declare the same path after normalization\"\n },\n {\n \"code\": \"ORB_P_EMPTY_TRAITS\",\n \"category\": \"page\",\n \"description\": \"A page declares an empty traits array\"\n },\n {\n \"code\": \"ORB_P_HOST_RESERVED_ROUTE\",\n \"category\": \"page\",\n \"description\": \"A page is declared on the host's reserved sign-in route\"\n },\n {\n \"code\": \"ORB_P_INDEX_PARAM_ROUTE\",\n \"category\": \"page\",\n \"description\": \"A parameter-route page is marked indexing index although its concrete URLs are not declared\"\n },\n {\n \"code\": \"ORB_P_INDEX_REQUIRES_PUBLIC\",\n \"category\": \"page\",\n \"description\": \"A page declares indexing: index but lacks the public access it requires\"\n },\n {\n \"code\": \"ORB_P_INVALID_PATH\",\n \"category\": \"page\",\n \"description\": \"A page or navigate path does not start with a slash\"\n },\n {\n \"code\": \"ORB_P_INVALID_TRAIT_REF\",\n \"category\": \"page\",\n \"description\": \"A page's inline trait reference has no name\"\n },\n {\n \"code\": \"ORB_P_INVALID_VIEW_TYPE\",\n \"category\": \"page\",\n \"description\": \"A page declares a view type that is not a valid view type\"\n },\n {\n \"code\": \"ORB_P_MISSING_NAME\",\n \"category\": \"page\",\n \"description\": \"A page does not declare a name\"\n },\n {\n \"code\": \"ORB_P_MISSING_PATH\",\n \"category\": \"page\",\n \"description\": \"A page is missing its required path\"\n },\n {\n \"code\": \"ORB_P_MISSING_TRAITS\",\n \"category\": \"page\",\n \"description\": \"A page has no traits array for trait-driven UI\"\n },\n {\n \"code\": \"ORB_P_SIGN_IN_UNKNOWN_ROUTE\",\n \"category\": \"page\",\n \"description\": \"The app's signIn route names a path that is no page of the app\"\n },\n {\n \"code\": \"ORB_P_TRANSLATION_DUPLICATE_LOCALE\",\n \"category\": \"page\",\n \"description\": \"A translation group holds more than one page in the same locale\"\n },\n {\n \"code\": \"ORB_RANDOM_BYTES_COUNT\",\n \"category\": \"random\",\n \"description\": \"A random-bytes count argument is outside the allowed integer range\"\n },\n {\n \"code\": \"ORB_RENDER_ACTION_LIFECYCLE_EVENT\",\n \"category\": \"render_ui\",\n \"description\": \"A rendered pattern prop targets a lifecycle event that the bus never delivers\"\n },\n {\n \"code\": \"ORB_RENDER_GROUPBY_ENUM_COLUMN_GAP\",\n \"category\": \"render_ui\",\n \"description\": \"A groupBy column set omits enum values of the field, so rows with those values match no column and disappear\"\n },\n {\n \"code\": \"ORB_RENDER_ORBITAL_VALUE_EMBEDDED\",\n \"category\": \"render_ui\",\n \"description\": \"A render-ui embeds an orbital value, but only trait values can be rendered\"\n },\n {\n \"code\": \"ORB_RENDER_UNBOUND_TRAIT_KNOB_EMBEDDED\",\n \"category\": \"render_ui\",\n \"description\": \"A render-ui embeds a trait-typed value that may be unbound without a guard, so it renders nothing\"\n },\n {\n \"code\": \"ORB_RUI_CHILD_NOT_DRAWABLE\",\n \"category\": \"render_ui\",\n \"description\": \"A non-drawable child is composed under a canvas draw-host, which paints only neutral drawable descriptors\"\n },\n {\n \"code\": \"ORB_RUI_ELEMENT_SHAPE_MISMATCH\",\n \"category\": \"render_ui\",\n \"description\": \"An element of a pattern prop is missing a field required by the pattern's element shape\"\n },\n {\n \"code\": \"ORB_RUI_FORM_FIELD_INTRINSIC\",\n \"category\": \"render_ui\",\n \"description\": \"A form pattern offers an input for an intrinsic entity field, which is never persisted so the input is discarded\"\n },\n {\n \"code\": \"ORB_RUI_INVALID_FIELD_PATH\",\n \"category\": \"render_ui\",\n \"description\": \"A nested field path references an invalid relation or field\"\n },\n {\n \"code\": \"ORB_RUI_INVALID_ITEM_ACTION\",\n \"category\": \"render_ui\",\n \"description\": \"An itemAction configuration on a rendered pattern is invalid\"\n },\n {\n \"code\": \"ORB_RUI_INVALID_PATTERN\",\n \"category\": \"render_ui\",\n \"description\": \"A render-ui pattern type is not in the pattern registry\"\n },\n {\n \"code\": \"ORB_RUI_INVALID_PROP\",\n \"category\": \"render_ui\",\n \"description\": \"A render-ui pattern is given a prop that the pattern does not define\"\n },\n {\n \"code\": \"ORB_RUI_INVALID_SLOT\",\n \"category\": \"render_ui\",\n \"description\": \"A render-ui effect targets an invalid slot\"\n },\n {\n \"code\": \"ORB_RUI_MISSING_ACTION\",\n \"category\": \"render_ui\",\n \"description\": \"A render-ui pattern that needs an interaction target has no action, onClick, event or href\"\n },\n {\n \"code\": \"ORB_RUI_MISSING_PATTERN_TYPE\",\n \"category\": \"render_ui\",\n \"description\": \"A render-ui pattern has no type property\"\n },\n {\n \"code\": \"ORB_RUI_MISSING_REQUIRED_PROP\",\n \"category\": \"render_ui\",\n \"description\": \"A render-ui pattern is missing a prop that the pattern requires\"\n },\n {\n \"code\": \"ORB_RUI_PROP_TYPE_MISMATCH\",\n \"category\": \"render_ui\",\n \"description\": \"A render-ui pattern prop has a value that is not one of its allowed values\"\n },\n {\n \"code\": \"ORB_RUI_RENDERABLE_IN_GENERIC_FIELD\",\n \"category\": \"render_ui\",\n \"description\": \"A render-ui pattern literal is passed to a field not typed node, hiding renderable content from render-ui checks\"\n },\n {\n \"code\": \"ORB_SET_COLUMN_WITHOUT_ROW\",\n \"category\": \"entity_mutation\",\n \"description\": \"A set writes an entity column with no row in scope and no persist create or update that could land it\"\n },\n {\n \"code\": \"ORB_SHARED_ENTITY_FIELD_CONFLICT\",\n \"category\": \"entity_mutation\",\n \"description\": \"A field of a shared entity is written by more than one trait\"\n },\n {\n \"code\": \"ORB_SHARED_ENTITY_RENDER_AUTHORITY\",\n \"category\": \"entity_mutation\",\n \"description\": \"A shared entity is render-ui-read by more than one trait, but only one render authority is allowed per entity and slot\"\n },\n {\n \"code\": \"ORB_SLOT_CONTENTION\",\n \"category\": \"slot\",\n \"description\": \"Multiple traits on a page render into the same slot\"\n },\n {\n \"code\": \"ORB_SLOT_CONTENTION_RUNTIME\",\n \"category\": \"slot\",\n \"description\": \"Several traits render to the same slot in the same state, so they contend for it\"\n },\n {\n \"code\": \"ORB_SLOT_CONTENTION_TICK\",\n \"category\": \"slot\",\n \"description\": \"Several traits on a page render into the same slot from ticks, so their output contends\"\n },\n {\n \"code\": \"ORB_SLOT_INVALID_NESTING\",\n \"category\": \"slot\",\n \"description\": \"A slot is nested in an invalid way\"\n },\n {\n \"code\": \"ORB_SLOT_MAIN_NOT_COVERED\",\n \"category\": \"slot\",\n \"description\": \"No trait on a page renders anything into the main slot\"\n },\n {\n \"code\": \"ORB_STORE_DRIVER_CONTRACT\",\n \"category\": \"store\",\n \"description\": \"A store driver has no trait handling one or more verbs required by the row-store driver contract\"\n },\n {\n \"code\": \"ORB_STORE_DRIVER_NOT_CONDITIONAL\",\n \"category\": \"store\",\n \"description\": \"A conditional persist op is bound to a store driver that cannot execute conditional writes\"\n },\n {\n \"code\": \"ORB_STORE_ON_NON_PERSISTENT\",\n \"category\": \"store\",\n \"description\": \"An entity binds a store but its rows live in no store\"\n },\n {\n \"code\": \"ORB_STORE_UNKNOWN_ORBITAL\",\n \"category\": \"store\",\n \"description\": \"A store binding names an orbital that is not part of the program\"\n },\n {\n \"code\": \"ORB_STORE_VERB_OUTSIDE_SEAM\",\n \"category\": \"store\",\n \"description\": \"A trait emits a row-store verb directly, but a store driver may be asked only by the store seam\"\n },\n {\n \"code\": \"ORB_S_ACCESS_POLICY_INVALID_BINDING\",\n \"category\": \"schema\",\n \"description\": \"An access directive uses a binding other than the ones legal there\"\n },\n {\n \"code\": \"ORB_S_ACCESS_POLICY_REQUIRES_IDENTITY\",\n \"category\": \"schema\",\n \"description\": \"An access directive reads @user but the program declares no identity entity\"\n },\n {\n \"code\": \"ORB_S_ACCESS_POLICY_UNKNOWN_ENTITY_FIELD\",\n \"category\": \"schema\",\n \"description\": \"An access policy references a name that is not a field of its entity, so it resolves to null and denies everyone\"\n },\n {\n \"code\": \"ORB_S_COLLECTION_POLICY_CONFLICT\",\n \"category\": \"schema\",\n \"description\": \"Entities bound to the same collection declare different access directives\"\n },\n {\n \"code\": \"ORB_S_EMPTY_VERSION\",\n \"category\": \"schema\",\n \"description\": \"The schema version is empty\"\n },\n {\n \"code\": \"ORB_S_EXPECTATION_FIELD_UNDECLARED\",\n \"category\": \"schema\",\n \"description\": \"An effect persists a field that the orbital's expects entity shape does not declare\"\n },\n {\n \"code\": \"ORB_S_EXPECTATION_PROVIDER_MISMATCH\",\n \"category\": \"schema\",\n \"description\": \"An expectation requires a field to be marked as a key but the providing entity declares it without that mark\"\n },\n {\n \"code\": \"ORB_S_EXPECTATION_UNSATISFIED\",\n \"category\": \"schema\",\n \"description\": \"An orbital expects an entity, trait, event, or config default that nothing in the program provides\"\n },\n {\n \"code\": \"ORB_S_EXPECTED_FIELD_NOT_PROVIDED\",\n \"category\": \"schema\",\n \"description\": \"A rebound entity does not provide a field that the trait expects it to have\"\n },\n {\n \"code\": \"ORB_S_EXPECTED_FIELD_TYPE_MISMATCH\",\n \"category\": \"schema\",\n \"description\": \"The provider has the expected field or knob but with an incompatible type\"\n },\n {\n \"code\": \"ORB_S_IDENTITY_NOT_UNIQUE\",\n \"category\": \"schema\",\n \"description\": \"More than one entity is tagged identity, making every @user field reference ambiguous\"\n },\n {\n \"code\": \"ORB_S_INVARIANT_UNPROVED\",\n \"category\": \"spec\",\n \"description\": \"A spec proposition the prover cannot decide, so the program is not shown to keep it\"\n },\n {\n \"code\": \"ORB_S_INVARIANT_VIOLATED\",\n \"category\": \"spec\",\n \"description\": \"A spec proposition (invariant, holds, ensures) is broken by a write, with a counterexample the evaluator confirms\"\n },\n {\n \"code\": \"ORB_S_MISSING_NAME\",\n \"category\": \"schema\",\n \"description\": \"The schema does not declare a name\"\n },\n {\n \"code\": \"ORB_S_NO_ORBITALS\",\n \"category\": \"schema\",\n \"description\": \"The schema declares no orbitals\"\n },\n {\n \"code\": \"ORB_S_OWNER_FIELD_NOT_IDENTITY_TYPED\",\n \"category\": \"schema\",\n \"description\": \"An access directive compares a field to @user.id but the field is not a relation to the identity entity\"\n },\n {\n \"code\": \"ORB_S_ROLE_LITERAL_NOT_MEMBER\",\n \"category\": \"schema\",\n \"description\": \"A literal compared against an @user field with a closed vocabulary is not a member of that vocabulary, so the branch can never be taken\"\n },\n {\n \"code\": \"ORB_S_SHARED_WITHOUT_PERSISTENCE_MODE\",\n \"category\": \"schema\",\n \"description\": \"A shared entity declares no persistence mode, and none may be inferred\"\n },\n {\n \"code\": \"ORB_S_UNKNOWN_IDENTITY_FIELD\",\n \"category\": \"schema\",\n \"description\": \"A read of a field of the signed-in user names a field the declared identity entity does not have\"\n },\n {\n \"code\": \"ORB_TAB_EFFECT_ON_SERVER\",\n \"category\": \"tab\",\n \"description\": \"A browser tab effect is used in a transition that runs on the server, which holds no tabs\"\n },\n {\n \"code\": \"ORB_TAB_REQUEST_INVALID\",\n \"category\": \"browser\",\n \"description\": \"A browser/tab request is not an object of the operation's closed keys or has refused literal values\"\n },\n {\n \"code\": \"ORB_THEME_PIN_CONTRADICTS_APP\",\n \"category\": \"theme\",\n \"description\": \"An orbital pins a theme that differs from the theme the app declares at app level\"\n },\n {\n \"code\": \"ORB_THEME_UNDECLARED\",\n \"category\": \"theme\",\n \"description\": \"A frame is shown in a literal theme that the program does not declare, so no stylesheet ships for it\"\n },\n {\n \"code\": \"ORB_TICK_ASYNC_EFFECT\",\n \"category\": \"tick\",\n \"description\": \"A tick calls a server-async operator, which ticks cannot run\"\n },\n {\n \"code\": \"ORB_TICK_REQUIRES_RUNTIME\",\n \"category\": \"trait\",\n \"description\": \"A non-cron tick mutates a persistent entity, which should usually be runtime\"\n },\n {\n \"code\": \"ORB_T_CLIENT_TICK_NOT_LOCAL\",\n \"category\": \"trait\",\n \"description\": \"A trait writes a frame entity ticked on the client but declares no dispatch mode, so a server step overwrites the live frame\"\n },\n {\n \"code\": \"ORB_T_CLIENT_TICK_SERVER_EFFECT\",\n \"category\": \"trait\",\n \"description\": \"A tick that runs in the browser has effects that reach the server, and nothing replays a tick there\"\n },\n {\n \"code\": \"ORB_T_CONFIG_MISSING_REQUIRED_KEY\",\n \"category\": \"trait\",\n \"description\": \"A trait reference does not supply a config knob that the referenced trait declares as required\"\n },\n {\n \"code\": \"ORB_T_CONFIG_OBJECT_ARRAY_FORBIDDEN\",\n \"category\": \"trait\",\n \"description\": \"A config field uses a banned bare object or array type instead of a named struct alias\"\n },\n {\n \"code\": \"ORB_T_CONFIG_TIER_INVALID\",\n \"category\": \"trait\",\n \"description\": \"A config field declares a tier value outside domain, policy, infra, presentation and internal\"\n },\n {\n \"code\": \"ORB_T_CONFIG_UNKNOWN_CALL_SITE_KEY\",\n \"category\": \"trait\",\n \"description\": \"A call-site config key matches no config knob declared on the referenced trait\"\n },\n {\n \"code\": \"ORB_T_DUPLICATE_NAME\",\n \"category\": \"trait\",\n \"description\": \"The same trait name is defined in more than one orbital\"\n },\n {\n \"code\": \"ORB_T_DUPLICATE_STATE\",\n \"category\": \"trait\",\n \"description\": \"A trait declares the same state name more than once\"\n },\n {\n \"code\": \"ORB_T_DUPLICATE_TRANSITION\",\n \"category\": \"trait\",\n \"description\": \"Two transitions share the same source state and event without guards\"\n },\n {\n \"code\": \"ORB_T_EMPTY_EVENT_NAME\",\n \"category\": \"trait\",\n \"description\": \"An event name is empty\"\n },\n {\n \"code\": \"ORB_T_ENDPOINT_TRAIT_RENDERS\",\n \"category\": \"trait\",\n \"description\": \"A trait mounted only on protocol endpoints renders UI, which endpoints cannot show\"\n },\n {\n \"code\": \"ORB_T_ENTITY_NAME_SHADOWS_TRAIT_UNION\",\n \"category\": \"trait\",\n \"description\": \"An entity name collides with a trait's generated state union type\"\n },\n {\n \"code\": \"ORB_T_ENTITY_NOT_REBINDABLE\",\n \"category\": \"trait\",\n \"description\": \"A trait is bound to an entity it cannot be rebound to\"\n },\n {\n \"code\": \"ORB_T_EVENT_RENAME_UNKNOWN_KEY\",\n \"category\": \"trait\",\n \"description\": \"An events rename key names no event declared by the referenced trait\"\n },\n {\n \"code\": \"ORB_T_EVT_EXTERNAL_MISSING_PAYLOAD\",\n \"category\": \"trait\",\n \"description\": \"An external event does not declare a typed payload\"\n },\n {\n \"code\": \"ORB_T_EVT_INVALID_NAME\",\n \"category\": \"trait\",\n \"description\": \"An event name is not a valid UPPER_SNAKE_CASE identifier\"\n },\n {\n \"code\": \"ORB_T_EVT_UNDECLARED\",\n \"category\": \"trait\",\n \"description\": \"An event is emitted but not declared in the trait's emits array\"\n },\n {\n \"code\": \"ORB_T_EXTERNAL_INPUT_NOT_RESTING\",\n \"category\": \"trait\",\n \"description\": \"An external input is not accepted from the trait's initial state\"\n },\n {\n \"code\": \"ORB_T_GENERIC_TYPE_DEPRECATED\",\n \"category\": \"trait\",\n \"description\": \"A declaration uses a generic type such as bare json, object without properties, or any, which the language no longer allows\"\n },\n {\n \"code\": \"ORB_T_INIT_MISSING_FETCH\",\n \"category\": \"trait\",\n \"description\": \"No trait fetches a persistent entity on INIT, so interaction traits read data nothing loads\"\n },\n {\n \"code\": \"ORB_T_INVALID_EVENT_DEFAULT\",\n \"category\": \"trait\",\n \"description\": \"A config field typed event holds a value that is not a valid event name or member of the trait's event set\"\n },\n {\n \"code\": \"ORB_T_INVALID_FORMAT\",\n \"category\": \"trait\",\n \"description\": \"A trait reference has neither a ref nor a name property\"\n },\n {\n \"code\": \"ORB_T_INVALID_PATTERN_DEFAULT\",\n \"category\": \"trait\",\n \"description\": \"A pattern-typed config knob has a default that is not a known pattern type\"\n },\n {\n \"code\": \"ORB_T_INVALID_SLOT_DEFAULT\",\n \"category\": \"trait\",\n \"description\": \"A slot-typed config field has a default that is not a valid slot\"\n },\n {\n \"code\": \"ORB_T_INVALID_TRANSITION\",\n \"category\": \"trait\",\n \"description\": \"A transition references a source or target state that does not exist\"\n },\n {\n \"code\": \"ORB_T_LOCAL_ON_NON_SHARED_PERSISTENT\",\n \"category\": \"trait\",\n \"description\": \"A client-dispatch trait is linked to an entity that is neither shared nor client-resident, hiding server-gated writes behind optimism\"\n },\n {\n \"code\": \"ORB_T_LOCAL_TRAIT_TOUCHES_SERVER\",\n \"category\": \"trait\",\n \"description\": \"A client trait transition guards on or touches server-only state\"\n },\n {\n \"code\": \"ORB_T_MISSING_INIT_TRANSITION\",\n \"category\": \"trait\",\n \"description\": \"A route trait has no INIT transition on its initial state\"\n },\n {\n \"code\": \"ORB_T_MULTIPLE_INITIAL_STATES\",\n \"category\": \"trait\",\n \"description\": \"A trait state machine declares more than one initial state\"\n },\n {\n \"code\": \"ORB_T_NO_INITIAL_STATE\",\n \"category\": \"trait\",\n \"description\": \"A state machine declares no states and so has no initial state\"\n },\n {\n \"code\": \"ORB_T_REBIND_MISSING_FIELDS\",\n \"category\": \"trait\",\n \"description\": \"A trait is rebound to an entity that lacks fields the trait requires\"\n },\n {\n \"code\": \"ORB_T_REBIND_TARGET_UNRESOLVED\",\n \"category\": \"trait\",\n \"description\": \"A trait rebind target cannot be resolved\"\n },\n {\n \"code\": \"ORB_T_SECRET_DEFAULT_NOT_STRING\",\n \"category\": \"trait\",\n \"description\": \"A config field typed secret does not default to a string credential reference\"\n },\n {\n \"code\": \"ORB_T_STATE_UNREACHABLE\",\n \"category\": \"trait\",\n \"description\": \"A state is unreachable from the initial state through any transition path\"\n },\n {\n \"code\": \"ORB_T_TRAIT_ON_ROUTE_AND_ENDPOINT\",\n \"category\": \"trait\",\n \"description\": \"A trait is mounted on both a route page and a protocol endpoint\"\n },\n {\n \"code\": \"ORB_T_TRAIT_UNMOUNTED\",\n \"category\": \"trait\",\n \"description\": \"A trait owns a state machine but is listed on no page and reached by no embed\"\n },\n {\n \"code\": \"ORB_T_UNDEFINED_EVENT\",\n \"category\": \"trait\",\n \"description\": \"A transition uses an event that is not defined in the trait's events array\"\n },\n {\n \"code\": \"ORB_T_UNDEFINED_TRAIT\",\n \"category\": \"trait\",\n \"description\": \"A trait reference does not give a trait name\"\n },\n {\n \"code\": \"ORB_T_UNRESOLVED_TYPE_PARAM\",\n \"category\": \"trait\",\n \"description\": \"A declaration uses a type variable that no trait parameter binds\"\n },\n {\n \"code\": \"ORB_UI_ICON_EMPTY\",\n \"category\": \"icon\",\n \"description\": \"An icon name is empty\"\n },\n {\n \"code\": \"ORB_UI_ICON_INVALID_FORMAT\",\n \"category\": \"icon\",\n \"description\": \"An icon name has an invalid format\"\n },\n {\n \"code\": \"ORB_UI_ICON_NOT_FOUND\",\n \"category\": \"icon\",\n \"description\": \"An icon name does not exist in the icon set\"\n },\n {\n \"code\": \"ORB_U_CONFIG_UNKNOWN_KEY\",\n \"category\": \"uses\",\n \"description\": \"A uses config override names a knob the imported behavior app-level config never declared\"\n },\n {\n \"code\": \"ORB_W_LOOP_INVARIANT_PARSE\",\n \"category\": \"lint\",\n \"description\": \"A parse inside a lambda re-parses the same value for every element and should be bound once outside\"\n },\n {\n \"code\": \"ORB_X_CIRCULAR_DEPENDENCY\",\n \"category\": \"cross\",\n \"description\": \"Traits form a circular event dependency\"\n },\n {\n \"code\": \"ORB_X_CROSS_EMITTER_DECLARED_PAYLOAD_MISMATCH\",\n \"category\": \"cross\",\n \"description\": \"An event declared by several emitters has conflicting payload fields across them\"\n },\n {\n \"code\": \"ORB_X_DUPLICATE_ENTITY\",\n \"category\": \"cross\",\n \"description\": \"The same entity name is defined in more than one orbital\"\n },\n {\n \"code\": \"ORB_X_DUPLICATE_TRAIT_ID\",\n \"category\": \"cross\",\n \"description\": \"Two or more traits carry the same trait id, so listens match each other's emits\"\n },\n {\n \"code\": \"ORB_X_ENUM_VALUE_NOT_MEMBER\",\n \"category\": \"cross\",\n \"description\": \"A set effect assigns a string literal that is not a declared member of the target field's enum\"\n },\n {\n \"code\": \"ORB_X_FILTER_FIELD_NEVER_WRITTEN\",\n \"category\": \"cross\",\n \"description\": \"A fetch filters on a field that no persist create or update of that entity supplies, so it always returns empty\"\n },\n {\n \"code\": \"ORB_X_LISTEN_PER_ENTITY\",\n \"category\": \"trait_event\",\n \"description\": \"A trait that listens per a key does not link a [runtime] entity declaring an id : string field\"\n },\n {\n \"code\": \"ORB_X_LISTEN_PER_ROUTED_PAGE\",\n \"category\": \"trait_event\",\n \"description\": \"A trait that listens per a key is placed on a route page\"\n },\n {\n \"code\": \"ORB_X_LISTEN_SOURCE_NEVER_PRODUCES\",\n \"category\": \"cross\",\n \"description\": \"A listens route names a source whose emits contract never produces the listened event\"\n },\n {\n \"code\": \"ORB_X_LISTEN_SOURCE_UNRESOLVED\",\n \"category\": \"cross\",\n \"description\": \"A listen entry references a source trait event that the source does not declare\"\n },\n {\n \"code\": \"ORB_X_LISTEN_TRIGGER_UNMATCHED\",\n \"category\": \"cross\",\n \"description\": \"A listens entry triggers an event that no transition in the same trait reacts to\"\n },\n {\n \"code\": \"ORB_X_LLM_WIRE_UNROUTED\",\n \"category\": \"cross\",\n \"description\": \"A composed std-llm trait can emit a wire event that no trait in the program listens to\"\n },\n {\n \"code\": \"ORB_X_MISSING_ORBITAL_NAME\",\n \"category\": \"cross\",\n \"description\": \"An orbital does not declare a name\"\n },\n {\n \"code\": \"ORB_X_ORPHAN_LISTENER\",\n \"category\": \"cross\",\n \"description\": \"A trait listens for an event that no trait emits\"\n },\n {\n \"code\": \"ORB_X_PARALLEL_LAMBDA_IMPURE\",\n \"category\": \"parallel\",\n \"description\": \"The lambda of array/pmap or array/preduce is not a literal fn or is not provably pure\"\n },\n {\n \"code\": \"ORB_X_PAYLOAD_FIELD_NAME\",\n \"category\": \"cross\",\n \"description\": \"A payload field name is not a valid TypeScript identifier\"\n },\n {\n \"code\": \"ORB_X_PAYLOAD_MISMATCH\",\n \"category\": \"cross\",\n \"description\": \"An external emit is missing a payload field required by the event's declaration\"\n },\n {\n \"code\": \"ORB_X_RENDER_UI_EVENT_LITERAL_STALE\",\n \"category\": \"cross\",\n \"description\": \"A render-ui prop references an event literal that no longer matches a declared event\"\n },\n {\n \"code\": \"ORB_X_ROW_LITERAL_FIELD_TYPE_MISMATCH\",\n \"category\": \"effect\",\n \"description\": \"A record literal written into an entity carries a value whose type the declared field does not admit.\"\n },\n {\n \"code\": \"ORB_X_ROW_LITERAL_MISSING_REQUIRED\",\n \"category\": \"effect\",\n \"description\": \"A `persist create` data literal omits a column the entity requires (no default, not framework-stamped).\"\n },\n {\n \"code\": \"ORB_X_ROW_LITERAL_UNKNOWN_FIELD\",\n \"category\": \"effect\",\n \"description\": \"A record literal written into an entity (a `persist` data literal, or a `set` into a relation field) names a key the entity does not declare.\"\n },\n {\n \"code\": \"ORB_X_UNKNOWN_THEME\",\n \"category\": \"cross\",\n \"description\": \"A theme reference is neither a built-in theme key nor an orbital-declared inline theme\"\n },\n {\n \"code\": \"ORB_X_UNRESOLVED_RELATION_TARGET\",\n \"category\": \"cross\",\n \"description\": \"A relation field points at an entity that is not declared in the schema\"\n },\n {\n \"code\": \"ORB_X_UNTYPED_ARRAY\",\n \"category\": \"cross\",\n \"description\": \"An array field declares no element type\"\n },\n {\n \"code\": \"ORB_X_UNUSED_EMISSION\",\n \"category\": \"cross\",\n \"description\": \"A trait emits an event that no trait listens for\"\n },\n {\n \"code\": \"SEXPR_INVALID_BINDING\",\n \"category\": \"sexpr\",\n \"description\": \"An s-expression contains an invalid binding\"\n },\n {\n \"code\": \"SEXPR_INVALID_OPERATOR\",\n \"category\": \"sexpr\",\n \"description\": \"An S-expression uses an operator that is not in the operator registry\"\n },\n {\n \"code\": \"SEXPR_UNKNOWN_ENTITY\",\n \"category\": \"sexpr\",\n \"description\": \"An entity named in a binding may not exist in the program\"\n },\n {\n \"code\": \"inbound-hook-duplicate\",\n \"category\": \"lint\",\n \"description\": \"Two cli hooks declare the same inbound name\"\n },\n {\n \"code\": \"shared-type-drift\",\n \"category\": \"lint\",\n \"description\": \"A type shared between behaviors has drifted from its canonical declaration\"\n },\n {\n \"code\": \"unread\",\n \"category\": \"lint\",\n \"description\": \"The file the rule reads could not be read or listed\"\n }\n]\n","/**\n * Validation error types — the shape emitted by every\n * `.orb` / `.lolo` validator pass.\n *\n * `ValidationError` is the wire shape: `{ code, path, message, suggestion? }`.\n * `code` is `ValidationErrorCode`, which is an OPEN `string` to let the\n * Rust validator emit new codes without an `@almadar/core` rev. The\n * `KNOWN_VALIDATION_ERROR_CODES` const documents the codes currently\n * emitted by the validator + lolo lower pipeline (extracted from\n * `orbital-rust/crates/orbital-compiler/src/phases/validation/` +\n * `orbital-rust/crates/orbital-lolo/src/`).\n *\n * Consumers that want to narrow a code to the closed known set use\n * `KnownValidationErrorCode`:\n *\n * ```ts\n * if (err.code in KNOWN_VALIDATION_ERROR_CODES) {\n * // err.code is now narrowable to KnownValidationErrorCode for\n * // exhaustive switch handling.\n * }\n * ```\n *\n * @packageDocumentation\n */\n\nimport validationCodesJson from '../generated/language/validation-codes.json' with { type: 'json' };\n\ninterface ValidationCodeEntry {\n code: string;\n category: string;\n description: string;\n}\n\nconst validationCodes: readonly ValidationCodeEntry[] = validationCodesJson;\n\n/**\n * One validation diagnostic emitted by the validator / lolo lower pipeline.\n *\n * - `code`: machine-readable identifier (see `KNOWN_VALIDATION_ERROR_CODES`).\n * - `path`: JSON pointer-like path into the failing schema location,\n * e.g. `'orbitals[0].traits[2].stateMachine.transitions[1].effects[0]'`.\n * - `message`: human-readable description of the failure.\n * - `suggestion`: optional hint the validator may add to help the\n * author / LLM fix the issue.\n */\nexport interface ValidationError {\n code: ValidationErrorCode;\n path: string;\n message: string;\n suggestion?: string;\n}\n\n/**\n * Validation error code — open `string` for forward-compat with the\n * Rust validator's evolving code set. Narrow to the closed known set\n * via `KnownValidationErrorCode` when exhaustive handling is needed.\n */\nexport type ValidationErrorCode = string;\n\nconst ORBITAL_PATH_PREFIX = /^orbitals\\[(\\d+)(?: \\([^\\]]*\\))?\\]/;\n\n/**\n * The index of the orbital a validation error belongs to, read from the\n * validator's declared path shape `orbitals[<index> (<name>)]…`, split into\n * segments or not (`['orbitals[<index> (<name>)]', …]`, `['orbitals', <index>, …]`);\n * null for a schema-level (or missing) path.\n */\nexport function orbitalIndexOfValidationPath(path: string | ReadonlyArray<string | number> | undefined): number | null {\n if (Array.isArray(path)) {\n if (path[0] === 'orbitals') return typeof path[1] === 'number' ? path[1] : null;\n return typeof path[0] === 'string' ? orbitalIndexOfValidationPath(path[0]) : null;\n }\n const m = typeof path === 'string' ? ORBITAL_PATH_PREFIX.exec(path) : null;\n return m ? Number(m[1]) : null;\n}\n\n/**\n * The result of a single validator pass: a boolean verdict plus the errors\n * and warnings (the validator wire shape, `ValidationError`).\n *\n * Distinct from `ValidationResults` (app.ts): that is the Firestore-persisted\n * app-document shape keyed on `ValidationIssue` (with `severity` + array path\n * + `validatedAt`). This `ValidationResult` is the in-process pass result keyed\n * on `ValidationError` (code + JSON-pointer string path + `suggestion`).\n * `ok === true` iff there are zero errors AND zero warnings.\n */\nexport interface ValidationResult {\n ok: boolean;\n errors: ValidationError[];\n warnings: ValidationError[];\n}\n\n/**\n * Closed set of validation codes the Rust validator + lolo lower\n * pipeline emit, derived from the generated\n * `generated/language/validation-codes.json` (orbital-compiler\n * `ErrorCode::ALL`). Never hand-listed here.\n *\n * Categories (prefix → meaning):\n * - `ORB_BINDING_*` — binding (`@entity.X`, `@payload.Y`, ...) issues\n * - `ORB_E_*` / `ORB_EFF_*` / `ORB_EMIT_*` — entity / effect / emit\n * - `ORB_GEN_*` — generic / cross-cutting structure\n * - `ORB_O_*` / `ORB_P_*` / `ORB_S_*` / `ORB_SM_*` / `ORB_T_*` —\n * orbital / page / schema / state-machine / trait\n * - `ORB_QUERY_*` — query / search behaviors\n * - `ORB_RUI_*` — render-UI binding + prop validation\n * - `ORB_SLOT_*` — UI-slot conflict / contention\n * - `ORB_SVC_*` / `ORB_UI_*` — service / UI primitives\n * - `ORB_X_*` — cross-orbital constraints (listens, emits, IDs)\n * - `ORB_ID_*` — V4 dual-carry id integrity (unknown ref, name/kind\n * mismatch, ledger orphan)\n */\nexport const KNOWN_VALIDATION_ERROR_CODES: Readonly<Record<string, string>> = Object.fromEntries(\n validationCodes.map((entry) => [entry.code, entry.code]),\n);\n\n/**\n * Narrow union of the codes documented in `KNOWN_VALIDATION_ERROR_CODES`.\n * Use this in exhaustive `switch` handlers; use the broader\n * `ValidationErrorCode` (open `string`) anywhere a fresh validator-side\n * code could plausibly arrive.\n */\nexport type KnownValidationErrorCode = string;\n\n/**\n * Type guard: is the given code a known one? After the guard returns\n * true, the code can be narrowed to `KnownValidationErrorCode` via a\n * separate cast, because the type system can't track `in` against\n * `as const` records without an explicit narrowing helper.\n */\nexport function isKnownValidationErrorCode(\n code: ValidationErrorCode,\n): boolean {\n return code in KNOWN_VALIDATION_ERROR_CODES;\n}\n","/**\n * Living Orbital Schema — Golden Data Structure type system.\n *\n * The Living layer treats an `OrbitalSchema` as a heterogeneous attributed\n * graph: every vertex (orbital, entity, trait, state, transition, page, field,\n * event, effect, config-knob) carries a `SemanticAnnotation` + an embedding\n * vector, and the whole object can embed / validate / compile / similarity-\n * search / evolve itself. These are the canonical TYPE definitions shared by\n * the masar (Python) implementation and any TS implementation (rabit, Phase 5);\n * the numeric implementation lives outside @almadar/core.\n *\n * See `docs/Almadar_Masar_Golden_Data_Structure.md` §II/§III/§VIII. Existing\n * core vocabulary is reused, never re-defined: `SchemaChange`/`SemanticChangeKind`\n * (changeset.ts) back the evolution delta, `ValidationError`/`ValidationResult`\n * (validation.ts) back `validate()`, and the per-vertex payloads ARE the existing\n * structural types.\n *\n * @packageDocumentation\n */\n\nimport type { OrbitalSchema } from \"./schema.js\";\nimport type { OrbitalDefinition } from \"./orbital.js\";\nimport type { Entity } from \"./entity.js\";\nimport type { EntityField } from \"./field.js\";\nimport type { Trait, TraitConfigValue, ConfigFieldDeclaration } from \"./trait.js\";\nimport type { State, Transition, Event } from \"./state-machine.js\";\nimport type { Page } from \"./page.js\";\nimport type { Effect } from \"./effect.js\";\nimport type { SExpr, EvalContext, EventPayload } from \"./expression.js\";\nimport type { SchemaChange } from \"./changeset.js\";\nimport type { ValidationError, ValidationResult } from \"./validation.js\";\n// Type-only import (erased at build): no runtime cycle even though factory/\n// imports from types/. `AnnotationTier` is the documented superset of this.\nimport type { FactoryConfigTier } from \"../factory/types.js\";\n\n// ============================================================================\n// Semantic annotation (the NL → typed bridge)\n// ============================================================================\n\n/**\n * Decision-kind tier for the annotation layer. SUPERSET of the validator-\n * enforced `FactoryConfigTier` (`domain`/`policy`/`infra`/`presentation`/\n * `internal`), adding `essential` and `customization` for non-knob (event)\n * vertices that still carry the old vocabulary. Every `FactoryConfigTier`\n * value must be a member so `widenTier` stays a valid identity widen.\n */\nexport type AnnotationTier =\n | \"essential\"\n | \"domain\"\n | \"policy\"\n | \"infra\"\n | \"presentation\"\n | \"customization\"\n | \"internal\";\n\n/** Widen a knob's `FactoryConfigTier` into the annotation-layer `AnnotationTier`. */\nexport function widenTier(tier: FactoryConfigTier): AnnotationTier {\n return tier;\n}\n\n/**\n * The natural-language metadata attached to every living vertex — the text that\n * gets embedded for `similar()`/`match_intent()`. Today these four members live\n * scattered inline across core types (`EntityField.description`/`synonyms`,\n * `Event`/`TraitEventContract`.`description`/`synonyms`/`tier`,\n * `FactoryConfigParam.label`/`description`/`synonyms`/`tier`); `SemanticAnnotation`\n * is the uniform bundle of them, generalized to every vertex.\n */\nexport interface SemanticAnnotation {\n description: string;\n synonyms: string[];\n label: string;\n tier: AnnotationTier;\n}\n\n// ============================================================================\n// ML scalar/vector aliases\n// ============================================================================\n\n/**\n * A dense semantic embedding. In-memory form is `Float32Array`; the at-rest\n * JSON form (e.g. rabit's `knob-embeddings.json`) is `number[]`.\n */\nexport type SemanticVector = Float32Array;\n\n/** A probability in `[0, 1]`. */\nexport type Probability = number;\n\n/** Whether a semantic gate's transition is open, closed, or ~0.5 ambiguous. */\nexport type GateState = \"open\" | \"closed\" | \"ambiguous\";\n\n// ============================================================================\n// Graph vertex / edge typing\n// ============================================================================\n\n/** The typed vertex kinds of the living attributed graph (§II.1 `V_*`). */\nexport type VertexType =\n | \"orbital\"\n | \"entity\"\n | \"trait\"\n | \"state\"\n | \"transition\"\n | \"page\"\n | \"field\"\n | \"event\"\n | \"effect\"\n | \"value\";\n\n/**\n * A stable, structural, embedding-independent vertex id (path style, e.g.\n * `orb:Cart/trt:AddItem/st:Open`). Re-embedding never changes it.\n */\nexport type VertexId = string;\n\n/** The typed directed edge kinds of the living attributed graph (§II.1 `E_*`). */\nexport type EdgeType =\n | \"belongs_to\"\n | \"has_trait\"\n | \"has_state\"\n | \"has_transition\"\n | \"from_state\"\n | \"to_state\"\n | \"on_event\"\n | \"emits\"\n | \"listens\"\n | \"cross_orbital\"\n | \"has_effect\"\n | \"effect_seq\"\n | \"data_flow\"\n | \"ref_in_effect\"\n | \"has_page\"\n | \"has_field\"\n | \"ref\";\n\n/**\n * An effect vertex's payload. Effects are positional S-expression tuples\n * (`Effect`), so the synthesized coordinates (operator, owning transition,\n * positional index) carry the addressing the raw tuple lacks.\n */\nexport interface EffectPayload {\n sexpr: Effect;\n operator: string;\n transitionId: VertexId;\n index: number;\n}\n\n/**\n * A config-knob vertex's payload — joins a `Trait.config` dict key with its\n * declaration (no single core type carries both).\n */\nexport interface KnobPayload {\n name: string;\n declaration: ConfigFieldDeclaration;\n traitId: VertexId;\n}\n\n/** The union of every kind of vertex payload (the existing structural types). */\nexport type VertexPayload =\n | OrbitalDefinition\n | Entity\n | Trait\n | State\n | Transition\n | Page\n | EntityField\n | Event\n | EffectPayload\n | KnobPayload;\n\n/**\n * One vertex of the living graph: a structural payload plus its annotation and\n * embedding. Identity is `id` (structural); annotation/embedding are derived.\n */\nexport interface LivingVertex<P extends VertexPayload = VertexPayload> {\n id: VertexId;\n vtype: VertexType;\n payload: P;\n annotation: SemanticAnnotation;\n /** Lazily populated — undefined until the schema's `embed()` runs. */\n embedding?: SemanticVector;\n}\n\nexport type LivingOrbital = LivingVertex<OrbitalDefinition>;\nexport type LivingEntity = LivingVertex<Entity>;\nexport type LivingTrait = LivingVertex<Trait>;\nexport type LivingState = LivingVertex<State>;\nexport type LivingTransition = LivingVertex<Transition>;\nexport type LivingPage = LivingVertex<Page>;\nexport type LivingField = LivingVertex<EntityField>;\nexport type LivingEvent = LivingVertex<Event>;\nexport type LivingEffect = LivingVertex<EffectPayload>;\nexport type LivingValue = LivingVertex<KnobPayload>;\n\n/**\n * One directed edge. `via` carries the transition vertex for the ternary\n * `has_transition(from, via, to)` decomposition; `seq` carries the ordering for\n * `effect_seq`.\n */\nexport interface LivingEdge {\n etype: EdgeType;\n src: VertexId;\n dst: VertexId;\n via?: VertexId;\n seq?: number;\n}\n\n// ============================================================================\n// Evolution + lineage (composes changeset.ts vocabulary)\n// ============================================================================\n\n/**\n * A single evolution step over the living graph. `modified` reuses the canonical\n * `SchemaChange` (changeset.ts) rather than inventing a parallel operation enum;\n * `intent` is the natural-language delta that caused the change.\n */\nexport interface EvolutionDelta {\n added: VertexId[];\n removed: VertexId[];\n modified: SchemaChange[];\n intent: string;\n}\n\n/** One immutable entry in a living schema's evolution lineage (§6.2). */\nexport interface LineageEntry {\n root: string;\n parent: string;\n delta: EvolutionDelta;\n intent: string;\n time: number;\n valid: boolean;\n}\n\n// ============================================================================\n// Effect-simulation results\n// ============================================================================\n\n/** The result of simulating one effect's S-expression (§4.6) — pure, no I/O. */\nexport interface EffectResult {\n result: SExpr;\n sideEffects: string[];\n emittedEvents: string[];\n}\n\n// ============================================================================\n// The living schema contract (§VIII) — implemented by masar (Python) + rabit (TS)\n// ============================================================================\n\n/**\n * The operation surface of a living orbital schema. This interface is the shared\n * CONTRACT; the numeric implementation (embedding, cosine, validator shelling)\n * is language-specific. `compile()` is the bridge back to the canonical\n * `OrbitalSchema` (the ML surface — annotations beyond `description`, embeddings,\n * gates — is stripped).\n */\nexport interface LivingOrbitalSchema {\n // Orbital container\n orbitals: LivingOrbital[];\n addOrbital(name: string): LivingOrbital;\n removeOrbital(name: string): void;\n getOrbital(name: string): LivingOrbital;\n\n // Semantic layer\n annotations: Map<VertexId, SemanticAnnotation>;\n embeddings: Map<VertexId, SemanticVector>;\n\n // Structural operations\n embed(): void;\n compile(): OrbitalSchema;\n validate(): ValidationResult;\n\n // Semantic retrieval\n similar(query: string | SemanticVector, k: number, type?: VertexType): LivingVertex[];\n matchIntent(intent: string, threshold?: number): { vertex: LivingVertex; score: number }[];\n\n // Predictive operations\n predictConfig(intent: string, trait: Trait): Record<string, TraitConfigValue>;\n predictPresence(intent: string): Set<string>;\n suggestOrbital(intent: string): LivingOrbital[];\n suggestEntity(intent: string): LivingEntity[];\n suggestTrait(intent: string): LivingTrait[];\n\n // Evolution\n evolve(intentDelta: string): LivingOrbitalSchema;\n compose(other: LivingOrbitalSchema): LivingOrbitalSchema;\n repair(errors: ValidationError[]): LivingOrbitalSchema;\n\n // Cross-orbital wiring\n wireEvents(source: LivingEvent, target: LivingEvent): void;\n findWiringGaps(): LivingEvent[];\n\n // Effect simulation\n simulateEffect(effect: LivingEffect, context: EvalContext): EffectResult;\n simulateInteraction(effect: LivingEffect, path: string[]): { event: LivingEvent; payload: EventPayload };\n traceDataFlow(transition: LivingTransition, inputEntity: LivingEntity): LivingEffect[];\n\n // Gates\n evaluateGates(intentEmbedding: SemanticVector): Map<VertexId, GateState[]>;\n sampleTrajectory(intentEmbedding: SemanticVector, steps: number): LivingVertex[];\n\n // Lineage\n lineage: LineageEntry[];\n checkout(hash: string): LivingOrbitalSchema;\n diff(hash1: string, hash2: string): EvolutionDelta;\n}\n","/**\n * Accessibility attribute vocabulary — the one source every layer reads.\n *\n * `@almadar/ui` components that forward these to their element declare\n * `extends A11yProps`; `@almadar/pattern-sync` expands `A11Y_ATTRIBUTES` into\n * those patterns' `propsSchema`, so `.lolo` render-ui can set them and both\n * execution paths (runtime + compiled) admit them.\n *\n * @packageDocumentation\n */\n\nimport { z } from \"zod\";\n\nexport const ARIA_LIVE = [\"off\", \"polite\", \"assertive\"] as const;\nexport type AriaLive = (typeof ARIA_LIVE)[number];\n\nexport const ARIA_CURRENT = [\"page\", \"step\", \"location\", \"date\", \"time\", \"true\", \"false\"] as const;\nexport type AriaCurrent = (typeof ARIA_CURRENT)[number];\n\nexport const ARIA_PRESSED = [\"true\", \"false\", \"mixed\"] as const;\nexport type AriaPressed = (typeof ARIA_PRESSED)[number];\n\nexport const TEXT_DIRECTIONS = [\"ltr\", \"rtl\", \"auto\"] as const;\nexport type TextDirection = (typeof TEXT_DIRECTIONS)[number];\n\n/** Focus order a pattern may opt into: in order (0) or programmatic-only (-1). */\nexport const TAB_INDEX_VALUES = [-1, 0] as const;\nexport type TabIndexValue = (typeof TAB_INDEX_VALUES)[number];\n\n/** WAI-ARIA 1.2 non-abstract roles. */\nexport const ARIA_ROLES = [\n \"alert\", \"alertdialog\", \"application\", \"article\", \"banner\", \"blockquote\", \"button\",\n \"caption\", \"cell\", \"checkbox\", \"code\", \"columnheader\", \"combobox\", \"complementary\",\n \"contentinfo\", \"definition\", \"deletion\", \"dialog\", \"document\", \"emphasis\", \"feed\",\n \"figure\", \"form\", \"generic\", \"grid\", \"gridcell\", \"group\", \"heading\", \"img\", \"insertion\",\n \"link\", \"list\", \"listbox\", \"listitem\", \"log\", \"main\", \"marquee\", \"math\", \"menu\",\n \"menubar\", \"menuitem\", \"menuitemcheckbox\", \"menuitemradio\", \"meter\", \"navigation\",\n \"none\", \"note\", \"option\", \"paragraph\", \"presentation\", \"progressbar\", \"radio\",\n \"radiogroup\", \"region\", \"row\", \"rowgroup\", \"rowheader\", \"scrollbar\", \"search\",\n \"searchbox\", \"separator\", \"slider\", \"spinbutton\", \"status\", \"strong\", \"subscript\",\n \"superscript\", \"switch\", \"tab\", \"table\", \"tablist\", \"tabpanel\", \"term\", \"textbox\",\n \"time\", \"timer\", \"toolbar\", \"tooltip\", \"tree\", \"treegrid\", \"treeitem\",\n] as const;\nexport type AriaRole = (typeof ARIA_ROLES)[number];\nexport const AriaRoleSchema = z.enum(ARIA_ROLES);\n\nconst ARIA_ROLE_SET: ReadonlySet<string> = new Set(ARIA_ROLES);\n\nexport function isAriaRole(value: string): value is AriaRole {\n return ARIA_ROLE_SET.has(value);\n}\n\n/** ARIA's boolean attribute values, as React accepts them. */\nexport type AriaBooleanish = boolean | \"true\" | \"false\";\n\n/**\n * The props an accessible pattern forwards to its element. Typed as React\n * accepts them (TSX call sites); `.lolo` gets the narrower A11Y_ATTRIBUTES.\n */\nexport interface A11yProps {\n \"aria-label\"?: string;\n \"aria-labelledby\"?: string;\n \"aria-describedby\"?: string;\n \"aria-live\"?: AriaLive;\n \"aria-current\"?: AriaCurrent | boolean;\n \"aria-pressed\"?: AriaBooleanish | \"mixed\";\n \"aria-expanded\"?: AriaBooleanish;\n \"aria-selected\"?: AriaBooleanish;\n \"aria-hidden\"?: AriaBooleanish;\n \"aria-busy\"?: AriaBooleanish;\n role?: AriaRole;\n lang?: string;\n dir?: TextDirection;\n tabIndex?: number;\n}\n\n/** A11yProps as propsSchema entries (the registry's prop shape). */\nexport interface A11yAttributeSchema {\n types: [\"string\"] | [\"boolean\"] | [\"number\"];\n description: string;\n enumValues?: readonly string[];\n numericEnumValues?: readonly number[];\n}\n\nexport const A11Y_ATTRIBUTES: Record<keyof A11yProps, A11yAttributeSchema> = {\n \"aria-label\": { types: [\"string\"], description: \"Accessible name read by screen readers when the visible text is missing or not descriptive (e.g. an icon-only control).\" },\n \"aria-labelledby\": { types: [\"string\"], description: \"Id of the element whose text names this one.\" },\n \"aria-describedby\": { types: [\"string\"], description: \"Id of the element whose text describes this one (help text, error).\" },\n \"aria-live\": { types: [\"string\"], enumValues: ARIA_LIVE, description: \"Announce changes to this region: polite waits for a pause, assertive interrupts.\" },\n \"aria-current\": { types: [\"string\"], enumValues: ARIA_CURRENT, description: \"Marks the current item in a set: the current page, step, location, date or time.\" },\n \"aria-pressed\": { types: [\"string\"], enumValues: ARIA_PRESSED, description: \"Toggle-button state.\" },\n \"aria-expanded\": { types: [\"boolean\"], description: \"Whether the element it controls is expanded.\" },\n \"aria-selected\": { types: [\"boolean\"], description: \"Whether this item is selected (tabs, options, grid cells).\" },\n \"aria-hidden\": { types: [\"boolean\"], description: \"Hide from assistive technology (decorative content only).\" },\n \"aria-busy\": { types: [\"boolean\"], description: \"This region is updating; assistive technology waits before announcing it.\" },\n role: { types: [\"string\"], enumValues: ARIA_ROLES, description: \"WAI-ARIA role when the element's native semantics don't describe it.\" },\n lang: { types: [\"string\"], description: \"Language of this element's content (BCP 47, e.g. ar, sl, en).\" },\n dir: { types: [\"string\"], enumValues: TEXT_DIRECTIONS, description: \"Text direction of this element's content.\" },\n tabIndex: { types: [\"number\"], numericEnumValues: TAB_INDEX_VALUES, description: \"0 puts the element in the Tab order; -1 makes it focusable only programmatically.\" },\n};\n\n/** Props that give an element its accessible name. */\nexport const ACCESSIBLE_NAME_ATTRIBUTES = [\"aria-label\", \"aria-labelledby\"] as const;\n","/** A content block's surface modes. */\nexport const SURFACE_MODES = ['auto', 'none'] as const;\n\n/**\n * A content block's surface: `auto` paints the theme-owned content surface\n * behind the block unless it already sits on one (a card, dialog or another\n * block); `none` places it directly on the page.\n */\nexport type SurfaceMode = (typeof SURFACE_MODES)[number];\n","/**\n * Canvas theme — the theme's drawing axes (`diagram`, `scene`, diagram colors, the canvas ground)\n * resolved to concrete values for surfaces that cannot evaluate CSS: canvas 2D, three.js and the\n * native painters. A mark names a role (`tone`, `stroke`, `text`, `font`); the surface asks the\n * resolved theme what that role looks like.\n */\n\nimport { z } from 'zod';\nimport type { DiagramFillStyle, DiagramLabelFont, DiagramLineCap, DiagramLineJoin, DiagramMarker } from './domain.js';\n\n/** The color roles a mark can name instead of a literal color. */\nexport type DiagramTone =\n | 'ink'\n | 'label'\n | 'guide'\n | 'axis'\n | 'grid'\n | 'highlight'\n | 'fill'\n | 'series-1'\n | 'series-2'\n | 'series-3'\n | 'series-4'\n | 'series-5'\n | 'series-6'\n | 'series-7'\n | 'series-8'\n | 'primary'\n | 'accent'\n | 'success'\n | 'warning'\n | 'error'\n | 'info'\n | 'muted';\n\nexport const DIAGRAM_TONES = [\n 'ink', 'label', 'guide', 'axis', 'grid', 'highlight', 'fill',\n 'series-1', 'series-2', 'series-3', 'series-4', 'series-5', 'series-6', 'series-7', 'series-8',\n 'primary', 'accent', 'success', 'warning', 'error', 'info', 'muted',\n] as const satisfies readonly DiagramTone[];\nexport const DiagramToneSchema = z.enum(DIAGRAM_TONES);\n\n/** The theme color key (`--color-<key>`) each tone draws with. */\nexport const DIAGRAM_TONE_COLOR_KEYS: Readonly<Record<DiagramTone, string>> = {\n ink: 'diagram-ink',\n label: 'diagram-label',\n guide: 'diagram-guide',\n axis: 'diagram-axis',\n grid: 'diagram-grid',\n highlight: 'diagram-highlight',\n fill: 'diagram-fill',\n 'series-1': 'series-1',\n 'series-2': 'series-2',\n 'series-3': 'series-3',\n 'series-4': 'series-4',\n 'series-5': 'series-5',\n 'series-6': 'series-6',\n 'series-7': 'series-7',\n 'series-8': 'series-8',\n primary: 'primary',\n accent: 'accent',\n success: 'success',\n warning: 'warning',\n error: 'error',\n info: 'info',\n muted: 'muted-foreground',\n};\n\nexport type DiagramStrokeWeight = 'thin' | 'normal' | 'bold';\nexport const DIAGRAM_STROKE_WEIGHTS = ['thin', 'normal', 'bold'] as const satisfies readonly DiagramStrokeWeight[];\nexport const DiagramStrokeWeightSchema = z.enum(DIAGRAM_STROKE_WEIGHTS);\n\nexport type DiagramTextSize = 'xs' | 'sm' | 'base' | 'lg' | 'xl' | '2xl';\nexport const DIAGRAM_TEXT_SIZES = ['xs', 'sm', 'base', 'lg', 'xl', '2xl'] as const satisfies readonly DiagramTextSize[];\nexport const DiagramTextSizeSchema = z.enum(DIAGRAM_TEXT_SIZES);\n\n/** Whether a label follows the theme's label case or keeps its letters (symbols, units, formulas). */\nexport type DiagramTextCase = 'theme' | 'verbatim';\nexport const DIAGRAM_TEXT_CASES = ['theme', 'verbatim'] as const satisfies readonly DiagramTextCase[];\nexport const DiagramTextCaseSchema = z.enum(DIAGRAM_TEXT_CASES);\n\n/** Each list names every member of its union (a missing member fails to compile). */\ntype Covers<U, L extends readonly U[]> = Exclude<U, L[number]> extends never ? true : false;\nconst _tonesComplete: Covers<DiagramTone, typeof DIAGRAM_TONES> = true;\nconst _strokesComplete: Covers<DiagramStrokeWeight, typeof DIAGRAM_STROKE_WEIGHTS> = true;\nconst _textComplete: Covers<DiagramTextSize, typeof DIAGRAM_TEXT_SIZES> = true;\nconst _caseComplete: Covers<DiagramTextCase, typeof DIAGRAM_TEXT_CASES> = true;\nvoid _tonesComplete;\nvoid _strokesComplete;\nvoid _textComplete;\nvoid _caseComplete;\n\n/**\n * The roles a drawn mark can carry. A role overrides the theme default for that mark; a literal\n * style field on the same mark (`color`, `lineWidth`, `fontSize`) overrides the role.\n */\nexport interface DiagramMarkRoles {\n /** Stroke / text color role. */\n tone?: DiagramTone;\n /** Fill color role (default: the stroke's tone under the theme's fill style). */\n fillTone?: DiagramTone;\n /** Stroke weight role. */\n stroke?: DiagramStrokeWeight;\n /** Label size role — a step of the theme's type scale. */\n textSize?: DiagramTextSize;\n /** Label face role. */\n font?: DiagramLabelFont;\n /** `verbatim` keeps a symbol's letters (mg, pH, Na, θ) under an uppercase label theme; default `theme`. */\n textCase?: DiagramTextCase;\n /** Fill treatment; absent = the theme's `--diagram-fill-style`. */\n fillStyle?: DiagramFillStyle;\n}\n\n/** A theme shadow recipe reduced to what a canvas context can draw. */\nexport interface CanvasShadow {\n offsetX: number;\n offsetY: number;\n blur: number;\n color: string;\n}\n\n/** The theme's drawing axes resolved for one scope. Colors are canvas-ready CSS strings. */\nexport interface CanvasTheme {\n ground: string;\n /**\n * Diagram chrome surfaces: the neutral wash (`--color-muted`), cards (`--color-card`) and text\n * drawn on a primary fill (`--color-primary-foreground`).\n */\n surfaces: Readonly<Record<'muted' | 'card' | 'onPrimary', string>>;\n tones: Readonly<Record<DiagramTone, string>>;\n series: readonly string[];\n strokes: Readonly<Record<DiagramStrokeWeight, number>>;\n lineCap: DiagramLineCap;\n lineJoin: DiagramLineJoin;\n dash: readonly number[];\n dot: readonly number[];\n fillStyle: DiagramFillStyle;\n fillOpacity: number;\n roughness: number;\n glow: number;\n shadow: CanvasShadow | null;\n marker: DiagramMarker;\n faces: Readonly<Record<DiagramLabelFont, string>>;\n label: {\n font: DiagramLabelFont;\n size: DiagramTextSize;\n weight: string;\n uppercase: boolean;\n };\n /** Type scale in px. */\n text: Readonly<Record<DiagramTextSize, number>>;\n corner: number;\n motion: {\n enabled: boolean;\n fastMs: number;\n normalMs: number;\n slowMs: number;\n easing: string;\n };\n scene: {\n roughness: number;\n metalness: number;\n flat: boolean;\n outline: number;\n ambient: number;\n key: number;\n keyColor: string;\n fog: number;\n };\n}\n","/**\n * A generator eval as data: the turns a user types, the structural checks each turn's built program\n * must pass, and what the build must adopt. `orb eval` runs it; mirrored by orbital-core `eval_spec`.\n */\nimport { z } from 'zod';\nimport type { JsonValue } from './json.js';\nimport { JsonValueSchema } from './json.js';\n\n/** A regular expression carried as data (`new RegExp(pattern, flags)`). */\nexport interface EvalPattern {\n pattern: string;\n flags?: string;\n}\n\nexport type EvalPredicate =\n /** a persistent entity named by the nouns */\n | { kind: 'entity' }\n /** a field named by the nouns on a persistent entity; `required`: declared required or read by a create guard/policy */\n | { kind: 'field'; required?: boolean }\n /** an enum value named by `value` on a persistent entity named by the nouns */\n | { kind: 'enumValue'; value: EvalPattern }\n /** a policy or transition guard on the nouns entity compares `@user.role` */\n | { kind: 'roleGated' }\n /** the nouns entity's read policy compares a row value to `@user.id`; with `by`, through a field the request names */\n | { kind: 'ownerScoped'; by?: EvalPattern }\n /** one transition's effects read a nouns field and a field named by `with` */\n | { kind: 'feeds'; with: EvalPattern }\n /** a transition that notifies reads a nouns field in its guard or effects */\n | { kind: 'notifies' }\n /** an external input whose event key or payload field is named by the nouns */\n | { kind: 'input' }\n /** an in-app agent (std-agent-tool-loop) runs in the program */\n | { kind: 'agent' }\n /** a page is declared at `path` */\n | { kind: 'route'; path: string }\n /** text named by the nouns is visible on `route`, else on every route of the entity named by `on` (default: the nouns) */\n | { kind: 'rendered'; route?: string; on?: EvalPattern }\n /** visible text on every concrete route must not show these words */\n | { kind: 'absentText'; words: string[] }\n /** no persistent entity is named by the nouns */\n | { kind: 'absentEntity' }\n /** an orbital named by the nouns is declared; with `absent`, none is */\n | { kind: 'orbital'; absent?: boolean }\n /** a trait named by the nouns sets config `key` to `value` */\n | { kind: 'knob'; key: string; value: JsonValue };\n\nexport interface EvalCheck {\n id: string;\n /** the turn (0-based) from which this check must hold, and keep holding */\n introducedTurn: number;\n /** the request's own words for the thing it asks for */\n nouns: EvalPattern;\n require: EvalPredicate[];\n /** routes framed for the rubric; default: every route a predicate bound */\n frameRoutes?: string[];\n coversDeclines?: string[];\n}\n\nexport const EVAL_TIERS = ['none', 'organism', 'subset', 'compose', 'substrate', 'free'] as const;\nexport type EvalTier = (typeof EVAL_TIERS)[number];\n\nexport interface EvalExpectations {\n /** the build must take one of these tiers */\n tiers?: EvalTier[];\n /** behaviors (exact ids) the build must adopt */\n adopts?: string[];\n /** orbitals (exact names) the built program must declare */\n orbitals?: string[];\n /** the built program passes `orb validate --final` */\n validates?: boolean;\n}\n\nexport type EvalClass = 'plain' | 'specific' | 'complex';\n\nexport interface EvalSpec {\n id: string;\n class: EvalClass;\n description?: string;\n turns: [string, ...string[]];\n checks: EvalCheck[];\n expect?: EvalExpectations;\n /** behaviors (exact ids) the build must not adopt */\n forbidSources?: string[];\n}\n\nfunction validPattern(p: { pattern: string; flags?: string }): boolean {\n try {\n new RegExp(p.pattern, p.flags);\n return true;\n } catch {\n return false;\n }\n}\n\nconst EvalPatternSchema: z.ZodType<EvalPattern> = z\n .object({ pattern: z.string(), flags: z.string().optional() })\n .strict()\n .refine(validPattern, { message: 'pattern is not a valid regular expression' });\n\nconst EvalPredicateSchema: z.ZodType<EvalPredicate> = z.discriminatedUnion('kind', [\n z.object({ kind: z.literal('entity') }).strict(),\n z.object({ kind: z.literal('field'), required: z.boolean().optional() }).strict(),\n z.object({ kind: z.literal('enumValue'), value: EvalPatternSchema }).strict(),\n z.object({ kind: z.literal('roleGated') }).strict(),\n z.object({ kind: z.literal('ownerScoped'), by: EvalPatternSchema.optional() }).strict(),\n z.object({ kind: z.literal('feeds'), with: EvalPatternSchema }).strict(),\n z.object({ kind: z.literal('notifies') }).strict(),\n z.object({ kind: z.literal('input') }).strict(),\n z.object({ kind: z.literal('agent') }).strict(),\n z.object({ kind: z.literal('route'), path: z.string() }).strict(),\n z.object({ kind: z.literal('rendered'), route: z.string().optional(), on: EvalPatternSchema.optional() }).strict(),\n z.object({ kind: z.literal('absentText'), words: z.array(z.string()) }).strict(),\n z.object({ kind: z.literal('absentEntity') }).strict(),\n z.object({ kind: z.literal('orbital'), absent: z.boolean().optional() }).strict(),\n z.object({ kind: z.literal('knob'), key: z.string().min(1), value: JsonValueSchema }).strict(),\n]);\n\nconst EvalCheckSchema: z.ZodType<EvalCheck> = z\n .object({\n id: z.string().min(1),\n introducedTurn: z.number().int().min(0),\n nouns: EvalPatternSchema,\n require: z.array(EvalPredicateSchema),\n frameRoutes: z.array(z.string()).optional(),\n coversDeclines: z.array(z.string()).optional(),\n })\n .strict();\n\nexport const EvalSpecSchema: z.ZodType<EvalSpec> = z\n .object({\n id: z.string().min(1),\n class: z.enum(['plain', 'specific', 'complex']),\n description: z.string().optional(),\n turns: z.tuple([z.string()]).rest(z.string()),\n checks: z.array(EvalCheckSchema),\n expect: z\n .object({\n tiers: z.array(z.enum(EVAL_TIERS)).optional(),\n adopts: z.array(z.string()).optional(),\n orbitals: z.array(z.string()).optional(),\n validates: z.boolean().optional(),\n })\n .strict()\n .optional(),\n forbidSources: z.array(z.string()).optional(),\n })\n .strict()\n .superRefine((spec, ctx) => {\n for (const [i, check] of spec.checks.entries()) {\n if (check.introducedTurn >= spec.turns.length) {\n ctx.addIssue({ code: 'custom', path: ['checks', i, 'introducedTurn'], message: `introducedTurn ${check.introducedTurn} is past the spec's ${spec.turns.length} turns` });\n }\n }\n });\n\n/** Parse an eval spec, throwing with every issue (path + message) when it does not conform. */\nexport function parseEvalSpec(input: JsonValue): EvalSpec {\n const parsed = EvalSpecSchema.safeParse(input);\n if (parsed.success) return parsed.data;\n throw new Error(`invalid eval spec: ${parsed.error.issues.map((i) => `${i.path.join('.') || '(root)'}: ${i.message}`).join('; ')}`);\n}\n\nexport function evalPatternMatches(p: EvalPattern, text: string): boolean {\n return new RegExp(p.pattern, p.flags).test(text);\n}\n","/**\n * The browser-tab host port: what a browser host does for the kernel's `browser/tab-*` effects. The kernel\n * validates every request and shapes every result; the port performs one raw tab or page operation per ask\n * and holds no decision.\n */\nimport type { TabAsk, TabFailureKind } from '../generated/kernel-wire.js';\nimport type { EventPayload } from './expression.js';\nimport type { JsonValue } from './json.js';\n\n/** A raw ask a host could not perform, with the kernel's closed reason. */\nexport class TabHostFailure extends Error {\n constructor(\n readonly kind: TabFailureKind,\n message: string,\n ) {\n super(message);\n this.name = 'TabHostFailure';\n }\n}\n\n/** What one ask comes with: the abort signal of a keyed ask, and the way a watch's elements reach the program. */\nexport interface TabAskContext {\n signal?: AbortSignal;\n /** Dispatches `payload` to the declared external input the watch ask names; a no-op for any other ask. */\n deliver: (payload: EventPayload) => void;\n}\n\nexport interface BrowserTabPort {\n /** Perform one raw ask and resolve its JSON reply (the shape each `TabAsk` documents), or throw a `TabHostFailure`. */\n perform(ask: TabAsk, context: TabAskContext): Promise<JsonValue>;\n}\n\n/** Whether a Chrome match pattern matches a URL: the kernel's one rule (`tabUrlMatches` of `@almadar/kernel`). */\nexport type TabUrlMatcher = (pattern: string, url: string) => boolean;\n","/**\n * What a server hands the program-independent web client at startup (`/client.json`), beside `program.client.orb`:\n * the program's locale and text direction and its themes with the default theme and mode. The TypeScript shell writes it\n * for `orb compile` and `orb serve` alike, beside the kernel's language data (`/language.json`).\n */\nimport { z } from 'zod';\nimport type { JsonValue } from './json.js';\n\nexport const ClientThemeSchema = z\n .object({\n name: z.string().min(1),\n displayName: z.string(),\n hasLightMode: z.boolean(),\n hasDarkMode: z.boolean(),\n })\n .strict();\n\nexport const ClientManifestSchema = z\n .object({\n locale: z.string().min(1),\n direction: z.enum(['ltr', 'rtl']),\n themes: z.array(ClientThemeSchema),\n defaultTheme: z.string().min(1).nullable(),\n defaultMode: z.enum(['light', 'dark']),\n })\n .strict();\n\nexport type ClientTheme = z.infer<typeof ClientThemeSchema>;\nexport type ClientManifest = z.infer<typeof ClientManifestSchema>;\n\n/** The manifest, or a throw naming what is wrong with it. */\nexport function parseClientManifest(value: JsonValue): ClientManifest {\n return ClientManifestSchema.parse(value);\n}\n","/**\n * Zod twins of the program reflection records the kernel answers with: a program's state machine as rows\n * (`program/machine` → `MachineRow[]`) and a played request (`program/step` → `PlayedStep[]`). The types are\n * generated from `orbital-core` `program_machine`; these schemas are what `program-types.ts` projects so a `.lolo`\n * program can read them member by member.\n */\nimport { z } from 'zod';\n\nimport type {\n EntityBinding,\n EntityBindingKind,\n EnsuresVerdict,\n EvalStepWire,\n GuardVerdict,\n MachineRow,\n PayloadSlot,\n PendingAsk,\n PlayedEffect,\n PlayedEffectStatus,\n PlayedEmit,\n PlayedEnsures,\n PlayedGuard,\n PlayedOutcome,\n PlayedResult,\n PlayedState,\n PlayedStep,\n PropositionBindings,\n RenderedNode,\n RenderedSlot,\n TraitRef,\n} from '../generated/kernel-wire.js';\nimport { EventPayloadSchema } from './expression.js';\nimport { JsonValueSchema } from './json.js';\n\nexport type {\n EntityBinding,\n EntityBindingKind,\n EnsuresVerdict,\n GuardVerdict,\n MachineRow,\n PayloadSlot,\n PendingAsk,\n PlayedEffect,\n PlayedEffectStatus,\n PlayedEmit,\n PlayedEnsures,\n PlayedGuard,\n PlayedOutcome,\n PlayedResult,\n PlayedState,\n PlayedStep,\n PropositionBindings,\n RenderedNode,\n RenderedSlot,\n TraitRef,\n};\n\nexport const PayloadSlotSchema: z.ZodType<PayloadSlot> = z.object({\n name: z.string(),\n type: z.string(),\n required: z.boolean(),\n values: z.array(z.string()).optional(),\n entity: z.string().optional(),\n});\n\nexport const MachineRowSchema: z.ZodType<MachineRow> = z.object({\n orbital: z.string(),\n trait: z.string(),\n from: z.string(),\n event: z.string(),\n to: z.string(),\n guarded: z.boolean(),\n payload: z.array(PayloadSlotSchema),\n});\n\n/** Where a traced evaluation step sits in its expression: indexes and keys, outermost first. */\nexport const EvalPathSchema = z.array(z.union([z.number(), z.string()]));\n\nconst EvalStepWireSchema: z.ZodType<EvalStepWire> = z.object({\n kind: z.enum(['enter', 'exit', 'iter', 'skip']),\n path: EvalPathSchema,\n value: JsonValueSchema.optional(),\n error: z.string().optional(),\n});\n\nconst PlayedEffectSchema: z.ZodType<PlayedEffect> = z.object({\n type: z.string(),\n args: z.array(JsonValueSchema),\n status: z.enum(['executed', 'failed', 'skipped']),\n error: z.string().optional(),\n routed: z.boolean(),\n});\n\nconst PropositionBindingsSchema: z.ZodType<PropositionBindings> = z.object({\n entity: JsonValueSchema,\n fromEntity: JsonValueSchema,\n payload: JsonValueSchema,\n});\n\nconst PlayedEnsuresSchema: z.ZodType<PlayedEnsures> = z.object({\n proposition: JsonValueSchema,\n verdict: z.enum(['held', 'broken', 'inconclusive']),\n reason: z.string().optional(),\n counterexample: PropositionBindingsSchema.optional(),\n});\n\nconst PlayedEmitSchema: z.ZodType<PlayedEmit> = z.object({\n type: z.string(),\n payload: EventPayloadSchema.optional(),\n timestamp: z.number(),\n});\n\nconst PlayedGuardSchema: z.ZodType<PlayedGuard> = z.object({\n arm: z.number(),\n guard: JsonValueSchema,\n passed: z.boolean(),\n trace: z.array(EvalStepWireSchema),\n error: z.string().optional(),\n});\n\nconst EntityBindingSchema: z.ZodType<EntityBinding> = z.object({\n kind: z.enum(['none', 'absent', 'malformed', 'inline', 'named', 'payload-unresolved', 'context-unresolved']),\n entity: z.string(),\n rows: z.number(),\n readGated: z.boolean(),\n});\n\nconst TraitRefSchema: z.ZodType<TraitRef> = z.object({\n name: z.string(),\n resolved: z.boolean(),\n overlayOnly: z.boolean(),\n});\n\nconst RenderedNodeSchema: z.ZodType<RenderedNode> = z.object({\n pattern: z.string(),\n dynamic: z.boolean(),\n supported: z.boolean(),\n stub: z.boolean(),\n binding: EntityBindingSchema,\n traitRefs: z.array(TraitRefSchema),\n});\n\nconst RenderedSlotSchema: z.ZodType<RenderedSlot> = z.object({\n slot: z.string(),\n sourceTrait: z.string(),\n ownerEntity: z.string(),\n nodes: z.array(RenderedNodeSchema),\n props: JsonValueSchema.optional(),\n fault: z.object({ code: z.enum(['no-matching-transition', 'guard-rejected', 'no-dispatchable-traits', 'not-an-external-input', 'inbound-only-event', 'effect-failed', 'locale-not-declared', 'client-circuit-state-refused', 'repaint-failed']), error: z.string() }).optional(),\n});\n\nconst PlayedStateSchema: z.ZodType<PlayedState> = z.object({ before: z.string().nullable(), after: z.string().nullable() });\n\nconst PendingAskSchema: z.ZodType<PendingAsk> = z.object({\n trait: z.string(),\n operator: z.string(),\n args: z.array(JsonValueSchema),\n key: z.string(),\n});\n\nconst PlayedOutcomeSchema: z.ZodType<PlayedOutcome> = z.object({\n orbital: z.string(),\n trait: z.string(),\n event: z.string(),\n from: z.string(),\n to: z.string(),\n arm: z.number().optional(),\n fired: z.boolean(),\n effects: z.array(PlayedEffectSchema),\n emitted: z.array(PlayedEmitSchema),\n});\n\nconst JsonRecordSchema = z.record(z.string(), JsonValueSchema);\n\nconst PlayedResultSchema: z.ZodType<PlayedResult> = z.object({\n trait: z.string(),\n event: z.string(),\n transitionFired: z.boolean(),\n guard: z.enum(['pass', 'fail', 'none']),\n firedArm: z.number().optional(),\n state: PlayedStateSchema,\n effects: z.array(PlayedEffectSchema),\n emitted: z.array(PlayedEmitSchema),\n guards: z.array(PlayedGuardSchema),\n ensures: z.array(PlayedEnsuresSchema),\n rendered: z.array(RenderedSlotSchema).optional(),\n failure: z.string().optional(),\n entityAfter: EventPayloadSchema.nullable(),\n pendingAsks: z.array(PendingAskSchema),\n outcomes: z.array(PlayedOutcomeSchema),\n});\n\nexport const PlayedStepSchema: z.ZodType<PlayedStep> = z.object({\n orbital: z.string(),\n trait: z.string(),\n from: z.string(),\n event: z.string(),\n payload: EventPayloadSchema,\n result: PlayedResultSchema,\n entity: JsonRecordSchema.optional(),\n config: JsonRecordSchema.optional(),\n now: z.number().optional(),\n settleMs: z.number().optional(),\n identity: z.object({ subject: z.string(), claims: JsonRecordSchema }).optional(),\n credentials: z.record(z.string(), z.string()).optional(),\n});\n","import { z } from 'zod';\nimport { JsonValueSchema } from './json.js';\nimport { OrbitalSchemaSchema } from './schema.js';\nimport { SourceDeclarationMetadataSchema } from './trait.js';\n\n// Positions are 1-based Unicode scalars with an exclusive end; length counts original UTF-8 bytes.\nexport const ProgramSourceLocationSchema = z.object({\n path: z.string(),\n line: z.number().int().positive(),\n column: z.number().int().positive(),\n length: z.number().int().nonnegative(),\n endLine: z.number().int().positive(),\n endColumn: z.number().int().positive(),\n exact: z.boolean(),\n scopeEndLine: z.number().int().positive().optional(),\n scopeEndColumn: z.number().int().positive().optional(),\n scopeLength: z.number().int().nonnegative().optional(),\n});\n\nexport const ProgramSourceAnchorSchema = ProgramSourceLocationSchema.extend({\n pointer: z.string(),\n orbitalId: z.string().nullable(),\n traitId: z.string().nullable(),\n originTraitId: z.string(),\n});\n\nexport const ProgramInspectionSchema = z.object({\n program: OrbitalSchemaSchema,\n authoredProgram: OrbitalSchemaSchema,\n definitions: z.array(z.object({\n traitId: z.string(),\n definitionFingerprint: z.string(),\n sourceDeclaration: SourceDeclarationMetadataSchema.extend({ path: z.string().nullable() }).nullable(),\n sourceCandidates: z.array(z.string()),\n })),\n composition: z.array(z.object({ traitId: z.string(), kind: z.enum(['trait-declaration', 'orbital-reference']), authoredPointer: z.string(), traitOverrideKey: z.string().nullable(), binding: JsonValueSchema, source: ProgramSourceLocationSchema.nullable() })),\n sourceMap: z.array(ProgramSourceAnchorSchema),\n imports: z.array(z.object({ path: z.string(), specifier: z.string(), program: z.string(), authoredProgram: OrbitalSchemaSchema })),\n lazy: z.array(JsonValueSchema),\n path: z.string(),\n version: z.number().int().nonnegative().nullable(),\n columnEncoding: z.literal('unicode-scalar'),\n lengthEncoding: z.literal('utf-8-bytes'),\n lineBase: z.literal(1),\n columnBase: z.literal(1),\n});\n\nexport type ProgramSourceLocation = z.infer<typeof ProgramSourceLocationSchema>;\nexport type ProgramSourceAnchor = z.infer<typeof ProgramSourceAnchorSchema>;\nexport type ProgramInspection = z.infer<typeof ProgramInspectionSchema>;\n"]}