@lucern/sdk 0.3.0-alpha.3 → 0.3.0-alpha.5

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 (136) hide show
  1. package/README.md +47 -0
  2. package/dist/adminClient.js +4 -3
  3. package/dist/adminClient.js.map +1 -1
  4. package/dist/answersClient.js +4 -3
  5. package/dist/answersClient.js.map +1 -1
  6. package/dist/audiencesClient.js +4 -3
  7. package/dist/audiencesClient.js.map +1 -1
  8. package/dist/auditClient.js +4 -3
  9. package/dist/auditClient.js.map +1 -1
  10. package/dist/authContext.js +4 -3
  11. package/dist/authContext.js.map +1 -1
  12. package/dist/beliefs/index.d.ts +3 -1
  13. package/dist/beliefs/index.js +333 -7
  14. package/dist/beliefs/index.js.map +1 -1
  15. package/dist/beliefsClient.js +4 -3
  16. package/dist/beliefsClient.js.map +1 -1
  17. package/dist/client.d.ts +2981 -40
  18. package/dist/client.js +333 -7
  19. package/dist/client.js.map +1 -1
  20. package/dist/contextClient.js +4 -3
  21. package/dist/contextClient.js.map +1 -1
  22. package/dist/contracts/api-enums.contract.d.ts +1 -1
  23. package/dist/contracts/api-enums.contract.js.map +1 -1
  24. package/dist/contracts/index.js.map +1 -1
  25. package/dist/contradictions/index.d.ts +3 -1
  26. package/dist/contradictions/index.js +333 -7
  27. package/dist/contradictions/index.js.map +1 -1
  28. package/dist/coreClient.js +4 -3
  29. package/dist/coreClient.js.map +1 -1
  30. package/dist/decisions/index.d.ts +3 -1
  31. package/dist/decisions/index.js +333 -7
  32. package/dist/decisions/index.js.map +1 -1
  33. package/dist/decisionsClient.js +4 -3
  34. package/dist/decisionsClient.js.map +1 -1
  35. package/dist/edges/index.d.ts +3 -1
  36. package/dist/edges/index.js +333 -7
  37. package/dist/edges/index.js.map +1 -1
  38. package/dist/embeddingsClient.js +4 -3
  39. package/dist/embeddingsClient.js.map +1 -1
  40. package/dist/eventingClient.js +4 -3
  41. package/dist/eventingClient.js.map +1 -1
  42. package/dist/eventsCore.js +4 -3
  43. package/dist/eventsCore.js.map +1 -1
  44. package/dist/evidence/index.d.ts +3 -1
  45. package/dist/evidence/index.js +333 -7
  46. package/dist/evidence/index.js.map +1 -1
  47. package/dist/evidenceClient.js +4 -3
  48. package/dist/evidenceClient.js.map +1 -1
  49. package/dist/functionSurface.d.ts +129 -0
  50. package/dist/functionSurface.js +1118 -0
  51. package/dist/functionSurface.js.map +1 -0
  52. package/dist/functionSurfaceClient.d.ts +8 -0
  53. package/dist/functionSurfaceClient.js +1118 -0
  54. package/dist/functionSurfaceClient.js.map +1 -0
  55. package/dist/gatewayFacades.d.ts +34 -1
  56. package/dist/gatewayFacades.js +4 -3
  57. package/dist/gatewayFacades.js.map +1 -1
  58. package/dist/graphAnalysisClient.d.ts +53 -1
  59. package/dist/graphAnalysisClient.js +31 -4
  60. package/dist/graphAnalysisClient.js.map +1 -1
  61. package/dist/graphClient.js +4 -3
  62. package/dist/graphClient.js.map +1 -1
  63. package/dist/graphIntel.d.ts +3 -0
  64. package/dist/graphIntel.js +3 -0
  65. package/dist/graphIntel.js.map +1 -0
  66. package/dist/graphIntelligence.d.ts +2 -0
  67. package/dist/graphIntelligence.js +47 -0
  68. package/dist/graphIntelligence.js.map +1 -0
  69. package/dist/graphRecommendationsClient.js +4 -3
  70. package/dist/graphRecommendationsClient.js.map +1 -1
  71. package/dist/graphStateClassifierClient.js +4 -3
  72. package/dist/graphStateClassifierClient.js.map +1 -1
  73. package/dist/harnessClient.js +4 -3
  74. package/dist/harnessClient.js.map +1 -1
  75. package/dist/identityClient.js +4 -3
  76. package/dist/identityClient.js.map +1 -1
  77. package/dist/index.d.ts +8 -3
  78. package/dist/index.js +670 -8
  79. package/dist/index.js.map +1 -1
  80. package/dist/infisicalRuntime.d.ts +42 -0
  81. package/dist/infisicalRuntime.js +291 -0
  82. package/dist/infisicalRuntime.js.map +1 -0
  83. package/dist/jobsClient.js +4 -3
  84. package/dist/jobsClient.js.map +1 -1
  85. package/dist/learningClient.js +4 -3
  86. package/dist/learningClient.js.map +1 -1
  87. package/dist/lenses/index.d.ts +28 -2
  88. package/dist/lenses/index.js +333 -7
  89. package/dist/lenses/index.js.map +1 -1
  90. package/dist/mcpClient.js +4 -3
  91. package/dist/mcpClient.js.map +1 -1
  92. package/dist/modelRuntimeClient.js +4 -3
  93. package/dist/modelRuntimeClient.js.map +1 -1
  94. package/dist/nodes/index.d.ts +21 -1
  95. package/dist/nodes/index.js +333 -7
  96. package/dist/nodes/index.js.map +1 -1
  97. package/dist/ontologies/index.d.ts +3 -1
  98. package/dist/ontologies/index.js +333 -7
  99. package/dist/ontologies/index.js.map +1 -1
  100. package/dist/ontologyClient.js +4 -3
  101. package/dist/ontologyClient.js.map +1 -1
  102. package/dist/ontologyLinksClient.js +4 -3
  103. package/dist/ontologyLinksClient.js.map +1 -1
  104. package/dist/orgGraphSearchClient.js +4 -3
  105. package/dist/orgGraphSearchClient.js.map +1 -1
  106. package/dist/packRuntime.d.ts +2 -1
  107. package/dist/packsClient.js +4 -3
  108. package/dist/packsClient.js.map +1 -1
  109. package/dist/policyClient.js +4 -3
  110. package/dist/policyClient.js.map +1 -1
  111. package/dist/questions/index.d.ts +3 -1
  112. package/dist/questions/index.js +333 -7
  113. package/dist/questions/index.js.map +1 -1
  114. package/dist/reportsClient.js +4 -3
  115. package/dist/reportsClient.js.map +1 -1
  116. package/dist/schemaClient.js +4 -3
  117. package/dist/schemaClient.js.map +1 -1
  118. package/dist/sourcesClient.js +4 -3
  119. package/dist/sourcesClient.js.map +1 -1
  120. package/dist/telemetryClient.js +4 -3
  121. package/dist/telemetryClient.js.map +1 -1
  122. package/dist/toolRegistryClient.js +4 -3
  123. package/dist/toolRegistryClient.js.map +1 -1
  124. package/dist/topics/index.d.ts +3 -1
  125. package/dist/topics/index.js +333 -7
  126. package/dist/topics/index.js.map +1 -1
  127. package/dist/topicsClient.js +4 -3
  128. package/dist/topicsClient.js.map +1 -1
  129. package/dist/workflowClient.d.ts +41 -7
  130. package/dist/workflowClient.js +4 -3
  131. package/dist/workflowClient.js.map +1 -1
  132. package/dist/worktrees/index.d.ts +29 -3
  133. package/dist/worktrees/index.js +333 -7
  134. package/dist/worktrees/index.js.map +1 -1
  135. package/package.json +12 -3
  136. package/dist/client-EiG9nJOY.d.ts +0 -2911
