@makaio/framework 1.0.0-dev-1790585290134 → 1.0.0-dev-1790598955306

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 (66) hide show
  1. package/dist/.makaio-build.json +2 -2
  2. package/dist/adapters/claude/index.mjs +1 -1
  3. package/dist/artifact-XE82Q2bH.mjs +1 -0
  4. package/dist/bus/index.mjs +1 -1
  5. package/dist/bus--m38BS3i.mjs +9 -0
  6. package/dist/contracts/adapter/index.d.mts +1 -1
  7. package/dist/contracts/artifact/index.d.mts +3 -3
  8. package/dist/contracts/artifact/index.mjs +1 -1
  9. package/dist/contracts/capabilities/index.d.mts +1 -1
  10. package/dist/contracts/client/index.d.mts +1 -1
  11. package/dist/contracts/extension/index.d.mts +2 -2
  12. package/dist/contracts/extension/index.mjs +1 -1
  13. package/dist/contracts/index.d.mts +51 -51
  14. package/dist/contracts/index.mjs +1 -1
  15. package/dist/contracts/materialization/index.d.mts +2 -2
  16. package/dist/contracts/materialization/index.mjs +1 -1
  17. package/dist/contracts/worker/index.d.mts +1 -1
  18. package/dist/contracts/worker/index.mjs +1 -1
  19. package/dist/contracts/workflow/index.d.mts +2 -2
  20. package/dist/contracts/workflow/index.mjs +1 -1
  21. package/dist/{extension-CeZwB88e.mjs → extension-DeTvdQIB.mjs} +1 -1
  22. package/dist/{index-DvdBCT0Z.d.mts → index-CGM0-mt2.d.mts} +37 -37
  23. package/dist/{index-DxtUM-qd.d.mts → index-CLwnkYRD.d.mts} +1 -1
  24. package/dist/{index-DdA7SmMH2.d.mts → index-CPOJqxrf2.d.mts} +8 -8
  25. package/dist/{index-BM53WQaQ.d.mts → index-CVRQS5jk.d.mts} +1 -1
  26. package/dist/{index-DFa6C6wt.d.mts → index-CXroIgOA.d.mts} +3 -3
  27. package/dist/{index-CJDZBc-p.d.mts → index-CZIFCrMc.d.mts} +14 -14
  28. package/dist/{index-CoD7P-IS.d.mts → index-CpaWzUE5.d.mts} +1 -1
  29. package/dist/{index-DyequYaC.d.mts → index-CtwkMknv.d.mts} +1 -1
  30. package/dist/{index-CfELOEbZ.d.mts → index-DrfwkH1x.d.mts} +5 -5
  31. package/dist/{index-H_oth7rJ.d.mts → index-bXozN5vc.d.mts} +61 -2
  32. package/dist/{index-v9Tsvlnu.d.mts → index-e3AB0Iyv.d.mts} +43 -43
  33. package/dist/kind-registration-CdjmVxY_.mjs +1 -0
  34. package/dist/{materialization-6Whrkf5D.mjs → materialization-BzSgnv2R.mjs} +1 -1
  35. package/dist/{namespace-ybTsfz1t.d.mts → namespace-B9iQN3FQ.d.mts} +2 -2
  36. package/dist/{namespace-h7gq_v5U.d.mts → namespace-CHSwZhH7.d.mts} +2 -2
  37. package/dist/{namespace-D6W4Erwp.d.mts → namespace-DAzOxaux.d.mts} +2 -2
  38. package/dist/package.json +1 -1
  39. package/dist/{schemas-B2fs9-uF.d.mts → schemas-BNQtL3Ln.d.mts} +22 -2
  40. package/dist/{schemas-BTJvvq9Y.d.mts → schemas-BXkSHQaF.d.mts} +2 -2
  41. package/dist/{schemas-D6ZdMKo3.mjs → schemas-BvDsO8Is.mjs} +1 -1
  42. package/dist/{schemas-Cb9OJ9va.d.mts → schemas-CBDNnyz4.d.mts} +1 -1
  43. package/dist/{schemas-CYjPZwlQ.d.mts → schemas-DnyXA-9o.d.mts} +2 -2
  44. package/dist/services/adapter-runtime/index.d.mts +3 -3
  45. package/dist/services/adapter-runtime/namespace.d.mts +1 -1
  46. package/dist/services/adapter-runtime/schemas.d.mts +1 -1
  47. package/dist/services/execution-target/index.d.mts +2 -2
  48. package/dist/services/execution-target/namespace.d.mts +1 -1
  49. package/dist/services/execution-target/schemas.d.mts +1 -1
  50. package/dist/services/index.d.mts +13 -13
  51. package/dist/services/session/handlers/index.d.mts +1 -1
  52. package/dist/services/session/index.d.mts +3 -3
  53. package/dist/services/session/messages/namespace.d.mts +1 -1
  54. package/dist/services/settings/namespace.d.mts +2 -2
  55. package/dist/services/settings/storage/extension-configs/namespace.d.mts +3 -3
  56. package/dist/services/subagent-template/index.d.mts +1 -1
  57. package/dist/services/subagent-template/schemas.d.mts +1 -1
  58. package/dist/{transition-ClMo_PUJ.d.mts → transition-DK43U3QJ.d.mts} +1 -1
  59. package/dist/{view-builder-B8WSU6WT.d.mts → view-builder-Nffvg8MI.d.mts} +1 -1
  60. package/dist/{worker-CIhuGZx1.mjs → worker-toBnRJ0A.mjs} +1 -1
  61. package/dist/{workflow-Co4YAyPP.mjs → workflow-BDDB6EJi.mjs} +1 -1
  62. package/dist/workflow-engine/index.d.mts +31 -31
  63. package/package.json +1 -1
  64. package/dist/artifact-z-GlRNax.mjs +0 -1
  65. package/dist/bus-_RyFr-xv.mjs +0 -9
  66. package/dist/kind-registration-XiS6z3mC.mjs +0 -1
@@ -1,4 +1,4 @@
1
- import { C as ArtifactScope, K as ArtifactKindRegistration$1, V as ArtifactCategory, X as ArtifactLifecycleState, _ as ArtifactRelationTarget, ot as ArtifactRef$1, p as ArtifactRelation, rt as ArtifactUniquenessRule, s as ArtifactObservation$1, t as ArtifactActor, x as ArtifactRevision$1, y as ArtifactRepresentations } from "./schemas-B2fs9-uF.mjs";
1
+ import { C as ArtifactScope, K as ArtifactKindRegistration$1, V as ArtifactCategory, X as ArtifactLifecycleState, _ as ArtifactRelationTarget, at as ArtifactUniquenessRule, ct as ArtifactRef$1, et as ArtifactRelationRequirement, p as ArtifactRelation, s as ArtifactObservation$1, t as ArtifactActor, x as ArtifactRevision$1, y as ArtifactRepresentations } from "./schemas-BNQtL3Ln.mjs";
2
2
  import { l as JsonValue$1 } from "./json-value--pv1-OHx.mjs";
3
3
  import { z } from "zod";
4
4
  import * as _$_makaio_core0 from "@makaio/framework/core";
@@ -1194,6 +1194,10 @@ declare const ArtifactSchemas$1: {
1194
1194
  targetKinds: z.ZodOptional<z.ZodArray<z.ZodString>>;
1195
1195
  minItems: z.ZodNumber;
1196
1196
  maxItems: z.ZodOptional<z.ZodNumber>;
1197
+ when: z.ZodOptional<z.ZodObject<{
1198
+ path: z.ZodString;
1199
+ equals: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>;
1200
+ }, z.core.$strict>>;
1197
1201
  }, z.core.$strict>>>;
