@lucern/sdk 1.0.11 → 1.0.13
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/CHANGELOG.md +10 -0
- package/README.md +24 -27
- package/dist/.generated +2 -0
- package/dist/accessControl.d.ts +19 -26
- package/dist/accessControl.js +195 -1423
- package/dist/adminClient.d.ts +52 -59
- package/dist/adminClient.js +364 -1142
- package/dist/answersClient.d.ts +5 -14
- package/dist/answersClient.js +19 -737
- package/dist/audience/index.d.ts +18 -18
- package/dist/audience/index.js +87 -90
- package/dist/audiencesClient.d.ts +19 -27
- package/dist/audiencesClient.js +107 -868
- package/dist/auditClient.d.ts +8 -15
- package/dist/auditClient.js +18 -791
- package/dist/authContext.d.ts +11 -16
- package/dist/authContext.js +122 -154
- package/dist/authDeviceClient.d.ts +8 -17
- package/dist/authDeviceClient.js +113 -102
- package/dist/beliefs/index.d.ts +16 -67
- package/dist/beliefs/index.js +20 -10181
- package/dist/beliefs/lifecycle.d.ts +10 -11
- package/dist/beliefs/lifecycle.js +78 -80
- package/dist/beliefsClient.d.ts +30 -35
- package/dist/beliefsClient.js +238 -994
- package/dist/boundaryClientSurface.d.ts +11 -16
- package/dist/boundaryClientSurface.js +49 -68
- package/dist/client.d.ts +82 -113
- package/dist/client.js +232 -10155
- package/dist/clientAssemblyTypes.d.ts +3 -3
- package/dist/clientAssemblyTypes.js +1 -2
- package/dist/clientConfig.d.ts +45 -59
- package/dist/clientConfig.js +1 -2
- package/dist/clientEvidenceCompat.d.ts +24 -14
- package/dist/clientEvidenceCompat.js +56 -64
- package/dist/clientGraphNamespaces.d.ts +3 -5
- package/dist/clientGraphNamespaces.js +170 -245
- package/dist/clientHelpers.d.ts +20 -25
- package/dist/clientHelpers.js +104 -127
- package/dist/clientKnowledgeNamespaces.d.ts +24 -54
- package/dist/clientKnowledgeNamespaces.js +506 -506
- package/dist/clientLocalHelpers.d.ts +11 -56
- package/dist/clientLocalHelpers.js +503 -732
- package/dist/clientPlatformNamespaces.d.ts +5 -53
- package/dist/clientPlatformNamespaces.js +229 -323
- package/dist/clientRuntime.d.ts +5 -53
- package/dist/clientRuntime.js +26 -30
- package/dist/clientWorkflowNamespaces.d.ts +6 -15
- package/dist/clientWorkflowNamespaces.js +529 -596
- package/dist/contextClient.d.ts +9 -17
- package/dist/contextClient.js +92 -805
- package/dist/contextFacade.d.ts +11 -2
- package/dist/contextFacade.js +10 -81
- package/dist/contextPackCompiler.d.ts +10 -11
- package/dist/contextPackCompiler.js +494 -1040
- package/dist/contextPackPolicy.d.ts +14 -15
- package/dist/contextPackPolicy.js +227 -305
- package/dist/contextPackSchema.d.ts +3 -3
- package/dist/contextPackSchema.js +169 -176
- package/dist/contextTypes.d.ts +14 -15
- package/dist/contextTypes.js +1 -2
- package/dist/contracts/api-enums.contract.d.ts +29 -30
- package/dist/contracts/api-enums.contract.js +162 -88
- package/dist/contracts/auth-session.contract.d.ts +13 -14
- package/dist/contracts/auth-session.contract.js +55 -52
- package/dist/contracts/context-pack.contract.d.ts +54 -55
- package/dist/contracts/context-pack.contract.js +160 -88
- package/dist/contracts/contextPack.d.ts +2 -1
- package/dist/contracts/contextPack.js +1 -97
- package/dist/contracts/index.d.ts +11 -12
- package/dist/contracts/index.js +10 -854
- package/dist/contracts/lens-filter.contract.d.ts +9 -10
- package/dist/contracts/lens-filter.contract.js +82 -58
- package/dist/contracts/lens-workflow.contract.d.ts +21 -23
- package/dist/contracts/lens-workflow.contract.js +48 -117
- package/dist/contracts/lensFilter.d.ts +2 -1
- package/dist/contracts/lensFilter.js +1 -71
- package/dist/contracts/lensWorkflow.d.ts +2 -2
- package/dist/contracts/lensWorkflow.js +1 -123
- package/dist/contracts/mcpTools.d.ts +16 -18
- package/dist/contracts/mcpTools.js +89 -123
- package/dist/contracts/prompt.contract.d.ts +4 -5
- package/dist/contracts/prompt.contract.js +23 -10
- package/dist/contracts/prompt.d.ts +2 -1
- package/dist/contracts/prompt.js +1 -11
- package/dist/contracts/sdk-tools.contract.d.ts +2 -1
- package/dist/contracts/sdk-tools.contract.js +1 -2
- package/dist/contracts/sdkTools.d.ts +2 -1
- package/dist/contracts/sdkTools.js +1 -26
- package/dist/contracts/tool-contracts.d.ts +2 -1
- package/dist/contracts/tool-contracts.js +1 -2
- package/dist/contracts/workflow-runtime.contract.d.ts +45 -46
- package/dist/contracts/workflow-runtime.contract.js +241 -228
- package/dist/contracts/workflowRuntime.d.ts +2 -1
- package/dist/contracts/workflowRuntime.js +1 -244
- package/dist/contradictions/index.d.ts +8 -60
- package/dist/contradictions/index.js +11 -10175
- package/dist/control-plane.d.ts +17 -24
- package/dist/control-plane.js +124 -840
- package/dist/controlObjectOwnership.d.ts +19 -20
- package/dist/controlObjectOwnership.js +207 -201
- package/dist/coreClient.d.ts +23 -28
- package/dist/coreClient.js +567 -692
- package/dist/customTools.d.ts +17 -21
- package/dist/customTools.js +221 -221
- package/dist/decisions/index.d.ts +7 -58
- package/dist/decisions/index.js +14 -10177
- package/dist/decisionsClient.d.ts +25 -32
- package/dist/decisionsClient.js +113 -913
- package/dist/domainContext.d.ts +2 -1
- package/dist/domainContext.js +1 -2
- package/dist/edges/index.d.ts +21 -73
- package/dist/edges/index.js +12 -10176
- package/dist/embeddingsClient.d.ts +22 -30
- package/dist/embeddingsClient.js +73 -922
- package/dist/eventingClient.d.ts +23 -31
- package/dist/eventingClient.js +89 -918
- package/dist/events.d.ts +48 -49
- package/dist/events.js +257 -241
- package/dist/eventsCore.d.ts +20 -29
- package/dist/eventsCore.js +86 -830
- package/dist/evidence/index.d.ts +42 -61
- package/dist/evidence/index.js +13 -10176
- package/dist/evidenceClient.d.ts +13 -22
- package/dist/evidenceClient.js +34 -751
- package/dist/facade/context.d.ts +7 -8
- package/dist/facade/context.js +73 -72
- package/dist/functionSurface.d.ts +2 -156
- package/dist/functionSurface.js +1 -1460
- package/dist/functionSurfaceClient.d.ts +2 -9
- package/dist/functionSurfaceClient.js +1 -1460
- package/dist/gatewayFacades.d.ts +93 -296
- package/dist/gatewayFacades.factories.d.ts +209 -14
- package/dist/gatewayFacades.factories.js +545 -2228
- package/dist/gatewayFacades.js +284 -2627
- package/dist/generated/functionSurface.d.ts +149 -0
- package/dist/generated/functionSurface.js +749 -0
- package/dist/graphAnalysisClient.d.ts +41 -49
- package/dist/graphAnalysisClient.js +185 -974
- package/dist/graphClient.d.ts +53 -60
- package/dist/graphClient.js +219 -1090
- package/dist/graphIntel.d.ts +2 -4
- package/dist/graphIntel.js +1 -2
- package/dist/graphIntelligence.d.ts +4 -2
- package/dist/graphIntelligence.js +2 -46
- package/dist/graphRecommendationsClient.d.ts +15 -23
- package/dist/graphRecommendationsClient.js +70 -849
- package/dist/graphStateClassifierClient.d.ts +17 -25
- package/dist/graphStateClassifierClient.js +67 -908
- package/dist/harnessClient.d.ts +40 -47
- package/dist/harnessClient.js +198 -993
- package/dist/identityClient.d.ts +25 -33
- package/dist/identityClient.js +245 -1186
- package/dist/index.d.ts +73 -69
- package/dist/index.js +72 -13313
- package/dist/infisicalRuntime.d.ts +12 -14
- package/dist/infisicalRuntime.js +290 -297
- package/dist/jobsClient.d.ts +24 -32
- package/dist/jobsClient.js +101 -916
- package/dist/learningClient.d.ts +8 -16
- package/dist/learningClient.js +45 -809
- package/dist/lenses/index.d.ts +13 -65
- package/dist/lenses/index.js +11 -10175
- package/dist/mcpClient.d.ts +14 -23
- package/dist/mcpClient.js +115 -856
- package/dist/modelRuntimeClient.d.ts +18 -26
- package/dist/modelRuntimeClient.js +74 -894
- package/dist/nodes/index.d.ts +7 -58
- package/dist/nodes/index.js +14 -10177
- package/dist/ontologies/index.d.ts +21 -73
- package/dist/ontologies/index.js +14 -10178
- package/dist/ontologyClient.d.ts +23 -31
- package/dist/ontologyClient.js +138 -924
- package/dist/ontologyLinksClient.d.ts +16 -24
- package/dist/ontologyLinksClient.js +76 -886
- package/dist/opinion.d.ts +5 -6
- package/dist/opinion.js +21 -25
- package/dist/orgGraphSearchClient.d.ts +19 -27
- package/dist/orgGraphSearchClient.js +89 -857
- package/dist/packRuntime.d.ts +2 -2
- package/dist/packRuntime.js +1 -2
- package/dist/packsClient.d.ts +30 -37
- package/dist/packsClient.js +131 -906
- package/dist/policyClient.d.ts +21 -29
- package/dist/policyClient.js +267 -1026
- package/dist/proof-attestation.json +1 -1
- package/dist/questions/index.d.ts +9 -60
- package/dist/questions/index.js +15 -10178
- package/dist/realtime/index.d.ts +20 -16
- package/dist/realtime/index.js +30 -19
- package/dist/realtime/refs.d.ts +4 -6
- package/dist/realtime/refs.js +12 -7
- package/dist/realtime-refs.d.ts +1 -0
- package/dist/realtime-refs.js +1 -0
- package/dist/realtime.d.ts +1 -0
- package/dist/realtime.js +1 -0
- package/dist/reportsClient.d.ts +10 -19
- package/dist/reportsClient.js +48 -836
- package/dist/schemaClient.d.ts +16 -23
- package/dist/schemaClient.js +62 -832
- package/dist/sdkSurface.d.ts +18 -25
- package/dist/sdkSurface.js +135 -106
- package/dist/secrets.d.ts +2 -1
- package/dist/secrets.js +1 -2
- package/dist/sourcesClient.d.ts +11 -18
- package/dist/sourcesClient.js +18 -741
- package/dist/telemetryClient.d.ts +22 -30
- package/dist/telemetryClient.js +107 -931
- package/dist/toolRegistryClient.d.ts +27 -35
- package/dist/toolRegistryClient.js +116 -954
- package/dist/topics/index.d.ts +13 -64
- package/dist/topics/index.js +15 -10178
- package/dist/topicsClient.d.ts +19 -27
- package/dist/topicsClient.js +106 -894
- package/dist/types.d.ts +84 -87
- package/dist/types.js +1 -2
- package/dist/version.d.ts +2 -3
- package/dist/version.js +2 -5
- package/dist/workflowClient.d.ts +60 -65
- package/dist/workflowClient.js +343 -1219
- package/dist/worktrees/index.d.ts +16 -68
- package/dist/worktrees/index.js +14 -10178
- package/package.json +6 -6
- package/dist/accessControl.js.map +0 -1
- package/dist/adminClient.js.map +0 -1
- package/dist/answersClient.js.map +0 -1
- package/dist/audience/index.js.map +0 -1
- package/dist/audiencesClient.js.map +0 -1
- package/dist/auditClient.js.map +0 -1
- package/dist/authContext.js.map +0 -1
- package/dist/authDeviceClient.js.map +0 -1
- package/dist/beliefs/index.js.map +0 -1
- package/dist/beliefs/lifecycle.js.map +0 -1
- package/dist/beliefsClient.js.map +0 -1
- package/dist/boundaryClientSurface.js.map +0 -1
- package/dist/client.js.map +0 -1
- package/dist/clientAssemblyTypes.js.map +0 -1
- package/dist/clientConfig.js.map +0 -1
- package/dist/clientEvidenceCompat.js.map +0 -1
- package/dist/clientGraphNamespaces.js.map +0 -1
- package/dist/clientHelpers.js.map +0 -1
- package/dist/clientKnowledgeNamespaces.js.map +0 -1
- package/dist/clientLocalHelpers.js.map +0 -1
- package/dist/clientPlatformNamespaces.js.map +0 -1
- package/dist/clientRuntime.js.map +0 -1
- package/dist/clientWorkflowNamespaces.js.map +0 -1
- package/dist/contextClient.js.map +0 -1
- package/dist/contextFacade.js.map +0 -1
- package/dist/contextPackCompiler.js.map +0 -1
- package/dist/contextPackPolicy.js.map +0 -1
- package/dist/contextPackSchema.js.map +0 -1
- package/dist/contextTypes.js.map +0 -1
- package/dist/contracts/api-enums.contract.js.map +0 -1
- package/dist/contracts/auth-session.contract.js.map +0 -1
- package/dist/contracts/context-pack.contract.js.map +0 -1
- package/dist/contracts/contextPack.js.map +0 -1
- package/dist/contracts/index.js.map +0 -1
- package/dist/contracts/lens-filter.contract.js.map +0 -1
- package/dist/contracts/lens-workflow.contract.js.map +0 -1
- package/dist/contracts/lensFilter.js.map +0 -1
- package/dist/contracts/lensWorkflow.js.map +0 -1
- package/dist/contracts/mcpTools.js.map +0 -1
- package/dist/contracts/prompt.contract.js.map +0 -1
- package/dist/contracts/prompt.js.map +0 -1
- package/dist/contracts/sdk-tools.contract.js.map +0 -1
- package/dist/contracts/sdkTools.js.map +0 -1
- package/dist/contracts/tool-contracts.js.map +0 -1
- package/dist/contracts/workflow-runtime.contract.js.map +0 -1
- package/dist/contracts/workflowRuntime.js.map +0 -1
- package/dist/contradictions/index.js.map +0 -1
- package/dist/control-plane.js.map +0 -1
- package/dist/controlObjectOwnership.js.map +0 -1
- package/dist/coreClient.js.map +0 -1
- package/dist/customTools.js.map +0 -1
- package/dist/decisions/index.js.map +0 -1
- package/dist/decisionsClient.js.map +0 -1
- package/dist/domainContext.js.map +0 -1
- package/dist/edges/index.js.map +0 -1
- package/dist/embeddingsClient.js.map +0 -1
- package/dist/eventingClient.js.map +0 -1
- package/dist/events.js.map +0 -1
- package/dist/eventsCore.js.map +0 -1
- package/dist/evidence/index.js.map +0 -1
- package/dist/evidenceClient.js.map +0 -1
- package/dist/facade/context.js.map +0 -1
- package/dist/functionSurface.js.map +0 -1
- package/dist/functionSurfaceClient.js.map +0 -1
- package/dist/gatewayFacades.factories.js.map +0 -1
- package/dist/gatewayFacades.js.map +0 -1
- package/dist/graphAnalysisClient.js.map +0 -1
- package/dist/graphClient.js.map +0 -1
- package/dist/graphIntel.js.map +0 -1
- package/dist/graphIntelligence.js.map +0 -1
- package/dist/graphRecommendationsClient.js.map +0 -1
- package/dist/graphStateClassifierClient.js.map +0 -1
- package/dist/harnessClient.js.map +0 -1
- package/dist/identityClient.js.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/infisicalRuntime.js.map +0 -1
- package/dist/jobsClient.js.map +0 -1
- package/dist/learningClient.js.map +0 -1
- package/dist/lenses/index.js.map +0 -1
- package/dist/mcpClient.js.map +0 -1
- package/dist/modelRuntimeClient.js.map +0 -1
- package/dist/nodes/index.js.map +0 -1
- package/dist/ontologies/index.js.map +0 -1
- package/dist/ontologyClient.js.map +0 -1
- package/dist/ontologyLinksClient.js.map +0 -1
- package/dist/opinion.js.map +0 -1
- package/dist/orgGraphSearchClient.js.map +0 -1
- package/dist/packRuntime.js.map +0 -1
- package/dist/packsClient.js.map +0 -1
- package/dist/policyClient.js.map +0 -1
- package/dist/questions/index.js.map +0 -1
- package/dist/realtime/index.js.map +0 -1
- package/dist/realtime/refs.js.map +0 -1
- package/dist/reportsClient.js.map +0 -1
- package/dist/schemaClient.js.map +0 -1
- package/dist/sdk-tools.contract-B4c1Zr1o.d.ts +0 -22
- package/dist/sdkSurface.js.map +0 -1
- package/dist/secrets.js.map +0 -1
- package/dist/sourcesClient.js.map +0 -1
- package/dist/telemetryClient.js.map +0 -1
- package/dist/tool-contracts-BUiL9P6z.d.ts +0 -22
- package/dist/toolRegistryClient.js.map +0 -1
- package/dist/topics/index.js.map +0 -1
- package/dist/topicsClient.js.map +0 -1
- package/dist/types.js.map +0 -1
- package/dist/version.js.map +0 -1
- package/dist/workflowClient.js.map +0 -1
- package/dist/worktrees/index.js.map +0 -1
|
@@ -3,7 +3,7 @@ type AnyClient = Record<string, AnyFunction> & {
|
|
|
3
3
|
create: AnyFunction;
|
|
4
4
|
link: AnyFunction;
|
|
5
5
|
};
|
|
6
|
-
type ClientNamespaceContext = Record<string, any> & {
|
|
6
|
+
export type ClientNamespaceContext = Record<string, any> & {
|
|
7
7
|
exposeGatewayData: <T = unknown>(response: any) => any;
|
|
8
8
|
gateway: {
|
|
9
9
|
request: <T = unknown>(input: any) => Promise<any>;
|
|
@@ -29,5 +29,5 @@ type ClientNamespaceContext = Record<string, any> & {
|
|
|
29
29
|
publicationNamespace: Record<string, AnyFunction>;
|
|
30
30
|
nodesNamespace: Record<string, any>;
|
|
31
31
|
};
|
|
32
|
-
|
|
33
|
-
|
|
32
|
+
export {};
|
|
33
|
+
//# sourceMappingURL=clientAssemblyTypes.d.ts.map
|
package/dist/clientConfig.d.ts
CHANGED
|
@@ -1,57 +1,44 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import {
|
|
33
|
-
import {
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
36
|
-
|
|
37
|
-
import
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
import './contracts/lens-workflow.contract.js';
|
|
43
|
-
import './contracts/lens-filter.contract.js';
|
|
44
|
-
import './opinion.js';
|
|
45
|
-
import './contextTypes.js';
|
|
46
|
-
import './boundaryClientSurface.js';
|
|
47
|
-
import '@lucern/contracts';
|
|
48
|
-
|
|
49
|
-
type ClientConfig = BeliefsClientConfig | SourcesClientConfig | GraphClientConfig | DecisionsClientConfig | AnswersClientConfig | ContextClientConfig | WorkflowClientConfig | AuditClientConfig | AdminClientConfig | EvidenceClientConfig | EmbeddingsClientConfig | EventingClientConfig | GraphAnalysisClientConfig | GraphRecommendationsClientConfig | GraphStateClassifierClientConfig | IdentityClientConfig | JobsClientConfig | ModelRuntimeClientConfig | OntologyLinksClientConfig | OrgGraphSearchClientConfig | PolicyClientConfig | PacksClientConfig | ReportsClientConfig | LearningClientConfig | TelemetryClientConfig | ToolRegistryClientConfig | FunctionSurfaceClientConfig | ControlPlaneIdentityClientConfig | OntologyClientConfig | HarnessClientConfig | SchemaClientConfig | AudiencesClientConfig | TopicsClientConfig | GatewayClientConfig;
|
|
50
|
-
type CustomToolInput = CustomToolInput$1;
|
|
51
|
-
type CustomToolInvoker = (input?: CustomToolInput) => Promise<unknown>;
|
|
52
|
-
type CustomToolNamespace = Record<string, CustomToolInvoker>;
|
|
53
|
-
type GatewayDataEnvelope<T = unknown> = PlatformGatewaySuccess<T> & (T extends Record<string, unknown> ? T : Record<string, unknown>);
|
|
54
|
-
type BeliefsCompatCreateInput = {
|
|
1
|
+
import type { AdminClientConfig } from "./adminClient";
|
|
2
|
+
import type { AnswersClientConfig } from "./answersClient";
|
|
3
|
+
import type { AudiencesClientConfig } from "./audiencesClient";
|
|
4
|
+
import type { AuditClientConfig } from "./auditClient";
|
|
5
|
+
import type { BeliefsClientConfig, ModulateConfidenceInput } from "./beliefsClient";
|
|
6
|
+
import type { ContextClientConfig } from "./contextClient";
|
|
7
|
+
import type { ControlPlaneIdentityClientConfig } from "./control-plane";
|
|
8
|
+
import type { DecisionsClientConfig } from "./decisionsClient";
|
|
9
|
+
import type { EmbeddingsClientConfig } from "./embeddingsClient";
|
|
10
|
+
import type { EventingClientConfig } from "./eventingClient";
|
|
11
|
+
import type { EvidenceClientConfig } from "./evidenceClient";
|
|
12
|
+
import type { FunctionSurfaceClientConfig } from "./generated/functionSurface";
|
|
13
|
+
import type { GatewayClientConfig, PlatformGatewaySuccess } from "./coreClient";
|
|
14
|
+
import type { GraphAnalysisClientConfig } from "./graphAnalysisClient";
|
|
15
|
+
import type { GraphClientConfig } from "./graphClient";
|
|
16
|
+
import type { GraphRecommendationsClientConfig } from "./graphRecommendationsClient";
|
|
17
|
+
import type { GraphStateClassifierClientConfig } from "./graphStateClassifierClient";
|
|
18
|
+
import type { HarnessClientConfig } from "./harnessClient";
|
|
19
|
+
import type { IdentityClientConfig } from "./identityClient";
|
|
20
|
+
import type { JobsClientConfig } from "./jobsClient";
|
|
21
|
+
import type { LearningClientConfig } from "./learningClient";
|
|
22
|
+
import type { ModelRuntimeClientConfig } from "./modelRuntimeClient";
|
|
23
|
+
import type { OntologyClientConfig } from "./ontologyClient";
|
|
24
|
+
import type { OntologyLinksClientConfig } from "./ontologyLinksClient";
|
|
25
|
+
import type { OrgGraphSearchClientConfig } from "./orgGraphSearchClient";
|
|
26
|
+
import type { PacksClientConfig } from "./packsClient";
|
|
27
|
+
import type { PolicyClientConfig } from "./policyClient";
|
|
28
|
+
import type { ReportsClientConfig } from "./reportsClient";
|
|
29
|
+
import type { SchemaClientConfig } from "./schemaClient";
|
|
30
|
+
import type { SourcesClientConfig } from "./sourcesClient";
|
|
31
|
+
import type { TelemetryClientConfig } from "./telemetryClient";
|
|
32
|
+
import type { ToolRegistryClientConfig } from "./toolRegistryClient";
|
|
33
|
+
import type { TopicsClientConfig } from "./topicsClient";
|
|
34
|
+
import type { JsonObject } from "./types";
|
|
35
|
+
import type { WorkflowClientConfig } from "./workflowClient";
|
|
36
|
+
export type ClientConfig = BeliefsClientConfig | SourcesClientConfig | GraphClientConfig | DecisionsClientConfig | AnswersClientConfig | ContextClientConfig | WorkflowClientConfig | AuditClientConfig | AdminClientConfig | EvidenceClientConfig | EmbeddingsClientConfig | EventingClientConfig | GraphAnalysisClientConfig | GraphRecommendationsClientConfig | GraphStateClassifierClientConfig | IdentityClientConfig | JobsClientConfig | ModelRuntimeClientConfig | OntologyLinksClientConfig | OrgGraphSearchClientConfig | PolicyClientConfig | PacksClientConfig | ReportsClientConfig | LearningClientConfig | TelemetryClientConfig | ToolRegistryClientConfig | FunctionSurfaceClientConfig | ControlPlaneIdentityClientConfig | OntologyClientConfig | HarnessClientConfig | SchemaClientConfig | AudiencesClientConfig | TopicsClientConfig | GatewayClientConfig;
|
|
37
|
+
export type CustomToolInput = import("./clientHelpers").CustomToolInput;
|
|
38
|
+
export type CustomToolInvoker = (input?: CustomToolInput) => Promise<unknown>;
|
|
39
|
+
export type CustomToolNamespace = Record<string, CustomToolInvoker>;
|
|
40
|
+
export type GatewayDataEnvelope<T = unknown> = PlatformGatewaySuccess<T> & (T extends Record<string, unknown> ? T : Record<string, unknown>);
|
|
41
|
+
export type BeliefsCompatCreateInput = {
|
|
55
42
|
topicId?: string;
|
|
56
43
|
text?: string;
|
|
57
44
|
canonicalText?: string;
|
|
@@ -67,21 +54,21 @@ type BeliefsCompatCreateInput = {
|
|
|
67
54
|
predictionMeta?: JsonObject;
|
|
68
55
|
metadata?: JsonObject;
|
|
69
56
|
};
|
|
70
|
-
type BeliefsCompatForkInput = {
|
|
57
|
+
export type BeliefsCompatForkInput = {
|
|
71
58
|
text?: string;
|
|
72
59
|
newFormulation?: string;
|
|
73
60
|
formulation?: string;
|
|
74
61
|
forkReason?: "refinement" | "contradiction_response" | "scope_change" | "confidence_collapse" | "manual";
|
|
75
62
|
rationale?: string;
|
|
76
63
|
};
|
|
77
|
-
type BeliefsCompatUpdateConfidenceInput = ModulateConfidenceInput;
|
|
64
|
+
export type BeliefsCompatUpdateConfidenceInput = ModulateConfidenceInput;
|
|
78
65
|
/**
|
|
79
66
|
* Configuration for the high-level Lucern SDK client.
|
|
80
67
|
*
|
|
81
68
|
* At minimum, provide `apiKey` and `baseUrl`. The SDK handles
|
|
82
69
|
* authentication, retries, and idempotency automatically.
|
|
83
70
|
*/
|
|
84
|
-
type LucernClientConfig = ClientConfig & {
|
|
71
|
+
export type LucernClientConfig = ClientConfig & {
|
|
85
72
|
/** API key for authenticating with the Lucern platform. */
|
|
86
73
|
apiKey?: string;
|
|
87
74
|
/**
|
|
@@ -105,5 +92,4 @@ type LucernClientConfig = ClientConfig & {
|
|
|
105
92
|
/** Target environment. Defaults to production if not specified. */
|
|
106
93
|
environment?: "sandbox" | "production";
|
|
107
94
|
};
|
|
108
|
-
|
|
109
|
-
export type { BeliefsCompatCreateInput, BeliefsCompatForkInput, BeliefsCompatUpdateConfidenceInput, ClientConfig, CustomToolInput, CustomToolInvoker, CustomToolNamespace, GatewayDataEnvelope, LucernClientConfig };
|
|
95
|
+
//# sourceMappingURL=clientConfig.d.ts.map
|
package/dist/clientConfig.js
CHANGED
|
@@ -1,13 +1,6 @@
|
|
|
1
|
-
import { PlatformGatewaySuccess } from
|
|
2
|
-
import { JsonObject } from
|
|
3
|
-
|
|
4
|
-
import './authContext.js';
|
|
5
|
-
import './contracts/auth-session.contract.js';
|
|
6
|
-
import './contracts/workflow-runtime.contract.js';
|
|
7
|
-
import './contracts/lens-workflow.contract.js';
|
|
8
|
-
import './contracts/lens-filter.contract.js';
|
|
9
|
-
|
|
10
|
-
type EvidenceCompatInput = {
|
|
1
|
+
import type { PlatformGatewaySuccess } from "./coreClient";
|
|
2
|
+
import type { JsonObject } from "./types";
|
|
3
|
+
export type EvidenceCompatInput = {
|
|
11
4
|
text?: string;
|
|
12
5
|
canonicalText?: string;
|
|
13
6
|
topicId?: string;
|
|
@@ -15,6 +8,18 @@ type EvidenceCompatInput = {
|
|
|
15
8
|
sourceUrl?: string;
|
|
16
9
|
targetId?: string;
|
|
17
10
|
weight?: number;
|
|
11
|
+
evidenceRelation?: "supports" | "contradicts";
|
|
12
|
+
confidence?: number;
|
|
13
|
+
beliefRelations?: Array<{
|
|
14
|
+
beliefId?: string;
|
|
15
|
+
beliefNodeId?: string;
|
|
16
|
+
targetId?: string;
|
|
17
|
+
relation?: "supports" | "contradicts" | "supporting" | "contradicting";
|
|
18
|
+
evidenceRelation?: "supports" | "contradicts";
|
|
19
|
+
confidence?: number;
|
|
20
|
+
weight?: number;
|
|
21
|
+
rationale?: string;
|
|
22
|
+
}>;
|
|
18
23
|
metadata?: JsonObject;
|
|
19
24
|
title?: string;
|
|
20
25
|
content?: string;
|
|
@@ -34,6 +39,9 @@ type EvidenceFacadeLike = {
|
|
|
34
39
|
source?: string;
|
|
35
40
|
targetId?: string;
|
|
36
41
|
weight?: number;
|
|
42
|
+
evidenceRelation?: "supports" | "contradicts";
|
|
43
|
+
confidence?: number;
|
|
44
|
+
beliefRelations?: EvidenceCompatInput["beliefRelations"];
|
|
37
45
|
rationale: string;
|
|
38
46
|
metadata?: JsonObject;
|
|
39
47
|
title?: string;
|
|
@@ -45,12 +53,14 @@ type EvidenceFacadeLike = {
|
|
|
45
53
|
evidenceId: string;
|
|
46
54
|
targetId: string;
|
|
47
55
|
weight: number;
|
|
56
|
+
evidenceRelation?: "supports" | "contradicts";
|
|
57
|
+
confidence?: number;
|
|
48
58
|
rationale?: string;
|
|
49
59
|
}): Promise<PlatformGatewaySuccess<{
|
|
50
60
|
edgeId?: string;
|
|
51
61
|
}>>;
|
|
52
62
|
};
|
|
53
|
-
declare function createEvidenceCompat(evidenceFacade: EvidenceFacadeLike, args: EvidenceCompatInput): Promise<PlatformGatewaySuccess<Record<string, unknown>>>;
|
|
54
|
-
declare function addEvidenceCompat(evidenceFacade: EvidenceFacadeLike, args: EvidenceCompatInput): Promise<Record<string, unknown>>;
|
|
55
|
-
|
|
56
|
-
|
|
63
|
+
export declare function createEvidenceCompat(evidenceFacade: EvidenceFacadeLike, args: EvidenceCompatInput): Promise<PlatformGatewaySuccess<Record<string, unknown>>>;
|
|
64
|
+
export declare function addEvidenceCompat(evidenceFacade: EvidenceFacadeLike, args: EvidenceCompatInput): Promise<Record<string, unknown>>;
|
|
65
|
+
export {};
|
|
66
|
+
//# sourceMappingURL=clientEvidenceCompat.d.ts.map
|
|
@@ -1,67 +1,59 @@
|
|
|
1
|
-
|
|
2
|
-
function
|
|
3
|
-
|
|
1
|
+
import { resolveText, resolveTopicId } from "./sdkSurface.js";
|
|
2
|
+
export async function createEvidenceCompat(evidenceFacade, args) {
|
|
3
|
+
const text = resolveText(args);
|
|
4
|
+
if (!text) {
|
|
5
|
+
throw new Error("text is required");
|
|
6
|
+
}
|
|
7
|
+
const rationale = args.rationale ?? args.supports?.reasoning;
|
|
8
|
+
if (!rationale) {
|
|
9
|
+
throw new Error("rationale is required");
|
|
10
|
+
}
|
|
11
|
+
const metadata = {
|
|
12
|
+
...(args.metadata ?? {}),
|
|
13
|
+
rationale,
|
|
14
|
+
};
|
|
15
|
+
return evidenceFacade.create({
|
|
16
|
+
topicId: resolveTopicId(args),
|
|
17
|
+
text,
|
|
18
|
+
source: args.source ?? args.sourceUrl,
|
|
19
|
+
targetId: args.targetId ?? args.supports?.nodeId,
|
|
20
|
+
weight: args.weight ?? args.supports?.weight,
|
|
21
|
+
evidenceRelation: args.evidenceRelation,
|
|
22
|
+
confidence: args.confidence,
|
|
23
|
+
beliefRelations: args.beliefRelations,
|
|
24
|
+
rationale,
|
|
25
|
+
metadata: Object.keys(metadata).length > 0 ? metadata : undefined,
|
|
26
|
+
title: args.title,
|
|
27
|
+
content: args.content,
|
|
28
|
+
contentType: args.contentType,
|
|
29
|
+
kind: args.kind,
|
|
30
|
+
});
|
|
4
31
|
}
|
|
5
|
-
function
|
|
6
|
-
|
|
32
|
+
export async function addEvidenceCompat(evidenceFacade, args) {
|
|
33
|
+
const created = await createEvidenceCompat(evidenceFacade, {
|
|
34
|
+
...args,
|
|
35
|
+
targetId: args.supports ? undefined : args.targetId,
|
|
36
|
+
weight: args.supports ? undefined : args.weight,
|
|
37
|
+
});
|
|
38
|
+
if (!args.supports) {
|
|
39
|
+
return created.data;
|
|
40
|
+
}
|
|
41
|
+
const evidenceId = created.data.id;
|
|
42
|
+
if (typeof evidenceId !== "string" || evidenceId.length === 0) {
|
|
43
|
+
throw new Error("evidence create did not return an id");
|
|
44
|
+
}
|
|
45
|
+
const linked = await evidenceFacade.link({
|
|
46
|
+
evidenceId,
|
|
47
|
+
targetId: args.supports.nodeId,
|
|
48
|
+
weight: args.supports.weight,
|
|
49
|
+
evidenceRelation: args.evidenceRelation ??
|
|
50
|
+
(args.supports.weight < 0 ? "contradicts" : "supports"),
|
|
51
|
+
confidence: args.confidence ?? Math.min(1, Math.abs(args.supports.weight)),
|
|
52
|
+
rationale: args.supports.reasoning,
|
|
53
|
+
});
|
|
54
|
+
return {
|
|
55
|
+
...created.data,
|
|
56
|
+
edgeId: linked.data.edgeId,
|
|
57
|
+
};
|
|
7
58
|
}
|
|
8
|
-
function resolveText(value) {
|
|
9
|
-
return cleanString(value.text) ?? cleanString(value.canonicalText);
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
// src/clientEvidenceCompat.ts
|
|
13
|
-
async function createEvidenceCompat(evidenceFacade, args) {
|
|
14
|
-
const text = resolveText(args);
|
|
15
|
-
if (!text) {
|
|
16
|
-
throw new Error("text is required");
|
|
17
|
-
}
|
|
18
|
-
const rationale = args.rationale ?? args.supports?.reasoning;
|
|
19
|
-
if (!rationale) {
|
|
20
|
-
throw new Error("rationale is required");
|
|
21
|
-
}
|
|
22
|
-
const metadata = {
|
|
23
|
-
...args.metadata ?? {},
|
|
24
|
-
rationale
|
|
25
|
-
};
|
|
26
|
-
return evidenceFacade.create({
|
|
27
|
-
topicId: resolveTopicId(args),
|
|
28
|
-
text,
|
|
29
|
-
source: args.source ?? args.sourceUrl,
|
|
30
|
-
targetId: args.targetId ?? args.supports?.nodeId,
|
|
31
|
-
weight: args.weight ?? args.supports?.weight,
|
|
32
|
-
rationale,
|
|
33
|
-
metadata: Object.keys(metadata).length > 0 ? metadata : void 0,
|
|
34
|
-
title: args.title,
|
|
35
|
-
content: args.content,
|
|
36
|
-
contentType: args.contentType,
|
|
37
|
-
kind: args.kind
|
|
38
|
-
});
|
|
39
|
-
}
|
|
40
|
-
async function addEvidenceCompat(evidenceFacade, args) {
|
|
41
|
-
const created = await createEvidenceCompat(evidenceFacade, {
|
|
42
|
-
...args,
|
|
43
|
-
targetId: args.supports ? void 0 : args.targetId,
|
|
44
|
-
weight: args.supports ? void 0 : args.weight
|
|
45
|
-
});
|
|
46
|
-
if (!args.supports) {
|
|
47
|
-
return created.data;
|
|
48
|
-
}
|
|
49
|
-
const evidenceId = created.data.id;
|
|
50
|
-
if (typeof evidenceId !== "string" || evidenceId.length === 0) {
|
|
51
|
-
throw new Error("evidence create did not return an id");
|
|
52
|
-
}
|
|
53
|
-
const linked = await evidenceFacade.link({
|
|
54
|
-
evidenceId,
|
|
55
|
-
targetId: args.supports.nodeId,
|
|
56
|
-
weight: args.supports.weight,
|
|
57
|
-
rationale: args.supports.reasoning
|
|
58
|
-
});
|
|
59
|
-
return {
|
|
60
|
-
...created.data,
|
|
61
|
-
edgeId: linked.data.edgeId
|
|
62
|
-
};
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
export { addEvidenceCompat, createEvidenceCompat };
|
|
66
|
-
//# sourceMappingURL=clientEvidenceCompat.js.map
|
|
67
59
|
//# sourceMappingURL=clientEvidenceCompat.js.map
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import { ClientNamespaceContext } from
|
|
2
|
-
|
|
3
|
-
declare function createClientGraphNamespaces(ctx: ClientNamespaceContext): {
|
|
1
|
+
import type { ClientNamespaceContext } from "./clientAssemblyTypes";
|
|
2
|
+
export declare function createClientGraphNamespaces(ctx: ClientNamespaceContext): {
|
|
4
3
|
graph: {
|
|
5
4
|
nodes: Record<string, any>;
|
|
6
5
|
createEdge: (...args: any[]) => any;
|
|
@@ -86,5 +85,4 @@ declare function createClientGraphNamespaces(ctx: ClientNamespaceContext): {
|
|
|
86
85
|
}): Promise<any>;
|
|
87
86
|
};
|
|
88
87
|
};
|
|
89
|
-
|
|
90
|
-
export { createClientGraphNamespaces };
|
|
88
|
+
//# sourceMappingURL=clientGraphNamespaces.d.ts.map
|