package/dist/client.js CHANGED
@@ -85,14 +85,15 @@ function normalizeCanonicalLucernAuthContext(input) {
85
85
  );
86
86
  const roles = cleanStringList(input.roles);
87
87
  const scopes = cleanStringList(input.scopes);
88
- if (roles.length === 0 || scopes.length === 0) {
88
+ const principalType = requirePrincipalType(input.principalType);
89
+ const authMode = requireAuthMode(input.authMode);
90
+ const roleBasedInteractiveAuth = authMode === "interactive_user" && roles.length > 0;
91
+ if (roles.length === 0 || scopes.length === 0 && !roleBasedInteractiveAuth) {
89
92
  throw new LucernSdkAuthContextError(
90
93
  "membership_missing",
91
94
  "Canonical Lucern SDK auth context requires non-empty roles and scopes."
92
95
  );
93
96
  }
94
- const principalType = requirePrincipalType(input.principalType);
95
- const authMode = requireAuthMode(input.authMode);
96
97
  const subject = cleanString(input.permit?.subject) ?? principalId;
97
98
  const tenant = cleanString(input.permit?.tenant) ?? tenantId;
98
99
  const workspace = cleanString(input.permit?.workspace) ?? workspaceId;
@@ -4115,9 +4116,33 @@ function graphAnalysisQuery(input) {
4115
4116
  cursor: input.cursor
4116
4117
  };
4117
4118
  }
