@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.
- package/README.md +47 -0
- package/dist/adminClient.js +4 -3
- package/dist/adminClient.js.map +1 -1
- package/dist/answersClient.js +4 -3
- package/dist/answersClient.js.map +1 -1
- package/dist/audiencesClient.js +4 -3
- package/dist/audiencesClient.js.map +1 -1
- package/dist/auditClient.js +4 -3
- package/dist/auditClient.js.map +1 -1
- package/dist/authContext.js +4 -3
- package/dist/authContext.js.map +1 -1
- package/dist/beliefs/index.d.ts +3 -1
- package/dist/beliefs/index.js +333 -7
- package/dist/beliefs/index.js.map +1 -1
- package/dist/beliefsClient.js +4 -3
- package/dist/beliefsClient.js.map +1 -1
- package/dist/client.d.ts +2981 -40
- package/dist/client.js +333 -7
- package/dist/client.js.map +1 -1
- package/dist/contextClient.js +4 -3
- package/dist/contextClient.js.map +1 -1
- package/dist/contracts/api-enums.contract.d.ts +1 -1
- package/dist/contracts/api-enums.contract.js.map +1 -1
- package/dist/contracts/index.js.map +1 -1
- package/dist/contradictions/index.d.ts +3 -1
- package/dist/contradictions/index.js +333 -7
- package/dist/contradictions/index.js.map +1 -1
- package/dist/coreClient.js +4 -3
- package/dist/coreClient.js.map +1 -1
- package/dist/decisions/index.d.ts +3 -1
- package/dist/decisions/index.js +333 -7
- package/dist/decisions/index.js.map +1 -1
- package/dist/decisionsClient.js +4 -3
- package/dist/decisionsClient.js.map +1 -1
- package/dist/edges/index.d.ts +3 -1
- package/dist/edges/index.js +333 -7
- package/dist/edges/index.js.map +1 -1
- package/dist/embeddingsClient.js +4 -3
- package/dist/embeddingsClient.js.map +1 -1
- package/dist/eventingClient.js +4 -3
- package/dist/eventingClient.js.map +1 -1
- package/dist/eventsCore.js +4 -3
- package/dist/eventsCore.js.map +1 -1
- package/dist/evidence/index.d.ts +3 -1
- package/dist/evidence/index.js +333 -7
- package/dist/evidence/index.js.map +1 -1
- package/dist/evidenceClient.js +4 -3
- package/dist/evidenceClient.js.map +1 -1
- package/dist/functionSurface.d.ts +129 -0
- package/dist/functionSurface.js +1118 -0
- package/dist/functionSurface.js.map +1 -0
- package/dist/functionSurfaceClient.d.ts +8 -0
- package/dist/functionSurfaceClient.js +1118 -0
- package/dist/functionSurfaceClient.js.map +1 -0
- package/dist/gatewayFacades.d.ts +34 -1
- package/dist/gatewayFacades.js +4 -3
- package/dist/gatewayFacades.js.map +1 -1
- package/dist/graphAnalysisClient.d.ts +53 -1
- package/dist/graphAnalysisClient.js +31 -4
- package/dist/graphAnalysisClient.js.map +1 -1
- package/dist/graphClient.js +4 -3
- package/dist/graphClient.js.map +1 -1
- package/dist/graphIntel.d.ts +3 -0
- package/dist/graphIntel.js +3 -0
- package/dist/graphIntel.js.map +1 -0
- package/dist/graphIntelligence.d.ts +2 -0
- package/dist/graphIntelligence.js +47 -0
- package/dist/graphIntelligence.js.map +1 -0
- package/dist/graphRecommendationsClient.js +4 -3
- package/dist/graphRecommendationsClient.js.map +1 -1
- package/dist/graphStateClassifierClient.js +4 -3
- package/dist/graphStateClassifierClient.js.map +1 -1
- package/dist/harnessClient.js +4 -3
- package/dist/harnessClient.js.map +1 -1
- package/dist/identityClient.js +4 -3
- package/dist/identityClient.js.map +1 -1
- package/dist/index.d.ts +8 -3
- package/dist/index.js +670 -8
- package/dist/index.js.map +1 -1
- package/dist/infisicalRuntime.d.ts +42 -0
- package/dist/infisicalRuntime.js +291 -0
- package/dist/infisicalRuntime.js.map +1 -0
- package/dist/jobsClient.js +4 -3
- package/dist/jobsClient.js.map +1 -1
- package/dist/learningClient.js +4 -3
- package/dist/learningClient.js.map +1 -1
- package/dist/lenses/index.d.ts +28 -2
- package/dist/lenses/index.js +333 -7
- package/dist/lenses/index.js.map +1 -1
- package/dist/mcpClient.js +4 -3
- package/dist/mcpClient.js.map +1 -1
- package/dist/modelRuntimeClient.js +4 -3
- package/dist/modelRuntimeClient.js.map +1 -1
- package/dist/nodes/index.d.ts +21 -1
- package/dist/nodes/index.js +333 -7
- package/dist/nodes/index.js.map +1 -1
- package/dist/ontologies/index.d.ts +3 -1
- package/dist/ontologies/index.js +333 -7
- package/dist/ontologies/index.js.map +1 -1
- package/dist/ontologyClient.js +4 -3
- package/dist/ontologyClient.js.map +1 -1
- package/dist/ontologyLinksClient.js +4 -3
- package/dist/ontologyLinksClient.js.map +1 -1
- package/dist/orgGraphSearchClient.js +4 -3
- package/dist/orgGraphSearchClient.js.map +1 -1
- package/dist/packRuntime.d.ts +2 -1
- package/dist/packsClient.js +4 -3
- package/dist/packsClient.js.map +1 -1
- package/dist/policyClient.js +4 -3
- package/dist/policyClient.js.map +1 -1
- package/dist/questions/index.d.ts +3 -1
- package/dist/questions/index.js +333 -7
- package/dist/questions/index.js.map +1 -1
- package/dist/reportsClient.js +4 -3
- package/dist/reportsClient.js.map +1 -1
- package/dist/schemaClient.js +4 -3
- package/dist/schemaClient.js.map +1 -1
- package/dist/sourcesClient.js +4 -3
- package/dist/sourcesClient.js.map +1 -1
- package/dist/telemetryClient.js +4 -3
- package/dist/telemetryClient.js.map +1 -1
- package/dist/toolRegistryClient.js +4 -3
- package/dist/toolRegistryClient.js.map +1 -1
- package/dist/topics/index.d.ts +3 -1
- package/dist/topics/index.js +333 -7
- package/dist/topics/index.js.map +1 -1
- package/dist/topicsClient.js +4 -3
- package/dist/topicsClient.js.map +1 -1
- package/dist/workflowClient.d.ts +41 -7
- package/dist/workflowClient.js +4 -3
- package/dist/workflowClient.js.map +1 -1
- package/dist/worktrees/index.d.ts +29 -3
- package/dist/worktrees/index.js +333 -7
- package/dist/worktrees/index.js.map +1 -1
- package/package.json +12 -3
- package/dist/client-EiG9nJOY.d.ts +0 -2911
package/dist/edges/index.js
CHANGED
|
@@ -91,14 +91,15 @@ function normalizeCanonicalLucernAuthContext(input) {
|
|
|
91
91
|
);
|
|
92
92
|
const roles = cleanStringList(input.roles);
|
|
93
93
|
const scopes = cleanStringList(input.scopes);
|
|
94
|
-
|
|
94
|
+
const principalType = requirePrincipalType(input.principalType);
|
|
95
|
+
const authMode = requireAuthMode(input.authMode);
|
|
96
|
+
const roleBasedInteractiveAuth = authMode === "interactive_user" && roles.length > 0;
|
|
97
|
+
if (roles.length === 0 || scopes.length === 0 && !roleBasedInteractiveAuth) {
|
|
95
98
|
throw new LucernSdkAuthContextError(
|
|
96
99
|
"membership_missing",
|
|
97
100
|
"Canonical Lucern SDK auth context requires non-empty roles and scopes."
|
|
98
101
|
);
|
|
99
102
|
}
|
|
100
|
-
const principalType = requirePrincipalType(input.principalType);
|
|
101
|
-
const authMode = requireAuthMode(input.authMode);
|
|
102
103
|
const subject = cleanString(input.permit?.subject) ?? principalId;
|
|
103
104
|
const tenant = cleanString(input.permit?.tenant) ?? tenantId;
|
|
104
105
|
const workspace = cleanString(input.permit?.workspace) ?? workspaceId;
|
|
@@ -4121,9 +4122,33 @@ function graphAnalysisQuery(input) {
|
|
|
4121
4122
|
cursor: input.cursor
|
|
4122
4123
|
};
|
|
4123
4124
|
}
|
|
4125
|
+
function normalizeRunQueryPayload(input) {
|
|
4126
|
+
return {
|
|
4127
|
+
...input,
|
|
4128
|
+
topicId: requireTopicId2(input),
|
|
4129
|
+
projectId: void 0
|
|
4130
|
+
};
|
|
4131
|
+
}
|
|
4124
4132
|
function createGraphAnalysisClient(config = {}) {
|
|
4125
4133
|
const gateway = createGatewayRequestClient(config);
|
|
4126
4134
|
return {
|
|
4135
|
+
listGraphIntelligenceQueries(input = {}) {
|
|
4136
|
+
return gateway.request({
|
|
4137
|
+
path: "/api/platform/v1/graph-intelligence/queries",
|
|
4138
|
+
method: "POST",
|
|
4139
|
+
body: {
|
|
4140
|
+
categoryId: input.categoryId,
|
|
4141
|
+
mode: input.mode
|
|
4142
|
+
}
|
|
4143
|
+
});
|
|
4144
|
+
},
|
|
4145
|
+
runGraphIntelligenceQuery(input) {
|
|
4146
|
+
return gateway.request({
|
|
4147
|
+
path: "/api/platform/v1/graph-intelligence/run",
|
|
4148
|
+
method: "POST",
|
|
4149
|
+
body: normalizeRunQueryPayload(input)
|
|
4150
|
+
});
|
|
4151
|
+
},
|
|
4127
4152
|
saveAnalysis(input, idempotencyKey) {
|
|
4128
4153
|
return gateway.request({
|
|
4129
4154
|
path: "/api/platform/v1/graph-analysis/analyses",
|
|
@@ -4205,7 +4230,9 @@ function createGraphAnalysisClient(config = {}) {
|
|
|
4205
4230
|
topicId: requireTopicId2(input),
|
|
4206
4231
|
workspaceId: input.workspaceId,
|
|
4207
4232
|
analysisId: input.analysisId,
|
|
4208
|
-
|
|
4233
|
+
minimumCreatedAt: input.minimumCreatedAt ?? input.since ?? input.createdAt ?? input.analysisCreatedAt,
|
|
4234
|
+
sourceNodeIds: input.sourceNodeIds?.join(",") ?? (input.nodeId ? input.nodeId : void 0),
|
|
4235
|
+
sourceEdgeIds: input.sourceEdgeIds?.join(",") ?? (input.edgeId ? input.edgeId : void 0),
|
|
4209
4236
|
limit: input.limit,
|
|
4210
4237
|
cursor: input.cursor
|
|
4211
4238
|
})}`
|
|
@@ -4961,6 +4988,7 @@ var CONTRACTS = {
|
|
|
4961
4988
|
"archive_belief": { method: "DELETE", path: "/beliefs", kind: "mutation", idempotent: true, surfaceIntent: "mcp_core" },
|
|
4962
4989
|
"archive_ontology": { method: "DELETE", path: "/ontologies", kind: "mutation", idempotent: true, surfaceIntent: "mcp_governance" },
|
|
4963
4990
|
"archive_question": { method: "DELETE", path: "/questions", kind: "mutation", idempotent: true, surfaceIntent: "mcp_core" },
|
|
4991
|
+
"begin_build_session": { method: "POST", path: "/mcp/build-session/begin", kind: "mutation", idempotent: true, surfaceIntent: "system" },
|
|
4964
4992
|
"bisect_confidence": { method: "POST", path: "/beliefs/confidence/bisect", kind: "query", idempotent: false, surfaceIntent: "mcp_core" },
|
|
4965
4993
|
"broadcast_message": { method: "POST", path: "/coordination/messages/broadcast", kind: "mutation", idempotent: true, surfaceIntent: "system" },
|
|
4966
4994
|
"check_permission": { method: "POST", path: "/identity/check-permission", kind: "query", idempotent: false, surfaceIntent: "mcp_core" },
|
|
@@ -5023,6 +5051,7 @@ var CONTRACTS = {
|
|
|
5023
5051
|
"list_beliefs": { method: "GET", path: "/beliefs", kind: "query", idempotent: false, surfaceIntent: "mcp_core" },
|
|
5024
5052
|
"list_campaigns": { method: "GET", path: "/worktrees/campaigns", kind: "query", idempotent: false, surfaceIntent: "mcp_workflow" },
|
|
5025
5053
|
"list_evidence": { method: "GET", path: "/evidence", kind: "query", idempotent: false, surfaceIntent: "mcp_core" },
|
|
5054
|
+
"list_graph_intelligence_queries": { method: "POST", path: "/graph-intelligence/queries", kind: "query", idempotent: false, surfaceIntent: "mcp_analysis" },
|
|
5026
5055
|
"list_lenses": { method: "GET", path: "/lenses", kind: "query", idempotent: false, surfaceIntent: "mcp_workflow" },
|
|
5027
5056
|
"list_ontologies": { method: "GET", path: "/ontologies", kind: "query", idempotent: false, surfaceIntent: "mcp_workflow" },
|
|
5028
5057
|
"list_questions": { method: "GET", path: "/questions", kind: "query", idempotent: false, surfaceIntent: "mcp_core" },
|
|
@@ -5046,6 +5075,7 @@ var CONTRACTS = {
|
|
|
5046
5075
|
"register_session": { method: "POST", path: "/coordination/register-session", kind: "mutation", idempotent: true, surfaceIntent: "system" },
|
|
5047
5076
|
"remove_lens_from_topic": { method: "DELETE", path: "/lenses/apply", kind: "mutation", idempotent: true, surfaceIntent: "mcp_workflow" },
|
|
5048
5077
|
"resolve_effective_ontology": { method: "POST", path: "/ontologies/effective", kind: "query", idempotent: false, surfaceIntent: "mcp_workflow" },
|
|
5078
|
+
"run_graph_intelligence_query": { method: "POST", path: "/graph-intelligence/run", kind: "query", idempotent: false, surfaceIntent: "mcp_analysis" },
|
|
5049
5079
|
"search_beliefs": { method: "POST", path: "/beliefs/search", kind: "query", idempotent: false, surfaceIntent: "mcp_core" },
|
|
5050
5080
|
"search_evidence": { method: "POST", path: "/evidence/search", kind: "query", idempotent: false, surfaceIntent: "mcp_core" },
|
|
5051
5081
|
"seed_belief_lattice": { method: "POST", path: "/scope/belief-lattice/seed", kind: "mutation", idempotent: true, surfaceIntent: "system" },
|
|
@@ -5132,6 +5162,9 @@ function createFunctionSurfaceClient(config = {}) {
|
|
|
5132
5162
|
archiveQuestion(input = {}, idempotencyKey) {
|
|
5133
5163
|
return execute("archive_question", input, idempotencyKey);
|
|
5134
5164
|
},
|
|
5165
|
+
beginBuildSession(input = {}, idempotencyKey) {
|
|
5166
|
+
return execute("begin_build_session", input, idempotencyKey);
|
|
5167
|
+
},
|
|
5135
5168
|
bisectConfidence(input = {}, idempotencyKey) {
|
|
5136
5169
|
return execute("bisect_confidence", input, idempotencyKey);
|
|
5137
5170
|
},
|
|
@@ -5318,6 +5351,9 @@ function createFunctionSurfaceClient(config = {}) {
|
|
|
5318
5351
|
listEvidence(input = {}, idempotencyKey) {
|
|
5319
5352
|
return execute("list_evidence", input, idempotencyKey);
|
|
5320
5353
|
},
|
|
5354
|
+
listGraphIntelligenceQueries(input = {}, idempotencyKey) {
|
|
5355
|
+
return execute("list_graph_intelligence_queries", input, idempotencyKey);
|
|
5356
|
+
},
|
|
5321
5357
|
listLenses(input = {}, idempotencyKey) {
|
|
5322
5358
|
return execute("list_lenses", input, idempotencyKey);
|
|
5323
5359
|
},
|
|
@@ -5387,6 +5423,9 @@ function createFunctionSurfaceClient(config = {}) {
|
|
|
5387
5423
|
resolveEffectiveOntology(input = {}, idempotencyKey) {
|
|
5388
5424
|
return execute("resolve_effective_ontology", input, idempotencyKey);
|
|
5389
5425
|
},
|
|
5426
|
+
runGraphIntelligenceQuery(input = {}, idempotencyKey) {
|
|
5427
|
+
return execute("run_graph_intelligence_query", input, idempotencyKey);
|
|
5428
|
+
},
|
|
5390
5429
|
searchBeliefs(input = {}, idempotencyKey) {
|
|
5391
5430
|
return execute("search_beliefs", input, idempotencyKey);
|
|
5392
5431
|
},
|
|
@@ -7066,6 +7105,13 @@ function requireTopicId4(args) {
|
|
|
7066
7105
|
}
|
|
7067
7106
|
return topicId;
|
|
7068
7107
|
}
|
|
7108
|
+
function requireTopicOrProjectId(args) {
|
|
7109
|
+
const topicId = args.topicId?.trim() || args.projectId?.trim() || void 0;
|
|
7110
|
+
if (!topicId) {
|
|
7111
|
+
throw new Error("topicId is required");
|
|
7112
|
+
}
|
|
7113
|
+
return topicId;
|
|
7114
|
+
}
|
|
7069
7115
|
var AUDIT_NODE_REFERENCE_KEY_PATTERN = /(^|_)(id|nodeid|beliefid|resourceid|targetid|sourceid|subjectid|globalid|entityid|recordid|fromnodeid|tonodeid|linkednodeid|linkedbeliefid|nodeids|beliefids|resourceids)$/i;
|
|
7070
7116
|
function matchesAuditNodeReference(value, nodeId) {
|
|
7071
7117
|
if (Array.isArray(value)) {
|
|
@@ -7101,6 +7147,23 @@ function requireBaseRate(args) {
|
|
|
7101
7147
|
function exposeGatewayData(response) {
|
|
7102
7148
|
return Object.assign({}, response, response.data);
|
|
7103
7149
|
}
|
|
7150
|
+
function sdkQueryString(input) {
|
|
7151
|
+
const params = new URLSearchParams();
|
|
7152
|
+
for (const [key, value] of Object.entries(input)) {
|
|
7153
|
+
if (value === void 0 || value === null) {
|
|
7154
|
+
continue;
|
|
7155
|
+
}
|
|
7156
|
+
if (Array.isArray(value)) {
|
|
7157
|
+
if (value.length > 0) {
|
|
7158
|
+
params.set(key, value.join(","));
|
|
7159
|
+
}
|
|
7160
|
+
continue;
|
|
7161
|
+
}
|
|
7162
|
+
params.set(key, String(value));
|
|
7163
|
+
}
|
|
7164
|
+
const serialized = params.toString();
|
|
7165
|
+
return serialized ? `?${serialized}` : "";
|
|
7166
|
+
}
|
|
7104
7167
|
function createLucernClient(config = {}) {
|
|
7105
7168
|
const gatewayConfig = toGatewayConfig(config);
|
|
7106
7169
|
const beliefsClient = createBeliefsClient(gatewayConfig);
|
|
@@ -7521,6 +7584,30 @@ function createLucernClient(config = {}) {
|
|
|
7521
7584
|
batchCreate(input, idempotencyKey) {
|
|
7522
7585
|
return graphClient.batchCreateNodes(input, idempotencyKey);
|
|
7523
7586
|
},
|
|
7587
|
+
listByTopicAndType(input) {
|
|
7588
|
+
return gateway.request({
|
|
7589
|
+
path: `/api/platform/v1/nodes${sdkQueryString({
|
|
7590
|
+
topicId: requireTopicOrProjectId(input),
|
|
7591
|
+
nodeType: input.nodeType,
|
|
7592
|
+
nodeTypes: input.nodeTypes,
|
|
7593
|
+
query: input.query,
|
|
7594
|
+
sourceText: input.sourceText,
|
|
7595
|
+
limit: input.limit,
|
|
7596
|
+
cursor: input.cursor
|
|
7597
|
+
})}`
|
|
7598
|
+
}).then(exposeGatewayData);
|
|
7599
|
+
},
|
|
7600
|
+
countByTopicAndType(input) {
|
|
7601
|
+
return gateway.request({
|
|
7602
|
+
path: `/api/platform/v1/nodes/count${sdkQueryString({
|
|
7603
|
+
topicId: requireTopicOrProjectId(input),
|
|
7604
|
+
nodeType: input.nodeType,
|
|
7605
|
+
nodeTypes: input.nodeTypes,
|
|
7606
|
+
query: input.query,
|
|
7607
|
+
limit: input.limit
|
|
7608
|
+
})}`
|
|
7609
|
+
}).then(exposeGatewayData);
|
|
7610
|
+
},
|
|
7524
7611
|
supersede(input, idempotencyKey) {
|
|
7525
7612
|
return graphClient.supersedeNode(input, idempotencyKey);
|
|
7526
7613
|
},
|
|
@@ -7531,6 +7618,78 @@ function createLucernClient(config = {}) {
|
|
|
7531
7618
|
return graphClient.hardDeleteNode(input, idempotencyKey);
|
|
7532
7619
|
}
|
|
7533
7620
|
};
|
|
7621
|
+
const publicationNamespace = {
|
|
7622
|
+
create(input, idempotencyKey) {
|
|
7623
|
+
return gateway.request({
|
|
7624
|
+
path: "/api/platform/v1/publication",
|
|
7625
|
+
method: "POST",
|
|
7626
|
+
body: input,
|
|
7627
|
+
idempotencyKey: idempotencyKey ?? randomIdempotencyKey()
|
|
7628
|
+
}).then(exposeGatewayData);
|
|
7629
|
+
},
|
|
7630
|
+
update(publicationId, input, idempotencyKey) {
|
|
7631
|
+
return gateway.request({
|
|
7632
|
+
path: `/api/platform/v1/publication/${encodeURIComponent(
|
|
7633
|
+
publicationId
|
|
7634
|
+
)}`,
|
|
7635
|
+
method: "PATCH",
|
|
7636
|
+
body: input,
|
|
7637
|
+
idempotencyKey: idempotencyKey ?? randomIdempotencyKey()
|
|
7638
|
+
}).then(exposeGatewayData);
|
|
7639
|
+
},
|
|
7640
|
+
list(input = {}) {
|
|
7641
|
+
return gateway.request({
|
|
7642
|
+
path: `/api/platform/v1/publication${sdkQueryString(input)}`
|
|
7643
|
+
}).then(exposeGatewayData);
|
|
7644
|
+
},
|
|
7645
|
+
getByTopic(input) {
|
|
7646
|
+
const topicId = typeof input === "string" ? input : input.topicId;
|
|
7647
|
+
const workspaceId = typeof input === "string" ? void 0 : input.workspaceId;
|
|
7648
|
+
return gateway.request({
|
|
7649
|
+
path: `/api/platform/v1/publication/by-topic/${encodeURIComponent(
|
|
7650
|
+
topicId
|
|
7651
|
+
)}${sdkQueryString({ workspaceId })}`
|
|
7652
|
+
}).then(exposeGatewayData);
|
|
7653
|
+
},
|
|
7654
|
+
publish(publicationId, input = {}, idempotencyKey) {
|
|
7655
|
+
return gateway.request({
|
|
7656
|
+
path: `/api/platform/v1/publication/${encodeURIComponent(
|
|
7657
|
+
publicationId
|
|
7658
|
+
)}/publish`,
|
|
7659
|
+
method: "POST",
|
|
7660
|
+
body: input,
|
|
7661
|
+
idempotencyKey: idempotencyKey ?? randomIdempotencyKey()
|
|
7662
|
+
}).then(exposeGatewayData);
|
|
7663
|
+
},
|
|
7664
|
+
unpublish(publicationId, input = {}, idempotencyKey) {
|
|
7665
|
+
return gateway.request({
|
|
7666
|
+
path: `/api/platform/v1/publication/${encodeURIComponent(
|
|
7667
|
+
publicationId
|
|
7668
|
+
)}/unpublish`,
|
|
7669
|
+
method: "POST",
|
|
7670
|
+
body: input,
|
|
7671
|
+
idempotencyKey: idempotencyKey ?? randomIdempotencyKey()
|
|
7672
|
+
}).then(exposeGatewayData);
|
|
7673
|
+
},
|
|
7674
|
+
remove(publicationId, input = {}) {
|
|
7675
|
+
return gateway.request({
|
|
7676
|
+
path: `/api/platform/v1/publication/${encodeURIComponent(
|
|
7677
|
+
publicationId
|
|
7678
|
+
)}${sdkQueryString(input)}`,
|
|
7679
|
+
method: "DELETE"
|
|
7680
|
+
}).then(exposeGatewayData);
|
|
7681
|
+
}
|
|
7682
|
+
};
|
|
7683
|
+
const ontologyLinksNamespace = {
|
|
7684
|
+
...ontologyLinksClient,
|
|
7685
|
+
resolveThemeSource(input) {
|
|
7686
|
+
return gateway.request({
|
|
7687
|
+
path: "/api/platform/v1/ontology-links/theme-source",
|
|
7688
|
+
method: "POST",
|
|
7689
|
+
body: input
|
|
7690
|
+
}).then(exposeGatewayData);
|
|
7691
|
+
}
|
|
7692
|
+
};
|
|
7534
7693
|
return {
|
|
7535
7694
|
config,
|
|
7536
7695
|
version: LUCERN_SDK_VERSION,
|
|
@@ -8012,6 +8171,54 @@ function createLucernClient(config = {}) {
|
|
|
8012
8171
|
}));
|
|
8013
8172
|
}
|
|
8014
8173
|
},
|
|
8174
|
+
themes: {
|
|
8175
|
+
listByTopic(input) {
|
|
8176
|
+
return gateway.request({
|
|
8177
|
+
path: `/api/platform/v1/themes${sdkQueryString({
|
|
8178
|
+
topicId: requireTopicOrProjectId(input),
|
|
8179
|
+
query: input.query,
|
|
8180
|
+
limit: input.limit,
|
|
8181
|
+
cursor: input.cursor
|
|
8182
|
+
})}`
|
|
8183
|
+
}).then(exposeGatewayData);
|
|
8184
|
+
}
|
|
8185
|
+
},
|
|
8186
|
+
graphSearch: {
|
|
8187
|
+
keywordSearchNodes(input) {
|
|
8188
|
+
return gateway.request({
|
|
8189
|
+
path: "/api/platform/v1/graph-search/keyword-nodes",
|
|
8190
|
+
method: "POST",
|
|
8191
|
+
body: {
|
|
8192
|
+
...input,
|
|
8193
|
+
topicId: requireTopicOrProjectId(input),
|
|
8194
|
+
projectId: void 0
|
|
8195
|
+
}
|
|
8196
|
+
}).then(exposeGatewayData);
|
|
8197
|
+
}
|
|
8198
|
+
},
|
|
8199
|
+
classifiers: {
|
|
8200
|
+
listBeliefCandidates(input) {
|
|
8201
|
+
return gateway.request({
|
|
8202
|
+
path: `/api/platform/v1/classifiers/belief-candidates${sdkQueryString({
|
|
8203
|
+
topicId: requireTopicOrProjectId(input),
|
|
8204
|
+
classifierKey: input.classifierKey,
|
|
8205
|
+
query: input.query,
|
|
8206
|
+
limit: input.limit,
|
|
8207
|
+
cursor: input.cursor
|
|
8208
|
+
})}`
|
|
8209
|
+
}).then(exposeGatewayData);
|
|
8210
|
+
}
|
|
8211
|
+
},
|
|
8212
|
+
archetypes: {
|
|
8213
|
+
getJudgmentSignature(input) {
|
|
8214
|
+
return gateway.request({
|
|
8215
|
+
path: `/api/platform/v1/archetypes/judgment-signature${sdkQueryString({
|
|
8216
|
+
topicId: requireTopicOrProjectId(input),
|
|
8217
|
+
principalId: input.principalId
|
|
8218
|
+
})}`
|
|
8219
|
+
}).then(exposeGatewayData);
|
|
8220
|
+
}
|
|
8221
|
+
},
|
|
8015
8222
|
judgments: {
|
|
8016
8223
|
create(input) {
|
|
8017
8224
|
return decisionsClient.createJudgment(input);
|
|
@@ -8053,6 +8260,52 @@ function createLucernClient(config = {}) {
|
|
|
8053
8260
|
});
|
|
8054
8261
|
}
|
|
8055
8262
|
},
|
|
8263
|
+
decisions: {
|
|
8264
|
+
create(input) {
|
|
8265
|
+
return decisionsClient.createJudgment(input);
|
|
8266
|
+
},
|
|
8267
|
+
record(input) {
|
|
8268
|
+
return decisionsClient.recordJudgment(input);
|
|
8269
|
+
},
|
|
8270
|
+
list(query5) {
|
|
8271
|
+
return decisionsClient.listJudgments(query5);
|
|
8272
|
+
},
|
|
8273
|
+
get(decisionId) {
|
|
8274
|
+
return decisionsClient.getJudgment(decisionId);
|
|
8275
|
+
},
|
|
8276
|
+
recordOutcome(decisionId, input) {
|
|
8277
|
+
return decisionsClient.recordJudgmentOutcome(decisionId, input);
|
|
8278
|
+
},
|
|
8279
|
+
lessons(decisionId, input, idempotencyKey) {
|
|
8280
|
+
return gateway.request({
|
|
8281
|
+
path: `/api/platform/v1/decisions/${encodeURIComponent(
|
|
8282
|
+
decisionId
|
|
8283
|
+
)}/lessons`,
|
|
8284
|
+
method: "POST",
|
|
8285
|
+
body: input,
|
|
8286
|
+
idempotencyKey: idempotencyKey ?? randomIdempotencyKey()
|
|
8287
|
+
}).then(exposeGatewayData);
|
|
8288
|
+
},
|
|
8289
|
+
archive(decisionId, input = {}, idempotencyKey) {
|
|
8290
|
+
return gateway.request({
|
|
8291
|
+
path: `/api/platform/v1/decisions/${encodeURIComponent(
|
|
8292
|
+
decisionId
|
|
8293
|
+
)}/archive`,
|
|
8294
|
+
method: "POST",
|
|
8295
|
+
body: input,
|
|
8296
|
+
idempotencyKey: idempotencyKey ?? randomIdempotencyKey()
|
|
8297
|
+
}).then(exposeGatewayData);
|
|
8298
|
+
},
|
|
8299
|
+
readiness(topicId) {
|
|
8300
|
+
return decisionsClient.getJudgmentReadiness({ topicId });
|
|
8301
|
+
},
|
|
8302
|
+
calibration(topicId) {
|
|
8303
|
+
return decisionsClient.getJudgmentCalibration({ topicId });
|
|
8304
|
+
},
|
|
8305
|
+
pendingOutcomeReview(topicId) {
|
|
8306
|
+
return decisionsClient.listPendingJudgmentOutcomeReview({ topicId });
|
|
8307
|
+
}
|
|
8308
|
+
},
|
|
8056
8309
|
worktrees: {
|
|
8057
8310
|
createBranch(input) {
|
|
8058
8311
|
return workflowClient.createBranch(input);
|
|
@@ -8075,7 +8328,21 @@ function createLucernClient(config = {}) {
|
|
|
8075
8328
|
topicId: requireTopicId4(input),
|
|
8076
8329
|
objective: input.objective,
|
|
8077
8330
|
hypothesis: input.hypothesis,
|
|
8331
|
+
rationale: input.rationale,
|
|
8332
|
+
worktreeType: input.worktreeType,
|
|
8333
|
+
startDate: input.startDate,
|
|
8334
|
+
endDate: input.endDate,
|
|
8335
|
+
durationWeeks: input.durationWeeks,
|
|
8336
|
+
confidenceImpact: input.confidenceImpact,
|
|
8337
|
+
beliefFocus: input.beliefFocus,
|
|
8078
8338
|
beliefIds: input.beliefIds,
|
|
8339
|
+
targetBeliefIds: input.targetBeliefIds,
|
|
8340
|
+
targetQuestionIds: input.targetQuestionIds,
|
|
8341
|
+
keyQuestions: input.keyQuestions,
|
|
8342
|
+
evidenceSignals: input.evidenceSignals,
|
|
8343
|
+
decisionGate: input.decisionGate,
|
|
8344
|
+
goCriteria: input.goCriteria,
|
|
8345
|
+
noGoSignals: input.noGoSignals,
|
|
8079
8346
|
autoShape: input.autoShape,
|
|
8080
8347
|
domainPackId: input.domainPackId,
|
|
8081
8348
|
campaign: input.campaign,
|
|
@@ -8088,7 +8355,8 @@ function createLucernClient(config = {}) {
|
|
|
8088
8355
|
proofArtifacts: input.proofArtifacts,
|
|
8089
8356
|
staffingHint: typeof input.staffingHint === "string" ? input.staffingHint : void 0,
|
|
8090
8357
|
lastReconciledAt: input.lastReconciledAt,
|
|
8091
|
-
autoFixPolicy: input.autoFixPolicy
|
|
8358
|
+
autoFixPolicy: input.autoFixPolicy,
|
|
8359
|
+
lensId: input.lensId
|
|
8092
8360
|
});
|
|
8093
8361
|
},
|
|
8094
8362
|
add(input) {
|
|
@@ -8097,7 +8365,21 @@ function createLucernClient(config = {}) {
|
|
|
8097
8365
|
topicId: requireTopicId4(input),
|
|
8098
8366
|
objective: input.objective,
|
|
8099
8367
|
hypothesis: input.hypothesis,
|
|
8368
|
+
rationale: input.rationale,
|
|
8369
|
+
worktreeType: input.worktreeType,
|
|
8370
|
+
startDate: input.startDate,
|
|
8371
|
+
endDate: input.endDate,
|
|
8372
|
+
durationWeeks: input.durationWeeks,
|
|
8373
|
+
confidenceImpact: input.confidenceImpact,
|
|
8374
|
+
beliefFocus: input.beliefFocus,
|
|
8100
8375
|
beliefIds: input.beliefIds,
|
|
8376
|
+
targetBeliefIds: input.targetBeliefIds,
|
|
8377
|
+
targetQuestionIds: input.targetQuestionIds,
|
|
8378
|
+
keyQuestions: input.keyQuestions,
|
|
8379
|
+
evidenceSignals: input.evidenceSignals,
|
|
8380
|
+
decisionGate: input.decisionGate,
|
|
8381
|
+
goCriteria: input.goCriteria,
|
|
8382
|
+
noGoSignals: input.noGoSignals,
|
|
8101
8383
|
autoShape: input.autoShape,
|
|
8102
8384
|
domainPackId: input.domainPackId,
|
|
8103
8385
|
campaign: input.campaign,
|
|
@@ -8110,7 +8392,8 @@ function createLucernClient(config = {}) {
|
|
|
8110
8392
|
proofArtifacts: input.proofArtifacts,
|
|
8111
8393
|
staffingHint: typeof input.staffingHint === "string" ? input.staffingHint : void 0,
|
|
8112
8394
|
lastReconciledAt: input.lastReconciledAt,
|
|
8113
|
-
autoFixPolicy: input.autoFixPolicy
|
|
8395
|
+
autoFixPolicy: input.autoFixPolicy,
|
|
8396
|
+
lensId: input.lensId
|
|
8114
8397
|
});
|
|
8115
8398
|
},
|
|
8116
8399
|
list(query5) {
|
|
@@ -8120,6 +8403,22 @@ function createLucernClient(config = {}) {
|
|
|
8120
8403
|
limit: query5.limit
|
|
8121
8404
|
});
|
|
8122
8405
|
},
|
|
8406
|
+
listByTopic(query5) {
|
|
8407
|
+
return worktreesFacade.list({
|
|
8408
|
+
topicId: requireTopicId4(query5),
|
|
8409
|
+
status: query5.status,
|
|
8410
|
+
limit: query5.limit
|
|
8411
|
+
});
|
|
8412
|
+
},
|
|
8413
|
+
findByPairedSprint(input) {
|
|
8414
|
+
return gateway.request({
|
|
8415
|
+
path: `/api/platform/v1/worktrees/paired-sprint${sdkQueryString({
|
|
8416
|
+
sprintId: input.sprintId,
|
|
8417
|
+
topicId: input.topicId ?? input.projectId,
|
|
8418
|
+
limit: input.limit
|
|
8419
|
+
})}`
|
|
8420
|
+
}).then(exposeGatewayData);
|
|
8421
|
+
},
|
|
8123
8422
|
activate(worktreeId) {
|
|
8124
8423
|
return worktreesFacade.activate({ id: worktreeId });
|
|
8125
8424
|
},
|
|
@@ -8271,6 +8570,31 @@ function createLucernClient(config = {}) {
|
|
|
8271
8570
|
status: typeof input.status === "string" ? input.status : void 0,
|
|
8272
8571
|
limit: typeof input.limit === "number" ? input.limit : void 0
|
|
8273
8572
|
});
|
|
8573
|
+
},
|
|
8574
|
+
listByTopic(input) {
|
|
8575
|
+
return tasksFacade.list({
|
|
8576
|
+
topicId: requireTopicId4(input),
|
|
8577
|
+
status: typeof input.status === "string" ? input.status : void 0,
|
|
8578
|
+
limit: typeof input.limit === "number" ? input.limit : void 0
|
|
8579
|
+
});
|
|
8580
|
+
},
|
|
8581
|
+
listByWorktree(input) {
|
|
8582
|
+
return tasksFacade.list({
|
|
8583
|
+
topicId: typeof input.topicId === "string" ? input.topicId : void 0,
|
|
8584
|
+
worktreeId: input.worktreeId,
|
|
8585
|
+
status: typeof input.status === "string" ? input.status : void 0,
|
|
8586
|
+
limit: typeof input.limit === "number" ? input.limit : void 0
|
|
8587
|
+
});
|
|
8588
|
+
},
|
|
8589
|
+
linkChat(taskId, input, idempotencyKey) {
|
|
8590
|
+
return gateway.request({
|
|
8591
|
+
path: `/api/platform/v1/tasks/${encodeURIComponent(
|
|
8592
|
+
taskId
|
|
8593
|
+
)}/link-chat`,
|
|
8594
|
+
method: "POST",
|
|
8595
|
+
body: input,
|
|
8596
|
+
idempotencyKey: idempotencyKey ?? randomIdempotencyKey()
|
|
8597
|
+
}).then(exposeGatewayData);
|
|
8274
8598
|
}
|
|
8275
8599
|
},
|
|
8276
8600
|
topics: {
|
|
@@ -8555,11 +8879,13 @@ function createLucernClient(config = {}) {
|
|
|
8555
8879
|
graphAnalysis: graphAnalysisClient,
|
|
8556
8880
|
graphRecommendations: graphRecommendationsClient,
|
|
8557
8881
|
orgGraphSearch: orgGraphSearchClient,
|
|
8558
|
-
ontologyLinks:
|
|
8882
|
+
ontologyLinks: ontologyLinksNamespace,
|
|
8559
8883
|
graphStateClassifier: graphStateClassifierClient,
|
|
8560
8884
|
modelRuntime: modelRuntimeClient,
|
|
8561
8885
|
jobs: jobsClient,
|
|
8562
8886
|
telemetry: telemetryClient,
|
|
8887
|
+
publication: publicationNamespace,
|
|
8888
|
+
contentPublication: publicationNamespace,
|
|
8563
8889
|
tools: {
|
|
8564
8890
|
listCatalog: toolRegistryClient.listCatalog,
|
|
8565
8891
|
listExecutable: toolRegistryClient.listExecutable,
|