1198
1202
  uniqueness: z.ZodOptional<z.ZodArray<z.ZodObject<{
1199
1203
  by: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
@@ -1254,6 +1258,10 @@ declare const ArtifactSchemas$1: {
1254
1258
  targetKinds: z.ZodOptional<z.ZodArray<z.ZodString>>;
1255
1259
  minItems: z.ZodNumber;
1256
1260
  maxItems: z.ZodOptional<z.ZodNumber>;
1261
+ when: z.ZodOptional<z.ZodObject<{
1262
+ path: z.ZodString;
1263
+ equals: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>;
1264
+ }, z.core.$strict>>;
1257
1265
  }, z.core.$strict>>>;
1258
1266
  uniqueness: z.ZodOptional<z.ZodArray<z.ZodObject<{
1259
1267
  by: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
@@ -3997,6 +4005,10 @@ declare const ArtifactNamespace: _$_makaio_core0.BusNamespaceDefinition<"artifac
3997
4005
  targetKinds: z.ZodOptional<z.ZodArray<z.ZodString>>;
3998
4006
  minItems: z.ZodNumber;
3999
4007
  maxItems: z.ZodOptional<z.ZodNumber>;
4008
+ when: z.ZodOptional<z.ZodObject<{
4009
+ path: z.ZodString;
4010
+ equals: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>;
4011
+ }, z.core.$strict>>;
4000
4012
  }, z.core.$strict>>>;
4001
4013
  uniqueness: z.ZodOptional<z.ZodArray<z.ZodObject<{
4002
4014
  by: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
@@ -4057,6 +4069,10 @@ declare const ArtifactNamespace: _$_makaio_core0.BusNamespaceDefinition<"artifac
4057
4069
  targetKinds: z.ZodOptional<z.ZodArray<z.ZodString>>;
4058
4070
  minItems: z.ZodNumber;
4059
4071
  maxItems: z.ZodOptional<z.ZodNumber>;
4072
+ when: z.ZodOptional<z.ZodObject<{
4073
+ path: z.ZodString;
4074
+ equals: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>;
4075
+ }, z.core.$strict>>;
4060
4076
  }, z.core.$strict>>>;
4061
4077
  uniqueness: z.ZodOptional<z.ZodArray<z.ZodObject<{
4062
4078
  by: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
@@ -6822,6 +6838,10 @@ declare const ArtifactSubjects$1: _$_makaio_core0.BusSubjects<_$_makaio_core0.Fl
6822
6838
  targetKinds: z.ZodOptional<z.ZodArray<z.ZodString>>;
6823
6839
  minItems: z.ZodNumber;
6824
6840
  maxItems: z.ZodOptional<z.ZodNumber>;
6841
+ when: z.ZodOptional<z.ZodObject<{
6842
+ path: z.ZodString;
6843
+ equals: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>;
6844
+ }, z.core.$strict>>;
6825
6845
  }, z.core.$strict>>>;
6826
6846
  uniqueness: z.ZodOptional<z.ZodArray<z.ZodObject<{
6827
6847
  by: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
@@ -6882,6 +6902,10 @@ declare const ArtifactSubjects$1: _$_makaio_core0.BusSubjects<_$_makaio_core0.Fl
6882
6902
  targetKinds: z.ZodOptional<z.ZodArray<z.ZodString>>;
6883
6903
  minItems: z.ZodNumber;
6884
6904
  maxItems: z.ZodOptional<z.ZodNumber>;
6905
+ when: z.ZodOptional<z.ZodObject<{
6906
+ path: z.ZodString;
6907
+ equals: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>;
6908
+ }, z.core.$strict>>;
6885
6909
  }, z.core.$strict>>>;
6886
6910
  uniqueness: z.ZodOptional<z.ZodArray<z.ZodObject<{
6887
6911
  by: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
@@ -12209,4 +12233,39 @@ declare function buildUniquenessKeys(rules: readonly ArtifactUniquenessRule[], r
12209
12233
  */
12210
12234
  declare function describeUniquenessKey(key: UniquenessKey): string;
12211
12235
  //#endregion
12212
- export { ArtifactLifecycleTransitionIntent as $, ArtifactContextRelationDirection as $n, ArtifactSchemaFragment as $t, ArtifactLifecycleRejectedPayload as A, ArtifactSchemas$1 as An, EvidenceOccurrence as Ar, ArtifactPatchResponse as At, ArtifactLifecycleHistoryEntry as B, ArtifactContextTree as Bn, ARTIFACT_SLUG_PATTERN as Br, artifactPatchSegment as Bt, ArtifactLifecycleGetRequestSchema as C, ArtifactResolveContextRequest as Cn, ArtifactLifecycleHookDefinition as Cr, ArtifactPatchOperationResult as Ct, ArtifactLifecycleHistoryRequestSchema as D, ArtifactReviseRequest as Dn, BeforeArtifactHookContext as Dr, ArtifactPatchPersistedSchema as Dt, ArtifactLifecycleHistoryRequest as E, ArtifactResolveResponse as En, ArtifactLifecycleSemanticEvent as Er, ArtifactPatchPathSchema as Et, toArtifactLifecycleFailure as F, ArtifactResolvePartResponse as Fn, EvidenceResolveResponse as Fr, ArtifactPatchTarget as Ft, ArtifactLifecycleRejection as G, ArtifactContextUnresolvedReason as Gn, ARTIFACT_VALUE_TYPE_KEYWORD as Gr, ArtifactResolvePartError as Gt, ArtifactLifecycleIdentitySchema as H, UnresolvedArtifactContextNode as Hn, ArtifactSlugSchema as Hr, ARTIFACT_RESOLVE_PART_ERROR_CODES as Ht, ARTIFACT_LIFECYCLE_REJECTED_CODE as I, ArtifactResolvePartResponseSchema as In, EvidenceResolveResponseSchema as Ir, ArtifactPatchTargetSchema as It, ArtifactLifecycleSituationSchema as J, ResolvedArtifactContextWireSchema as Jn, EvidenceValueSchema$1 as Jr, checkArtifactPartIds as Jt, ArtifactLifecycleRejectionSchema as K, ArtifactContextUnresolvedReasonSchema as Kn, EVIDENCE_VALUE_TYPE as Kr, ArtifactResolvePartErrorCode as Kt, ArtifactLifecycleCurrent as L, hydrateArtifactContextTree as Ln, mayArtifactDataCarryProperty as Lr, artifactPatchFilterName as Lt, ArtifactLifecycleSchemas as M, ArtifactSubjects$1 as Mn, extractEvidenceOccurrences as Mr, ArtifactPatchSegment as Mt, ArtifactLifecycleTransitionResponse as N, ArtifactResolvePartRequest as Nn, EvidenceResolveRequest as Nr, ArtifactPatchSuccess as Nt, ArtifactLifecycleHistoryResponse as O, ArtifactReviseResponse as On, BeforeArtifactHookRegistration as Or, ArtifactPatchRequest as Ot, ArtifactLifecycleTransitionResponseSchema as P, ArtifactResolvePartRequestSchema as Pn, EvidenceResolveRequestSchema as Pr, ArtifactPatchSuccessSchema as Pt, ArtifactLifecycleTransitionCommandSchema as Q, ArtifactContextKnownRenderHint as Qn, ARTIFACT_COLLECTION_ELEMENT_SEGMENT as Qt, ArtifactLifecycleCurrentSchema as R, ArtifactContextNode as Rn, ARTIFACT_DERIVED_SLUG_MAX_LENGTH as Rr, artifactPatchInstructions as Rt, ArtifactLifecycleGetRequest as S, ArtifactRelationTypeRegisterResponse as Sn, ArtifactHookFilter as Sr, ArtifactPatchMigrationSchema as St, ArtifactLifecycleGetResponseSchema as T, ArtifactResolveRequest as Tn, ArtifactLifecycleHookRegistration$1 as Tr, ArtifactPatchOperator as Tt, ArtifactLifecycleInitializedEntry as U, ArtifactContextRefEntry as Un, deriveArtifactSlug as Ur, ArtifactPartResolution as Ut, ArtifactLifecycleHistoryEntrySchema as V, ResolvedArtifactContextNode as Vn, ArtifactSlug as Vr, artifactPatchSegments as Vt, ArtifactLifecycleInitializedEntrySchema as W, ArtifactContextRefEntrySchema as Wn, slugify as Wr, ArtifactRelationSourceIssue as Wt, ArtifactLifecycleSnapshotSchema as X, ARTIFACT_CONTEXT_RELATION_DIRECTIONS as Xn, resolveArtifactPart as Xt, ArtifactLifecycleSnapshot as Y, artifactRevisionKey as Yn, checkArtifactRelationSourceParts as Yt, ArtifactLifecycleTransitionCommand as Z, ARTIFACT_CONTEXT_RENDER_HINTS as Zn, validateArtifactPartAreas as Zt, serializeArtifactRelationTargetIdentity as _, ArtifactQueryResponse as _n, defineArtifactKind as _r, ArtifactPatchFailureSchema as _t, UniquenessKeyIssueReason as a, ArtifactCreatedPayload as an, ArtifactContextSelector$1 as ar, initialArtifactLifecycle as at, ArtifactLifecycleFailure as b, ArtifactRelationTypeListResponse as bn, ArtifactDraft as br, ArtifactPatchIssueSchema as bt, UniquenessSelectorCapability as c, ArtifactKindChangedPayload as cn, ArtifactDataChecker as cr, ARTIFACT_PATCH_OPERATORS as ct, buildUniquenessKeys as d, ArtifactKindRegisterRequest as dn, compileArtifactDataChecker as dr, ArtifactPatchDocument as dt, inspectArtifactDataLocation as en, ArtifactContextRelationDirectionSchema as er, ArtifactLifecycleTransitionIntentSchema as et, describeUniquenessKey as f, ArtifactKindRegisterResponse as fn, compileArtifactDataSchema as fr, ArtifactPatchDocumentSchema as ft, describeArtifactRelationTargetIdentity as g, ArtifactPatchSubjectResponse as gn, ArtifactOf as gr, ArtifactPatchErrorSchema as gt, artifactRelationTargetIdentity as h, ArtifactPatchSubjectRequest as hn, ArtifactKindDefinition as hr, ArtifactPatchErrorCode as ht, UniquenessKeyIssue as i, ArtifactCreateResponse as in, ArtifactContextRenderHintSchema as ir, advanceArtifactLifecycle as it, ArtifactLifecycleRejectedPayloadSchema as j, ArtifactStatusChangedPayload as jn, EvidenceOccurrenceExtractionOptions as jr, ArtifactPatchResponseSchema as jt, ArtifactLifecycleHistoryResponseSchema as k, ArtifactRevisedPayload as kn, defineArtifactLifecycleHooks as kr, ArtifactPatchRequestSchema as kt, UniquenessSupportIssue as l, ArtifactKindListRequest as ln, ArtifactDataIssue as lr, ArtifactPatchArrayFilter as lt, ArtifactRelationTargetIdentitySchema as m, ArtifactObservationAddedPayload as mn, ArtifactDataOf as mr, ArtifactPatchError as mt, UniquenessDataKeyPart as n, readArtifactTitle as nn, ArtifactContextRelationSelectorSchema as nr, ArtifactLifecycleTransitionedEntrySchema as nt, UniquenessKeyPart as o, ArtifactEvidenceResolveRequest as on, ArtifactContextSelectorSchema as or, isArtifactLifecycleTransitionAllowed as ot, ArtifactRelationTargetIdentity as p, ArtifactNamespace as pn, AnyArtifactKindDefinition as pr, ArtifactPatchDryRunSchema as pt, ArtifactLifecycleSituation as q, ResolvedArtifactContextWire$1 as qn, EvidenceValue$1 as qr, ArtifactResolvePartErrorSchema as qt, UniquenessKey as r, ArtifactCreateRequest as rn, ArtifactContextRenderHint as rr, ArtifactLifecycleVersionSchema as rt, UniquenessRelationTargetKeyPart as s, ArtifactEvidenceResolveResponse$1 as sn, ArtifactDataCheck as sr, ARTIFACT_PATCH_ERROR_CODES as st, BuildUniquenessKeysResult as t, isArtifactDataPathDeclared as tn, ArtifactContextRelationSelector as tr, ArtifactLifecycleTransitionedEntry as tt, assessUniquenessSupport as u, ArtifactKindListResponse as un, ArtifactDataValidator as ur, ArtifactPatchArrayFilterSchema as ut, ArtifactLifecycleCommittedPayload as v, ArtifactRelationAddedPayload as vn, AfterArtifactHookContext as vr, ArtifactPatchInstruction as vt, ArtifactLifecycleGetResponse as w, ArtifactResolveContextResponse as wn, ArtifactLifecycleHookEvent as wr, ArtifactPatchOperationResultSchema as wt, ArtifactLifecycleFailureSchema as x, ArtifactRelationTypeRegisterRequest as xn, ArtifactDraftPatch as xr, ArtifactPatchMigration as xt, ArtifactLifecycleCommittedPayloadSchema as y, ArtifactRelationTypeListRequest as yn, AfterArtifactHookRegistration as yr, ArtifactPatchIssue as yt, ArtifactLifecycleError as z, ArtifactContextRootNode as zn, ARTIFACT_SLUG_FIELD as zr, artifactPatchPathFilterNames as zt };
12236
+ //#region core/contracts/src/artifact/relation-requirements.d.ts
12237
+ /** Why an applicable relation requirement is not met by a write. */
12238
+ type RelationRequirementIssueReason = 'below-min-items' | 'above-max-items';
12239
+ /** One unmet relation requirement, as reported by {@link evaluateRelationRequirements}. */
12240
+ interface RelationRequirementIssue {
12241
+ /** Zero-based index of the requirement in the declared requirements array. */
12242
+ readonly index: number;
12243
+ /** The requirement that is not met. */
12244
+ readonly requirement: ArtifactRelationRequirement;
12245
+ /** Whether the count falls below `minItems` or exceeds `maxItems`. */
12246
+ readonly reason: RelationRequirementIssueReason;
12247
+ /** Number of distinct target artifacts that matched the requirement. */
12248
+ readonly count: number;
12249
+ }
12250
+ /**
12251
+ * Evaluates registration relation requirements against one write; pure.
12252
+ *
12253
+ * A requirement counts the distinct target artifacts (by kind and id, revision
12254
+ * pins ignored) among relations of its `relationType` that start at the
12255
+ * artifact itself (no `sourceLocalId`) and, when `targetKinds` is non-empty,
12256
+ * target one of those kinds. Non-artifact targets never count.
12257
+ *
12258
+ * A requirement with `when` applies only when the value at `when.path` in
12259
+ * `data` is a scalar strictly equal to `when.equals`; a missing, null,
12260
+ * non-scalar, or unequal value skips the requirement without an issue.
12261
+ *
12262
+ * The caller decides which relations to pass, e.g. only the relations its
12263
+ * relation-type registry permits; this function does not filter them further.
12264
+ * @param requirements - Declared `registration.relations` of the written kind.
12265
+ * @param relations - Relations of the write that may count toward requirements.
12266
+ * @param data - Data of the artifact being written; only read for `when` conditions.
12267
+ * @returns One issue per violated bound of each applicable requirement, in declaration order.
12268
+ */
12269
+ declare function evaluateRelationRequirements(requirements: readonly ArtifactRelationRequirement[] | undefined, relations: readonly ArtifactRelation[], data: Record<string, unknown> | undefined): RelationRequirementIssue[];
12270
+ //#endregion
12271
+ export { ArtifactLifecycleSnapshotSchema as $, ARTIFACT_CONTEXT_RELATION_DIRECTIONS as $n, resolveArtifactPart as $t, ArtifactLifecycleHistoryRequestSchema as A, ArtifactReviseRequest as An, BeforeArtifactHookContext as Ar, ArtifactPatchPersistedSchema as At, ArtifactLifecycleCurrent as B, hydrateArtifactContextTree as Bn, mayArtifactDataCarryProperty as Br, artifactPatchFilterName as Bt, ArtifactLifecycleFailure as C, ArtifactRelationTypeListResponse as Cn, ArtifactDraft as Cr, ArtifactPatchIssueSchema as Ct, ArtifactLifecycleGetResponse as D, ArtifactResolveContextResponse as Dn, ArtifactLifecycleHookEvent as Dr, ArtifactPatchOperationResultSchema as Dt, ArtifactLifecycleGetRequestSchema as E, ArtifactResolveContextRequest as En, ArtifactLifecycleHookDefinition as Er, ArtifactPatchOperationResult as Et, ArtifactLifecycleSchemas as F, ArtifactSubjects$1 as Fn, extractEvidenceOccurrences as Fr, ArtifactPatchSegment as Ft, ArtifactLifecycleIdentitySchema as G, UnresolvedArtifactContextNode as Gn, ArtifactSlugSchema as Gr, ARTIFACT_RESOLVE_PART_ERROR_CODES as Gt, ArtifactLifecycleError as H, ArtifactContextRootNode as Hn, ARTIFACT_SLUG_FIELD as Hr, artifactPatchPathFilterNames as Ht, ArtifactLifecycleTransitionResponse as I, ArtifactResolvePartRequest as In, EvidenceResolveRequest as Ir, ArtifactPatchSuccess as It, ArtifactLifecycleRejection as J, ArtifactContextUnresolvedReason as Jn, ARTIFACT_VALUE_TYPE_KEYWORD as Jr, ArtifactResolvePartError as Jt, ArtifactLifecycleInitializedEntry as K, ArtifactContextRefEntry as Kn, deriveArtifactSlug as Kr, ArtifactPartResolution as Kt, ArtifactLifecycleTransitionResponseSchema as L, ArtifactResolvePartRequestSchema as Ln, EvidenceResolveRequestSchema as Lr, ArtifactPatchSuccessSchema as Lt, ArtifactLifecycleHistoryResponseSchema as M, ArtifactRevisedPayload as Mn, defineArtifactLifecycleHooks as Mr, ArtifactPatchRequestSchema as Mt, ArtifactLifecycleRejectedPayload as N, ArtifactSchemas$1 as Nn, EvidenceOccurrence as Nr, ArtifactPatchResponse as Nt, ArtifactLifecycleGetResponseSchema as O, ArtifactResolveRequest as On, ArtifactLifecycleHookRegistration$1 as Or, ArtifactPatchOperator as Ot, ArtifactLifecycleRejectedPayloadSchema as P, ArtifactStatusChangedPayload as Pn, EvidenceOccurrenceExtractionOptions as Pr, ArtifactPatchResponseSchema as Pt, ArtifactLifecycleSnapshot as Q, artifactRevisionKey as Qn, checkArtifactRelationSourceParts as Qt, toArtifactLifecycleFailure as R, ArtifactResolvePartResponse as Rn, EvidenceResolveResponse as Rr, ArtifactPatchTarget as Rt, ArtifactLifecycleCommittedPayloadSchema as S, ArtifactRelationTypeListRequest as Sn, AfterArtifactHookRegistration as Sr, ArtifactPatchIssue as St, ArtifactLifecycleGetRequest as T, ArtifactRelationTypeRegisterResponse as Tn, ArtifactHookFilter as Tr, ArtifactPatchMigrationSchema as Tt, ArtifactLifecycleHistoryEntry as U, ArtifactContextTree as Un, ARTIFACT_SLUG_PATTERN as Ur, artifactPatchSegment as Ut, ArtifactLifecycleCurrentSchema as V, ArtifactContextNode as Vn, ARTIFACT_DERIVED_SLUG_MAX_LENGTH as Vr, artifactPatchInstructions as Vt, ArtifactLifecycleHistoryEntrySchema as W, ResolvedArtifactContextNode as Wn, ArtifactSlug as Wr, artifactPatchSegments as Wt, ArtifactLifecycleSituation as X, ResolvedArtifactContextWire$1 as Xn, EvidenceValue$1 as Xr, ArtifactResolvePartErrorSchema as Xt, ArtifactLifecycleRejectionSchema as Y, ArtifactContextUnresolvedReasonSchema as Yn, EVIDENCE_VALUE_TYPE as Yr, ArtifactResolvePartErrorCode as Yt, ArtifactLifecycleSituationSchema as Z, ResolvedArtifactContextWireSchema as Zn, EvidenceValueSchema$1 as Zr, checkArtifactPartIds as Zt, ArtifactRelationTargetIdentitySchema as _, ArtifactObservationAddedPayload as _n, ArtifactDataOf as _r, ArtifactPatchError as _t, UniquenessDataKeyPart as a, readArtifactTitle as an, ArtifactContextRelationSelectorSchema as ar, ArtifactLifecycleTransitionedEntrySchema as at, serializeArtifactRelationTargetIdentity as b, ArtifactQueryResponse as bn, defineArtifactKind as br, ArtifactPatchFailureSchema as bt, UniquenessKeyIssueReason as c, ArtifactCreatedPayload as cn, ArtifactContextSelector$1 as cr, initialArtifactLifecycle as ct, UniquenessSelectorCapability as d, ArtifactKindChangedPayload as dn, ArtifactDataChecker as dr, ARTIFACT_PATCH_OPERATORS as dt, validateArtifactPartAreas as en, ARTIFACT_CONTEXT_RENDER_HINTS as er, ArtifactLifecycleTransitionCommand as et, UniquenessSupportIssue as f, ArtifactKindListRequest as fn, ArtifactDataIssue as fr, ArtifactPatchArrayFilter as ft, ArtifactRelationTargetIdentity as g, ArtifactNamespace as gn, AnyArtifactKindDefinition as gr, ArtifactPatchDryRunSchema as gt, describeUniquenessKey as h, ArtifactKindRegisterResponse as hn, compileArtifactDataSchema as hr, ArtifactPatchDocumentSchema as ht, BuildUniquenessKeysResult as i, isArtifactDataPathDeclared as in, ArtifactContextRelationSelector as ir, ArtifactLifecycleTransitionedEntry as it, ArtifactLifecycleHistoryResponse as j, ArtifactReviseResponse as jn, BeforeArtifactHookRegistration as jr, ArtifactPatchRequest as jt, ArtifactLifecycleHistoryRequest as k, ArtifactResolveResponse as kn, ArtifactLifecycleSemanticEvent as kr, ArtifactPatchPathSchema as kt, UniquenessKeyPart as l, ArtifactEvidenceResolveRequest as ln, ArtifactContextSelectorSchema as lr, isArtifactLifecycleTransitionAllowed as lt, buildUniquenessKeys as m, ArtifactKindRegisterRequest as mn, compileArtifactDataChecker as mr, ArtifactPatchDocument as mt, RelationRequirementIssueReason as n, ArtifactSchemaFragment as nn, ArtifactContextRelationDirection as nr, ArtifactLifecycleTransitionIntent as nt, UniquenessKey as o, ArtifactCreateRequest as on, ArtifactContextRenderHint as or, ArtifactLifecycleVersionSchema as ot, assessUniquenessSupport as p, ArtifactKindListResponse as pn, ArtifactDataValidator as pr, ArtifactPatchArrayFilterSchema as pt, ArtifactLifecycleInitializedEntrySchema as q, ArtifactContextRefEntrySchema as qn, slugify as qr, ArtifactRelationSourceIssue as qt, evaluateRelationRequirements as r, inspectArtifactDataLocation as rn, ArtifactContextRelationDirectionSchema as rr, ArtifactLifecycleTransitionIntentSchema as rt, UniquenessKeyIssue as s, ArtifactCreateResponse as sn, ArtifactContextRenderHintSchema as sr, advanceArtifactLifecycle as st, RelationRequirementIssue as t, ARTIFACT_COLLECTION_ELEMENT_SEGMENT as tn, ArtifactContextKnownRenderHint as tr, ArtifactLifecycleTransitionCommandSchema as tt, UniquenessRelationTargetKeyPart as u, ArtifactEvidenceResolveResponse$1 as un, ArtifactDataCheck as ur, ARTIFACT_PATCH_ERROR_CODES as ut, artifactRelationTargetIdentity as v, ArtifactPatchSubjectRequest as vn, ArtifactKindDefinition as vr, ArtifactPatchErrorCode as vt, ArtifactLifecycleFailureSchema as w, ArtifactRelationTypeRegisterRequest as wn, ArtifactDraftPatch as wr, ArtifactPatchMigration as wt, ArtifactLifecycleCommittedPayload as x, ArtifactRelationAddedPayload as xn, AfterArtifactHookContext as xr, ArtifactPatchInstruction as xt, describeArtifactRelationTargetIdentity as y, ArtifactPatchSubjectResponse as yn, ArtifactOf as yr, ArtifactPatchErrorSchema as yt, ARTIFACT_LIFECYCLE_REJECTED_CODE as z, ArtifactResolvePartResponseSchema as zn, EvidenceResolveResponseSchema as zr, ArtifactPatchTargetSchema as zt };
@@ -1,4 +1,4 @@
1
- import { x as ArtifactRevision$1 } from "./schemas-B2fs9-uF.mjs";
1
+ import { x as ArtifactRevision$1 } from "./schemas-BNQtL3Ln.mjs";
2
2
  import { a as JsonObjectContractSchema, l as JsonValue$1 } from "./json-value--pv1-OHx.mjs";
3
3
  import { n as AutomationTriggerBinding$1, o as AutomationTriggerParams, u as DefinedAutomationTrigger } from "./definition-DWhjp0db.mjs";
4
4
  import { z } from "zod";
@@ -145,10 +145,10 @@ type WorkflowSourceLocation = z.infer<typeof WorkflowSourceLocationSchema>;
145
145
  * - `sequence` — ordered list of child nodes (the structural container)
146
146
  */
147
147
  declare const WorkflowNodeTypeSchema: z.ZodEnum<{
148
- sequence: "sequence";
149
148
  station: "station";
150
149
  "delegate-agent": "delegate-agent";
151
150
  "delegate-role": "delegate-role";
151
+ sequence: "sequence";
152
152
  parallel: "parallel";
153
153
  gate: "gate";
154
154
  iterate: "iterate";
@@ -814,8 +814,8 @@ declare const ExecutionStatusSchema$1: z.ZodEnum<{
814
814
  completed: "completed";
815
815
  cancelled: "cancelled";
816
816
  failed: "failed";
817
- paused: "paused";
818
817
  running: "running";
818
+ paused: "paused";
819
819
  finalizing: "finalizing";
820
820
  }>;
821
821
  type ExecutionStatus = z.infer<typeof ExecutionStatusSchema$1>;
@@ -831,8 +831,8 @@ declare const WorkflowExecutionSchema$1: z.ZodObject<{
831
831
  completed: "completed";
832
832
  cancelled: "cancelled";
833
833
  failed: "failed";
834
- paused: "paused";
835
834
  running: "running";
835
+ paused: "paused";
836
836
  finalizing: "finalizing";
837
837
  }>;
838
838
  inputs: z.ZodType<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue, z.core.$ZodTypeInternals<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue>>;
@@ -872,10 +872,10 @@ declare const WorkflowFrameStateSchema$1: z.ZodObject<{
872
872
  frameId: z.ZodString;
873
873
  nodeId: z.ZodString;
874
874
  nodeType: z.ZodEnum<{
875
- sequence: "sequence";
876
875
  station: "station";
877
876
  "delegate-agent": "delegate-agent";
878
877
  "delegate-role": "delegate-role";
878
+ sequence: "sequence";
879
879
  parallel: "parallel";
880
880
  gate: "gate";
881
881
  iterate: "iterate";
@@ -1228,8 +1228,8 @@ declare const ExecutionListQuerySchema$1: z.ZodObject<{
1228
1228
  completed: "completed";
1229
1229
  cancelled: "cancelled";
1230
1230
  failed: "failed";
1231
- paused: "paused";
1232
1231
  running: "running";
1232
+ paused: "paused";
1233
1233
  finalizing: "finalizing";
1234
1234
  }>>;
1235
1235
  artifactRef: z.ZodOptional<z.ZodObject<{
@@ -3729,8 +3729,8 @@ declare const WorkflowSchemas: {
3729
3729
  completed: "completed";
3730
3730
  cancelled: "cancelled";
3731
3731
  failed: "failed";
3732
- paused: "paused";
3733
3732
  running: "running";
3733
+ paused: "paused";
3734
3734
  finalizing: "finalizing";
3735
3735
  }>;
3736
3736
  }, z.core.$strip>;
@@ -3808,8 +3808,8 @@ declare const WorkflowSchemas: {
3808
3808
  completed: "completed";
3809
3809
  cancelled: "cancelled";
3810
3810
  failed: "failed";
3811
- paused: "paused";
3812
3811
  running: "running";
3812
+ paused: "paused";
3813
3813
  finalizing: "finalizing";
3814
3814
  }>;
3815
3815
  inputs: z.ZodType<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue, z.core.$ZodTypeInternals<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue>>;
@@ -3866,8 +3866,8 @@ declare const WorkflowSchemas: {
3866
3866
  completed: "completed";
3867
3867
  cancelled: "cancelled";
3868
3868
  failed: "failed";
3869
- paused: "paused";
3870
3869
  running: "running";
3870
+ paused: "paused";
3871
3871
  finalizing: "finalizing";
3872
3872
  }>>;
3873
3873
  artifactRef: z.ZodOptional<z.ZodObject<{
@@ -3890,8 +3890,8 @@ declare const WorkflowSchemas: {
3890
3890
  completed: "completed";
3891
3891
  cancelled: "cancelled";
3892
3892
  failed: "failed";
3893
- paused: "paused";
3894
3893
  running: "running";
3894
+ paused: "paused";
3895
3895
  finalizing: "finalizing";
3896
3896
  }>;
3897
3897
  inputs: z.ZodType<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue, z.core.$ZodTypeInternals<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue>>;
@@ -3947,8 +3947,8 @@ declare const WorkflowSchemas: {
3947
3947
  completed: "completed";
3948
3948
  cancelled: "cancelled";
3949
3949
  failed: "failed";
3950
- paused: "paused";
3951
3950
  running: "running";
3951
+ paused: "paused";
3952
3952
  finalizing: "finalizing";
3953
3953
  }>;
3954
3954
  inputs: z.ZodType<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue, z.core.$ZodTypeInternals<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue>>;
@@ -4129,10 +4129,10 @@ declare const WorkflowSchemas: {
4129
4129
  frameId: z.ZodString;
4130
4130
  nodeId: z.ZodString;
4131
4131
  nodeType: z.ZodEnum<{
4132
- sequence: "sequence";
4133
4132
  station: "station";
4134
4133
  "delegate-agent": "delegate-agent";
4135
4134
  "delegate-role": "delegate-role";
4135
+ sequence: "sequence";
4136
4136
  parallel: "parallel";
4137
4137
  gate: "gate";
4138
4138
  iterate: "iterate";
@@ -4950,10 +4950,10 @@ declare const WorkflowSchemas: {
4950
4950
  frameId: z.ZodString;
4951
4951
  nodeId: z.ZodString;
4952
4952
  nodeType: z.ZodEnum<{
4953
- sequence: "sequence";
4954
4953
  station: "station";
4955
4954
  "delegate-agent": "delegate-agent";
4956
4955
  "delegate-role": "delegate-role";
4956
+ sequence: "sequence";
4957
4957
  parallel: "parallel";
4958
4958
  gate: "gate";
4959
4959
  iterate: "iterate";
@@ -5081,8 +5081,8 @@ declare const WorkflowSchemas: {
5081
5081
  completed: "completed";
5082
5082
  cancelled: "cancelled";
5083
5083
  failed: "failed";
5084
- paused: "paused";
5085
5084
  running: "running";
5085
+ paused: "paused";
5086
5086
  finalizing: "finalizing";
5087
5087
  }>;
5088
5088
  startedAt: z.ZodNumber;
@@ -5112,10 +5112,10 @@ declare const WorkflowSchemas: {
5112
5112
  frameId: z.ZodString;
5113
5113
  nodeId: z.ZodString;
5114
5114
  nodeType: z.ZodEnum<{
5115
- sequence: "sequence";
5116
5115
  station: "station";
5117
5116
  "delegate-agent": "delegate-agent";
5118
5117
  "delegate-role": "delegate-role";
5118
+ sequence: "sequence";
5119
5119
  parallel: "parallel";
5120
5120
  gate: "gate";
5121
5121
  iterate: "iterate";
@@ -5159,8 +5159,8 @@ declare const WorkflowSchemas: {
5159
5159
  completed: "completed";
5160
5160
  cancelled: "cancelled";
5161
5161
  failed: "failed";
5162
- paused: "paused";
5163
5162
  running: "running";
5163
+ paused: "paused";
5164
5164
  finalizing: "finalizing";
5165
5165
  }>>;
5166
5166
  limit: z.ZodOptional<z.ZodNumber>;
@@ -5176,8 +5176,8 @@ declare const WorkflowSchemas: {
5176
5176
  completed: "completed";
5177
5177
  cancelled: "cancelled";
5178
5178
  failed: "failed";
5179
- paused: "paused";
5180
5179
  running: "running";
5180
+ paused: "paused";
5181
5181
  finalizing: "finalizing";
5182
5182
  }>;
5183
5183
  startedAt: z.ZodNumber;
@@ -6711,8 +6711,8 @@ declare const WorkflowNamespace$1: _$_makaio_core0.BusNamespaceDefinition<"workf
6711
6711
  completed: "completed";
6712
6712
  cancelled: "cancelled";
6713
6713
  failed: "failed";
6714
- paused: "paused";
6715
6714
  running: "running";
6715
+ paused: "paused";
6716
6716
  finalizing: "finalizing";
6717
6717
  }>;
6718
6718
  }, z.core.$strip>;
@@ -6790,8 +6790,8 @@ declare const WorkflowNamespace$1: _$_makaio_core0.BusNamespaceDefinition<"workf
6790
6790
  completed: "completed";
6791
6791
  cancelled: "cancelled";
6792
6792
  failed: "failed";
6793
- paused: "paused";
6794
6793
  running: "running";
6794
+ paused: "paused";
6795
6795
  finalizing: "finalizing";
6796
6796
  }>;
6797
6797
  inputs: z.ZodType<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue, z.core.$ZodTypeInternals<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue>>;
@@ -6848,8 +6848,8 @@ declare const WorkflowNamespace$1: _$_makaio_core0.BusNamespaceDefinition<"workf
6848
6848
  completed: "completed";
6849
6849
  cancelled: "cancelled";
6850
6850
  failed: "failed";
6851
- paused: "paused";
6852
6851
  running: "running";
6852
+ paused: "paused";
6853
6853
  finalizing: "finalizing";
6854
6854
  }>>;
6855
6855
  artifactRef: z.ZodOptional<z.ZodObject<{
@@ -6872,8 +6872,8 @@ declare const WorkflowNamespace$1: _$_makaio_core0.BusNamespaceDefinition<"workf
6872
6872
  completed: "completed";
6873
6873
  cancelled: "cancelled";
6874
6874
  failed: "failed";
6875
- paused: "paused";
6876
6875
  running: "running";
6876
+ paused: "paused";
6877
6877
  finalizing: "finalizing";
6878
6878
  }>;
6879
6879
  inputs: z.ZodType<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue, z.core.$ZodTypeInternals<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue>>;
@@ -6929,8 +6929,8 @@ declare const WorkflowNamespace$1: _$_makaio_core0.BusNamespaceDefinition<"workf
6929
6929
  completed: "completed";
6930
6930
  cancelled: "cancelled";
6931
6931
  failed: "failed";
6932
- paused: "paused";
6933
6932
  running: "running";
6933
+ paused: "paused";
6934
6934
  finalizing: "finalizing";
6935
6935
  }>;
6936
6936
  inputs: z.ZodType<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue, z.core.$ZodTypeInternals<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue>>;
@@ -7111,10 +7111,10 @@ declare const WorkflowNamespace$1: _$_makaio_core0.BusNamespaceDefinition<"workf
7111
7111
  frameId: z.ZodString;
7112
7112
  nodeId: z.ZodString;
7113
7113
  nodeType: z.ZodEnum<{
7114
- sequence: "sequence";
7115
7114
  station: "station";
7116
7115
  "delegate-agent": "delegate-agent";
7117
7116
  "delegate-role": "delegate-role";
7117
+ sequence: "sequence";
7118
7118
  parallel: "parallel";
7119
7119
  gate: "gate";
7120
7120
  iterate: "iterate";
@@ -7932,10 +7932,10 @@ declare const WorkflowNamespace$1: _$_makaio_core0.BusNamespaceDefinition<"workf
7932
7932
  frameId: z.ZodString;
7933
7933
  nodeId: z.ZodString;
7934
7934
  nodeType: z.ZodEnum<{
7935
- sequence: "sequence";
7936
7935
  station: "station";
7937
7936
  "delegate-agent": "delegate-agent";
7938
7937
  "delegate-role": "delegate-role";
7938
+ sequence: "sequence";
7939
7939
  parallel: "parallel";
7940
7940
  gate: "gate";
7941
7941
  iterate: "iterate";
@@ -8063,8 +8063,8 @@ declare const WorkflowNamespace$1: _$_makaio_core0.BusNamespaceDefinition<"workf
8063
8063
  completed: "completed";
8064
8064
  cancelled: "cancelled";
8065
8065
  failed: "failed";
8066
- paused: "paused";
8067
8066
  running: "running";
8067
+ paused: "paused";
8068
8068
  finalizing: "finalizing";
8069
8069
  }>;
8070
8070
  startedAt: z.ZodNumber;
@@ -8094,10 +8094,10 @@ declare const WorkflowNamespace$1: _$_makaio_core0.BusNamespaceDefinition<"workf
8094
8094
  frameId: z.ZodString;
8095
8095
  nodeId: z.ZodString;
8096
8096
  nodeType: z.ZodEnum<{
8097
- sequence: "sequence";
8098
8097
  station: "station";
8099
8098
  "delegate-agent": "delegate-agent";
8100
8099
  "delegate-role": "delegate-role";
8100
+ sequence: "sequence";
8101
8101
  parallel: "parallel";
8102
8102
  gate: "gate";
8103
8103
  iterate: "iterate";
@@ -8141,8 +8141,8 @@ declare const WorkflowNamespace$1: _$_makaio_core0.BusNamespaceDefinition<"workf
8141
8141
  completed: "completed";
8142
8142
  cancelled: "cancelled";
8143
8143
  failed: "failed";
8144
- paused: "paused";
8145
8144
  running: "running";
8145
+ paused: "paused";
8146
8146
  finalizing: "finalizing";
8147
8147
  }>>;
8148
8148
  limit: z.ZodOptional<z.ZodNumber>;
@@ -8158,8 +8158,8 @@ declare const WorkflowNamespace$1: _$_makaio_core0.BusNamespaceDefinition<"workf
8158
8158
  completed: "completed";
8159
8159
  cancelled: "cancelled";
8160
8160
  failed: "failed";
8161
- paused: "paused";
8162
8161
  running: "running";
8162
+ paused: "paused";
8163
8163
  finalizing: "finalizing";
8164
8164
  }>;
8165
8165
  startedAt: z.ZodNumber;
@@ -9693,8 +9693,8 @@ declare const WorkflowSubjects$1: _$_makaio_core0.BusSubjects<_$_makaio_core0.Fl
9693
9693
  completed: "completed";
9694
9694
  cancelled: "cancelled";
9695
9695
  failed: "failed";
9696
- paused: "paused";
9697
9696
  running: "running";
9697
+ paused: "paused";
9698
9698
  finalizing: "finalizing";
9699
9699
  }>;
9700
9700
  }, z.core.$strip>;
@@ -9772,8 +9772,8 @@ declare const WorkflowSubjects$1: _$_makaio_core0.BusSubjects<_$_makaio_core0.Fl
9772
9772
  completed: "completed";
9773
9773
  cancelled: "cancelled";
9774
9774
  failed: "failed";
9775
- paused: "paused";
9776
9775
  running: "running";
9776
+ paused: "paused";
9777
9777
  finalizing: "finalizing";
9778
9778
  }>;
9779
9779
  inputs: z.ZodType<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue, z.core.$ZodTypeInternals<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue>>;
@@ -9830,8 +9830,8 @@ declare const WorkflowSubjects$1: _$_makaio_core0.BusSubjects<_$_makaio_core0.Fl
9830
9830
  completed: "completed";
9831
9831
  cancelled: "cancelled";
9832
9832
  failed: "failed";
9833
- paused: "paused";
9834
9833
  running: "running";
9834
+ paused: "paused";
9835
9835
  finalizing: "finalizing";
9836
9836
  }>>;
9837
9837
  artifactRef: z.ZodOptional<z.ZodObject<{
@@ -9854,8 +9854,8 @@ declare const WorkflowSubjects$1: _$_makaio_core0.BusSubjects<_$_makaio_core0.Fl
9854
9854
  completed: "completed";
9855
9855
  cancelled: "cancelled";
9856
9856
  failed: "failed";
9857
- paused: "paused";
9858
9857
  running: "running";
9858
+ paused: "paused";
9859
9859
  finalizing: "finalizing";
9860
9860
  }>;
9861
9861
  inputs: z.ZodType<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue, z.core.$ZodTypeInternals<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue>>;
@@ -9911,8 +9911,8 @@ declare const WorkflowSubjects$1: _$_makaio_core0.BusSubjects<_$_makaio_core0.Fl
9911
9911
  completed: "completed";
9912
9912
  cancelled: "cancelled";
9913
9913
  failed: "failed";
9914
- paused: "paused";
9915
9914
  running: "running";
9915
+ paused: "paused";
9916
9916
  finalizing: "finalizing";
9917
9917
  }>;
9918
9918
  inputs: z.ZodType<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue, z.core.$ZodTypeInternals<_$_makaio_contracts0.JsonValue, _$_makaio_contracts0.JsonValue>>;
@@ -10093,10 +10093,10 @@ declare const WorkflowSubjects$1: _$_makaio_core0.BusSubjects<_$_makaio_core0.Fl
10093
10093
  frameId: z.ZodString;
10094
10094
  nodeId: z.ZodString;
10095
10095
  nodeType: z.ZodEnum<{
10096
- sequence: "sequence";
10097
10096
  station: "station";
10098
10097
  "delegate-agent": "delegate-agent";
10099
10098
  "delegate-role": "delegate-role";
10099
+ sequence: "sequence";
10100
10100
  parallel: "parallel";
10101
10101
  gate: "gate";
10102
10102
  iterate: "iterate";
@@ -10914,10 +10914,10 @@ declare const WorkflowSubjects$1: _$_makaio_core0.BusSubjects<_$_makaio_core0.Fl
10914
10914
  frameId: z.ZodString;
10915
10915
  nodeId: z.ZodString;
10916
10916
  nodeType: z.ZodEnum<{
10917
- sequence: "sequence";
10918
10917
  station: "station";
10919
10918
  "delegate-agent": "delegate-agent";
10920
10919
  "delegate-role": "delegate-role";
10920
+ sequence: "sequence";
10921
10921
  parallel: "parallel";
10922
10922
  gate: "gate";
10923
10923
  iterate: "iterate";
@@ -11045,8 +11045,8 @@ declare const WorkflowSubjects$1: _$_makaio_core0.BusSubjects<_$_makaio_core0.Fl
11045
11045
  completed: "completed";
11046
11046
  cancelled: "cancelled";
11047
11047
  failed: "failed";
11048
- paused: "paused";
11049
11048
  running: "running";
11049
+ paused: "paused";
11050
11050
  finalizing: "finalizing";
11051
11051
  }>;
11052
11052
  startedAt: z.ZodNumber;
@@ -11076,10 +11076,10 @@ declare const WorkflowSubjects$1: _$_makaio_core0.BusSubjects<_$_makaio_core0.Fl
11076
11076
  frameId: z.ZodString;
11077
11077
  nodeId: z.ZodString;
11078
11078
  nodeType: z.ZodEnum<{
11079
- sequence: "sequence";
11080
11079
  station: "station";
11081
11080
  "delegate-agent": "delegate-agent";
11082
11081
  "delegate-role": "delegate-role";
11082
+ sequence: "sequence";
11083
11083
  parallel: "parallel";
11084
11084
  gate: "gate";
11085
11085
  iterate: "iterate";
@@ -11123,8 +11123,8 @@ declare const WorkflowSubjects$1: _$_makaio_core0.BusSubjects<_$_makaio_core0.Fl
11123
11123
  completed: "completed";
11124
11124
  cancelled: "cancelled";
11125
11125
  failed: "failed";
11126
- paused: "paused";
11127
11126
  running: "running";
11127
+ paused: "paused";
11128
11128
  finalizing: "finalizing";
11129
11129
  }>>;
11130
11130
  limit: z.ZodOptional<z.ZodNumber>;
@@ -11140,8 +11140,8 @@ declare const WorkflowSubjects$1: _$_makaio_core0.BusSubjects<_$_makaio_core0.Fl
11140
11140
  completed: "completed";
11141
11141
  cancelled: "cancelled";
11142
11142
  failed: "failed";
11143
- paused: "paused";
11144
11143
  running: "running";
11144
+ paused: "paused";
11145
11145
  finalizing: "finalizing";
11146
11146
  }>;
11147
11147
  startedAt: z.ZodNumber;
@@ -11845,8 +11845,8 @@ declare const ExecutionAttemptControlReportSchema$1: z.ZodObject<{
11845
11845
  }, z.core.$strict>;
11846
11846
  /** Correlation refusals do not invalidate the durable Attempt-wide Cancel. */
11847
11847
  declare const ExecutionAttemptControlRefusalReasonSchema: z.ZodEnum<{
11848
- conflict: "conflict";
11849
11848
  "not-found": "not-found";
11849
+ conflict: "conflict";
11850
11850
  "stale-generation": "stale-generation";
11851
11851
  "cancel-mismatch": "cancel-mismatch";
11852
11852
  "operation-mismatch": "operation-mismatch";
@@ -11859,8 +11859,8 @@ declare const ExecutionAttemptControlReportResponseSchema: z.ZodDiscriminatedUni
11859
11859
  }, z.core.$strict>, z.ZodObject<{
11860
11860
  decision: z.ZodLiteral<"refused">;
11861
11861
  reason: z.ZodEnum<{
11862
- conflict: "conflict";
11863
11862
  "not-found": "not-found";
11863
+ conflict: "conflict";
11864
11864
  "stale-generation": "stale-generation";
11865
11865
  "cancel-mismatch": "cancel-mismatch";
11866
11866
  "operation-mismatch": "operation-mismatch";
@@ -12707,8 +12707,8 @@ declare const WorkLogExecutionSummarySchema: z.ZodObject<{
12707
12707
  completed: "completed";
12708
12708
  cancelled: "cancelled";
12709
12709
  failed: "failed";
12710
- paused: "paused";
12711
12710
  running: "running";
12711
+ paused: "paused";
12712
12712
  finalizing: "finalizing";
12713
12713
  }>;
12714
12714
  startedAt: z.ZodNumber;
@@ -12734,10 +12734,10 @@ declare const WorkLogFrameEntrySchema$1: z.ZodObject<{
12734
12734
  frameId: z.ZodString;
12735
12735
  nodeId: z.ZodString;
12736
12736
  nodeType: z.ZodEnum<{
12737
- sequence: "sequence";
12738
12737
  station: "station";
12739
12738
  "delegate-agent": "delegate-agent";
12740
12739
  "delegate-role": "delegate-role";
12740
+ sequence: "sequence";
12741
12741
  parallel: "parallel";
12742
12742
  gate: "gate";
12743
12743
  iterate: "iterate";
@@ -0,0 +1 @@
1
+ import{n as e}from"./json-value-DM-EjTC1.mjs";import{a as t,n}from"./json-tree-Cmb_BzHr.mjs";import{z as r}from"zod";function i(e){return a(e)?e:void 0}function a(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function o(e,t){if(!a(e))return!1;let n=e.type;return n===t?!0:Array.isArray(n)&&n.length===1&&n[0]===t}const s=`[]`;function c(e,t){return Object.keys(t).length===0?e:e?t:!1}function l(e,t){if(t===`#`)return e;if(!t.startsWith(`#/`))return;let n=e;for(let e of t.slice(2).split(`/`)){let t=i(n),r=e.replace(/~1/g,`/`).replace(/~0/g,`~`);if(!t||!Object.hasOwn(t,r))return;n=t[r]}return n}function u(e,t){let n=t.$ref;if(typeof n!=`string`)return;let r=l(e,n);if(typeof r==`boolean`){if(e.$schema!==`https://json-schema.org/draft/2020-12/schema`)return r;let{$ref:n,...i}=t;return c(r,i)}let a=i(r);if(!a||e.$schema!==`https://json-schema.org/draft/2020-12/schema`)return a;let{$ref:o,...s}=t;return Object.keys(s).length===0?a:{...a,allOf:[s,...Array.isArray(a.allOf)?a.allOf:[]]}}function d(e,t){for(let[n,r]of Object.entries(t))e[n]=Object.hasOwn(e,n)?{allOf:[e[n],r]}:r}function f(e){return Array.isArray(e.required)?e.required.filter(e=>typeof e==`string`):[]}function ee(e,t){let n=i(e.properties);if(!n||!Object.hasOwn(n,t))return;let r=n[t];return typeof r==`boolean`?r:i(r)}function p(e,t,n){if(typeof t.$ref==`string`){if(n.has(t.$ref))return;let r=u(e,t);return a(r)?p(e,r,new Set([...n,t.$ref])):void 0}if(!Array.isArray(t.allOf))return t;let{allOf:r,...o}=t,s={},c={},l=new Set;for(let t of[o,...r]){let r=i(t),a=r?p(e,r,n):void 0;if(!a||a.anyOf||a.oneOf)return;if(a.type!==void 0){if(s.type!==void 0&&s.type!==a.type)return;s.type=a.type}for(let e of[`items`,`prefixItems`])if(a[e]!==void 0){if(s[e]!==void 0)return;s[e]=a[e]}d(c,i(a.properties)??{});for(let e of f(a))l.add(e)}return{...s,properties:c,required:[...l]}}function te(e,t,n,r,i,a,o,s){if(a.has(n))return;let c=u(e,t);return typeof c==`boolean`?r.length===0?[c]:void 0:c?m(e,c,r,i,new Set([...a,n]),o,s):void 0}function ne(e,t,n,r){if(!o(t,`array`))return;let a=t.items;if(typeof a==`boolean`)return n.length===0?[a]:void 0;let s=i(a);return s?m(e,s,n,r):void 0}function re(e,t,n){if(typeof n.$ref!=`string`)return{node:{...n,allOf:[t,...Array.isArray(n.allOf)?n.allOf:[]]}};let r=u(e,n);return a(r)?{node:{...r,allOf:[t,...Array.isArray(r.allOf)?r.allOf:[]]},ref:n.$ref}:{node:{allOf:[t,n]}}}function m(e,t,n,r,a=new Set,s=!1,c=!1){if(typeof t.$ref==`string`){let i=t.$ref;return te(e,t,i,n,r,a,s,c)}let l=Array.isArray(t.anyOf)?`anyOf`:`oneOf`,u=t[l];if(Array.isArray(u)){let{[l]:o,...d}=t,f=u.map(t=>{let o=i(t);if(!o)return;let{node:l,ref:u}=re(e,d,o);return m(e,l,n,r,u===void 0?a:new Set([...a,u]),s,c)});return f.every(e=>e!==void 0)?f.flatMap(e=>e??[]):void 0}if(Array.isArray(t.allOf)){let i=p(e,t,a);return i?m(e,i,n,r,a,s,c):void 0}if(n.length===0)return[t];let[d,...h]=n;if(d===`[]`)return ne(e,t,h,r||c);if(!(!o(t,`object`)&&!(t.type===void 0&&s))&&!(!d||r&&!f(t).includes(d)))return ie(e,ee(t,d),h,r,c)}function ie(e,t,n,r,i){return typeof t==`boolean`?n.length===0?[t]:void 0:t?m(e,t,n,r,new Set,!1,i):void 0}function h(e,t,n){return m(e,e,[...t],n?.required??!1,new Set,!0,n?.requiredAfterElement??!1)}function g(e,t){return h(e,t.split(`.`))!==void 0}function _(e){let t=[],n=(e,n)=>{let r=i(e);r&&t.push({node:r,path:n})};for(let t of[`properties`,`patternProperties`,`$defs`,`definitions`,`dependentSchemas`,`dependencies`])for(let[r,a]of Object.entries(i(e[t])??{}))n(a,[t,r]);for(let t of[`allOf`,`anyOf`,`oneOf`,`prefixItems`,`items`]){let r=e[t];Array.isArray(r)&&r.forEach((e,r)=>n(e,[t,r]))}for(let t of[`items`,`additionalItems`,`additionalProperties`,`unevaluatedItems`,`unevaluatedProperties`,`propertyNames`,`contains`,`not`,`if`,`then`,`else`,`contentSchema`])n(e[t],[t]);return t}function v(e,t=[`dataSchema`]){if(Array.isArray(e.prefixItems)||Array.isArray(e.items))throw Error(`Unsupported tuple serialization at ${t.join(`.`)}: use an array schema or an explicit JSON Schema registration`);for(let n of _(e))v(n.node,[...t,...n.path])}function y(e,t,n=new Set){if(t.additionalProperties===!1)return!0;if(typeof t.$ref==`string`&&!n.has(t.$ref)){let r=u(e,t);if(r===void 0||a(r)&&y(e,r,new Set([...n,t.$ref])))return!0}return _(t).some(t=>y(e,t.node,n))}function ae(e,t,n,r){if(Object.hasOwn(t,`$ref`)&&typeof t.$ref!=`string`&&n.addIssue({code:`custom`,path:[...r,`$ref`],message:`Schema reference must be a string`}),typeof t.$ref==`string`&&!t.$ref.startsWith(`#`)&&n.addIssue({code:`custom`,path:[...r,`$ref`],message:`Only fragment schema references are supported; absolute and document-relative references are outside the artifact registration profile`}),Object.hasOwn(t,`$anchor`)&&n.addIssue({code:`custom`,path:[...r,`$anchor`],message:`Named schema anchors are not supported; use local JSON Pointer references`}),typeof t.$ref==`string`&&t.$ref.startsWith(`#`)&&t.$ref.length>1&&!t.$ref.startsWith(`#/`)&&n.addIssue({code:`custom`,path:[...r,`$ref`],message:`Named schema references are not supported; use local JSON Pointer references`}),typeof t.$ref==`string`&&(t.$ref===`#`||t.$ref.startsWith(`#/`))){let a=l(e,t.$ref);!i(a)&&typeof a!=`boolean`&&n.addIssue({code:`custom`,path:[...r,`$ref`],message:`Fragment schema reference must resolve to an existing object or boolean schema`})}}function b(e,t,n,r=[`dataSchema`]){Object.hasOwn(t,`$async`)&&t.$async!==!1&&n.addIssue({code:`custom`,path:[...r,`$async`],message:`Asynchronous artifact schemas are not supported`}),ae(e,t,n,r);for(let e of[`anyOf`,`oneOf`]){let i=t[e];Array.isArray(i)&&i.some(e=>typeof e==`boolean`)&&n.addIssue({code:`custom`,path:[...r,e],message:`Unsupported boolean union alternative: use object schema declarations`})}Array.isArray(t.allOf)&&(y(e,t)||!p(e,t,new Set))&&n.addIssue({code:`custom`,path:[...r,`allOf`],message:`Unsupported intersection: use open compatible conjuncts or a single closed object schema`});for(let i of _(t))b(e,i.node,n,[...r,...i.path])}function oe(e,t){b(e.dataSchema,e.dataSchema,t);let n=m(e.dataSchema,e.dataSchema,e.titlePath.split(`.`),!0,new Set,!0);(!n?.length||n.some(e=>!o(e,`string`)))&&t.addIssue({code:`custom`,path:[`titlePath`],message:`titlePath must select a required string in every data schema variant`});let r=[...(e.indexedFields??[]).map((e,t)=>({path:e,location:[`indexedFields`,t]})),...(e.searchableFields??[]).map((e,t)=>({path:e,location:[`searchableFields`,t]})),...(e.uniqueness??[]).flatMap((e,t)=>e.by.flatMap((e,n)=>e.kind===`data`?[{path:e.path,location:[`uniqueness`,t,`by`,n,`path`]}]:[])),...Object.entries(e.views??{}).flatMap(([e,t])=>t.fields.map((t,n)=>({path:t,location:[`views`,e,`fields`,n]})))];for(let{path:n,location:i}of r)g(e.dataSchema,n)||t.addIssue({code:`custom`,path:i,message:`Data path ${n} must select a declared field`})}function x(e,t){let n=e;for(let e of t.split(`.`)){if(typeof n!=`object`||!n||Array.isArray(n)||!Object.hasOwn(n,e))throw Error(`Artifact title is missing at ${t}`);n=Reflect.get(n,e)}if(typeof n!=`string`||n.trim().length===0)throw Error(`Artifact title at ${t} must be a nonblank string`);return n}const S=[`$dynamicRef`,`$dynamicAnchor`,`$recursiveRef`,`$recursiveAnchor`];function C(e,t,n=[`dataSchema`]){for(let r of S)Object.hasOwn(e,r)&&t.addIssue({code:`custom`,path:[...n,r],message:`Unsupported dynamic reference: use a plain local $ref`});for(let r of _(e))C(r.node,t,[...n,...r.path])}function w(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function se(e,t){if(typeof t!=`string`)return;let n=l(e,t);return w(n)?n:void 0}function T(e,t){return w(e)?Object.values(e).some(e=>Array.isArray(e)&&e.includes(t)):!1}function E(e,t){let n=e.properties;if(w(n)&&Object.hasOwn(n,t)||Array.isArray(e.required)&&e.required.includes(t)||T(e.dependentRequired,t)||T(e.dependencies,t))return!0;let r=e.patternProperties;return w(r)?Object.keys(r).some(e=>{try{return new RegExp(e,`u`).test(t)}catch{return!1}}):!1}function D(e){let t=[];for(let n of[`allOf`,`anyOf`,`oneOf`]){let r=e[n];if(Array.isArray(r))for(let e of r)w(e)&&t.push(e)}for(let n of[`if`,`then`,`else`]){let r=e[n];w(r)&&t.push(r)}for(let n of[`dependentSchemas`,`dependencies`]){let r=e[n];if(w(r))for(let e of Object.values(r))w(e)&&t.push(e)}return t}function O(e,t){let n=new Set,r=i=>{if(n.has(i))return!1;if(n.add(i),E(i,t))return!0;let a=se(e,i.$ref);return a&&r(a)?!0:D(i).some(r)};return r(e)}const k=/^[a-z0-9]+(--?[a-z0-9]+)*$/,ce=r.string().regex(k,`Slug must be lowercase alphanumeric segments joined by hyphens.`),A=`slug`,le=`Data field slug is reserved: the artifact envelope owns the slug`,ue=[[/ä/g,`ae`],[/ö/g,`oe`],[/ü/g,`ue`],[/ß/g,`ss`],[/æ/g,`ae`],[/ø/g,`oe`]];function j(e){let t=ue.reduce((e,[t,n])=>e.replace(t,n),e.toLowerCase()).normalize(`NFKD`).replace(/\p{M}/gu,``).replace(/[^a-z0-9]+/g,`-`).replace(/^-+|-+$/g,``);return t.length>0?t:null}const de=80;function M(e){if(e.length<=80)return e;let t=e.lastIndexOf(`-`,80);return(t>0?e.slice(0,t):e.slice(0,80)).replace(/-+$/,``)}function N(e,t,n){let r=j(x(e,t));if(r!==null)return M(r);let i=j(n);if(i!==null)return M(i);throw Error(`Artifact ${n} yields no slug from its title or identity`)}function P(e,t){let n=e.addressableParts;if(!n||n.length===0)return;let r=new Set;for(let[i,a]of n.entries())r.has(a.path)&&t.addIssue({code:`custom`,path:[`addressableParts`,i,`path`],message:`addressableParts[${i}].path duplicates an earlier area; each declared area must have a distinct path`}),r.add(a.path),F(e.dataSchema,a,i,t)}function F(e,t,n,r){let i=h(e,t.path.split(`.`));if(!i||i.length===0){r.addIssue({code:`custom`,path:[`addressableParts`,n,`path`],message:`addressableParts[${n}].path must select a declared location in every data schema variant`});return}if(i.some(e=>!o(e,`array`))){r.addIssue({code:`custom`,path:[`addressableParts`,n,`path`],message:`addressableParts[${n}].path must select an array schema in every data schema variant`});return}if(i.some(e=>typeof e==`object`&&(Array.isArray(e.prefixItems)||Array.isArray(e.items)))){r.addIssue({code:`custom`,path:[`addressableParts`,n,`path`],message:`addressableParts[${n}].path selects a tuple schema; tuples are outside the addressable-parts profile (homogeneous arrays only)`});return}I(e,t,n,r)}function I(e,t,n,r){let i=()=>{r.addIssue({code:`custom`,path:[`addressableParts`,n,`idPath`],message:`addressableParts[${n}].idPath must select a required string in every element variant`})},a=t.idPath.split(`.`),s=h(e,[...t.path.split(`.`),`[]`,...a],{requiredAfterElement:!0});if(!s||s.length===0){i();return}s.some(e=>!o(e,`string`))&&i()}function L(e,r){let i=[],a=new Map;for(let o of e){let e=t(r,o.path.split(`.`));if(e===void 0)continue;if(!Array.isArray(e)){i.push({path:o.path,reason:`declared part area must be an array; found ${typeof e}`});continue}let s=o.idPath.split(`.`);for(let[r,c]of e.entries()){let e=`${o.path}.${r}.${o.idPath}`;if(!n(c)){i.push({path:e,reason:`part element is not an object; local identifier cannot be read`});continue}let l=t(c,s);if(typeof l!=`string`){i.push({path:e,reason:l===void 0?`local identifier is missing`:`local identifier must be a string; found ${typeof l}`});continue}if(/^\s*$/.test(l)){i.push({path:e,reason:`local identifier must be a non-empty, non-whitespace-only string`});continue}let u=a.get(l);u===void 0?a.set(l,e):i.push({path:e,reason:`duplicate local identifier "${l}"; also found at ${u}`})}}return i}function R(e,t,n){let r=[],i=V(e,t);for(let[t,a]of n.entries()){if(a.sourceLocalId===void 0)continue;let n=i?.get(a.sourceLocalId)??(e.length===0?{ok:!1,reason:`NO_PARTS_DECLARED`}:{ok:!1,reason:`PART_NOT_FOUND`});n.ok||r.push({relationIndex:t,reason:n.reason})}return r}const z=[`ARTIFACT_NOT_FOUND`,`KIND_NOT_REGISTERED`,`NO_PARTS_DECLARED`,`PART_NOT_FOUND`,`DUPLICATE_LOCAL_ID`],B=r.strictObject({code:r.enum(z),message:r.string().min(1),repair:r.string().min(1)});function V(e,r){if(e.length===0)return;let i=new Map;for(let a of e){let e=t(r,a.path.split(`.`));if(!Array.isArray(e))continue;let o=a.idPath.split(`.`);for(let r of e){if(!n(r))continue;let e=t(r,o);typeof e==`string`&&(i.has(e)?i.set(e,{ok:!1,reason:`DUPLICATE_LOCAL_ID`}):i.set(e,{ok:!0,areaPath:a.path,part:r}))}}return i}function fe(e,t,n){let r=V(e,t);return r===void 0?{ok:!1,reason:`NO_PARTS_DECLARED`}:r.get(n)??{ok:!1,reason:`PART_NOT_FOUND`}}const H=r.number().int().positive(),U=r.enum([`knowledge`,`commitment`,`interaction`,`record`]),W=r.string().regex(/^[A-Za-z_$][\w$-]*(?:\.[A-Za-z_$][\w$-]*)*$/),G=r.strictObject({fields:r.array(W).min(1)}),pe=new Set([`full`]),K={knowledge:[`valid`,`retired`],commitment:[`proposed`,`decided`,`fulfilled`,`revoked`],interaction:[`open`,`resolved`,`closed-without-resolution`],record:[]},q=r.enum([...K.knowledge,...K.commitment,...K.interaction]),J=r.strictObject({path:W,equals:r.union([r.string(),r.number(),r.boolean()])}),Y=r.strictObject({relationType:r.string().trim().min(1),targetKinds:r.array(r.string().trim().min(1)).min(1).optional(),minItems:r.number().int().nonnegative(),maxItems:r.number().int().nonnegative().optional(),when:J.optional()}).refine(e=>e.maxItems===void 0||e.maxItems>=e.minItems,{path:[`maxItems`],message:`maxItems must be at least minItems`}),X=r.discriminatedUnion(`kind`,[r.strictObject({kind:r.literal(`data`),path:W}),r.strictObject({kind:r.literal(`relation-target`),relationType:r.string().trim().min(1)})]),Z=r.strictObject({path:W,idPath:W}),Q=r.strictObject({by:r.array(X).min(1),lifecycleStates:r.array(q).min(1).optional()}),$=r.strictObject({minItems:r.number().int().nonnegative()}),me=r.enum([`http://json-schema.org/draft-07/schema#`,`https://json-schema.org/draft/2020-12/schema`]).optional(),he=r.strictObject({kind:r.string().trim().min(1),description:r.string().trim().min(1),schemaVersion:H,category:U,dataSchema:e,titlePath:W,relations:r.array(Y).optional(),uniqueness:r.array(Q).optional(),evidenceRequirements:$.optional(),indexedFields:r.array(W).optional(),searchableFields:r.array(W).optional(),addressableParts:r.array(Z).min(1).optional(),views:r.record(r.string().trim().min(1),G).optional()}).superRefine((e,t)=>{me.safeParse(e.dataSchema.$schema).success||t.addIssue({code:`custom`,path:[`dataSchema`,`$schema`],message:`Unsupported data schema dialect: omit $schema for draft-7 or declare the supported draft-7 or 2020-12 URI`});let n=K[e.category];e.uniqueness?.forEach((r,i)=>{r.lifecycleStates?.some(e=>!n.includes(e))&&t.addIssue({code:`custom`,path:[`uniqueness`,i,`lifecycleStates`],message:`Lifecycle conditions are incompatible with category ${e.category}`})}),e.relations?.forEach((n,r)=>{n.when&&!g(e.dataSchema,n.when.path)&&t.addIssue({code:`custom`,path:[`relations`,r,`when`,`path`],message:`Data path ${n.when.path} must select a declared field`})}),Object.keys(e.views??{}).forEach(e=>{pe.has(e)&&t.addIssue({code:`custom`,path:[`views`,e],message:`Artifact kind view ${e} is reserved for the generic complete-payload view`})}),O(e.dataSchema,`slug`)&&t.addIssue({code:`custom`,path:[`dataSchema`,`properties`,A],message:`Data field ${A} is reserved: the artifact envelope owns the slug`}),C(e.dataSchema,t),oe(e,t),P(e,t)});export{h as A,le as C,O as D,j as E,x as M,s as O,k as S,N as T,R as _,he as a,de as b,Z as c,H as d,Q as f,L as g,B as h,$ as i,g as j,v as k,J as l,z as m,U as n,G as o,X as p,W as r,q as s,K as t,Y as u,fe as v,ce as w,A as x,P as y};