4119
+ function normalizeRunQueryPayload(input) {
4120
+ return {
4121
+ ...input,
4122
+ topicId: requireTopicId2(input),
4123
+ projectId: void 0
4124
+ };
4125
+ }
4118
4126
  function createGraphAnalysisClient(config = {}) {
4119
4127
  const gateway = createGatewayRequestClient(config);
4120
4128
  return {
4129
+ listGraphIntelligenceQueries(input = {}) {
4130
+ return gateway.request({
4131
+ path: "/api/platform/v1/graph-intelligence/queries",
4132
+ method: "POST",
4133
+ body: {
4134
+ categoryId: input.categoryId,
4135
+ mode: input.mode
4136
+ }
4137
+ });
4138
+ },
4139
+ runGraphIntelligenceQuery(input) {
4140
+ return gateway.request({
4141
+ path: "/api/platform/v1/graph-intelligence/run",
4142
+ method: "POST",
4143
+ body: normalizeRunQueryPayload(input)
4144
+ });
4145
+ },
4121
4146
  saveAnalysis(input, idempotencyKey) {
4122
4147
  return gateway.request({
4123
4148
  path: "/api/platform/v1/graph-analysis/analyses",
@@ -4199,7 +4224,9 @@ function createGraphAnalysisClient(config = {}) {
4199
4224
  topicId: requireTopicId2(input),
4200
4225
  workspaceId: input.workspaceId,
4201
4226
  analysisId: input.analysisId,
4202
- since: input.since,
4227
+ minimumCreatedAt: input.minimumCreatedAt ?? input.since ?? input.createdAt ?? input.analysisCreatedAt,
4228
+ sourceNodeIds: input.sourceNodeIds?.join(",") ?? (input.nodeId ? input.nodeId : void 0),
4229
+ sourceEdgeIds: input.sourceEdgeIds?.join(",") ?? (input.edgeId ? input.edgeId : void 0),
4203
4230
  limit: input.limit,
4204
4231
  cursor: input.cursor
4205
4232
  })}`
@@ -4955,6 +4982,7 @@ var CONTRACTS = {
4955
4982
  "archive_belief": { method: "DELETE", path: "/beliefs", kind: "mutation", idempotent: true, surfaceIntent: "mcp_core" },
4956
4983
  "archive_ontology": { method: "DELETE", path: "/ontologies", kind: "mutation", idempotent: true, surfaceIntent: "mcp_governance" },
4957
4984
  "archive_question": { method: "DELETE", path: "/questions", kind: "mutation", idempotent: true, surfaceIntent: "mcp_core" },
4985
+ "begin_build_session": { method: "POST", path: "/mcp/build-session/begin", kind: "mutation", idempotent: true, surfaceIntent: "system" },
4958
4986
  "bisect_confidence": { method: "POST", path: "/beliefs/confidence/bisect", kind: "query", idempotent: false, surfaceIntent: "mcp_core" },
4959
4987
  "broadcast_message": { method: "POST", path: "/coordination/messages/broadcast", kind: "mutation", idempotent: true, surfaceIntent: "system" },
4960
4988
  "check_permission": { method: "POST", path: "/identity/check-permission", kind: "query", idempotent: false, surfaceIntent: "mcp_core" },
@@ -5017,6 +5045,7 @@ var CONTRACTS = {
5017
5045
  "list_beliefs": { method: "GET", path: "/beliefs", kind: "query", idempotent: false, surfaceIntent: "mcp_core" },
5018
5046
  "list_campaigns": { method: "GET", path: "/worktrees/campaigns", kind: "query", idempotent: false, surfaceIntent: "mcp_workflow" },
5019
5047
  "list_evidence": { method: "GET", path: "/evidence", kind: "query", idempotent: false, surfaceIntent: "mcp_core" },
5048
+ "list_graph_intelligence_queries": { method: "POST", path: "/graph-intelligence/queries", kind: "query", idempotent: false, surfaceIntent: "mcp_analysis" },
5020
5049
  "list_lenses": { method: "GET", path: "/lenses", kind: "query", idempotent: false, surfaceIntent: "mcp_workflow" },
5021
5050
  "list_ontologies": { method: "GET", path: "/ontologies", kind: "query", idempotent: false, surfaceIntent: "mcp_workflow" },
5022
5051
  "list_questions": { method: "GET", path: "/questions", kind: "query", idempotent: false, surfaceIntent: "mcp_core" },
@@ -5040,6 +5069,7 @@ var CONTRACTS = {
5040
5069
  "register_session": { method: "POST", path: "/coordination/register-session", kind: "mutation", idempotent: true, surfaceIntent: "system" },
5041
5070
  "remove_lens_from_topic": { method: "DELETE", path: "/lenses/apply", kind: "mutation", idempotent: true, surfaceIntent: "mcp_workflow" },
5042
5071
  "resolve_effective_ontology": { method: "POST", path: "/ontologies/effective", kind: "query", idempotent: false, surfaceIntent: "mcp_workflow" },
5072
+ "run_graph_intelligence_query": { method: "POST", path: "/graph-intelligence/run", kind: "query", idempotent: false, surfaceIntent: "mcp_analysis" },
5043
5073
  "search_beliefs": { method: "POST", path: "/beliefs/search", kind: "query", idempotent: false, surfaceIntent: "mcp_core" },
5044
5074
  "search_evidence": { method: "POST", path: "/evidence/search", kind: "query", idempotent: false, surfaceIntent: "mcp_core" },
5045
5075
  "seed_belief_lattice": { method: "POST", path: "/scope/belief-lattice/seed", kind: "mutation", idempotent: true, surfaceIntent: "system" },
@@ -5126,6 +5156,9 @@ function createFunctionSurfaceClient(config = {}) {
5126
5156
  archiveQuestion(input = {}, idempotencyKey) {
5127
5157
  return execute("archive_question", input, idempotencyKey);
5128
5158
  },
5159
+ beginBuildSession(input = {}, idempotencyKey) {
5160
+ return execute("begin_build_session", input, idempotencyKey);
5161
+ },
5129
5162
  bisectConfidence(input = {}, idempotencyKey) {
5130
5163
  return execute("bisect_confidence", input, idempotencyKey);
5131
5164
  },
@@ -5312,6 +5345,9 @@ function createFunctionSurfaceClient(config = {}) {
5312
5345
  listEvidence(input = {}, idempotencyKey) {
5313
5346
  return execute("list_evidence", input, idempotencyKey);
5314
5347
  },
5348
+ listGraphIntelligenceQueries(input = {}, idempotencyKey) {
5349
+ return execute("list_graph_intelligence_queries", input, idempotencyKey);
5350
+ },
5315
5351
  listLenses(input = {}, idempotencyKey) {
5316
5352
  return execute("list_lenses", input, idempotencyKey);
5317
5353
  },
@@ -5381,6 +5417,9 @@ function createFunctionSurfaceClient(config = {}) {
5381
5417
  resolveEffectiveOntology(input = {}, idempotencyKey) {
5382
5418
  return execute("resolve_effective_ontology", input, idempotencyKey);
5383
5419
  },
5420
+ runGraphIntelligenceQuery(input = {}, idempotencyKey) {
5421
+ return execute("run_graph_intelligence_query", input, idempotencyKey);
5422
+ },
5384
5423
  searchBeliefs(input = {}, idempotencyKey) {
5385
5424
  return execute("search_beliefs", input, idempotencyKey);
5386
5425
  },
@@ -7060,6 +7099,13 @@ function requireTopicId4(args) {
7060
7099
  }
7061
7100
  return topicId;
7062
7101
  }
7102
+ function requireTopicOrProjectId(args) {
7103
+ const topicId = args.topicId?.trim() || args.projectId?.trim() || void 0;
7104
+ if (!topicId) {
7105
+ throw new Error("topicId is required");
7106
+ }
7107
+ return topicId;
7108
+ }
7063
7109
  var AUDIT_NODE_REFERENCE_KEY_PATTERN = /(^|_)(id|nodeid|beliefid|resourceid|targetid|sourceid|subjectid|globalid|entityid|recordid|fromnodeid|tonodeid|linkednodeid|linkedbeliefid|nodeids|beliefids|resourceids)$/i;
7064
7110
  function matchesAuditNodeReference(value, nodeId) {
7065
7111
  if (Array.isArray(value)) {
@@ -7095,6 +7141,23 @@ function requireBaseRate(args) {
7095
7141
  function exposeGatewayData(response) {
7096
7142
  return Object.assign({}, response, response.data);
7097
7143
  }
7144
+ function sdkQueryString(input) {
7145
+ const params = new URLSearchParams();
7146
+ for (const [key, value] of Object.entries(input)) {
7147
+ if (value === void 0 || value === null) {
7148
+ continue;
7149
+ }
7150
+ if (Array.isArray(value)) {
7151
+ if (value.length > 0) {
7152
+ params.set(key, value.join(","));
7153
+ }
7154
+ continue;
7155
+ }
7156
+ params.set(key, String(value));
7157
+ }
7158
+ const serialized = params.toString();
7159
+ return serialized ? `?${serialized}` : "";
7160
+ }
7098
7161
  function createLucernClient(config = {}) {
7099
7162
  const gatewayConfig = toGatewayConfig(config);
7100
7163
  const beliefsClient = createBeliefsClient(gatewayConfig);
@@ -7515,6 +7578,30 @@ function createLucernClient(config = {}) {
7515
7578
  batchCreate(input, idempotencyKey) {
7516
7579
  return graphClient.batchCreateNodes(input, idempotencyKey);
7517
7580
  },
7581
+ listByTopicAndType(input) {
7582
+ return gateway.request({
7583
+ path: `/api/platform/v1/nodes${sdkQueryString({
7584
+ topicId: requireTopicOrProjectId(input),
7585
+ nodeType: input.nodeType,
7586
+ nodeTypes: input.nodeTypes,
7587
+ query: input.query,
7588
+ sourceText: input.sourceText,
7589
+ limit: input.limit,
7590
+ cursor: input.cursor
7591
+ })}`
7592
+ }).then(exposeGatewayData);
7593
+ },
7594
+ countByTopicAndType(input) {
7595
+ return gateway.request({
7596
+ path: `/api/platform/v1/nodes/count${sdkQueryString({
7597
+ topicId: requireTopicOrProjectId(input),
7598
+ nodeType: input.nodeType,
7599
+ nodeTypes: input.nodeTypes,
7600
+ query: input.query,
7601
+ limit: input.limit
7602
+ })}`
7603
+ }).then(exposeGatewayData);
7604
+ },
7518
7605
  supersede(input, idempotencyKey) {
7519
7606
  return graphClient.supersedeNode(input, idempotencyKey);
7520
7607
  },
@@ -7525,6 +7612,78 @@ function createLucernClient(config = {}) {
7525
7612
  return graphClient.hardDeleteNode(input, idempotencyKey);
7526
7613
  }
7527
7614
  };
7615
+ const publicationNamespace = {
7616
+ create(input, idempotencyKey) {
7617
+ return gateway.request({
7618
+ path: "/api/platform/v1/publication",
7619
+ method: "POST",
7620
+ body: input,
7621
+ idempotencyKey: idempotencyKey ?? randomIdempotencyKey()
7622
+ }).then(exposeGatewayData);
7623
+ },
7624
+ update(publicationId, input, idempotencyKey) {
7625
+ return gateway.request({
7626
+ path: `/api/platform/v1/publication/${encodeURIComponent(
7627
+ publicationId
7628
+ )}`,
7629
+ method: "PATCH",
7630
+ body: input,
7631
+ idempotencyKey: idempotencyKey ?? randomIdempotencyKey()
7632
+ }).then(exposeGatewayData);
7633
+ },
7634
+ list(input = {}) {
7635
+ return gateway.request({
7636
+ path: `/api/platform/v1/publication${sdkQueryString(input)}`
7637
+ }).then(exposeGatewayData);
7638
+ },
7639
+ getByTopic(input) {
7640
+ const topicId = typeof input === "string" ? input : input.topicId;
7641
+ const workspaceId = typeof input === "string" ? void 0 : input.workspaceId;
7642
+ return gateway.request({
7643
+ path: `/api/platform/v1/publication/by-topic/${encodeURIComponent(
7644
+ topicId
7645
+ )}${sdkQueryString({ workspaceId })}`
7646
+ }).then(exposeGatewayData);
7647
+ },
7648
+ publish(publicationId, input = {}, idempotencyKey) {
7649
+ return gateway.request({
7650
+ path: `/api/platform/v1/publication/${encodeURIComponent(
7651
+ publicationId
7652
+ )}/publish`,
7653
+ method: "POST",
7654
+ body: input,
7655
+ idempotencyKey: idempotencyKey ?? randomIdempotencyKey()
7656
+ }).then(exposeGatewayData);
7657
+ },
7658
+ unpublish(publicationId, input = {}, idempotencyKey) {
7659
+ return gateway.request({
7660
+ path: `/api/platform/v1/publication/${encodeURIComponent(
7661
+ publicationId
7662
+ )}/unpublish`,
7663
+ method: "POST",
7664
+ body: input,
7665
+ idempotencyKey: idempotencyKey ?? randomIdempotencyKey()
7666
+ }).then(exposeGatewayData);
7667
+ },
7668
+ remove(publicationId, input = {}) {
7669
+ return gateway.request({
7670
+ path: `/api/platform/v1/publication/${encodeURIComponent(
7671
+ publicationId
7672
+ )}${sdkQueryString(input)}`,
7673
+ method: "DELETE"
7674
+ }).then(exposeGatewayData);
7675
+ }
7676
+ };
7677
+ const ontologyLinksNamespace = {
7678
+ ...ontologyLinksClient,
7679
+ resolveThemeSource(input) {
7680
+ return gateway.request({
7681
+ path: "/api/platform/v1/ontology-links/theme-source",
7682
+ method: "POST",
7683
+ body: input
7684
+ }).then(exposeGatewayData);
7685
+ }
7686
+ };
7528
7687
  return {
7529
7688
  config,
7530
7689
  version: LUCERN_SDK_VERSION,
@@ -8006,6 +8165,54 @@ function createLucernClient(config = {}) {
8006
8165
  }));
8007
8166
  }
8008
8167
  },
8168
+ themes: {
8169
+ listByTopic(input) {
8170
+ return gateway.request({
8171
+ path: `/api/platform/v1/themes${sdkQueryString({
8172
+ topicId: requireTopicOrProjectId(input),
8173
+ query: input.query,
8174
+ limit: input.limit,
8175
+ cursor: input.cursor
8176
+ })}`
8177
+ }).then(exposeGatewayData);
8178
+ }
8179
+ },
8180
+ graphSearch: {
8181
+ keywordSearchNodes(input) {
8182
+ return gateway.request({
8183
+ path: "/api/platform/v1/graph-search/keyword-nodes",
8184
+ method: "POST",
8185
+ body: {
8186
+ ...input,
8187
+ topicId: requireTopicOrProjectId(input),
8188
+ projectId: void 0
8189
+ }
8190
+ }).then(exposeGatewayData);
8191
+ }
8192
+ },
8193
+ classifiers: {
8194
+ listBeliefCandidates(input) {
8195
+ return gateway.request({
8196
+ path: `/api/platform/v1/classifiers/belief-candidates${sdkQueryString({
8197
+ topicId: requireTopicOrProjectId(input),
8198
+ classifierKey: input.classifierKey,
8199
+ query: input.query,
8200
+ limit: input.limit,
8201
+ cursor: input.cursor
8202
+ })}`
8203
+ }).then(exposeGatewayData);
8204
+ }
8205
+ },
8206
+ archetypes: {
8207
+ getJudgmentSignature(input) {
8208
+ return gateway.request({
8209
+ path: `/api/platform/v1/archetypes/judgment-signature${sdkQueryString({
8210
+ topicId: requireTopicOrProjectId(input),
8211
+ principalId: input.principalId
8212
+ })}`
8213
+ }).then(exposeGatewayData);
8214
+ }
8215
+ },
8009
8216
  judgments: {
8010
8217
  create(input) {
8011
8218
  return decisionsClient.createJudgment(input);
@@ -8047,6 +8254,52 @@ function createLucernClient(config = {}) {
8047
8254
  });
8048
8255
  }
8049
8256
  },
8257
+ decisions: {
8258
+ create(input) {
8259
+ return decisionsClient.createJudgment(input);
8260
+ },
8261
+ record(input) {
8262
+ return decisionsClient.recordJudgment(input);
8263
+ },
8264
+ list(query5) {
8265
+ return decisionsClient.listJudgments(query5);
8266
+ },
8267
+ get(decisionId) {
8268
+ return decisionsClient.getJudgment(decisionId);
8269
+ },
8270
+ recordOutcome(decisionId, input) {
8271
+ return decisionsClient.recordJudgmentOutcome(decisionId, input);
8272
+ },
8273
+ lessons(decisionId, input, idempotencyKey) {
8274
+ return gateway.request({
8275
+ path: `/api/platform/v1/decisions/${encodeURIComponent(
8276
+ decisionId
8277
+ )}/lessons`,
8278
+ method: "POST",
8279
+ body: input,
8280
+ idempotencyKey: idempotencyKey ?? randomIdempotencyKey()
8281
+ }).then(exposeGatewayData);
8282
+ },
8283
+ archive(decisionId, input = {}, idempotencyKey) {
8284
+ return gateway.request({
8285
+ path: `/api/platform/v1/decisions/${encodeURIComponent(
8286
+ decisionId
8287
+ )}/archive`,
8288
+ method: "POST",
8289
+ body: input,
8290
+ idempotencyKey: idempotencyKey ?? randomIdempotencyKey()
8291
+ }).then(exposeGatewayData);
8292
+ },
8293
+ readiness(topicId) {
8294
+ return decisionsClient.getJudgmentReadiness({ topicId });
8295
+ },
8296
+ calibration(topicId) {
8297
+ return decisionsClient.getJudgmentCalibration({ topicId });
8298
+ },
8299
+ pendingOutcomeReview(topicId) {
8300
+ return decisionsClient.listPendingJudgmentOutcomeReview({ topicId });
8301
+ }
8302
+ },
8050
8303
  worktrees: {
8051
8304
  createBranch(input) {
8052
8305
  return workflowClient.createBranch(input);
@@ -8069,7 +8322,21 @@ function createLucernClient(config = {}) {
8069
8322
  topicId: requireTopicId4(input),
8070
8323
  objective: input.objective,
8071
8324
  hypothesis: input.hypothesis,
8325
+ rationale: input.rationale,
8326
+ worktreeType: input.worktreeType,
8327
+ startDate: input.startDate,
8328
+ endDate: input.endDate,
8329
+ durationWeeks: input.durationWeeks,
8330
+ confidenceImpact: input.confidenceImpact,
8331
+ beliefFocus: input.beliefFocus,
8072
8332
  beliefIds: input.beliefIds,
8333
+ targetBeliefIds: input.targetBeliefIds,
8334
+ targetQuestionIds: input.targetQuestionIds,
8335
+ keyQuestions: input.keyQuestions,
8336
+ evidenceSignals: input.evidenceSignals,
8337
+ decisionGate: input.decisionGate,
8338
+ goCriteria: input.goCriteria,
8339
+ noGoSignals: input.noGoSignals,
8073
8340
  autoShape: input.autoShape,
8074
8341
  domainPackId: input.domainPackId,
8075
8342
  campaign: input.campaign,
@@ -8082,7 +8349,8 @@ function createLucernClient(config = {}) {
8082
8349
  proofArtifacts: input.proofArtifacts,
8083
8350
  staffingHint: typeof input.staffingHint === "string" ? input.staffingHint : void 0,
8084
8351
  lastReconciledAt: input.lastReconciledAt,
8085
- autoFixPolicy: input.autoFixPolicy
8352
+ autoFixPolicy: input.autoFixPolicy,
8353
+ lensId: input.lensId
8086
8354
  });
8087
8355
  },
8088
8356
  add(input) {
@@ -8091,7 +8359,21 @@ function createLucernClient(config = {}) {
8091
8359
  topicId: requireTopicId4(input),
8092
8360
  objective: input.objective,
8093
8361
  hypothesis: input.hypothesis,
8362
+ rationale: input.rationale,
8363
+ worktreeType: input.worktreeType,
8364
+ startDate: input.startDate,
8365
+ endDate: input.endDate,
8366
+ durationWeeks: input.durationWeeks,
8367
+ confidenceImpact: input.confidenceImpact,
8368
+ beliefFocus: input.beliefFocus,
8094
8369
  beliefIds: input.beliefIds,
8370
+ targetBeliefIds: input.targetBeliefIds,
8371
+ targetQuestionIds: input.targetQuestionIds,
8372
+ keyQuestions: input.keyQuestions,
8373
+ evidenceSignals: input.evidenceSignals,
8374
+ decisionGate: input.decisionGate,
8375
+ goCriteria: input.goCriteria,
8376
+ noGoSignals: input.noGoSignals,
8095
8377
  autoShape: input.autoShape,
8096
8378
  domainPackId: input.domainPackId,
8097
8379
  campaign: input.campaign,
@@ -8104,7 +8386,8 @@ function createLucernClient(config = {}) {
8104
8386
  proofArtifacts: input.proofArtifacts,
8105
8387
  staffingHint: typeof input.staffingHint === "string" ? input.staffingHint : void 0,
8106
8388
  lastReconciledAt: input.lastReconciledAt,
8107
- autoFixPolicy: input.autoFixPolicy
8389
+ autoFixPolicy: input.autoFixPolicy,
8390
+ lensId: input.lensId
8108
8391
  });
8109
8392
  },
8110
8393
  list(query5) {
@@ -8114,6 +8397,22 @@ function createLucernClient(config = {}) {
8114
8397
  limit: query5.limit
8115
8398
  });
8116
8399
  },
8400
+ listByTopic(query5) {
8401
+ return worktreesFacade.list({
8402
+ topicId: requireTopicId4(query5),
8403
+ status: query5.status,
8404
+ limit: query5.limit
8405
+ });
8406
+ },
8407
+ findByPairedSprint(input) {
8408
+ return gateway.request({
8409
+ path: `/api/platform/v1/worktrees/paired-sprint${sdkQueryString({
8410
+ sprintId: input.sprintId,
8411
+ topicId: input.topicId ?? input.projectId,
8412
+ limit: input.limit
8413
+ })}`
8414
+ }).then(exposeGatewayData);
8415
+ },
8117
8416
  activate(worktreeId) {
8118
8417
  return worktreesFacade.activate({ id: worktreeId });
8119
8418
  },
@@ -8265,6 +8564,31 @@ function createLucernClient(config = {}) {
8265
8564
  status: typeof input.status === "string" ? input.status : void 0,
8266
8565
  limit: typeof input.limit === "number" ? input.limit : void 0
8267
8566
  });
8567
+ },
8568
+ listByTopic(input) {
8569
+ return tasksFacade.list({
8570
+ topicId: requireTopicId4(input),
8571
+ status: typeof input.status === "string" ? input.status : void 0,
8572
+ limit: typeof input.limit === "number" ? input.limit : void 0
8573
+ });
8574
+ },
8575
+ listByWorktree(input) {
8576
+ return tasksFacade.list({
8577
+ topicId: typeof input.topicId === "string" ? input.topicId : void 0,
8578
+ worktreeId: input.worktreeId,
8579
+ status: typeof input.status === "string" ? input.status : void 0,
8580
+ limit: typeof input.limit === "number" ? input.limit : void 0
8581
+ });
8582
+ },
8583
+ linkChat(taskId, input, idempotencyKey) {
8584
+ return gateway.request({
8585
+ path: `/api/platform/v1/tasks/${encodeURIComponent(
8586
+ taskId
8587
+ )}/link-chat`,
8588
+ method: "POST",
8589
+ body: input,
8590
+ idempotencyKey: idempotencyKey ?? randomIdempotencyKey()
8591
+ }).then(exposeGatewayData);
8268
8592
  }
8269
8593
  },
8270
8594
  topics: {
@@ -8549,11 +8873,13 @@ function createLucernClient(config = {}) {
8549
8873
  graphAnalysis: graphAnalysisClient,
8550
8874
  graphRecommendations: graphRecommendationsClient,
8551
8875
  orgGraphSearch: orgGraphSearchClient,
8552
- ontologyLinks: ontologyLinksClient,
8876
+ ontologyLinks: ontologyLinksNamespace,
8553
8877
  graphStateClassifier: graphStateClassifierClient,
8554
8878
  modelRuntime: modelRuntimeClient,
8555
8879
  jobs: jobsClient,
8556
8880
  telemetry: telemetryClient,
8881
+ publication: publicationNamespace,
8882
+ contentPublication: publicationNamespace,
8557
8883
  tools: {
8558
8884
  listCatalog: toolRegistryClient.listCatalog,
8559
8885
  listExecutable: toolRegistryClient.listExecutable,