@almadar/core 10.28.0 → 10.29.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.
@@ -1,5 +1,5 @@
1
- import { A as AnyPatternConfig, b as EntityRow, c as Entity, E as EntityField } from './pattern-types-BeQXwgpZ.js';
2
- import { S as SExpr, E as EventPayload, a as Expression } from './expression-C6X4A8L7.js';
1
+ import { A as AnyPatternConfig, b as EntityRow, c as Entity, E as EntityField } from './pattern-types-JZordBZv.js';
2
+ import { S as SExpr, E as EventPayload, a as Expression } from './expression-CB9R3KWk.js';
3
3
  import { z } from 'zod';
4
4
 
5
5
  /**
@@ -805,7 +805,7 @@ type RenderItemLambda = ['fn', string, AnyPatternConfig];
805
805
  * @example ['navigate', '/tasks'] or ['navigate', '/tasks/:id', { id: '123' }]
806
806
  * @example ['navigate', 'https://example.com']
807
807
  */
808
- type NavigateEffect = ['navigate', string] | ['navigate', string, Record<string, string>];
808
+ type NavigateEffect = ['navigate', string | SExpr] | ['navigate', string | SExpr, Record<string, string>];
809
809
  /**
810
810
  * Emit effect - emits an event, optionally with payload.
811
811
  * @example ['emit', 'SAVE'] or ['emit', 'PLAYER_DIED', { playerId: '@entity.id' }]
@@ -1147,6 +1147,43 @@ type AgentEffect = [`agent/${string}`, ...SExpr[]];
1147
1147
  * @example ['os/read-file', '/etc/hosts']
1148
1148
  */
1149
1149
  type OsEffect = [`os/${string}`, ...SExpr[]];
1150
+ /**
1151
+ * Browser effect - invokes a browser/* device operator (client host path).
1152
+ * User-initiated, async, resolves via the standard trailing emit envelope.
1153
+ * Concrete operators (browser/open-file-picker, browser/clipboard-read,
1154
+ * browser/clipboard-write, browser/geolocation-current) and their arity /
1155
+ * payload shapes live in @almadar/std BROWSER_OPERATORS.
1156
+ * @example ['browser/open-file-picker', { multiple: false }, { emit: { success: 'FILES_PICKED', failure: 'PICK_CANCELLED' } }]
1157
+ */
1158
+ type BrowserEffect = [`browser/${string}`, ...SExpr[]];
1159
+ /**
1160
+ * LLM effect - invokes an llm/* operator (agent path).
1161
+ * @example ['llm/generate', '@entity.request', { emit: { success: 'PLANNED', failure: 'PLAN_FAILED' } }]
1162
+ */
1163
+ type LlmEffect = [`llm/${string}`, ...SExpr[]];
1164
+ /**
1165
+ * Behavior effect - invokes a behavior/* operator (agent path).
1166
+ * @example ['behavior/instantiate', '@entity.plan', { emit: { failure: 'BUILD_FAILED' } }]
1167
+ */
1168
+ type BehaviorEffect = [`behavior/${string}`, ...SExpr[]];
1169
+ /**
1170
+ * Validate effect - invokes a validate/* operator (agent path).
1171
+ * @example ['validate/validate', '@entity.schema', { emit: { failure: 'INVALID' } }]
1172
+ */
1173
+ type ValidateEffect = [`validate/${string}`, ...SExpr[]];
1174
+ /**
1175
+ * Remaining agent-path operator effects: session/* (workspace session ops),
1176
+ * compose/* (schema composition), trace/* (trace emission), memory/*
1177
+ * (agent memory), application/* (app lifecycle). Expression-only namespaces
1178
+ * (array/, math/, object/, str/, …) are deliberately NOT effect heads.
1179
+ * @example ['session/write-spec', '@entity.spec']
1180
+ * @example ['compose/compose-all', { emit: { failure: 'COMPOSE_FAILED' } }]
1181
+ */
1182
+ type SessionEffect = [`session/${string}`, ...SExpr[]];
1183
+ type ComposeEffect = [`compose/${string}`, ...SExpr[]];
1184
+ type TraceEffect = [`trace/${string}`, ...SExpr[]];
1185
+ type MemoryEffect = [`memory/${string}`, ...SExpr[]];
1186
+ type ApplicationEffect = [`application/${string}`, ...SExpr[]];
1150
1187
  /**
1151
1188
  * Async delay effect - wait then execute effects.
1152
1189
  * @example ['async/delay', 2000, ['emit', 'TIMEOUT']]
@@ -1189,7 +1226,7 @@ type AsyncSequenceEffect = ['async/sequence', ...Effect[]];
1189
1226
  * Union of all typed effects.
1190
1227
  * Provides compile-time validation for common effect types.
1191
1228
  */
1192
- type TypedEffect = RenderUIEffect | NavigateEffect | EmitEffect | SetEffect | PersistEffect | CallServiceEffect | SpawnEffect | DespawnEffect | DoEffect | NotifyEffect | FetchEffect | IfEffect | WhenEffect | LetEffect | LogEffect | WaitEffect | RefEffect | DerefEffect | SwapEffect | WatchEffect | AtomicEffect | AsyncDelayEffect | AsyncDebounceEffect | AsyncThrottleEffect | AsyncIntervalEffect | AsyncRaceEffect | AsyncAllEffect | AsyncSequenceEffect | ForwardEffect | TrainEffect | EvaluateEffect | CheckpointSaveEffect | CheckpointLoadEffect | AgentEffect | OsEffect;
1229
+ type TypedEffect = RenderUIEffect | NavigateEffect | EmitEffect | SetEffect | PersistEffect | CallServiceEffect | SpawnEffect | DespawnEffect | DoEffect | NotifyEffect | FetchEffect | IfEffect | WhenEffect | LetEffect | LogEffect | WaitEffect | RefEffect | DerefEffect | SwapEffect | WatchEffect | AtomicEffect | AsyncDelayEffect | AsyncDebounceEffect | AsyncThrottleEffect | AsyncIntervalEffect | AsyncRaceEffect | AsyncAllEffect | AsyncSequenceEffect | ForwardEffect | TrainEffect | EvaluateEffect | CheckpointSaveEffect | CheckpointLoadEffect | AgentEffect | OsEffect | BrowserEffect | LlmEffect | BehaviorEffect | ValidateEffect | SessionEffect | ComposeEffect | TraceEffect | MemoryEffect | ApplicationEffect;
1193
1230
  /**
1194
1231
  * Effect type - typed S-expression format.
1195
1232
  *
@@ -1460,20 +1497,10 @@ interface PayloadField {
1460
1497
  */
1461
1498
  type: string;
1462
1499
  required?: boolean;
1500
+ /** Structured property schema for object-typed payload fields (recursive). */
1501
+ properties?: ReadonlyArray<PayloadField>;
1463
1502
  }
1464
- declare const PayloadFieldSchema: z.ZodObject<{
1465
- name: z.ZodString;
1466
- type: z.ZodString;
1467
- required: z.ZodOptional<z.ZodBoolean>;
1468
- }, "strip", z.ZodTypeAny, {
1469
- type: string;
1470
- name: string;
1471
- required?: boolean | undefined;
1472
- }, {
1473
- type: string;
1474
- name: string;
1475
- required?: boolean | undefined;
1476
- }>;
1503
+ declare const PayloadFieldSchema: z.ZodType<PayloadField>;
1477
1504
  /**
1478
1505
  * Represents an event that can trigger transitions
1479
1506
  */
