@lucern/contracts 0.3.0-alpha.8 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/dist/api-enums.contract.d.ts +5 -3
- package/dist/api-enums.contract.js +14 -12
- package/dist/api-enums.contract.js.map +1 -1
- package/dist/auth-context.contract.js +14 -2
- package/dist/auth-context.contract.js.map +1 -1
- package/dist/auth-session.contract.js +14 -2
- package/dist/auth-session.contract.js.map +1 -1
- package/dist/auth.contract.d.ts +1 -1
- package/dist/auth.contract.js +14 -2
- package/dist/auth.contract.js.map +1 -1
- package/dist/component-boundary.contract.d.ts +1 -1
- package/dist/component-boundary.contract.js +46 -26
- package/dist/component-boundary.contract.js.map +1 -1
- package/dist/component-host-boundary.contract.d.ts +10 -5
- package/dist/component-host-boundary.contract.js +10 -4
- package/dist/component-host-boundary.contract.js.map +1 -1
- package/dist/{defineTable-CBQ03FXl.d.ts → defineTable-t1wr5wgn.d.ts} +1 -1
- package/dist/{dsl-djCRfuWC.d.ts → dsl-DVPthQGY.d.ts} +1 -1
- package/dist/dsl.d.ts +2 -2
- package/dist/dsl.js.map +1 -1
- package/dist/edge-policy-manifest-Dw5IhT1L.d.ts +133 -0
- package/dist/function-registry/beliefs.d.ts +23 -10
- package/dist/function-registry/beliefs.js +467 -36
- package/dist/function-registry/beliefs.js.map +1 -1
- package/dist/function-registry/coding.d.ts +15 -6
- package/dist/function-registry/coding.js +531 -22
- package/dist/function-registry/coding.js.map +1 -1
- package/dist/function-registry/context.d.ts +9 -3
- package/dist/function-registry/context.js +464 -21
- package/dist/function-registry/context.js.map +1 -1
- package/dist/function-registry/contracts.d.ts +9 -3
- package/dist/function-registry/contracts.js +464 -21
- package/dist/function-registry/contracts.js.map +1 -1
- package/dist/function-registry/coordination.d.ts +21 -9
- package/dist/function-registry/coordination.js +464 -21
- package/dist/function-registry/coordination.js.map +1 -1
- package/dist/function-registry/edges.d.ts +167 -2
- package/dist/function-registry/edges.js +661 -52
- package/dist/function-registry/edges.js.map +1 -1
- package/dist/function-registry/evidence.d.ts +19 -8
- package/dist/function-registry/evidence.js +473 -40
- package/dist/function-registry/evidence.js.map +1 -1
- package/dist/function-registry/graph.d.ts +33 -15
- package/dist/function-registry/graph.js +464 -21
- package/dist/function-registry/graph.js.map +1 -1
- package/dist/function-registry/helpers.d.ts +6 -3
- package/dist/function-registry/helpers.js +465 -22
- package/dist/function-registry/helpers.js.map +1 -1
- package/dist/function-registry/identity.d.ts +62 -16
- package/dist/function-registry/identity.js +487 -27
- package/dist/function-registry/identity.js.map +1 -1
- package/dist/function-registry/index.d.ts +4 -2
- package/dist/function-registry/index.js +468 -22
- package/dist/function-registry/index.js.map +1 -1
- package/dist/function-registry/judgments.d.ts +7 -2
- package/dist/function-registry/judgments.js +464 -21
- package/dist/function-registry/judgments.js.map +1 -1
- package/dist/function-registry/legacy.d.ts +5 -1
- package/dist/function-registry/legacy.js +464 -21
- package/dist/function-registry/legacy.js.map +1 -1
- package/dist/function-registry/lenses.d.ts +11 -4
- package/dist/function-registry/lenses.js +464 -21
- package/dist/function-registry/lenses.js.map +1 -1
- package/dist/function-registry/manifest.d.ts +4 -4
- package/dist/function-registry/manifest.js +16 -1
- package/dist/function-registry/manifest.js.map +1 -1
- package/dist/function-registry/nodes.d.ts +412 -0
- package/dist/function-registry/nodes.js +5354 -0
- package/dist/function-registry/nodes.js.map +1 -0
- package/dist/function-registry/ontologies.d.ts +25 -11
- package/dist/function-registry/ontologies.js +464 -21
- package/dist/function-registry/ontologies.js.map +1 -1
- package/dist/function-registry/pipeline.d.ts +9 -3
- package/dist/function-registry/pipeline.js +464 -21
- package/dist/function-registry/pipeline.js.map +1 -1
- package/dist/function-registry/questions.d.ts +27 -12
- package/dist/function-registry/questions.js +466 -26
- package/dist/function-registry/questions.js.map +1 -1
- package/dist/function-registry/tasks.d.ts +11 -4
- package/dist/function-registry/tasks.js +497 -30
- package/dist/function-registry/tasks.js.map +1 -1
- package/dist/function-registry/topics.d.ts +93 -5
- package/dist/function-registry/topics.js +534 -24
- package/dist/function-registry/topics.js.map +1 -1
- package/dist/function-registry/types.d.ts +7 -3
- package/dist/function-registry/worktrees.d.ts +25 -11
- package/dist/function-registry/worktrees.js +480 -21
- package/dist/function-registry/worktrees.js.map +1 -1
- package/dist/gateway.contract.d.ts +4 -0
- package/dist/gateway.contract.js.map +1 -1
- package/dist/generated/convexSchemas.d.ts +3 -3
- package/dist/generated/convexSchemas.js +37 -17
- package/dist/generated/convexSchemas.js.map +1 -1
- package/dist/generated/infisicalRuntimeEnv.d.ts +70 -0
- package/dist/generated/infisicalRuntimeEnv.js +27585 -0
- package/dist/generated/infisicalRuntimeEnv.js.map +1 -0
- package/dist/generated/lucernGatewayEnv.d.ts +17 -0
- package/dist/generated/lucernGatewayEnv.js +38 -0
- package/dist/generated/lucernGatewayEnv.js.map +1 -0
- package/dist/generated/lucernWebPublicEnv.d.ts +26 -0
- package/dist/generated/lucernWebPublicEnv.js +32 -0
- package/dist/generated/lucernWebPublicEnv.js.map +1 -0
- package/dist/generated/lucernWebServerEnv.d.ts +33 -0
- package/dist/generated/lucernWebServerEnv.js +51 -0
- package/dist/generated/lucernWebServerEnv.js.map +1 -0
- package/dist/generated/schema-manifest.json +1221 -114
- package/dist/generated/tableOwnership.d.ts +48 -28
- package/dist/generated/tableOwnership.js +66 -26
- package/dist/generated/tableOwnership.js.map +1 -1
- package/dist/generated/tier-expectations.json +64 -9
- package/dist/{index-O09U2xHk.d.ts → index-CM1Pl_vI.d.ts} +3 -3
- package/dist/index.d.ts +12 -7
- package/dist/index.js +32892 -459
- package/dist/index.js.map +1 -1
- package/dist/infisical-runtime.contract.d.ts +1763 -6
- package/dist/infisical-runtime.contract.js +2994 -15
- package/dist/infisical-runtime.contract.js.map +1 -1
- package/dist/manifests/edge-policy-manifest.d.ts +1 -1
- package/dist/manifests/edge-policy-manifest.data.d.ts +6 -20
- package/dist/manifests/edge-policy-manifest.data.js +18 -26
- package/dist/manifests/edge-policy-manifest.data.js.map +1 -1
- package/dist/manifests/edge-policy-manifest.js +31 -4
- package/dist/manifests/edge-policy-manifest.js.map +1 -1
- package/dist/manifests/infisical-runtime-manifest.d.ts +1689 -6
- package/dist/manifests/infisical-runtime-manifest.js +2847 -12
- package/dist/manifests/infisical-runtime-manifest.js.map +1 -1
- package/dist/manifests/tenant-client-manifest.d.ts +19 -14
- package/dist/manifests/tenant-client-manifest.js +29 -12
- package/dist/manifests/tenant-client-manifest.js.map +1 -1
- package/dist/mcp-gateway-boundary.contract.d.ts +23 -3
- package/dist/mcp-gateway-boundary.contract.js +2 -0
- package/dist/mcp-gateway-boundary.contract.js.map +1 -1
- package/dist/permit-principal-projection.contract.d.ts +74 -0
- package/dist/permit-principal-projection.contract.js +167 -0
- package/dist/permit-principal-projection.contract.js.map +1 -0
- package/dist/projections/check-convex-args-shape.js +10 -6
- package/dist/projections/check-convex-args-shape.js.map +1 -1
- package/dist/projections/create-evidence.projection.d.ts +6 -6
- package/dist/projections/create-evidence.projection.js +2 -3
- package/dist/projections/create-evidence.projection.js.map +1 -1
- package/dist/projections/index.d.ts +3 -3
- package/dist/projections/index.js +10 -6
- package/dist/projections/index.js.map +1 -1
- package/dist/projections/list-tasks.projection.d.ts +20 -8
- package/dist/projections/list-tasks.projection.js +8 -3
- package/dist/projections/list-tasks.projection.js.map +1 -1
- package/dist/proof-attestation.json +45 -0
- package/dist/schemas/component-table-manifest.d.ts +6 -6
- package/dist/schemas/component-table-manifest.js +2 -2
- package/dist/schemas/component-table-manifest.js.map +1 -1
- package/dist/schemas/index.d.ts +2 -2
- package/dist/schemas/index.js +1123 -137
- package/dist/schemas/index.js.map +1 -1
- package/dist/schemas/manifest.d.ts +2102 -132
- package/dist/schemas/manifest.js +1121 -135
- package/dist/schemas/manifest.js.map +1 -1
- package/dist/schemas/tables/controlPlane/accessControl.d.ts +260 -0
- package/dist/schemas/tables/controlPlane/accessControl.js +658 -0
- package/dist/schemas/tables/controlPlane/accessControl.js.map +1 -0
- package/dist/schemas/tables/{identity → controlPlane}/agent.d.ts +1 -1
- package/dist/schemas/tables/{identity → controlPlane}/agent.js +3 -3
- package/dist/schemas/tables/controlPlane/agent.js.map +1 -0
- package/dist/schemas/tables/{identity → controlPlane}/epistemic.d.ts +1 -1
- package/dist/schemas/tables/{identity → controlPlane}/epistemic.js +3 -3
- package/dist/schemas/tables/controlPlane/epistemic.js.map +1 -0
- package/dist/schemas/tables/{identity → controlPlane}/model.d.ts +1 -1
- package/dist/schemas/tables/{identity → controlPlane}/model.js +6 -6
- package/dist/schemas/tables/controlPlane/model.js.map +1 -0
- package/dist/schemas/tables/{identity → controlPlane}/platform.d.ts +1 -1
- package/dist/schemas/tables/{identity → controlPlane}/platform.js +18 -18
- package/dist/schemas/tables/controlPlane/platform.js.map +1 -0
- package/dist/schemas/tables/{identity → controlPlane}/project.d.ts +1 -1
- package/dist/schemas/tables/{identity → controlPlane}/project.js +3 -3
- package/dist/schemas/tables/controlPlane/project.js.map +1 -0
- package/dist/schemas/tables/{identity → controlPlane}/user.d.ts +1 -1
- package/dist/schemas/tables/{identity → controlPlane}/user.js +3 -3
- package/dist/schemas/tables/controlPlane/user.js.map +1 -0
- package/dist/schemas/tables/kernel/config.d.ts +1 -1
- package/dist/schemas/tables/kernel/config.js.map +1 -1
- package/dist/schemas/tables/kernel/coordination.d.ts +1 -1
- package/dist/schemas/tables/kernel/coordination.js.map +1 -1
- package/dist/schemas/tables/kernel/decision.d.ts +1 -1
- package/dist/schemas/tables/kernel/decision.js.map +1 -1
- package/dist/schemas/tables/kernel/embedding.d.ts +1 -1
- package/dist/schemas/tables/kernel/embedding.js.map +1 -1
- package/dist/schemas/tables/kernel/epistemic.d.ts +1 -1
- package/dist/schemas/tables/kernel/epistemic.js.map +1 -1
- package/dist/schemas/tables/kernel/events.d.ts +21 -0
- package/dist/schemas/tables/kernel/events.js +43 -0
- package/dist/schemas/tables/kernel/events.js.map +1 -0
- package/dist/schemas/tables/kernel/idempotency.d.ts +1 -1
- package/dist/schemas/tables/kernel/idempotency.js.map +1 -1
- package/dist/schemas/tables/kernel/infra.d.ts +1 -1
- package/dist/schemas/tables/kernel/infra.js.map +1 -1
- package/dist/schemas/tables/kernel/intelligence.d.ts +1 -1
- package/dist/schemas/tables/kernel/intelligence.js.map +1 -1
- package/dist/schemas/tables/kernel/lens.d.ts +1 -1
- package/dist/schemas/tables/kernel/lens.js.map +1 -1
- package/dist/schemas/tables/kernel/ontology.d.ts +1 -1
- package/dist/schemas/tables/kernel/ontology.js.map +1 -1
- package/dist/schemas/tables/kernel/platform.d.ts +1 -1
- package/dist/schemas/tables/kernel/platform.js.map +1 -1
- package/dist/schemas/tables/kernel/spine.d.ts +2 -1
- package/dist/schemas/tables/kernel/spine.js +1 -0
- package/dist/schemas/tables/kernel/spine.js.map +1 -1
- package/dist/schemas/tables/kernel/task.d.ts +1 -1
- package/dist/schemas/tables/kernel/task.js.map +1 -1
- package/dist/schemas/tables/kernel/topic.d.ts +1 -1
- package/dist/schemas/tables/kernel/topic.js +1 -0
- package/dist/schemas/tables/kernel/topic.js.map +1 -1
- package/dist/schemas/tables/kernel/workflow.d.ts +1 -1
- package/dist/schemas/tables/kernel/workflow.js.map +1 -1
- package/dist/schemas/tables/kernel/worktree.d.ts +17 -17
- package/dist/schemas/tables/kernel/worktree.js.map +1 -1
- package/dist/schemas/tables/mc/identity.d.ts +19 -2
- package/dist/schemas/tables/mc/identity.js +32 -1
- package/dist/schemas/tables/mc/identity.js.map +1 -1
- package/dist/schemas/tables/mc/methodology.d.ts +1 -1
- package/dist/schemas/tables/mc/methodology.js.map +1 -1
- package/dist/schemas/tables/mc/pack.d.ts +1 -1
- package/dist/schemas/tables/mc/pack.js.map +1 -1
- package/dist/schemas/tables/mc/policy.d.ts +2 -2
- package/dist/schemas/tables/mc/policy.js +1 -1
- package/dist/schemas/tables/mc/policy.js.map +1 -1
- package/dist/schemas/tables/mc/registry.d.ts +1 -1
- package/dist/schemas/tables/mc/registry.js.map +1 -1
- package/dist/schemas/tables/mc/runtime.d.ts +109 -3
- package/dist/schemas/tables/mc/runtime.js +330 -104
- package/dist/schemas/tables/mc/runtime.js.map +1 -1
- package/dist/schemas/tables/mc/tenant.d.ts +4 -2
- package/dist/schemas/tables/mc/tenant.js +3 -1
- package/dist/schemas/tables/mc/tenant.js.map +1 -1
- package/dist/schemas/tables/mc/workspace.d.ts +22 -5
- package/dist/schemas/tables/mc/workspace.js +34 -2
- package/dist/schemas/tables/mc/workspace.js.map +1 -1
- package/dist/{sdk-tools.contract-Ci8bkoai.d.ts → sdk-tools.contract-CKmSsrZ2.d.ts} +1 -1
- package/dist/sdk-tools.contract.d.ts +2 -2
- package/dist/sdk-tools.contract.js +417 -13
- package/dist/sdk-tools.contract.js.map +1 -1
- package/dist/tenant-bootstrap-seed.contract.d.ts +244 -56
- package/dist/tenant-bootstrap-seed.contract.js +139 -28
- package/dist/tenant-bootstrap-seed.contract.js.map +1 -1
- package/dist/tenant-bootstrap-seed.defaults.d.ts +2 -2
- package/dist/tenant-bootstrap-seed.defaults.js +31 -13
- package/dist/tenant-bootstrap-seed.defaults.js.map +1 -1
- package/dist/tenant-client.contract.d.ts +20 -15
- package/dist/tenant-client.contract.js +29 -12
- package/dist/tenant-client.contract.js.map +1 -1
- package/dist/{tool-contracts-B4iWhejG.d.ts → tool-contracts-C_xvM9q2.d.ts} +32 -2
- package/dist/tool-contracts.d.ts +1 -1
- package/dist/tool-contracts.js +418 -14
- package/dist/tool-contracts.js.map +1 -1
- package/package.json +22 -1
- package/dist/edge-policy-manifest-Byv6cQPP.d.ts +0 -132
- package/dist/schemas/tables/identity/agent.js.map +0 -1
- package/dist/schemas/tables/identity/epistemic.js.map +0 -1
- package/dist/schemas/tables/identity/model.js.map +0 -1
- package/dist/schemas/tables/identity/platform.js.map +0 -1
- package/dist/schemas/tables/identity/project.js.map +0 -1
- package/dist/schemas/tables/identity/user.js.map +0 -1
|
@@ -3,6 +3,20 @@ import { v } from 'convex/values';
|
|
|
3
3
|
|
|
4
4
|
// src/function-registry/beliefs.ts
|
|
5
5
|
|
|
6
|
+
// src/types/reasoning-method.ts
|
|
7
|
+
var REASONING_METHODS = [
|
|
8
|
+
"deductive",
|
|
9
|
+
"inductive",
|
|
10
|
+
"abductive",
|
|
11
|
+
"analogical",
|
|
12
|
+
"causal",
|
|
13
|
+
"correlational",
|
|
14
|
+
"testimonial",
|
|
15
|
+
"statistical",
|
|
16
|
+
"implicit",
|
|
17
|
+
"pattern_match"
|
|
18
|
+
];
|
|
19
|
+
|
|
6
20
|
// src/lens-workflow.contract.ts
|
|
7
21
|
var LENS_PERSPECTIVE_TYPES = [
|
|
8
22
|
"investigation",
|
|
@@ -834,19 +848,23 @@ var FIND_CONTRADICTIONS = {
|
|
|
834
848
|
};
|
|
835
849
|
var CREATE_EDGE = {
|
|
836
850
|
name: "create_edge",
|
|
837
|
-
description: "Commit a typed relationship between two nodes in the reasoning graph. Like `git commit` \u2014 an atomic write that declares a dependency between nodes.
|
|
851
|
+
description: "Commit a typed relationship between two nodes in the reasoning graph. Like `git commit` \u2014 an atomic write that declares a dependency between nodes. Accepts any public epistemic edge type between public graph node refs so agents can author the full spine.",
|
|
838
852
|
parameters: {
|
|
839
|
-
|
|
840
|
-
type: "
|
|
841
|
-
description: "Source
|
|
853
|
+
from: {
|
|
854
|
+
type: "object",
|
|
855
|
+
description: "Source graph ref, e.g. { kind: 'epistemic_node', nodeId: '...', nodeType: 'topic' }"
|
|
842
856
|
},
|
|
843
|
-
|
|
844
|
-
type: "
|
|
845
|
-
description: "Target
|
|
857
|
+
to: {
|
|
858
|
+
type: "object",
|
|
859
|
+
description: "Target graph ref, e.g. { kind: 'epistemic_node', nodeId: '...', nodeType: 'belief' }"
|
|
846
860
|
},
|
|
847
861
|
edgeType: {
|
|
848
862
|
type: "string",
|
|
849
|
-
description: "Relationship type
|
|
863
|
+
description: "Relationship type from the public epistemic edge enum."
|
|
864
|
+
},
|
|
865
|
+
globalId: {
|
|
866
|
+
type: "string",
|
|
867
|
+
description: "Optional idempotent edge global ID."
|
|
850
868
|
},
|
|
851
869
|
weight: {
|
|
852
870
|
type: "number",
|
|
@@ -856,10 +874,14 @@ var CREATE_EDGE = {
|
|
|
856
874
|
reasoningMethod: {
|
|
857
875
|
type: "string",
|
|
858
876
|
description: "How this was determined",
|
|
859
|
-
enum: [
|
|
877
|
+
enum: [...REASONING_METHODS]
|
|
878
|
+
},
|
|
879
|
+
metadata: {
|
|
880
|
+
type: "object",
|
|
881
|
+
description: "Optional edge metadata."
|
|
860
882
|
}
|
|
861
883
|
},
|
|
862
|
-
required: ["
|
|
884
|
+
required: ["from", "to", "edgeType"],
|
|
863
885
|
response: {
|
|
864
886
|
description: "The created edge",
|
|
865
887
|
fields: {
|
|
@@ -873,6 +895,240 @@ var CREATE_EDGE = {
|
|
|
873
895
|
ontologyPrimitive: "edge",
|
|
874
896
|
tier: "showcase"
|
|
875
897
|
};
|
|
898
|
+
var UPDATE_EDGE = {
|
|
899
|
+
name: "update_edge",
|
|
900
|
+
description: "Amend metadata on an existing graph edge. Like `git commit --amend` \u2014 changes the edge annotation without recreating the relationship.",
|
|
901
|
+
parameters: {
|
|
902
|
+
edgeId: { type: "string", description: "Edge ID or global ID to update" },
|
|
903
|
+
weight: { type: "number", description: "Updated edge weight" },
|
|
904
|
+
confidence: { type: "number", description: "Updated confidence" },
|
|
905
|
+
context: { type: "string", description: "Updated human-readable context" },
|
|
906
|
+
derivationType: { type: "string", description: "Updated derivation type" },
|
|
907
|
+
metadata: { type: "object", description: "Updated metadata" }
|
|
908
|
+
},
|
|
909
|
+
required: ["edgeId"],
|
|
910
|
+
response: {
|
|
911
|
+
description: "Edge update result",
|
|
912
|
+
fields: { success: "boolean" }
|
|
913
|
+
},
|
|
914
|
+
ownerModule: "graph-primitives",
|
|
915
|
+
ontologyPrimitive: "edge",
|
|
916
|
+
tier: "workhorse"
|
|
917
|
+
};
|
|
918
|
+
var REMOVE_EDGE = {
|
|
919
|
+
name: "remove_edge",
|
|
920
|
+
description: "Remove one graph edge by ID. Like `git rm` \u2014 deletes a single explicit relationship from the spine.",
|
|
921
|
+
parameters: {
|
|
922
|
+
edgeId: { type: "string", description: "Edge ID or global ID to remove" }
|
|
923
|
+
},
|
|
924
|
+
required: ["edgeId"],
|
|
925
|
+
response: {
|
|
926
|
+
description: "Edge removal result",
|
|
927
|
+
fields: { success: "boolean" }
|
|
928
|
+
},
|
|
929
|
+
ownerModule: "graph-primitives",
|
|
930
|
+
ontologyPrimitive: "edge",
|
|
931
|
+
tier: "workhorse"
|
|
932
|
+
};
|
|
933
|
+
var REMOVE_EDGES_BETWEEN = {
|
|
934
|
+
name: "remove_edges_between",
|
|
935
|
+
description: "Remove graph edges between two nodes. Like `git rm <pathspec>` \u2014 deletes relationships matching a source, target, and optional type.",
|
|
936
|
+
parameters: {
|
|
937
|
+
fromNodeId: { type: "string", description: "Source node ID or global ID" },
|
|
938
|
+
toNodeId: { type: "string", description: "Target node ID or global ID" },
|
|
939
|
+
edgeType: { type: "string", description: "Optional edge type filter" }
|
|
940
|
+
},
|
|
941
|
+
required: ["fromNodeId", "toNodeId"],
|
|
942
|
+
response: {
|
|
943
|
+
description: "Matched edge removal result",
|
|
944
|
+
fields: { deleted: "number" }
|
|
945
|
+
},
|
|
946
|
+
ownerModule: "graph-primitives",
|
|
947
|
+
ontologyPrimitive: "edge",
|
|
948
|
+
tier: "workhorse"
|
|
949
|
+
};
|
|
950
|
+
var BATCH_CREATE_EDGES = {
|
|
951
|
+
name: "batch_create_edges",
|
|
952
|
+
description: "Commit multiple typed graph edges. Like `git commit` with many staged paths \u2014 writes a batch of explicit relationships atomically per edge.",
|
|
953
|
+
parameters: {
|
|
954
|
+
edges: {
|
|
955
|
+
type: "array",
|
|
956
|
+
description: "Edges to create, each with from, to, edgeType, and optional weight/confidence/context."
|
|
957
|
+
},
|
|
958
|
+
skipLayerValidation: {
|
|
959
|
+
type: "boolean",
|
|
960
|
+
description: "Skip kernel layer validation for trusted materialization flows."
|
|
961
|
+
}
|
|
962
|
+
},
|
|
963
|
+
required: ["edges"],
|
|
964
|
+
response: {
|
|
965
|
+
description: "Batch edge creation result",
|
|
966
|
+
fields: {
|
|
967
|
+
created: "number",
|
|
968
|
+
results: "array",
|
|
969
|
+
errors: "array"
|
|
970
|
+
}
|
|
971
|
+
},
|
|
972
|
+
ownerModule: "graph-primitives",
|
|
973
|
+
ontologyPrimitive: "edge",
|
|
974
|
+
tier: "workhorse"
|
|
975
|
+
};
|
|
976
|
+
var CREATE_EPISTEMIC_NODE = {
|
|
977
|
+
name: "create_epistemic_node",
|
|
978
|
+
description: "Commit a generic epistemic graph node. Like `git commit` \u2014 creates a canonical node in the public spine for topics, beliefs, evidence, questions, answers, sources, and entities.",
|
|
979
|
+
parameters: {
|
|
980
|
+
globalId: { type: "string", description: "Optional idempotent node global ID" },
|
|
981
|
+
nodeType: { type: "string", description: "Public epistemic node type" },
|
|
982
|
+
canonicalText: { type: "string", description: "Canonical node text" },
|
|
983
|
+
text: { type: "string", description: "Alias for canonicalText" },
|
|
984
|
+
contentHash: { type: "string", description: "Optional idempotency content hash" },
|
|
985
|
+
sourceType: { type: "string", description: "Source type for provenance" },
|
|
986
|
+
topicId: { type: "string", description: "Optional topic scope" },
|
|
987
|
+
content: { type: "string", description: "Extended content" },
|
|
988
|
+
title: { type: "string", description: "Display title" },
|
|
989
|
+
metadata: { type: "object", description: "Optional node metadata" }
|
|
990
|
+
},
|
|
991
|
+
required: ["nodeType"],
|
|
992
|
+
response: {
|
|
993
|
+
description: "Created node result",
|
|
994
|
+
fields: {
|
|
995
|
+
nodeId: "string",
|
|
996
|
+
nodeGlobalId: "string",
|
|
997
|
+
isDuplicate: "boolean"
|
|
998
|
+
}
|
|
999
|
+
},
|
|
1000
|
+
ownerModule: "reasoning-kernel",
|
|
1001
|
+
ontologyPrimitive: "graph",
|
|
1002
|
+
tier: "showcase"
|
|
1003
|
+
};
|
|
1004
|
+
var GET_EPISTEMIC_NODE = {
|
|
1005
|
+
name: "get_epistemic_node",
|
|
1006
|
+
description: "Read one epistemic graph node. Like `git show` \u2014 resolves a canonical spine node by ID or global ID.",
|
|
1007
|
+
parameters: {
|
|
1008
|
+
nodeId: { type: "string", description: "Node ID or global ID" }
|
|
1009
|
+
},
|
|
1010
|
+
required: ["nodeId"],
|
|
1011
|
+
response: {
|
|
1012
|
+
description: "The resolved node",
|
|
1013
|
+
fields: { node: "object" }
|
|
1014
|
+
},
|
|
1015
|
+
ownerModule: "reasoning-kernel",
|
|
1016
|
+
ontologyPrimitive: "graph",
|
|
1017
|
+
tier: "workhorse"
|
|
1018
|
+
};
|
|
1019
|
+
var LIST_EPISTEMIC_NODES = {
|
|
1020
|
+
name: "list_epistemic_nodes",
|
|
1021
|
+
description: "List epistemic graph nodes. Like `git ls-tree` \u2014 lists canonical spine nodes by topic, type, status, or search query.",
|
|
1022
|
+
parameters: {
|
|
1023
|
+
topicId: { type: "string", description: "Optional topic scope" },
|
|
1024
|
+
nodeType: { type: "string", description: "Optional node type filter" },
|
|
1025
|
+
status: { type: "string", description: "Optional lifecycle status" },
|
|
1026
|
+
searchQuery: { type: "string", description: "Optional text search query" },
|
|
1027
|
+
limit: { type: "number", description: "Maximum nodes to return" }
|
|
1028
|
+
},
|
|
1029
|
+
required: [],
|
|
1030
|
+
response: {
|
|
1031
|
+
description: "Matching nodes",
|
|
1032
|
+
fields: { nodes: "array" }
|
|
1033
|
+
},
|
|
1034
|
+
ownerModule: "reasoning-kernel",
|
|
1035
|
+
ontologyPrimitive: "graph",
|
|
1036
|
+
tier: "workhorse"
|
|
1037
|
+
};
|
|
1038
|
+
var UPDATE_EPISTEMIC_NODE = {
|
|
1039
|
+
name: "update_epistemic_node",
|
|
1040
|
+
description: "Amend an epistemic graph node. Like `git commit --amend` \u2014 updates mutable node metadata, text, status, or verification fields.",
|
|
1041
|
+
parameters: {
|
|
1042
|
+
nodeId: { type: "string", description: "Node ID or global ID" },
|
|
1043
|
+
canonicalText: { type: "string", description: "Updated canonical text" },
|
|
1044
|
+
text: { type: "string", description: "Alias for canonicalText" },
|
|
1045
|
+
contentHash: { type: "string", description: "Updated content hash" },
|
|
1046
|
+
content: { type: "string", description: "Updated content" },
|
|
1047
|
+
title: { type: "string", description: "Updated display title" },
|
|
1048
|
+
metadata: { type: "object", description: "Updated metadata" },
|
|
1049
|
+
confidence: { type: "number", description: "Updated confidence" },
|
|
1050
|
+
verificationStatus: { type: "string", description: "Updated verification status" },
|
|
1051
|
+
status: { type: "string", description: "Updated lifecycle status" }
|
|
1052
|
+
},
|
|
1053
|
+
required: ["nodeId"],
|
|
1054
|
+
response: {
|
|
1055
|
+
description: "Node update result",
|
|
1056
|
+
fields: { success: "boolean" }
|
|
1057
|
+
},
|
|
1058
|
+
ownerModule: "reasoning-kernel",
|
|
1059
|
+
ontologyPrimitive: "graph",
|
|
1060
|
+
tier: "workhorse"
|
|
1061
|
+
};
|
|
1062
|
+
var ARCHIVE_EPISTEMIC_NODE = {
|
|
1063
|
+
name: "archive_epistemic_node",
|
|
1064
|
+
description: "Archive an epistemic graph node. Like `git rm --cached` \u2014 removes a node from active traversal without hard-deleting it.",
|
|
1065
|
+
parameters: {
|
|
1066
|
+
nodeId: { type: "string", description: "Node ID or global ID" }
|
|
1067
|
+
},
|
|
1068
|
+
required: ["nodeId"],
|
|
1069
|
+
response: {
|
|
1070
|
+
description: "Archive result",
|
|
1071
|
+
fields: { success: "boolean", effectiveStatus: "string" }
|
|
1072
|
+
},
|
|
1073
|
+
ownerModule: "reasoning-kernel",
|
|
1074
|
+
ontologyPrimitive: "graph",
|
|
1075
|
+
tier: "workhorse"
|
|
1076
|
+
};
|
|
1077
|
+
var VERIFY_EPISTEMIC_NODE = {
|
|
1078
|
+
name: "verify_epistemic_node",
|
|
1079
|
+
description: "Record verification state on an epistemic graph node. Like `git tag` \u2014 marks the node with a reviewed verification state.",
|
|
1080
|
+
parameters: {
|
|
1081
|
+
nodeId: { type: "string", description: "Node ID or global ID" },
|
|
1082
|
+
verificationStatus: { type: "string", description: "Verification status" },
|
|
1083
|
+
confidence: { type: "number", description: "Optional confidence update" }
|
|
1084
|
+
},
|
|
1085
|
+
required: ["nodeId", "verificationStatus"],
|
|
1086
|
+
response: {
|
|
1087
|
+
description: "Verification result",
|
|
1088
|
+
fields: { success: "boolean" }
|
|
1089
|
+
},
|
|
1090
|
+
ownerModule: "reasoning-kernel",
|
|
1091
|
+
ontologyPrimitive: "graph",
|
|
1092
|
+
tier: "workhorse"
|
|
1093
|
+
};
|
|
1094
|
+
var SUPERSEDE_EPISTEMIC_NODE = {
|
|
1095
|
+
name: "supersede_epistemic_node",
|
|
1096
|
+
description: "Supersede an epistemic graph node with a new version. Like `git commit --amend` on an immutable history branch \u2014 creates the replacement and marks the old node superseded.",
|
|
1097
|
+
parameters: {
|
|
1098
|
+
oldNodeId: { type: "string", description: "Node ID or global ID to supersede" },
|
|
1099
|
+
newGlobalId: { type: "string", description: "Optional replacement global ID" },
|
|
1100
|
+
newCanonicalText: { type: "string", description: "Replacement canonical text" },
|
|
1101
|
+
text: { type: "string", description: "Alias for newCanonicalText" },
|
|
1102
|
+
newContentHash: { type: "string", description: "Optional replacement content hash" },
|
|
1103
|
+
reason: { type: "string", description: "Reason for superseding" }
|
|
1104
|
+
},
|
|
1105
|
+
required: ["oldNodeId"],
|
|
1106
|
+
response: {
|
|
1107
|
+
description: "Supersede result",
|
|
1108
|
+
fields: { oldNodeId: "string", newNodeId: "string" }
|
|
1109
|
+
},
|
|
1110
|
+
ownerModule: "reasoning-kernel",
|
|
1111
|
+
ontologyPrimitive: "graph",
|
|
1112
|
+
tier: "workhorse"
|
|
1113
|
+
};
|
|
1114
|
+
var BATCH_CREATE_EPISTEMIC_NODES = {
|
|
1115
|
+
name: "batch_create_epistemic_nodes",
|
|
1116
|
+
description: "Commit multiple epistemic graph nodes. Like `git commit` with many staged files \u2014 writes a batch of canonical spine nodes.",
|
|
1117
|
+
parameters: {
|
|
1118
|
+
nodes: {
|
|
1119
|
+
type: "array",
|
|
1120
|
+
description: "Nodes to create with nodeType, canonicalText/text, and optional metadata."
|
|
1121
|
+
}
|
|
1122
|
+
},
|
|
1123
|
+
required: ["nodes"],
|
|
1124
|
+
response: {
|
|
1125
|
+
description: "Batch node creation result",
|
|
1126
|
+
fields: { created: "number", results: "array" }
|
|
1127
|
+
},
|
|
1128
|
+
ownerModule: "reasoning-kernel",
|
|
1129
|
+
ontologyPrimitive: "graph",
|
|
1130
|
+
tier: "workhorse"
|
|
1131
|
+
};
|
|
876
1132
|
var RECORD_JUDGMENT = {
|
|
877
1133
|
name: "record_judgment",
|
|
878
1134
|
description: "Record a judgment \u2014 an irreversible commitment based on the current epistemic state. Like a `git tag` marking a release. A judgment synthesizes beliefs, evidence, and uncertainties into a determination. Once issued, a judgment is evaluated against the epistemic state that existed when it was made (knowledge horizon evaluation, Invariant #10).",
|
|
@@ -2072,8 +2328,8 @@ var IDENTITY_WHOAMI = {
|
|
|
2072
2328
|
response: {
|
|
2073
2329
|
description: "Canonical identity summary for the current session",
|
|
2074
2330
|
fields: {
|
|
2075
|
-
principalId: "string \u2014 canonical
|
|
2076
|
-
principalType: "string \u2014 human, service, or
|
|
2331
|
+
principalId: "string \u2014 canonical principal identifier; for humans this is the Clerk user_... ID",
|
|
2332
|
+
principalType: "string \u2014 human, service, agent, group, or external_viewer",
|
|
2077
2333
|
tenantId: "string | undefined \u2014 resolved tenant scope",
|
|
2078
2334
|
workspaceId: "string | undefined \u2014 resolved workspace scope",
|
|
2079
2335
|
scopes: "string[] | undefined \u2014 granted scopes for this session",
|
|
@@ -2084,6 +2340,49 @@ var IDENTITY_WHOAMI = {
|
|
|
2084
2340
|
ontologyPrimitive: "identity",
|
|
2085
2341
|
tier: "workhorse"
|
|
2086
2342
|
};
|
|
2343
|
+
var RESOLVE_INTERACTIVE_PRINCIPAL = {
|
|
2344
|
+
name: "resolve_interactive_principal",
|
|
2345
|
+
description: "Read the Permit-backed Lucern principal context for an authenticated Clerk user. Like `git config --get user.email` plus the repository ACL \u2014 resolves the Clerk subject into tenant/workspace authorization context.",
|
|
2346
|
+
parameters: {
|
|
2347
|
+
clerkId: {
|
|
2348
|
+
type: "string",
|
|
2349
|
+
description: "Authenticated Clerk subject (`sub`). Clerk proves identity only; it is not the authorization record."
|
|
2350
|
+
},
|
|
2351
|
+
tenantId: {
|
|
2352
|
+
type: "string",
|
|
2353
|
+
description: "Optional tenant scope. Omit only when the Clerk alias is globally unambiguous."
|
|
2354
|
+
},
|
|
2355
|
+
workspaceId: {
|
|
2356
|
+
type: "string",
|
|
2357
|
+
description: "Optional workspace scope. Required when the principal has access to multiple workspaces and no default can be inferred."
|
|
2358
|
+
},
|
|
2359
|
+
providerProjectId: {
|
|
2360
|
+
type: "string",
|
|
2361
|
+
description: "Optional Clerk project or provider instance id for tenants with multiple identity providers."
|
|
2362
|
+
}
|
|
2363
|
+
},
|
|
2364
|
+
required: ["clerkId"],
|
|
2365
|
+
response: {
|
|
2366
|
+
description: "Permit-backed Lucern principal context for tenant SDK bootstrap",
|
|
2367
|
+
fields: {
|
|
2368
|
+
principalId: "string \u2014 canonical Clerk user_... ID for human sessions",
|
|
2369
|
+
principalType: "string \u2014 human, service, agent, group, or external_viewer",
|
|
2370
|
+
clerkId: "string \u2014 authenticated Clerk subject alias",
|
|
2371
|
+
tenantId: "string \u2014 resolved tenant scope",
|
|
2372
|
+
workspaceId: "string | null \u2014 resolved workspace scope",
|
|
2373
|
+
roles: "string[] \u2014 effective Permit roles",
|
|
2374
|
+
scopes: "string[] \u2014 effective scopes derived from Permit/control-plane projection",
|
|
2375
|
+
groupIds: "string[] \u2014 active Permit group memberships",
|
|
2376
|
+
principalStatus: "string \u2014 active, invited, suspended, disabled, revoked, or missing",
|
|
2377
|
+
tenantStatus: "string \u2014 projected tenant resource status",
|
|
2378
|
+
workspaceStatus: "string \u2014 projected workspace resource status",
|
|
2379
|
+
permit: "object \u2014 Permit subject, tenant, and optional workspace tuple"
|
|
2380
|
+
}
|
|
2381
|
+
},
|
|
2382
|
+
ownerModule: "control-plane",
|
|
2383
|
+
ontologyPrimitive: "identity",
|
|
2384
|
+
tier: "workhorse"
|
|
2385
|
+
};
|
|
2087
2386
|
var COMPILE_CONTEXT = {
|
|
2088
2387
|
name: "compile_context",
|
|
2089
2388
|
description: "Compile a focused reasoning context. If topicId is omitted, Lucern resolves the best topic from the query. Like `git log --graph --decorate` for the reasoning substrate \u2014 returns the canonical Pillar 3 context pack through the public API shape.",
|
|
@@ -2345,6 +2644,10 @@ var CREATE_TASK = {
|
|
|
2345
2644
|
tags: {
|
|
2346
2645
|
type: "array",
|
|
2347
2646
|
description: "Free-form string tags"
|
|
2647
|
+
},
|
|
2648
|
+
metadata: {
|
|
2649
|
+
type: "object",
|
|
2650
|
+
description: "Structured task metadata for handoff context and routing hints"
|
|
2348
2651
|
}
|
|
2349
2652
|
},
|
|
2350
2653
|
required: ["title"],
|
|
@@ -2418,6 +2721,10 @@ var UPDATE_TASK = {
|
|
|
2418
2721
|
type: "string",
|
|
2419
2722
|
description: "Updated status",
|
|
2420
2723
|
enum: ["todo", "in_progress", "blocked", "done"]
|
|
2724
|
+
},
|
|
2725
|
+
metadata: {
|
|
2726
|
+
type: "object",
|
|
2727
|
+
description: "Structured task metadata to replace or refine"
|
|
2421
2728
|
}
|
|
2422
2729
|
},
|
|
2423
2730
|
required: ["taskId"],
|
|
@@ -2465,6 +2772,10 @@ var CREATE_TOPIC = {
|
|
|
2465
2772
|
name: "create_topic",
|
|
2466
2773
|
description: "Create a new topic container for scoping knowledge. Like `git init` \u2014 initializes a new repository for a knowledge domain. Topics are hierarchical: a deal topic can nest under a theme topic. Types: domain, theme, deal, strategy, constitution, project, portfolio.",
|
|
2467
2774
|
parameters: {
|
|
2775
|
+
globalId: {
|
|
2776
|
+
type: "string",
|
|
2777
|
+
description: "Optional idempotent topic global ID"
|
|
2778
|
+
},
|
|
2468
2779
|
name: { type: "string", description: "Topic name" },
|
|
2469
2780
|
type: {
|
|
2470
2781
|
type: "string",
|
|
@@ -2475,6 +2786,18 @@ var CREATE_TOPIC = {
|
|
|
2475
2786
|
type: "string",
|
|
2476
2787
|
description: "Optional parent topic for nesting"
|
|
2477
2788
|
},
|
|
2789
|
+
parentTopicGlobalId: {
|
|
2790
|
+
type: "string",
|
|
2791
|
+
description: "Optional parent topic global ID for nesting"
|
|
2792
|
+
},
|
|
2793
|
+
tenantId: { type: "string", description: "Optional tenant scope" },
|
|
2794
|
+
workspaceId: { type: "string", description: "Optional workspace scope" },
|
|
2795
|
+
visibility: {
|
|
2796
|
+
type: "string",
|
|
2797
|
+
description: "Topic visibility",
|
|
2798
|
+
enum: ["private", "team", "firm", "external", "public"]
|
|
2799
|
+
},
|
|
2800
|
+
metadata: { type: "object", description: "Optional topic metadata" },
|
|
2478
2801
|
createdBy: { type: "string", description: "Who created this topic" }
|
|
2479
2802
|
},
|
|
2480
2803
|
required: ["name", "type"],
|
|
@@ -2483,6 +2806,9 @@ var CREATE_TOPIC = {
|
|
|
2483
2806
|
fields: {
|
|
2484
2807
|
id: "string \u2014 topic ID",
|
|
2485
2808
|
globalId: "string \u2014 globally unique ID",
|
|
2809
|
+
topicGlobalId: "string \u2014 topic global ID",
|
|
2810
|
+
epistemicNodeId: "string \u2014 materialized topic node ID",
|
|
2811
|
+
epistemicNodeGlobalId: "string \u2014 materialized topic node global ID",
|
|
2486
2812
|
depth: "number \u2014 nesting depth"
|
|
2487
2813
|
}
|
|
2488
2814
|
},
|
|
@@ -2613,6 +2939,65 @@ var GET_TOPIC_TREE = {
|
|
|
2613
2939
|
ontologyPrimitive: "graph",
|
|
2614
2940
|
tier: "workhorse"
|
|
2615
2941
|
};
|
|
2942
|
+
var MATERIALIZE_TOPIC_GRAPH = {
|
|
2943
|
+
name: "materialize_topic_graph",
|
|
2944
|
+
description: "Backfill the topic graph spine. Like `git fsck --connectivity-only` with repair enabled \u2014 creates missing topic nodes and parent-child edges idempotently.",
|
|
2945
|
+
parameters: {
|
|
2946
|
+
rootTopicId: {
|
|
2947
|
+
type: "string",
|
|
2948
|
+
description: "Optional root topic for a bounded materialization pass"
|
|
2949
|
+
},
|
|
2950
|
+
dryRun: {
|
|
2951
|
+
type: "boolean",
|
|
2952
|
+
description: "When true, report missing rows without writing them"
|
|
2953
|
+
}
|
|
2954
|
+
},
|
|
2955
|
+
required: [],
|
|
2956
|
+
response: {
|
|
2957
|
+
description: "Topic graph materialization counts",
|
|
2958
|
+
fields: {
|
|
2959
|
+
topicsSeen: "number",
|
|
2960
|
+
nodesCreated: "number",
|
|
2961
|
+
nodesExisting: "number",
|
|
2962
|
+
edgesCreated: "number",
|
|
2963
|
+
edgesExisting: "number",
|
|
2964
|
+
errors: "array"
|
|
2965
|
+
}
|
|
2966
|
+
},
|
|
2967
|
+
ownerModule: "reasoning-kernel",
|
|
2968
|
+
ontologyPrimitive: "graph",
|
|
2969
|
+
tier: "workhorse"
|
|
2970
|
+
};
|
|
2971
|
+
var GET_TOPIC_GRAPH_SPINE = {
|
|
2972
|
+
name: "get_topic_graph_spine",
|
|
2973
|
+
description: "Verify the topic graph spine. Like `git fsck` \u2014 reads topics, materialized topic nodes, parent-child edges, and missing spine rows.",
|
|
2974
|
+
parameters: {
|
|
2975
|
+
rootTopicId: {
|
|
2976
|
+
type: "string",
|
|
2977
|
+
description: "Optional root topic for a bounded verifier pass"
|
|
2978
|
+
},
|
|
2979
|
+
includeTopicBeliefEdges: {
|
|
2980
|
+
type: "boolean",
|
|
2981
|
+
description: "Include topic -> belief edges in the verifier payload"
|
|
2982
|
+
}
|
|
2983
|
+
},
|
|
2984
|
+
required: [],
|
|
2985
|
+
response: {
|
|
2986
|
+
description: "Topic graph spine verification payload",
|
|
2987
|
+
fields: {
|
|
2988
|
+
ok: "boolean",
|
|
2989
|
+
counts: "object",
|
|
2990
|
+
topics: "array",
|
|
2991
|
+
topicNodes: "array",
|
|
2992
|
+
parentEdges: "array",
|
|
2993
|
+
missingTopicNodes: "array",
|
|
2994
|
+
missingParentEdges: "array"
|
|
2995
|
+
}
|
|
2996
|
+
},
|
|
2997
|
+
ownerModule: "reasoning-kernel",
|
|
2998
|
+
ontologyPrimitive: "graph",
|
|
2999
|
+
tier: "workhorse"
|
|
3000
|
+
};
|
|
2616
3001
|
var GET_CODE_CONTEXT = {
|
|
2617
3002
|
name: "get_code_context",
|
|
2618
3003
|
description: "Returns code-grounded beliefs, contracts, migration states, and failed attempts anchored to a specific file or function path. Like `git log -- <path>` \u2014 filters the knowledge graph to nodes anchored to a file path via metadata.codeAnchors. Results are separated by coding belief type: decisions, contracts, migrations, patterns, deprecations, and failures.",
|
|
@@ -2808,7 +3193,7 @@ var MANAGE_WRITE_POLICY = {
|
|
|
2808
3193
|
},
|
|
2809
3194
|
role: {
|
|
2810
3195
|
type: "string",
|
|
2811
|
-
description: "Role to set policy for (required for 'set'). E.g. 'agent:internal'
|
|
3196
|
+
description: "Role to set policy for (required for 'set'). E.g. 'agent:internal' or a Permit role key such as 'workspace_admin'."
|
|
2812
3197
|
},
|
|
2813
3198
|
permission: {
|
|
2814
3199
|
type: "string",
|
|
@@ -3795,6 +4180,9 @@ var BEGIN_BUILD_SESSION = {
|
|
|
3795
4180
|
sessionMode: "string \u2014 async | interactive",
|
|
3796
4181
|
targetBeliefIds: "array \u2014 scoped belief IDs",
|
|
3797
4182
|
targetQuestionIds: "array \u2014 scoped question IDs",
|
|
4183
|
+
taskIds: "array \u2014 assigned task IDs for this worktree",
|
|
4184
|
+
incompleteTaskIds: "array \u2014 assigned task IDs that still require done/deferred/blocked proof",
|
|
4185
|
+
tasks: "array \u2014 assigned task packet with id, title, status, priority, links, and summaries",
|
|
3798
4186
|
topBeliefs: "array \u2014 highest-confidence scoped beliefs",
|
|
3799
4187
|
openQuestions: "array \u2014 open scoped questions",
|
|
3800
4188
|
resolvedDecisions: "array \u2014 answered questions summarized for the session",
|
|
@@ -3850,6 +4238,19 @@ var MCP_TOOL_CONTRACTS = {
|
|
|
3850
4238
|
bisect_confidence: BISECT_CONFIDENCE,
|
|
3851
4239
|
// Edges (commit)
|
|
3852
4240
|
create_edge: CREATE_EDGE,
|
|
4241
|
+
update_edge: UPDATE_EDGE,
|
|
4242
|
+
remove_edge: REMOVE_EDGE,
|
|
4243
|
+
remove_edges_between: REMOVE_EDGES_BETWEEN,
|
|
4244
|
+
batch_create_edges: BATCH_CREATE_EDGES,
|
|
4245
|
+
// Epistemic node spine (commit/amend/show)
|
|
4246
|
+
create_epistemic_node: CREATE_EPISTEMIC_NODE,
|
|
4247
|
+
get_epistemic_node: GET_EPISTEMIC_NODE,
|
|
4248
|
+
list_epistemic_nodes: LIST_EPISTEMIC_NODES,
|
|
4249
|
+
update_epistemic_node: UPDATE_EPISTEMIC_NODE,
|
|
4250
|
+
archive_epistemic_node: ARCHIVE_EPISTEMIC_NODE,
|
|
4251
|
+
verify_epistemic_node: VERIFY_EPISTEMIC_NODE,
|
|
4252
|
+
supersede_epistemic_node: SUPERSEDE_EPISTEMIC_NODE,
|
|
4253
|
+
batch_create_epistemic_nodes: BATCH_CREATE_EPISTEMIC_NODES,
|
|
3853
4254
|
// Judgments (tag)
|
|
3854
4255
|
record_judgment: RECORD_JUDGMENT,
|
|
3855
4256
|
// Graph intelligence (showcase)
|
|
@@ -3884,6 +4285,7 @@ var MCP_TOOL_CONTRACTS = {
|
|
|
3884
4285
|
update_worktree_targets: UPDATE_WORKTREE_TARGETS,
|
|
3885
4286
|
update_worktree_metadata: UPDATE_WORKTREE_METADATA,
|
|
3886
4287
|
identity_whoami: IDENTITY_WHOAMI,
|
|
4288
|
+
resolve_interactive_principal: RESOLVE_INTERACTIVE_PRINCIPAL,
|
|
3887
4289
|
compile_context: COMPILE_CONTEXT,
|
|
3888
4290
|
record_scope_learning: RECORD_SCOPE_LEARNING,
|
|
3889
4291
|
pipeline_snapshot: PIPELINE_SNAPSHOT,
|
|
@@ -3923,6 +4325,8 @@ var MCP_TOOL_CONTRACTS = {
|
|
|
3923
4325
|
get_topic: GET_TOPIC,
|
|
3924
4326
|
update_topic: UPDATE_TOPIC,
|
|
3925
4327
|
get_topic_tree: GET_TOPIC_TREE,
|
|
4328
|
+
materialize_topic_graph: MATERIALIZE_TOPIC_GRAPH,
|
|
4329
|
+
get_topic_graph_spine: GET_TOPIC_GRAPH_SPINE,
|
|
3926
4330
|
// Coding intelligence (code-grounded knowledge)
|
|
3927
4331
|
get_code_context: GET_CODE_CONTEXT,
|
|
3928
4332
|
get_change_history: GET_CHANGE_HISTORY,
|
|
@@ -3999,6 +4403,7 @@ function entries(names, surfaceClass, surfaceIntent, surfaces, rationale) {
|
|
|
3999
4403
|
var MCP_CORE_OPERATION_NAMES = [
|
|
4000
4404
|
"compile_context",
|
|
4001
4405
|
"identity_whoami",
|
|
4406
|
+
"resolve_interactive_principal",
|
|
4002
4407
|
"check_permission",
|
|
4003
4408
|
"filter_by_permission",
|
|
4004
4409
|
"create_belief",
|
|
@@ -4027,14 +4432,28 @@ var MCP_CORE_OPERATION_NAMES = [
|
|
|
4027
4432
|
"find_missing_questions",
|
|
4028
4433
|
"get_high_priority_questions",
|
|
4029
4434
|
"get_falsification_questions",
|
|
4435
|
+
"create_epistemic_node",
|
|
4436
|
+
"get_epistemic_node",
|
|
4437
|
+
"list_epistemic_nodes",
|
|
4438
|
+
"update_epistemic_node",
|
|
4439
|
+
"archive_epistemic_node",
|
|
4440
|
+
"verify_epistemic_node",
|
|
4441
|
+
"supersede_epistemic_node",
|
|
4442
|
+
"batch_create_epistemic_nodes",
|
|
4030
4443
|
"create_topic",
|
|
4031
4444
|
"get_topic",
|
|
4032
4445
|
"list_topics",
|
|
4033
4446
|
"update_topic",
|
|
4034
|
-
"get_topic_tree"
|
|
4447
|
+
"get_topic_tree",
|
|
4448
|
+
"materialize_topic_graph",
|
|
4449
|
+
"get_topic_graph_spine"
|
|
4035
4450
|
];
|
|
4036
4451
|
var MCP_ANALYSIS_PLATFORM_OPERATION_NAMES = [
|
|
4037
4452
|
"create_edge",
|
|
4453
|
+
"update_edge",
|
|
4454
|
+
"remove_edge",
|
|
4455
|
+
"remove_edges_between",
|
|
4456
|
+
"batch_create_edges",
|
|
4038
4457
|
"query_lineage",
|
|
4039
4458
|
"traverse_graph",
|
|
4040
4459
|
"get_graph_neighborhood",
|
|
@@ -4270,6 +4689,13 @@ var LUCERN_OPERATION_MANIFEST = {
|
|
|
4270
4689
|
"Lucern MCP-only platform operation for local agent/bootstrap or verification workflows. Hidden from public discovery."
|
|
4271
4690
|
)
|
|
4272
4691
|
};
|
|
4692
|
+
z.enum(["decision", "belief", "question", "theme", "deal", "topic", "claim", "evidence", "synthesis", "answer", "atomic_fact", "excerpt", "source", "company", "person", "investor", "function", "value_chain"]);
|
|
4693
|
+
var EDGE_TYPE_VALUES = ["supports", "informs", "depends_on", "derived_from", "contains", "tests", "supersedes", "responds_to", "belongs_to", "relates_to_thesis", "works_at", "invested_in", "competes_with", "participates_in", "founded_by", "evaluates", "performs", "function_in", "impacts", "raised_from", "mentioned_in", "perspective_on", "plays_theme", "answers", "explores", "qualifies", "based_on", "based_on_belief", "based_on_question", "blocked_by_contradiction", "informed_by_theme", "same_as", "reinforces", "parent_of", "child_of", "falsified_by", "exclusive_with", "collapses_if", "cascade_from", "counterfactual_of", "cascade_to", "mutually_exclusive", "correlates_with", "amplifies", "precondition_for", "in_tension_with", "strengthened_by", "weakened_by", "alternative_to", "subsumes", "validated_by", "required_for", "blocks", "prerequisite_for", "parallel_to", "corroborates", "extends", "same_source_as", "same_theme_as", "assumes", "would_predict", "analogous_to", "independent_of", "implements", "violates", "co_changes_with", "migrating_from", "migrating_to", "scoped_by", "about_entity", "entity_referenced_in", "contradicts", "cites", "summarizes", "related_to", "partially_answers", "refines", "branches_from"];
|
|
4694
|
+
var STORAGE_EDGE_TYPE_VALUES = [...EDGE_TYPE_VALUES, "extracted_from"];
|
|
4695
|
+
z.enum(EDGE_TYPE_VALUES);
|
|
4696
|
+
z.enum(STORAGE_EDGE_TYPE_VALUES);
|
|
4697
|
+
z.enum(["active", "archived", "watching"]);
|
|
4698
|
+
z.enum(["private", "team", "firm", "external", "public"]);
|
|
4273
4699
|
|
|
4274
4700
|
// src/function-registry/helpers.ts
|
|
4275
4701
|
var jsonObjectSchema = z.record(z.unknown());
|
|
@@ -4366,12 +4792,20 @@ function unwrapMcpParameterSchema(schema) {
|
|
|
4366
4792
|
current = current._def.schema;
|
|
4367
4793
|
continue;
|
|
4368
4794
|
default:
|
|
4369
|
-
return {
|
|
4795
|
+
return {
|
|
4796
|
+
schema: current,
|
|
4797
|
+
required,
|
|
4798
|
+
description: description ?? current.description
|
|
4799
|
+
};
|
|
4370
4800
|
}
|
|
4371
4801
|
}
|
|
4372
4802
|
}
|
|
4373
4803
|
function mcpParameterFromZod(fieldName, schema, contractName) {
|
|
4374
|
-
const {
|
|
4804
|
+
const {
|
|
4805
|
+
schema: unwrapped,
|
|
4806
|
+
required,
|
|
4807
|
+
description: schemaDescription
|
|
4808
|
+
} = unwrapMcpParameterSchema(schema);
|
|
4375
4809
|
const description = schemaDescription ?? unwrapped.description ?? fieldName;
|
|
4376
4810
|
switch (unwrapped._def.typeName) {
|
|
4377
4811
|
case z.ZodFirstPartyTypeKind.ZodString:
|
|
@@ -4416,10 +4850,12 @@ function mcpContractFromArgsSchema(base, args, contractName) {
|
|
|
4416
4850
|
const entries2 = Object.entries(getObjectShape(args)).sort(
|
|
4417
4851
|
([left], [right]) => left.localeCompare(right)
|
|
4418
4852
|
);
|
|
4419
|
-
const converted = entries2.map(
|
|
4420
|
-
fieldName,
|
|
4421
|
-
|
|
4422
|
-
|
|
4853
|
+
const converted = entries2.map(
|
|
4854
|
+
([fieldName, schema]) => [
|
|
4855
|
+
fieldName,
|
|
4856
|
+
mcpParameterFromZod(fieldName, schema, contractName)
|
|
4857
|
+
]
|
|
4858
|
+
);
|
|
4423
4859
|
return {
|
|
4424
4860
|
...base,
|
|
4425
4861
|
parameters: Object.fromEntries(
|
|
@@ -4519,9 +4955,16 @@ function surfaceContract(args) {
|
|
|
4519
4955
|
scopes: args.scopes ?? [
|
|
4520
4956
|
args.kind === "query" ? `${args.domain}.read` : `${args.domain}.write`
|
|
4521
4957
|
],
|
|
4522
|
-
allowedPrincipalTypes: [
|
|
4958
|
+
allowedPrincipalTypes: [
|
|
4959
|
+
"user",
|
|
4960
|
+
"service",
|
|
4961
|
+
"agent",
|
|
4962
|
+
"group",
|
|
4963
|
+
"external_viewer"
|
|
4964
|
+
]
|
|
4523
4965
|
},
|
|
4524
4966
|
convex: args.convex,
|
|
4967
|
+
gateway: args.gateway,
|
|
4525
4968
|
args: canonicalArgs,
|
|
4526
4969
|
returns: canonicalReturns,
|
|
4527
4970
|
input,
|
|
@@ -4556,7 +4999,7 @@ function compactRecord2(input) {
|
|
|
4556
4999
|
Object.entries(input).filter(([, value]) => value !== void 0)
|
|
4557
5000
|
);
|
|
4558
5001
|
}
|
|
4559
|
-
|
|
5002
|
+
defineProjection({
|
|
4560
5003
|
contractName: "list_beliefs",
|
|
4561
5004
|
inputSchema: listBeliefsInputSchema,
|
|
4562
5005
|
project: (input) => compactRecord2({
|
|
@@ -4759,15 +5202,6 @@ var beliefLookupInput = (input) => compactRecord({
|
|
|
4759
5202
|
var beliefNodeInput = (input) => compactRecord({
|
|
4760
5203
|
nodeId: input.nodeId ?? input.id ?? input.beliefId
|
|
4761
5204
|
});
|
|
4762
|
-
var beliefTopicInput = (input) => {
|
|
4763
|
-
const parsed = listBeliefsProjection.inputSchema.safeParse(input);
|
|
4764
|
-
if (!parsed.success) {
|
|
4765
|
-
throw new Error(
|
|
4766
|
-
`list_beliefs projection input rejected: ${parsed.error.message}`
|
|
4767
|
-
);
|
|
4768
|
-
}
|
|
4769
|
-
return compactRecord(listBeliefsProjection.project(parsed.data));
|
|
4770
|
-
};
|
|
4771
5205
|
var createBeliefInput = (input, context) => {
|
|
4772
5206
|
return withUserId(
|
|
4773
5207
|
compactRecord({
|
|
@@ -4856,11 +5290,8 @@ var beliefsContracts = [
|
|
|
4856
5290
|
sdkNamespace: "beliefs",
|
|
4857
5291
|
sdkMethod: "listBeliefs",
|
|
4858
5292
|
summary: "List beliefs for a topic.",
|
|
4859
|
-
|
|
4860
|
-
|
|
4861
|
-
functionName: "getByTopic",
|
|
4862
|
-
kind: "query",
|
|
4863
|
-
inputProjection: beliefTopicInput
|
|
5293
|
+
gateway: {
|
|
5294
|
+
handler: "beliefs.list"
|
|
4864
5295
|
},
|
|
4865
5296
|
args: listBeliefsInputSchema
|
|
4866
5297
|
}),
|