@@ -1502,19 +1529,7 @@ declare const EventSchema: z.ZodObject<{
1502
1529
  description: z.ZodOptional<z.ZodString>;
1503
1530
  synonyms: z.ZodOptional<z.ZodString>;
1504
1531
  tier: z.ZodOptional<z.ZodString>;
1505
- payloadSchema: z.ZodOptional<z.ZodArray<z.ZodObject<{
1506
- name: z.ZodString;
1507
- type: z.ZodString;
1508
- required: z.ZodOptional<z.ZodBoolean>;
1509
- }, "strip", z.ZodTypeAny, {
1510
- type: string;
1511
- name: string;
1512
- required?: boolean | undefined;
1513
- }, {
1514
- type: string;
1515
- name: string;
1516
- required?: boolean | undefined;
1517
- }>, "many">>;
1532
+ payloadSchema: z.ZodOptional<z.ZodArray<z.ZodType<PayloadField, z.ZodTypeDef, PayloadField>, "many">>;
1518
1533
  classification: z.ZodOptional<z.ZodEnum<["domain", "system"]>>;
1519
1534
  semanticRole: z.ZodOptional<z.ZodString>;
1520
1535
  }, "strip", z.ZodTypeAny, {
@@ -1523,11 +1538,7 @@ declare const EventSchema: z.ZodObject<{
1523
1538
  description?: string | undefined;
1524
1539
  synonyms?: string | undefined;
1525
1540
  tier?: string | undefined;
1526
- payloadSchema?: {
1527
- type: string;
1528
- name: string;
1529
- required?: boolean | undefined;
1530
- }[] | undefined;
1541
+ payloadSchema?: PayloadField[] | undefined;
1531
1542
  classification?: "domain" | "system" | undefined;
1532
1543
  semanticRole?: string | undefined;
1533
1544
  }, {
@@ -1536,11 +1547,7 @@ declare const EventSchema: z.ZodObject<{
1536
1547
  description?: string | undefined;
1537
1548
  synonyms?: string | undefined;
1538
1549
  tier?: string | undefined;
1539
- payloadSchema?: {
1540
- type: string;
1541
- name: string;
1542
- required?: boolean | undefined;
1543
- }[] | undefined;
1550
+ payloadSchema?: PayloadField[] | undefined;
1544
1551
  classification?: "domain" | "system" | undefined;
1545
1552
  semanticRole?: string | undefined;
1546
1553
  }>;
@@ -1671,19 +1678,7 @@ declare const StateMachineSchema: z.ZodObject<{
1671
1678
  description: z.ZodOptional<z.ZodString>;
1672
1679
  synonyms: z.ZodOptional<z.ZodString>;
1673
1680
  tier: z.ZodOptional<z.ZodString>;
1674
- payloadSchema: z.ZodOptional<z.ZodArray<z.ZodObject<{
1675
- name: z.ZodString;
1676
- type: z.ZodString;
1677
- required: z.ZodOptional<z.ZodBoolean>;
1678
- }, "strip", z.ZodTypeAny, {
1679
- type: string;
1680
- name: string;
1681
- required?: boolean | undefined;
1682
- }, {
1683
- type: string;
1684
- name: string;
1685
- required?: boolean | undefined;
1686
- }>, "many">>;
1681
+ payloadSchema: z.ZodOptional<z.ZodArray<z.ZodType<PayloadField, z.ZodTypeDef, PayloadField>, "many">>;
1687
1682
  classification: z.ZodOptional<z.ZodEnum<["domain", "system"]>>;
1688
1683
  semanticRole: z.ZodOptional<z.ZodString>;
1689
1684
  }, "strip", z.ZodTypeAny, {
@@ -1692,11 +1687,7 @@ declare const StateMachineSchema: z.ZodObject<{
1692
1687
  description?: string | undefined;
1693
1688
  synonyms?: string | undefined;
1694
1689
  tier?: string | undefined;
1695
- payloadSchema?: {
1696
- type: string;
1697
- name: string;
1698
- required?: boolean | undefined;
1699
- }[] | undefined;
1690
+ payloadSchema?: PayloadField[] | undefined;
1700
1691
  classification?: "domain" | "system" | undefined;
1701
1692
  semanticRole?: string | undefined;
1702
1693
  }, {
@@ -1705,11 +1696,7 @@ declare const StateMachineSchema: z.ZodObject<{
1705
1696
  description?: string | undefined;
1706
1697
  synonyms?: string | undefined;
1707
1698
  tier?: string | undefined;
1708
- payloadSchema?: {
1709
- type: string;
1710
- name: string;
1711
- required?: boolean | undefined;
1712
- }[] | undefined;
1699
+ payloadSchema?: PayloadField[] | undefined;
1713
1700
  classification?: "domain" | "system" | undefined;
1714
1701
  semanticRole?: string | undefined;
1715
1702
  }>, "many">;
@@ -1755,11 +1742,7 @@ declare const StateMachineSchema: z.ZodObject<{
1755
1742
  description?: string | undefined;
1756
1743
  synonyms?: string | undefined;
1757
1744
  tier?: string | undefined;
1758
- payloadSchema?: {
1759
- type: string;
1760
- name: string;
1761
- required?: boolean | undefined;
1762
- }[] | undefined;
1745
+ payloadSchema?: PayloadField[] | undefined;
1763
1746
  classification?: "domain" | "system" | undefined;
1764
1747
  semanticRole?: string | undefined;
1765
1748
  }[];
@@ -1792,11 +1775,7 @@ declare const StateMachineSchema: z.ZodObject<{
1792
1775
  description?: string | undefined;
1793
1776
  synonyms?: string | undefined;
1794
1777
  tier?: string | undefined;
1795
- payloadSchema?: {
1796
- type: string;
1797
- name: string;
1798
- required?: boolean | undefined;
1799
- }[] | undefined;
1778
+ payloadSchema?: PayloadField[] | undefined;
1800
1779
  classification?: "domain" | "system" | undefined;
1801
1780
  semanticRole?: string | undefined;
1802
1781
  }[];
@@ -1890,6 +1869,23 @@ type CallSiteConfig = Readonly<Record<string, CallSiteConfigEntry>>;
1890
1869
  * not a `FieldDefinition`).
1891
1870
  */
1892
1871
  declare function isCallSiteConfigDeclaration(entry: CallSiteConfigEntry): entry is ConfigFieldDeclaration;
1872
+ /**
1873
+ * Convert a call-site config map into plain runtime values.
1874
+ *
1875
+ * A `CallSiteConfig` may contain either plain wiring values
1876
+ * (`TraitConfigValue`) or annotated `ConfigFieldDeclaration` objects
1877
+ * (`{ type, default, label, ... }`). Both the JS interpreter
1878
+ * (`@almadar/runtime`) and the render substrate (`@almadar/ui`) need this
1879
+ * extraction, so it lives here — the most-upstream package they share —
1880
+ * rather than being duplicated in each.
1881
+ *
1882
+ * A declared field with no `default` yields no value (dropped) — mirroring
1883
+ * `collectDeclaredConfigDefaults`. Leaking such a schema object through as a
1884
+ * value made `@config.leftIcon` resolve to `{ type: "icon", … }`, which the
1885
+ * render substrate then mounted as an element and passed to `Input`'s icon
1886
+ * slot → "Element type is invalid: got <SlotContentRenderer />".
1887
+ */
1888
+ declare function normalizeCallSiteConfigToValues(config: CallSiteConfig | undefined): TraitConfig | undefined;
1893
1889
  /**
1894
1890
  * Per-field entry in a trait's DECLARED `config { }` schema as it lives
1895
1891
  * on the `.orb` JSON: `{ type: "string" | "[string]" | "object" | ...,
@@ -1907,6 +1903,8 @@ declare function isCallSiteConfigDeclaration(entry: CallSiteConfigEntry): entry
1907
1903
  interface ConfigFieldDeclaration {
1908
1904
  readonly type: string;
1909
1905
  readonly default?: TraitConfigValue;
1906
+ /** Marks the knob as mandatory at every call site (own-page binding exempt). `required` + `default` may coexist — the default only serves the trait's own demo page. */
1907
+ readonly required?: boolean;
1910
1908
  /** `@label` — human-readable control label. */
1911
1909
  readonly label?: string;
1912
1910
  /** `@description` — help/tooltip text for the field. */
@@ -1917,6 +1915,17 @@ interface ConfigFieldDeclaration {
1917
1915
  readonly values?: ReadonlyArray<string>;
1918
1916
  /** `@synonyms` — comma-separated vocabulary synonyms (metadata). */
1919
1917
  readonly synonyms?: string;
1918
+ /** Structured per-item schema for array-of-object fields — `edges : [{from: string!, …}]` in `.lolo` lowers to `{ type: "object", properties: {…} }`. */
1919
+ readonly items?: ConfigFieldItemsDeclaration;
1920
+ /** Structured property schema for object-typed config fields (no items wrapper). */
1921
+ readonly properties?: Readonly<Record<string, TraitEntityField>>;
1922
+ }
1923
+ interface ConfigFieldItemsDeclaration {
1924
+ readonly type?: string;
1925
+ /** Absent for arrays of scalars (`items: { type: "string" }`). */
1926
+ readonly properties?: Readonly<Record<string, TraitEntityField>>;
1927
+ /** Nested per-item schema for arrays of arrays (recursive). */
1928
+ readonly items?: ConfigFieldItemsDeclaration;
1920
1929
  }
1921
1930
  declare const ConfigFieldDeclarationSchema: z.ZodType<ConfigFieldDeclaration>;
1922
1931
  /**
@@ -1944,26 +1953,12 @@ interface TraitEntityField {
1944
1953
  required?: boolean;
1945
1954
  default?: unknown;
1946
1955
  values?: string[];
1956
+ /** Structured per-item schema for array-of-object fields (recursive). */
1957
+ items?: ConfigFieldItemsDeclaration;
1958
+ /** Structured property schema for object-typed entity fields. */
1959
+ properties?: Readonly<Record<string, TraitEntityField>>;
1947
1960
  }
1948
- declare const TraitEntityFieldSchema: z.ZodObject<{
1949
- name: z.ZodString;
1950
- type: z.ZodEnum<["string", "number", "boolean", "date", "array", "object", "timestamp", "datetime", "enum"]>;
1951
- required: z.ZodOptional<z.ZodBoolean>;
1952
- default: z.ZodOptional<z.ZodUnknown>;
1953
- values: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1954
- }, "strip", z.ZodTypeAny, {
1955
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
1956
- name: string;
1957
- values?: string[] | undefined;
1958
- required?: boolean | undefined;
1959
- default?: unknown;
1960
- }, {
1961
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
1962
- name: string;
1963
- values?: string[] | undefined;
1964
- required?: boolean | undefined;
1965
- default?: unknown;
1966
- }>;
1961
+ declare const TraitEntityFieldSchema: z.ZodType<TraitEntityField>;
1967
1962
  /**
1968
1963
  * Simplified data entity for traits
1969
1964
  */
@@ -1980,25 +1975,7 @@ interface TraitDataEntity {
1980
1975
  declare const TraitDataEntitySchema: z.ZodObject<{
1981
1976
  name: z.ZodString;
1982
1977
  collection: z.ZodOptional<z.ZodString>;
1983
- fields: z.ZodArray<z.ZodObject<{
1984
- name: z.ZodString;
1985
- type: z.ZodEnum<["string", "number", "boolean", "date", "array", "object", "timestamp", "datetime", "enum"]>;
1986
- required: z.ZodOptional<z.ZodBoolean>;
1987
- default: z.ZodOptional<z.ZodUnknown>;
1988
- values: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1989
- }, "strip", z.ZodTypeAny, {
1990
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
1991
- name: string;
1992
- values?: string[] | undefined;
1993
- required?: boolean | undefined;
1994
- default?: unknown;
1995
- }, {
1996
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
1997
- name: string;
1998
- values?: string[] | undefined;
1999
- required?: boolean | undefined;
2000
- default?: unknown;
2001
- }>, "many">;
1978
+ fields: z.ZodArray<z.ZodType<TraitEntityField, z.ZodTypeDef, TraitEntityField>, "many">;
2002
1979
  timestamps: z.ZodOptional<z.ZodBoolean>;
2003
1980
  description: z.ZodOptional<z.ZodString>;
2004
1981
  runtime: z.ZodOptional<z.ZodBoolean>;
@@ -2006,13 +1983,7 @@ declare const TraitDataEntitySchema: z.ZodObject<{
2006
1983
  pages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
2007
1984
  }, "strip", z.ZodTypeAny, {
2008
1985
  name: string;
2009
- fields: {
2010
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
2011
- name: string;
2012
- values?: string[] | undefined;
2013
- required?: boolean | undefined;
2014
- default?: unknown;
2015
- }[];
1986
+ fields: TraitEntityField[];
2016
1987
  description?: string | undefined;
2017
1988
  runtime?: boolean | undefined;
2018
1989
  collection?: string | undefined;
@@ -2021,13 +1992,7 @@ declare const TraitDataEntitySchema: z.ZodObject<{
2021
1992
  singleton?: boolean | undefined;
2022
1993
  }, {
2023
1994
  name: string;
2024
- fields: {
2025
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
2026
- name: string;
2027
- values?: string[] | undefined;
2028
- required?: boolean | undefined;
2029
- default?: unknown;
2030
- }[];
1995
+ fields: TraitEntityField[];
2031
1996
  description?: string | undefined;
2032
1997
  runtime?: boolean | undefined;
2033
1998
  collection?: string | undefined;
@@ -2121,36 +2086,10 @@ interface EventPayloadField {
2121
2086
  description?: string;
2122
2087
  /** For 'entity' type: the entity type name */
2123
2088
  entityType?: string;
2089
+ /** Structured property schema for object-typed payload fields (recursive). */
2090
+ properties?: ReadonlyArray<EventPayloadField>;
2124
2091
  }
2125
- declare const EventPayloadFieldSchema: z.ZodObject<{
2126
- name: z.ZodString;
2127
- /**
2128
- * Field type. Mirrors the Rust validator's acceptance: any non-empty
2129
- * string. Primitives ('string' | 'number' | 'boolean' | 'object' |
2130
- * 'array') are the canonical values; entity-name references like
2131
- * 'ModalRecord' and array-of-entity references like '[ModalRecord]'
2132
- * are also valid because the Rust IR's PayloadField.field_type is
2133
- * just a String. Only enforced narrowly at the call site (e.g.
2134
- * emit-literal type-mismatch warnings in
2135
- * orbital-compiler/phases/validation/emit_payload.rs) — not here.
2136
- */
2137
- type: z.ZodString;
2138
- required: z.ZodOptional<z.ZodBoolean>;
2139
- description: z.ZodOptional<z.ZodString>;
2140
- entityType: z.ZodOptional<z.ZodString>;
2141
- }, "strip", z.ZodTypeAny, {
2142
- type: string;
2143
- name: string;
2144
- required?: boolean | undefined;
2145
- description?: string | undefined;
2146
- entityType?: string | undefined;
2147
- }, {
2148
- type: string;
2149
- name: string;
2150
- required?: boolean | undefined;
2151
- description?: string | undefined;
2152
- entityType?: string | undefined;
2153
- }>;
2092
+ declare const EventPayloadFieldSchema: z.ZodType<EventPayloadField>;
2154
2093
  /**
2155
2094
  * Event contract for events a trait emits.
2156
2095
  * Declares the event name, scope, and payload schema.
@@ -2176,47 +2115,48 @@ interface TraitEventContract {
2176
2115
  */
2177
2116
  scope?: EventScope;
2178
2117
  }
2118
+ /**
2119
+ * `@config.<knob>` is the only legal reference form for an emit/listen
2120
+ * event name (Option B — the declared event name resolves to a
2121
+ * string-typed config knob's value at inline/resolve time). Matches the
2122
+ * Rust lexer's dotted-sigil body (`config.<ident>`, no further dots).
2123
+ */
2124
+ declare const CONFIG_REF_EVENT_PATTERN: RegExp;
2125
+ /** Returns the knob identifier when `event` is a `@config.<knob>` reference, else `undefined`. */
2126
+ declare function configRefEventKnob(event: string): string | undefined;
2127
+ /** Why a `@config.<knob>` emit/listen event-name reference failed to resolve. */
2128
+ type ConfigRefEventError = 'unknown-knob' | 'not-string' | 'no-default';
2129
+ /**
2130
+ * Resolve a `@config.<knob>` emit/listen event-name reference to its
2131
+ * concrete literal, given the trait's declared config schema and the
2132
+ * effective config value map (call-site override folded over declared
2133
+ * default — same precedence the Rust inline phase's `effective_config`
2134
+ * uses). The single JS-side owner of this resolution rule; mirrors
2135
+ * `resolve_config_ref_event_name` in `orbital-core::schema` (Rust).
2136
+ * Returns the resolved literal, or the specific contract clause that failed.
2137
+ */
2138
+ declare function resolveConfigRefEventName(event: string, declaredConfig: DeclaredTraitConfig | undefined, effectiveConfig: Readonly<Record<string, TraitConfigValue>>): {
2139
+ readonly ok: true;
2140
+ readonly value: string;
2141
+ } | {
2142
+ readonly ok: false;
2143
+ readonly error: ConfigRefEventError;
2144
+ };
2179
2145
  declare const TraitEventContractSchema: z.ZodObject<{
2180
2146
  /**
2181
2147
  * Event name. Mirrors the Rust validator's `is_valid_event_identifier`:
2182
2148
  * starts with a letter, then any letters / digits / underscores. Both
2183
2149
  * UPPER_SNAKE_CASE and PascalCase shapes are valid identifiers in the
2184
2150
  * post-Phase 2.5 nominal-event type system (events declared via
2185
- * `type X = Event<T>`).
2151
+ * `type X = Event<T>`). A pre-resolution `@config.<knob>` reference
2152
+ * (Option B) is also legal — inline/resolve substitutes it with the
2153
+ * knob's effective literal before codegen/runtime consume it.
2186
2154
  */
2187
2155
  event: z.ZodString;
2188
2156
  description: z.ZodOptional<z.ZodString>;
2189
2157
  synonyms: z.ZodOptional<z.ZodString>;
2190
2158
  tier: z.ZodOptional<z.ZodString>;
2191
- payloadSchema: z.ZodOptional<z.ZodArray<z.ZodObject<{
2192
- name: z.ZodString;
2193
- /**
2194
- * Field type. Mirrors the Rust validator's acceptance: any non-empty
2195
- * string. Primitives ('string' | 'number' | 'boolean' | 'object' |
2196
- * 'array') are the canonical values; entity-name references like
2197
- * 'ModalRecord' and array-of-entity references like '[ModalRecord]'
2198
- * are also valid because the Rust IR's PayloadField.field_type is
2199
- * just a String. Only enforced narrowly at the call site (e.g.
2200
- * emit-literal type-mismatch warnings in
2201
- * orbital-compiler/phases/validation/emit_payload.rs) — not here.
2202
- */
2203
- type: z.ZodString;
2204
- required: z.ZodOptional<z.ZodBoolean>;
2205
- description: z.ZodOptional<z.ZodString>;
2206
- entityType: z.ZodOptional<z.ZodString>;
2207
- }, "strip", z.ZodTypeAny, {
2208
- type: string;
2209
- name: string;
2210
- required?: boolean | undefined;
2211
- description?: string | undefined;
2212
- entityType?: string | undefined;
2213
- }, {
2214
- type: string;
2215
- name: string;
2216
- required?: boolean | undefined;
2217
- description?: string | undefined;
2218
- entityType?: string | undefined;
2219
- }>, "many">>;
2159
+ payloadSchema: z.ZodOptional<z.ZodArray<z.ZodType<EventPayloadField, z.ZodTypeDef, EventPayloadField>, "many">>;
2220
2160
  scope: z.ZodOptional<z.ZodEnum<["internal", "external"]>>;
2221
2161
  }, "strip", z.ZodTypeAny, {
2222
2162
  event: string;
@@ -2224,26 +2164,14 @@ declare const TraitEventContractSchema: z.ZodObject<{
2224
2164
  synonyms?: string | undefined;
2225
2165
  scope?: "internal" | "external" | undefined;
2226
2166
  tier?: string | undefined;
2227
- payloadSchema?: {
2228
- type: string;
2229
- name: string;
2230
- required?: boolean | undefined;
2231
- description?: string | undefined;
2232
- entityType?: string | undefined;
2233
- }[] | undefined;
2167
+ payloadSchema?: EventPayloadField[] | undefined;
2234
2168
  }, {
2235
2169
  event: string;
2236
2170
  description?: string | undefined;
2237
2171
  synonyms?: string | undefined;
2238
2172
  scope?: "internal" | "external" | undefined;
2239
2173
  tier?: string | undefined;
2240
- payloadSchema?: {
2241
- type: string;
2242
- name: string;
2243
- required?: boolean | undefined;
2244
- description?: string | undefined;
2245
- entityType?: string | undefined;
2246
- }[] | undefined;
2174
+ payloadSchema?: EventPayloadField[] | undefined;
2247
2175
  }>;
2248
2176
  /**
2249
2177
  * Event listener for trait communication.
@@ -2788,25 +2716,7 @@ declare const TraitSchema: z.ZodObject<{
2788
2716
  dataEntities: z.ZodOptional<z.ZodArray<z.ZodObject<{
2789
2717
  name: z.ZodString;
2790
2718
  collection: z.ZodOptional<z.ZodString>;
2791
- fields: z.ZodArray<z.ZodObject<{
2792
- name: z.ZodString;
2793
- type: z.ZodEnum<["string", "number", "boolean", "date", "array", "object", "timestamp", "datetime", "enum"]>;
2794
- required: z.ZodOptional<z.ZodBoolean>;
2795
- default: z.ZodOptional<z.ZodUnknown>;
2796
- values: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
2797
- }, "strip", z.ZodTypeAny, {
2798
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
2799
- name: string;
2800
- values?: string[] | undefined;
2801
- required?: boolean | undefined;
2802
- default?: unknown;
2803
- }, {
2804
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
2805
- name: string;
2806
- values?: string[] | undefined;
2807
- required?: boolean | undefined;
2808
- default?: unknown;
2809
- }>, "many">;
2719
+ fields: z.ZodArray<z.ZodType<TraitEntityField, z.ZodTypeDef, TraitEntityField>, "many">;
2810
2720
  timestamps: z.ZodOptional<z.ZodBoolean>;
2811
2721
  description: z.ZodOptional<z.ZodString>;
2812
2722
  runtime: z.ZodOptional<z.ZodBoolean>;
@@ -2814,13 +2724,7 @@ declare const TraitSchema: z.ZodObject<{
2814
2724
  pages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
2815
2725
  }, "strip", z.ZodTypeAny, {
2816
2726
  name: string;
2817
- fields: {
2818
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
2819
- name: string;
2820
- values?: string[] | undefined;
2821
- required?: boolean | undefined;
2822
- default?: unknown;
2823
- }[];
2727
+ fields: TraitEntityField[];
2824
2728
  description?: string | undefined;
2825
2729
  runtime?: boolean | undefined;
2826
2730
  collection?: string | undefined;
@@ -2829,13 +2733,7 @@ declare const TraitSchema: z.ZodObject<{
2829
2733
  singleton?: boolean | undefined;
2830
2734
  }, {
2831
2735
  name: string;
2832
- fields: {
2833
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
2834
- name: string;
2835
- values?: string[] | undefined;
2836
- required?: boolean | undefined;
2837
- default?: unknown;
2838
- }[];
2736
+ fields: TraitEntityField[];
2839
2737
  description?: string | undefined;
2840
2738
  runtime?: boolean | undefined;
2841
2739
  collection?: string | undefined;
@@ -2875,19 +2773,7 @@ declare const TraitSchema: z.ZodObject<{
2875
2773
  description: z.ZodOptional<z.ZodString>;
2876
2774
  synonyms: z.ZodOptional<z.ZodString>;
2877
2775
  tier: z.ZodOptional<z.ZodString>;
2878
- payloadSchema: z.ZodOptional<z.ZodArray<z.ZodObject<{
2879
- name: z.ZodString;
2880
- type: z.ZodString;
2881
- required: z.ZodOptional<z.ZodBoolean>;
2882
- }, "strip", z.ZodTypeAny, {
2883
- type: string;
2884
- name: string;
2885
- required?: boolean | undefined;
2886
- }, {
2887
- type: string;
2888
- name: string;
2889
- required?: boolean | undefined;
2890
- }>, "many">>;
2776
+ payloadSchema: z.ZodOptional<z.ZodArray<z.ZodType<PayloadField, z.ZodTypeDef, PayloadField>, "many">>;
2891
2777
  classification: z.ZodOptional<z.ZodEnum<["domain", "system"]>>;
2892
2778
  semanticRole: z.ZodOptional<z.ZodString>;
2893
2779
  }, "strip", z.ZodTypeAny, {
@@ -2896,11 +2782,7 @@ declare const TraitSchema: z.ZodObject<{
2896
2782
  description?: string | undefined;
2897
2783
  synonyms?: string | undefined;
2898
2784
  tier?: string | undefined;
2899
- payloadSchema?: {
2900
- type: string;
2901
- name: string;
2902
- required?: boolean | undefined;
2903
- }[] | undefined;
2785
+ payloadSchema?: PayloadField[] | undefined;
2904
2786
  classification?: "domain" | "system" | undefined;
2905
2787
  semanticRole?: string | undefined;
2906
2788
  }, {
@@ -2909,11 +2791,7 @@ declare const TraitSchema: z.ZodObject<{
2909
2791
  description?: string | undefined;
2910
2792
  synonyms?: string | undefined;
2911
2793
  tier?: string | undefined;
2912
- payloadSchema?: {
2913
- type: string;
2914
- name: string;
2915
- required?: boolean | undefined;
2916
- }[] | undefined;
2794
+ payloadSchema?: PayloadField[] | undefined;
2917
2795
  classification?: "domain" | "system" | undefined;
2918
2796
  semanticRole?: string | undefined;
2919
2797
  }>, "many">;
@@ -2959,11 +2837,7 @@ declare const TraitSchema: z.ZodObject<{
2959
2837
  description?: string | undefined;
2960
2838
  synonyms?: string | undefined;
2961
2839
  tier?: string | undefined;
2962
- payloadSchema?: {
2963
- type: string;
2964
- name: string;
2965
- required?: boolean | undefined;
2966
- }[] | undefined;
2840
+ payloadSchema?: PayloadField[] | undefined;
2967
2841
  classification?: "domain" | "system" | undefined;
2968
2842
  semanticRole?: string | undefined;
2969
2843
  }[];
@@ -2996,11 +2870,7 @@ declare const TraitSchema: z.ZodObject<{
2996
2870
  description?: string | undefined;
2997
2871
  synonyms?: string | undefined;
2998
2872
  tier?: string | undefined;
2999
- payloadSchema?: {
3000
- type: string;
3001
- name: string;
3002
- required?: boolean | undefined;
3003
- }[] | undefined;
2873
+ payloadSchema?: PayloadField[] | undefined;
3004
2874
  classification?: "domain" | "system" | undefined;
3005
2875
  semanticRole?: string | undefined;
3006
2876
  }[];
@@ -3065,41 +2935,15 @@ declare const TraitSchema: z.ZodObject<{
3065
2935
  * starts with a letter, then any letters / digits / underscores. Both
3066
2936
  * UPPER_SNAKE_CASE and PascalCase shapes are valid identifiers in the
3067
2937
  * post-Phase 2.5 nominal-event type system (events declared via
3068
- * `type X = Event<T>`).
2938
+ * `type X = Event<T>`). A pre-resolution `@config.<knob>` reference
2939
+ * (Option B) is also legal — inline/resolve substitutes it with the
2940
+ * knob's effective literal before codegen/runtime consume it.
3069
2941
  */
3070
2942
  event: z.ZodString;
3071
2943
  description: z.ZodOptional<z.ZodString>;
3072
2944
  synonyms: z.ZodOptional<z.ZodString>;
3073
2945
  tier: z.ZodOptional<z.ZodString>;
3074
- payloadSchema: z.ZodOptional<z.ZodArray<z.ZodObject<{
3075
- name: z.ZodString;
3076
- /**
3077
- * Field type. Mirrors the Rust validator's acceptance: any non-empty
3078
- * string. Primitives ('string' | 'number' | 'boolean' | 'object' |
3079
- * 'array') are the canonical values; entity-name references like
3080
- * 'ModalRecord' and array-of-entity references like '[ModalRecord]'
3081
- * are also valid because the Rust IR's PayloadField.field_type is
3082
- * just a String. Only enforced narrowly at the call site (e.g.
3083
- * emit-literal type-mismatch warnings in
3084
- * orbital-compiler/phases/validation/emit_payload.rs) — not here.
3085
- */
3086
- type: z.ZodString;
3087
- required: z.ZodOptional<z.ZodBoolean>;
3088
- description: z.ZodOptional<z.ZodString>;
3089
- entityType: z.ZodOptional<z.ZodString>;
3090
- }, "strip", z.ZodTypeAny, {
3091
- type: string;
3092
- name: string;
3093
- required?: boolean | undefined;
3094
- description?: string | undefined;
3095
- entityType?: string | undefined;
3096
- }, {
3097
- type: string;
3098
- name: string;
3099
- required?: boolean | undefined;
3100
- description?: string | undefined;
3101
- entityType?: string | undefined;
3102
- }>, "many">>;
2946
+ payloadSchema: z.ZodOptional<z.ZodArray<z.ZodType<EventPayloadField, z.ZodTypeDef, EventPayloadField>, "many">>;
3103
2947
  scope: z.ZodOptional<z.ZodEnum<["internal", "external"]>>;
3104
2948
  }, "strip", z.ZodTypeAny, {
3105
2949
  event: string;
@@ -3107,26 +2951,14 @@ declare const TraitSchema: z.ZodObject<{
3107
2951
  synonyms?: string | undefined;
3108
2952
  scope?: "internal" | "external" | undefined;
3109
2953
  tier?: string | undefined;
3110
- payloadSchema?: {
3111
- type: string;
3112
- name: string;
3113
- required?: boolean | undefined;
3114
- description?: string | undefined;
3115
- entityType?: string | undefined;
3116
- }[] | undefined;
2954
+ payloadSchema?: EventPayloadField[] | undefined;
3117
2955
  }, {
3118
2956
  event: string;
3119
2957
  description?: string | undefined;
3120
2958
  synonyms?: string | undefined;
3121
2959
  scope?: "internal" | "external" | undefined;
3122
2960
  tier?: string | undefined;
3123
- payloadSchema?: {
3124
- type: string;
3125
- name: string;
3126
- required?: boolean | undefined;
3127
- description?: string | undefined;
3128
- entityType?: string | undefined;
3129
- }[] | undefined;
2961
+ payloadSchema?: EventPayloadField[] | undefined;
3130
2962
  }>, "many">>;
3131
2963
  listens: z.ZodOptional<z.ZodArray<z.ZodObject<{
3132
2964
  event: z.ZodString;
@@ -3306,13 +3138,7 @@ declare const TraitSchema: z.ZodObject<{
3306
3138
  capabilities?: string[] | undefined;
3307
3139
  dataEntities?: {
3308
3140
  name: string;
3309
- fields: {
3310
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
3311
- name: string;
3312
- values?: string[] | undefined;
3313
- required?: boolean | undefined;
3314
- default?: unknown;
3315
- }[];
3141
+ fields: TraitEntityField[];
3316
3142
  description?: string | undefined;
3317
3143
  runtime?: boolean | undefined;
3318
3144
  collection?: string | undefined;
@@ -3327,11 +3153,7 @@ declare const TraitSchema: z.ZodObject<{
3327
3153
  description?: string | undefined;
3328
3154
  synonyms?: string | undefined;
3329
3155
  tier?: string | undefined;
3330
- payloadSchema?: {
3331
- type: string;
3332
- name: string;
3333
- required?: boolean | undefined;
3334
- }[] | undefined;
3156
+ payloadSchema?: PayloadField[] | undefined;
3335
3157
  classification?: "domain" | "system" | undefined;
3336
3158
  semanticRole?: string | undefined;
3337
3159
  }[];
@@ -3364,13 +3186,7 @@ declare const TraitSchema: z.ZodObject<{
3364
3186
  synonyms?: string | undefined;
3365
3187
  scope?: "internal" | "external" | undefined;
3366
3188
  tier?: string | undefined;
3367
- payloadSchema?: {
3368
- type: string;
3369
- name: string;
3370
- required?: boolean | undefined;
3371
- description?: string | undefined;
3372
- entityType?: string | undefined;
3373
- }[] | undefined;
3189
+ payloadSchema?: EventPayloadField[] | undefined;
3374
3190
  }[] | undefined;
3375
3191
  linkedEntity?: string | undefined;
3376
3192
  listens?: {
@@ -3454,13 +3270,7 @@ declare const TraitSchema: z.ZodObject<{
3454
3270
  capabilities?: string[] | undefined;
3455
3271
  dataEntities?: {
3456
3272
  name: string;
3457
- fields: {
3458
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
3459
- name: string;
3460
- values?: string[] | undefined;
3461
- required?: boolean | undefined;
3462
- default?: unknown;
3463
- }[];
3273
+ fields: TraitEntityField[];
3464
3274
  description?: string | undefined;
3465
3275
  runtime?: boolean | undefined;
3466
3276
  collection?: string | undefined;
@@ -3475,11 +3285,7 @@ declare const TraitSchema: z.ZodObject<{
3475
3285
  description?: string | undefined;
3476
3286
  synonyms?: string | undefined;
3477
3287
  tier?: string | undefined;
3478
- payloadSchema?: {
3479
- type: string;
3480
- name: string;
3481
- required?: boolean | undefined;
3482
- }[] | undefined;
3288
+ payloadSchema?: PayloadField[] | undefined;
3483
3289
  classification?: "domain" | "system" | undefined;
3484
3290
  semanticRole?: string | undefined;
3485
3291
  }[];
@@ -3512,13 +3318,7 @@ declare const TraitSchema: z.ZodObject<{
3512
3318
  synonyms?: string | undefined;
3513
3319
  scope?: "internal" | "external" | undefined;
3514
3320
  tier?: string | undefined;
3515
- payloadSchema?: {
3516
- type: string;
3517
- name: string;
3518
- required?: boolean | undefined;
3519
- description?: string | undefined;
3520
- entityType?: string | undefined;
3521
- }[] | undefined;
3321
+ payloadSchema?: EventPayloadField[] | undefined;
3522
3322
  }[] | undefined;
3523
3323
  linkedEntity?: string | undefined;
3524
3324
  listens?: {
@@ -3648,25 +3448,7 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
3648
3448
  dataEntities: z.ZodOptional<z.ZodArray<z.ZodObject<{
3649
3449
  name: z.ZodString;
3650
3450
  collection: z.ZodOptional<z.ZodString>;
3651
- fields: z.ZodArray<z.ZodObject<{
3652
- name: z.ZodString;
3653
- type: z.ZodEnum<["string", "number", "boolean", "date", "array", "object", "timestamp", "datetime", "enum"]>;
3654
- required: z.ZodOptional<z.ZodBoolean>;
3655
- default: z.ZodOptional<z.ZodUnknown>;
3656
- values: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
3657
- }, "strip", z.ZodTypeAny, {
3658
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
3659
- name: string;
3660
- values?: string[] | undefined;
3661
- required?: boolean | undefined;
3662
- default?: unknown;
3663
- }, {
3664
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
3665
- name: string;
3666
- values?: string[] | undefined;
3667
- required?: boolean | undefined;
3668
- default?: unknown;
3669
- }>, "many">;
3451
+ fields: z.ZodArray<z.ZodType<TraitEntityField, z.ZodTypeDef, TraitEntityField>, "many">;
3670
3452
  timestamps: z.ZodOptional<z.ZodBoolean>;
3671
3453
  description: z.ZodOptional<z.ZodString>;
3672
3454
  runtime: z.ZodOptional<z.ZodBoolean>;
@@ -3674,13 +3456,7 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
3674
3456
  pages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
3675
3457
  }, "strip", z.ZodTypeAny, {
3676
3458
  name: string;
3677
- fields: {
3678
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
3679
- name: string;
3680
- values?: string[] | undefined;
3681
- required?: boolean | undefined;
3682
- default?: unknown;
3683
- }[];
3459
+ fields: TraitEntityField[];
3684
3460
  description?: string | undefined;
3685
3461
  runtime?: boolean | undefined;
3686
3462
  collection?: string | undefined;
@@ -3689,13 +3465,7 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
3689
3465
  singleton?: boolean | undefined;
3690
3466
  }, {
3691
3467
  name: string;
3692
- fields: {
3693
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
3694
- name: string;
3695
- values?: string[] | undefined;
3696
- required?: boolean | undefined;
3697
- default?: unknown;
3698
- }[];
3468
+ fields: TraitEntityField[];
3699
3469
  description?: string | undefined;
3700
3470
  runtime?: boolean | undefined;
3701
3471
  collection?: string | undefined;
@@ -3735,19 +3505,7 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
3735
3505
  description: z.ZodOptional<z.ZodString>;
3736
3506
  synonyms: z.ZodOptional<z.ZodString>;
3737
3507
  tier: z.ZodOptional<z.ZodString>;
3738
- payloadSchema: z.ZodOptional<z.ZodArray<z.ZodObject<{
3739
- name: z.ZodString;
3740
- type: z.ZodString;
3741
- required: z.ZodOptional<z.ZodBoolean>;
3742
- }, "strip", z.ZodTypeAny, {
3743
- type: string;
3744
- name: string;
3745
- required?: boolean | undefined;
3746
- }, {
3747
- type: string;
3748
- name: string;
3749
- required?: boolean | undefined;
3750
- }>, "many">>;
3508
+ payloadSchema: z.ZodOptional<z.ZodArray<z.ZodType<PayloadField, z.ZodTypeDef, PayloadField>, "many">>;
3751
3509
  classification: z.ZodOptional<z.ZodEnum<["domain", "system"]>>;
3752
3510
  semanticRole: z.ZodOptional<z.ZodString>;
3753
3511
  }, "strip", z.ZodTypeAny, {
@@ -3756,11 +3514,7 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
3756
3514
  description?: string | undefined;
3757
3515
  synonyms?: string | undefined;
3758
3516
  tier?: string | undefined;
3759
- payloadSchema?: {
3760
- type: string;
3761
- name: string;
3762
- required?: boolean | undefined;
3763
- }[] | undefined;
3517
+ payloadSchema?: PayloadField[] | undefined;
3764
3518
  classification?: "domain" | "system" | undefined;
3765
3519
  semanticRole?: string | undefined;
3766
3520
  }, {
@@ -3769,11 +3523,7 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
3769
3523
  description?: string | undefined;
3770
3524
  synonyms?: string | undefined;
3771
3525
  tier?: string | undefined;
3772
- payloadSchema?: {
3773
- type: string;
3774
- name: string;
3775
- required?: boolean | undefined;
3776
- }[] | undefined;
3526
+ payloadSchema?: PayloadField[] | undefined;
3777
3527
  classification?: "domain" | "system" | undefined;
3778
3528
  semanticRole?: string | undefined;
3779
3529
  }>, "many">;
@@ -3819,11 +3569,7 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
3819
3569
  description?: string | undefined;
3820
3570
  synonyms?: string | undefined;
3821
3571
  tier?: string | undefined;
3822
- payloadSchema?: {
3823
- type: string;
3824
- name: string;
3825
- required?: boolean | undefined;
3826
- }[] | undefined;
3572
+ payloadSchema?: PayloadField[] | undefined;
3827
3573
  classification?: "domain" | "system" | undefined;
3828
3574
  semanticRole?: string | undefined;
3829
3575
  }[];
@@ -3856,11 +3602,7 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
3856
3602
  description?: string | undefined;
3857
3603
  synonyms?: string | undefined;
3858
3604
  tier?: string | undefined;
3859
- payloadSchema?: {
3860
- type: string;
3861
- name: string;
3862
- required?: boolean | undefined;
3863
- }[] | undefined;
3605
+ payloadSchema?: PayloadField[] | undefined;
3864
3606
  classification?: "domain" | "system" | undefined;
3865
3607
  semanticRole?: string | undefined;
3866
3608
  }[];
@@ -3925,41 +3667,15 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
3925
3667
  * starts with a letter, then any letters / digits / underscores. Both
3926
3668
  * UPPER_SNAKE_CASE and PascalCase shapes are valid identifiers in the
3927
3669
  * post-Phase 2.5 nominal-event type system (events declared via
3928
- * `type X = Event<T>`).
3670
+ * `type X = Event<T>`). A pre-resolution `@config.<knob>` reference
3671
+ * (Option B) is also legal — inline/resolve substitutes it with the
3672
+ * knob's effective literal before codegen/runtime consume it.
3929
3673
  */
3930
3674
  event: z.ZodString;
3931
3675
  description: z.ZodOptional<z.ZodString>;
3932
3676
  synonyms: z.ZodOptional<z.ZodString>;
3933
3677
  tier: z.ZodOptional<z.ZodString>;
3934
- payloadSchema: z.ZodOptional<z.ZodArray<z.ZodObject<{
3935
- name: z.ZodString;
3936
- /**
3937
- * Field type. Mirrors the Rust validator's acceptance: any non-empty
3938
- * string. Primitives ('string' | 'number' | 'boolean' | 'object' |
3939
- * 'array') are the canonical values; entity-name references like
3940
- * 'ModalRecord' and array-of-entity references like '[ModalRecord]'
3941
- * are also valid because the Rust IR's PayloadField.field_type is
3942
- * just a String. Only enforced narrowly at the call site (e.g.
3943
- * emit-literal type-mismatch warnings in
3944
- * orbital-compiler/phases/validation/emit_payload.rs) — not here.
3945
- */
3946
- type: z.ZodString;
3947
- required: z.ZodOptional<z.ZodBoolean>;
3948
- description: z.ZodOptional<z.ZodString>;
3949
- entityType: z.ZodOptional<z.ZodString>;
3950
- }, "strip", z.ZodTypeAny, {
3951
- type: string;
3952
- name: string;
3953
- required?: boolean | undefined;
3954
- description?: string | undefined;
3955
- entityType?: string | undefined;
3956
- }, {
3957
- type: string;
3958
- name: string;
3959
- required?: boolean | undefined;
3960
- description?: string | undefined;
3961
- entityType?: string | undefined;
3962
- }>, "many">>;
3678
+ payloadSchema: z.ZodOptional<z.ZodArray<z.ZodType<EventPayloadField, z.ZodTypeDef, EventPayloadField>, "many">>;
3963
3679
  scope: z.ZodOptional<z.ZodEnum<["internal", "external"]>>;
3964
3680
  }, "strip", z.ZodTypeAny, {
3965
3681
  event: string;
@@ -3967,26 +3683,14 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
3967
3683
  synonyms?: string | undefined;
3968
3684
  scope?: "internal" | "external" | undefined;
3969
3685
  tier?: string | undefined;
3970
- payloadSchema?: {
3971
- type: string;
3972
- name: string;
3973
- required?: boolean | undefined;
3974
- description?: string | undefined;
3975
- entityType?: string | undefined;
3976
- }[] | undefined;
3686
+ payloadSchema?: EventPayloadField[] | undefined;
3977
3687
  }, {
3978
3688
  event: string;
3979
3689
  description?: string | undefined;
3980
3690
  synonyms?: string | undefined;
3981
3691
  scope?: "internal" | "external" | undefined;
3982
3692
  tier?: string | undefined;
3983
- payloadSchema?: {
3984
- type: string;
3985
- name: string;
3986
- required?: boolean | undefined;
3987
- description?: string | undefined;
3988
- entityType?: string | undefined;
3989
- }[] | undefined;
3693
+ payloadSchema?: EventPayloadField[] | undefined;
3990
3694
  }>, "many">>;
3991
3695
  listens: z.ZodOptional<z.ZodArray<z.ZodObject<{
3992
3696
  event: z.ZodString;
@@ -4166,13 +3870,7 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4166
3870
  capabilities?: string[] | undefined;
4167
3871
  dataEntities?: {
4168
3872
  name: string;
4169
- fields: {
4170
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
4171
- name: string;
4172
- values?: string[] | undefined;
4173
- required?: boolean | undefined;
4174
- default?: unknown;
4175
- }[];
3873
+ fields: TraitEntityField[];
4176
3874
  description?: string | undefined;
4177
3875
  runtime?: boolean | undefined;
4178
3876
  collection?: string | undefined;
@@ -4187,11 +3885,7 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4187
3885
  description?: string | undefined;
4188
3886
  synonyms?: string | undefined;
4189
3887
  tier?: string | undefined;
4190
- payloadSchema?: {
4191
- type: string;
4192
- name: string;
4193
- required?: boolean | undefined;
4194
- }[] | undefined;
3888
+ payloadSchema?: PayloadField[] | undefined;
4195
3889
  classification?: "domain" | "system" | undefined;
4196
3890
  semanticRole?: string | undefined;
4197
3891
  }[];
@@ -4224,13 +3918,7 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4224
3918
  synonyms?: string | undefined;
4225
3919
  scope?: "internal" | "external" | undefined;
4226
3920
  tier?: string | undefined;
4227
- payloadSchema?: {
4228
- type: string;
4229
- name: string;
4230
- required?: boolean | undefined;
4231
- description?: string | undefined;
4232
- entityType?: string | undefined;
4233
- }[] | undefined;
3921
+ payloadSchema?: EventPayloadField[] | undefined;
4234
3922
  }[] | undefined;
4235
3923
  linkedEntity?: string | undefined;
4236
3924
  listens?: {
@@ -4314,13 +4002,7 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4314
4002
  capabilities?: string[] | undefined;
4315
4003
  dataEntities?: {
4316
4004
  name: string;
4317
- fields: {
4318
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
4319
- name: string;
4320
- values?: string[] | undefined;
4321
- required?: boolean | undefined;
4322
- default?: unknown;
4323
- }[];
4005
+ fields: TraitEntityField[];
4324
4006
  description?: string | undefined;
4325
4007
  runtime?: boolean | undefined;
4326
4008
  collection?: string | undefined;
@@ -4335,11 +4017,7 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4335
4017
  description?: string | undefined;
4336
4018
  synonyms?: string | undefined;
4337
4019
  tier?: string | undefined;
4338
- payloadSchema?: {
4339
- type: string;
4340
- name: string;
4341
- required?: boolean | undefined;
4342
- }[] | undefined;
4020
+ payloadSchema?: PayloadField[] | undefined;
4343
4021
  classification?: "domain" | "system" | undefined;
4344
4022
  semanticRole?: string | undefined;
4345
4023
  }[];
@@ -4372,13 +4050,7 @@ declare const TraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4372
4050
  synonyms?: string | undefined;
4373
4051
  scope?: "internal" | "external" | undefined;
4374
4052
  tier?: string | undefined;
4375
- payloadSchema?: {
4376
- type: string;
4377
- name: string;
4378
- required?: boolean | undefined;
4379
- description?: string | undefined;
4380
- entityType?: string | undefined;
4381
- }[] | undefined;
4053
+ payloadSchema?: EventPayloadField[] | undefined;
4382
4054
  }[] | undefined;
4383
4055
  linkedEntity?: string | undefined;
4384
4056
  listens?: {
@@ -4578,25 +4250,7 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4578
4250
  dataEntities: z.ZodOptional<z.ZodArray<z.ZodObject<{
4579
4251
  name: z.ZodString;
4580
4252
  collection: z.ZodOptional<z.ZodString>;
4581
- fields: z.ZodArray<z.ZodObject<{
4582
- name: z.ZodString;
4583
- type: z.ZodEnum<["string", "number", "boolean", "date", "array", "object", "timestamp", "datetime", "enum"]>;
4584
- required: z.ZodOptional<z.ZodBoolean>;
4585
- default: z.ZodOptional<z.ZodUnknown>;
4586
- values: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
4587
- }, "strip", z.ZodTypeAny, {
4588
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
4589
- name: string;
4590
- values?: string[] | undefined;
4591
- required?: boolean | undefined;
4592
- default?: unknown;
4593
- }, {
4594
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
4595
- name: string;
4596
- values?: string[] | undefined;
4597
- required?: boolean | undefined;
4598
- default?: unknown;
4599
- }>, "many">;
4253
+ fields: z.ZodArray<z.ZodType<TraitEntityField, z.ZodTypeDef, TraitEntityField>, "many">;
4600
4254
  timestamps: z.ZodOptional<z.ZodBoolean>;
4601
4255
  description: z.ZodOptional<z.ZodString>;
4602
4256
  runtime: z.ZodOptional<z.ZodBoolean>;
@@ -4604,13 +4258,7 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4604
4258
  pages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
4605
4259
  }, "strip", z.ZodTypeAny, {
4606
4260
  name: string;
4607
- fields: {
4608
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
4609
- name: string;
4610
- values?: string[] | undefined;
4611
- required?: boolean | undefined;
4612
- default?: unknown;
4613
- }[];
4261
+ fields: TraitEntityField[];
4614
4262
  description?: string | undefined;
4615
4263
  runtime?: boolean | undefined;
4616
4264
  collection?: string | undefined;
@@ -4619,13 +4267,7 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4619
4267
  singleton?: boolean | undefined;
4620
4268
  }, {
4621
4269
  name: string;
4622
- fields: {
4623
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
4624
- name: string;
4625
- values?: string[] | undefined;
4626
- required?: boolean | undefined;
4627
- default?: unknown;
4628
- }[];
4270
+ fields: TraitEntityField[];
4629
4271
  description?: string | undefined;
4630
4272
  runtime?: boolean | undefined;
4631
4273
  collection?: string | undefined;
@@ -4665,19 +4307,7 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4665
4307
  description: z.ZodOptional<z.ZodString>;
4666
4308
  synonyms: z.ZodOptional<z.ZodString>;
4667
4309
  tier: z.ZodOptional<z.ZodString>;
4668
- payloadSchema: z.ZodOptional<z.ZodArray<z.ZodObject<{
4669
- name: z.ZodString;
4670
- type: z.ZodString;
4671
- required: z.ZodOptional<z.ZodBoolean>;
4672
- }, "strip", z.ZodTypeAny, {
4673
- type: string;
4674
- name: string;
4675
- required?: boolean | undefined;
4676
- }, {
4677
- type: string;
4678
- name: string;
4679
- required?: boolean | undefined;
4680
- }>, "many">>;
4310
+ payloadSchema: z.ZodOptional<z.ZodArray<z.ZodType<PayloadField, z.ZodTypeDef, PayloadField>, "many">>;
4681
4311
  classification: z.ZodOptional<z.ZodEnum<["domain", "system"]>>;
4682
4312
  semanticRole: z.ZodOptional<z.ZodString>;
4683
4313
  }, "strip", z.ZodTypeAny, {
@@ -4686,11 +4316,7 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4686
4316
  description?: string | undefined;
4687
4317
  synonyms?: string | undefined;
4688
4318
  tier?: string | undefined;
4689
- payloadSchema?: {
4690
- type: string;
4691
- name: string;
4692
- required?: boolean | undefined;
4693
- }[] | undefined;
4319
+ payloadSchema?: PayloadField[] | undefined;
4694
4320
  classification?: "domain" | "system" | undefined;
4695
4321
  semanticRole?: string | undefined;
4696
4322
  }, {
@@ -4699,11 +4325,7 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4699
4325
  description?: string | undefined;
4700
4326
  synonyms?: string | undefined;
4701
4327
  tier?: string | undefined;
4702
- payloadSchema?: {
4703
- type: string;
4704
- name: string;
4705
- required?: boolean | undefined;
4706
- }[] | undefined;
4328
+ payloadSchema?: PayloadField[] | undefined;
4707
4329
  classification?: "domain" | "system" | undefined;
4708
4330
  semanticRole?: string | undefined;
4709
4331
  }>, "many">;
@@ -4749,11 +4371,7 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4749
4371
  description?: string | undefined;
4750
4372
  synonyms?: string | undefined;
4751
4373
  tier?: string | undefined;
4752
- payloadSchema?: {
4753
- type: string;
4754
- name: string;
4755
- required?: boolean | undefined;
4756
- }[] | undefined;
4374
+ payloadSchema?: PayloadField[] | undefined;
4757
4375
  classification?: "domain" | "system" | undefined;
4758
4376
  semanticRole?: string | undefined;
4759
4377
  }[];
@@ -4786,11 +4404,7 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4786
4404
  description?: string | undefined;
4787
4405
  synonyms?: string | undefined;
4788
4406
  tier?: string | undefined;
4789
- payloadSchema?: {
4790
- type: string;
4791
- name: string;
4792
- required?: boolean | undefined;
4793
- }[] | undefined;
4407
+ payloadSchema?: PayloadField[] | undefined;
4794
4408
  classification?: "domain" | "system" | undefined;
4795
4409
  semanticRole?: string | undefined;
4796
4410
  }[];
@@ -4855,41 +4469,15 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4855
4469
  * starts with a letter, then any letters / digits / underscores. Both
4856
4470
  * UPPER_SNAKE_CASE and PascalCase shapes are valid identifiers in the
4857
4471
  * post-Phase 2.5 nominal-event type system (events declared via
4858
- * `type X = Event<T>`).
4472
+ * `type X = Event<T>`). A pre-resolution `@config.<knob>` reference
4473
+ * (Option B) is also legal — inline/resolve substitutes it with the
4474
+ * knob's effective literal before codegen/runtime consume it.
4859
4475
  */
4860
4476
  event: z.ZodString;
4861
4477
  description: z.ZodOptional<z.ZodString>;
4862
4478
  synonyms: z.ZodOptional<z.ZodString>;
4863
4479
  tier: z.ZodOptional<z.ZodString>;
4864
- payloadSchema: z.ZodOptional<z.ZodArray<z.ZodObject<{
4865
- name: z.ZodString;
4866
- /**
4867
- * Field type. Mirrors the Rust validator's acceptance: any non-empty
4868
- * string. Primitives ('string' | 'number' | 'boolean' | 'object' |
4869
- * 'array') are the canonical values; entity-name references like
4870
- * 'ModalRecord' and array-of-entity references like '[ModalRecord]'
4871
- * are also valid because the Rust IR's PayloadField.field_type is
4872
- * just a String. Only enforced narrowly at the call site (e.g.
4873
- * emit-literal type-mismatch warnings in
4874
- * orbital-compiler/phases/validation/emit_payload.rs) — not here.
4875
- */
4876
- type: z.ZodString;
4877
- required: z.ZodOptional<z.ZodBoolean>;
4878
- description: z.ZodOptional<z.ZodString>;
4879
- entityType: z.ZodOptional<z.ZodString>;
4880
- }, "strip", z.ZodTypeAny, {
4881
- type: string;
4882
- name: string;
4883
- required?: boolean | undefined;
4884
- description?: string | undefined;
4885
- entityType?: string | undefined;
4886
- }, {
4887
- type: string;
4888
- name: string;
4889
- required?: boolean | undefined;
4890
- description?: string | undefined;
4891
- entityType?: string | undefined;
4892
- }>, "many">>;
4480
+ payloadSchema: z.ZodOptional<z.ZodArray<z.ZodType<EventPayloadField, z.ZodTypeDef, EventPayloadField>, "many">>;
4893
4481
  scope: z.ZodOptional<z.ZodEnum<["internal", "external"]>>;
4894
4482
  }, "strip", z.ZodTypeAny, {
4895
4483
  event: string;
@@ -4897,26 +4485,14 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
4897
4485
  synonyms?: string | undefined;
4898
4486
  scope?: "internal" | "external" | undefined;
4899
4487
  tier?: string | undefined;
4900
- payloadSchema?: {
4901
- type: string;
4902
- name: string;
4903
- required?: boolean | undefined;
4904
- description?: string | undefined;
4905
- entityType?: string | undefined;
4906
- }[] | undefined;
4488
+ payloadSchema?: EventPayloadField[] | undefined;
4907
4489
  }, {
4908
4490
  event: string;
4909
4491
  description?: string | undefined;
4910
4492
  synonyms?: string | undefined;
4911
4493
  scope?: "internal" | "external" | undefined;
4912
4494
  tier?: string | undefined;
4913
- payloadSchema?: {
4914
- type: string;
4915
- name: string;
4916
- required?: boolean | undefined;
4917
- description?: string | undefined;
4918
- entityType?: string | undefined;
4919
- }[] | undefined;
4495
+ payloadSchema?: EventPayloadField[] | undefined;
4920
4496
  }>, "many">>;
4921
4497
  listens: z.ZodOptional<z.ZodArray<z.ZodObject<{
4922
4498
  event: z.ZodString;
@@ -5096,13 +4672,7 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
5096
4672
  capabilities?: string[] | undefined;
5097
4673
  dataEntities?: {
5098
4674
  name: string;
5099
- fields: {
5100
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
5101
- name: string;
5102
- values?: string[] | undefined;
5103
- required?: boolean | undefined;
5104
- default?: unknown;
5105
- }[];
4675
+ fields: TraitEntityField[];
5106
4676
  description?: string | undefined;
5107
4677
  runtime?: boolean | undefined;
5108
4678
  collection?: string | undefined;
@@ -5117,11 +4687,7 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
5117
4687
  description?: string | undefined;
5118
4688
  synonyms?: string | undefined;
5119
4689
  tier?: string | undefined;
5120
- payloadSchema?: {
5121
- type: string;
5122
- name: string;
5123
- required?: boolean | undefined;
5124
- }[] | undefined;
4690
+ payloadSchema?: PayloadField[] | undefined;
5125
4691
  classification?: "domain" | "system" | undefined;
5126
4692
  semanticRole?: string | undefined;
5127
4693
  }[];
@@ -5154,13 +4720,7 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
5154
4720
  synonyms?: string | undefined;
5155
4721
  scope?: "internal" | "external" | undefined;
5156
4722
  tier?: string | undefined;
5157
- payloadSchema?: {
5158
- type: string;
5159
- name: string;
5160
- required?: boolean | undefined;
5161
- description?: string | undefined;
5162
- entityType?: string | undefined;
5163
- }[] | undefined;
4723
+ payloadSchema?: EventPayloadField[] | undefined;
5164
4724
  }[] | undefined;
5165
4725
  linkedEntity?: string | undefined;
5166
4726
  listens?: {
@@ -5244,13 +4804,7 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
5244
4804
  capabilities?: string[] | undefined;
5245
4805
  dataEntities?: {
5246
4806
  name: string;
5247
- fields: {
5248
- type: "string" | "number" | "boolean" | "object" | "date" | "timestamp" | "datetime" | "array" | "enum";
5249
- name: string;
5250
- values?: string[] | undefined;
5251
- required?: boolean | undefined;
5252
- default?: unknown;
5253
- }[];
4807
+ fields: TraitEntityField[];
5254
4808
  description?: string | undefined;
5255
4809
  runtime?: boolean | undefined;
5256
4810
  collection?: string | undefined;
@@ -5265,11 +4819,7 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
5265
4819
  description?: string | undefined;
5266
4820
  synonyms?: string | undefined;
5267
4821
  tier?: string | undefined;
5268
- payloadSchema?: {
5269
- type: string;
5270
- name: string;
5271
- required?: boolean | undefined;
5272
- }[] | undefined;
4822
+ payloadSchema?: PayloadField[] | undefined;
5273
4823
  classification?: "domain" | "system" | undefined;
5274
4824
  semanticRole?: string | undefined;
5275
4825
  }[];
@@ -5302,13 +4852,7 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
5302
4852
  synonyms?: string | undefined;
5303
4853
  scope?: "internal" | "external" | undefined;
5304
4854
  tier?: string | undefined;
5305
- payloadSchema?: {
5306
- type: string;
5307
- name: string;
5308
- required?: boolean | undefined;
5309
- description?: string | undefined;
5310
- entityType?: string | undefined;
5311
- }[] | undefined;
4855
+ payloadSchema?: EventPayloadField[] | undefined;
5312
4856
  }[] | undefined;
5313
4857
  linkedEntity?: string | undefined;
5314
4858
  listens?: {
@@ -5384,4 +4928,4 @@ declare const OrbitalTraitRefSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
5384
4928
  } | undefined;
5385
4929
  }>]>;
5386
4930
 
5387
- export { OrbitalTraitRefSchema as $, type AgentEffect as A, EventSchema as B, type CallSiteConfig as C, type DeclaredTraitConfig as D, type Effect as E, type EventScope as F, EventScopeSchema as G, type FetchEffect as H, type FetchOptions as I, type FetchResult as J, type ForwardConfig as K, type ForwardEffect as L, type Guard as M, type GuardInput as N, GuardSchema as O, type ListenSource as P, ListenSourceSchema as Q, type LogEffect as R, type State as S, type TraitEventListener as T, type McpServiceDef as U, McpServiceDefSchema as V, type NavigateEffect as W, type NnConfig as X, type NnLayer as Y, type NotifyEffect as Z, type OrbitalTraitRef as _, type TraitReference as a, TraitReferenceSchema as a$, type OsEffect as a0, type PayloadField as a1, PayloadFieldSchema as a2, type PersistData as a3, type PersistEffect as a4, type PersistEmitConfig as a5, type PresentationType as a6, type RefEffect as a7, type RenderBinding as a8, type RenderItemLambda as a9, type SpawnEffect as aA, type StateInput as aB, type StateMachine as aC, type StateMachineInput as aD, StateMachineSchema as aE, StateSchema as aF, type SwapEffect as aG, type TrainConfig as aH, type TrainEffect as aI, type TraitCategory as aJ, TraitCategorySchema as aK, type TraitConfig as aL, type TraitConfigObject as aM, TraitConfigSchema as aN, type TraitConfigValue as aO, TraitConfigValueSchema as aP, type TraitDataEntity as aQ, TraitDataEntitySchema as aR, type TraitEntityField as aS, TraitEntityFieldSchema as aT, type TraitEventContract as aU, TraitEventContractSchema as aV, TraitEventListenerSchema as aW, type TraitInput as aX, type TraitRef as aY, TraitRefSchema as aZ, type TraitReferenceInput as a_, type RenderUIEffect as aa, type RenderUINode as ab, type RequiredField as ac, RequiredFieldSchema as ad, type ResolvedPatternProps as ae, type RestAuthConfig as af, RestAuthConfigSchema as ag, type RestServiceDef as ah, RestServiceDefSchema as ai, SERVICE_TYPES as aj, type ServiceDefinition as ak, ServiceDefinitionSchema as al, type ServiceParams as am, type ServiceParamsValue as an, type ServiceRef as ao, type ServiceRefObject as ap, ServiceRefObjectSchema as aq, ServiceRefSchema as ar, ServiceRefStringSchema as as, type ServiceType as at, ServiceTypeSchema as au, type SetEffect as av, type SocketEvents as aw, SocketEventsSchema as ax, type SocketServiceDef as ay, SocketServiceDefSchema as az, type CallSiteConfigEntry as b, TraitSchema as b0, type TraitTick as b1, TraitTickSchema as b2, type TraitUIBinding as b3, type Transition as b4, type TransitionInput as b5, TransitionSchema as b6, type TypedEffect as b7, type UISlot as b8, UISlotSchema as b9, notify as bA, parseServiceRef as bB, persist as bC, ref as bD, renderUI as bE, set as bF, spawn as bG, swap as bH, watch as bI, type TraitScope as bJ, UI_SLOTS as ba, type WatchEffect as bb, type WatchOptions as bc, atomic as bd, callService as be, deref as bf, despawn as bg, doEffects as bh, emit as bi, findService as bj, getServiceNames as bk, getTraitConfig as bl, getTraitName as bm, hasService as bn, isCallSiteConfigDeclaration as bo, isCircuitEvent as bp, isEffect as bq, isInlineTrait as br, isMcpService as bs, isRestService as bt, isSExprEffect as bu, isServiceReference as bv, isServiceReferenceObject as bw, isSocketService as bx, navigate as by, normalizeTraitRef as bz, type Trait as c, type AtomicEffect as d, type CallServiceConfig as e, type CallServiceEffect as f, type CheckpointLoadEffect as g, type CheckpointSaveEffect as h, type ConfigFieldDeclaration as i, ConfigFieldDeclarationSchema as j, DeclaredTraitConfigSchema as k, type DerefEffect as l, type DespawnEffect as m, type DoEffect as n, type EffectInput as o, EffectSchema as p, type EmitConfig as q, type EmitEffect as r, type EntityFieldContract as s, EntityFieldContractSchema as t, type EvaluateConfig as u, type EvaluateEffect as v, type Event as w, type EventInput as x, type EventPayloadField as y, EventPayloadFieldSchema as z };
4931
+ export { type LogEffect as $, type AgentEffect as A, type BehaviorEffect as B, type CallSiteConfig as C, type DeclaredTraitConfig as D, type Effect as E, type EvaluateConfig as F, type EvaluateEffect as G, type Event as H, type EventInput as I, type EventPayloadField as J, EventPayloadFieldSchema as K, EventSchema as L, type EventScope as M, EventScopeSchema as N, type FetchEffect as O, type FetchOptions as P, type FetchResult as Q, type ForwardConfig as R, type State as S, type TraitEventListener as T, type ForwardEffect as U, type Guard as V, type GuardInput as W, GuardSchema as X, type ListenSource as Y, ListenSourceSchema as Z, type LlmEffect as _, type TraitReference as a, TraitDataEntitySchema as a$, type McpServiceDef as a0, McpServiceDefSchema as a1, type MemoryEffect as a2, type NavigateEffect as a3, type NnConfig as a4, type NnLayer as a5, type NotifyEffect as a6, type OrbitalTraitRef as a7, OrbitalTraitRefSchema as a8, type OsEffect as a9, ServiceRefSchema as aA, ServiceRefStringSchema as aB, type ServiceType as aC, ServiceTypeSchema as aD, type SessionEffect as aE, type SetEffect as aF, type SocketEvents as aG, SocketEventsSchema as aH, type SocketServiceDef as aI, SocketServiceDefSchema as aJ, type SpawnEffect as aK, type StateInput as aL, type StateMachine as aM, type StateMachineInput as aN, StateMachineSchema as aO, StateSchema as aP, type SwapEffect as aQ, type TraceEffect as aR, type TrainConfig as aS, type TrainEffect as aT, type TraitCategory as aU, TraitCategorySchema as aV, type TraitConfigObject as aW, TraitConfigSchema as aX, type TraitConfigValue as aY, TraitConfigValueSchema as aZ, type TraitDataEntity as a_, type PayloadField as aa, PayloadFieldSchema as ab, type PersistData as ac, type PersistEffect as ad, type PersistEmitConfig as ae, type PresentationType as af, type RefEffect as ag, type RenderBinding as ah, type RenderItemLambda as ai, type RenderUIEffect as aj, type RenderUINode as ak, type RequiredField as al, RequiredFieldSchema as am, type ResolvedPatternProps as an, type RestAuthConfig as ao, RestAuthConfigSchema as ap, type RestServiceDef as aq, RestServiceDefSchema as ar, SERVICE_TYPES as as, type ServiceDefinition as at, ServiceDefinitionSchema as au, type ServiceParams as av, type ServiceParamsValue as aw, type ServiceRef as ax, type ServiceRefObject as ay, ServiceRefObjectSchema as az, type CallSiteConfigEntry as b, type TraitEntityField as b0, TraitEntityFieldSchema as b1, type TraitEventContract as b2, TraitEventContractSchema as b3, TraitEventListenerSchema as b4, type TraitInput as b5, type TraitRef as b6, TraitRefSchema as b7, type TraitReferenceInput as b8, TraitReferenceSchema as b9, isCallSiteConfigDeclaration as bA, isCircuitEvent as bB, isEffect as bC, isInlineTrait as bD, isMcpService as bE, isRestService as bF, isSExprEffect as bG, isServiceReference as bH, isServiceReferenceObject as bI, isSocketService as bJ, navigate as bK, normalizeCallSiteConfigToValues as bL, normalizeTraitRef as bM, notify as bN, parseServiceRef as bO, persist as bP, ref as bQ, renderUI as bR, resolveConfigRefEventName as bS, set as bT, spawn as bU, swap as bV, watch as bW, type TraitScope as bX, TraitSchema as ba, type TraitTick as bb, TraitTickSchema as bc, type TraitUIBinding as bd, type Transition as be, type TransitionInput as bf, TransitionSchema as bg, type TypedEffect as bh, type UISlot as bi, UISlotSchema as bj, UI_SLOTS as bk, type ValidateEffect as bl, type WatchEffect as bm, type WatchOptions as bn, atomic as bo, callService as bp, configRefEventKnob as bq, deref as br, despawn as bs, doEffects as bt, emit as bu, findService as bv, getServiceNames as bw, getTraitConfig as bx, getTraitName as by, hasService as bz, type Trait as c, type TraitConfig as d, type ApplicationEffect as e, type AtomicEffect as f, CONFIG_REF_EVENT_PATTERN as g, type CallServiceConfig as h, type CallServiceEffect as i, type CheckpointLoadEffect as j, type CheckpointSaveEffect as k, type ComposeEffect as l, type ConfigFieldDeclaration as m, ConfigFieldDeclarationSchema as n, type ConfigFieldItemsDeclaration as o, type ConfigRefEventError as p, DeclaredTraitConfigSchema as q, type DerefEffect as r, type DespawnEffect as s, type DoEffect as t, type EffectInput as u, EffectSchema as v, type EmitConfig as w, type EmitEffect as x, type EntityFieldContract as y, EntityFieldContractSchema as z };