@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
|
@@ -2,6 +2,20 @@ import { z } from 'zod';
|
|
|
2
2
|
|
|
3
3
|
// src/function-registry/helpers.ts
|
|
4
4
|
|
|
5
|
+
// src/types/reasoning-method.ts
|
|
6
|
+
var REASONING_METHODS = [
|
|
7
|
+
"deductive",
|
|
8
|
+
"inductive",
|
|
9
|
+
"abductive",
|
|
10
|
+
"analogical",
|
|
11
|
+
"causal",
|
|
12
|
+
"correlational",
|
|
13
|
+
"testimonial",
|
|
14
|
+
"statistical",
|
|
15
|
+
"implicit",
|
|
16
|
+
"pattern_match"
|
|
17
|
+
];
|
|
18
|
+
|
|
5
19
|
// src/lens-workflow.contract.ts
|
|
6
20
|
var LENS_PERSPECTIVE_TYPES = [
|
|
7
21
|
"investigation",
|
|
@@ -833,19 +847,23 @@ var FIND_CONTRADICTIONS = {
|
|
|
833
847
|
};
|
|
834
848
|
var CREATE_EDGE = {
|
|
835
849
|
name: "create_edge",
|
|
836
|
-
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.
|
|
850
|
+
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.",
|
|
837
851
|
parameters: {
|
|
838
|
-
|
|
839
|
-
type: "
|
|
840
|
-
description: "Source
|
|
852
|
+
from: {
|
|
853
|
+
type: "object",
|
|
854
|
+
description: "Source graph ref, e.g. { kind: 'epistemic_node', nodeId: '...', nodeType: 'topic' }"
|
|
841
855
|
},
|
|
842
|
-
|
|
843
|
-
type: "
|
|
844
|
-
description: "Target
|
|
856
|
+
to: {
|
|
857
|
+
type: "object",
|
|
858
|
+
description: "Target graph ref, e.g. { kind: 'epistemic_node', nodeId: '...', nodeType: 'belief' }"
|
|
845
859
|
},
|
|
846
860
|
edgeType: {
|
|
847
861
|
type: "string",
|
|
848
|
-
description: "Relationship type
|
|
862
|
+
description: "Relationship type from the public epistemic edge enum."
|
|
863
|
+
},
|
|
864
|
+
globalId: {
|
|
865
|
+
type: "string",
|
|
866
|
+
description: "Optional idempotent edge global ID."
|
|
849
867
|
},
|
|
850
868
|
weight: {
|
|
851
869
|
type: "number",
|
|
@@ -855,10 +873,14 @@ var CREATE_EDGE = {
|
|
|
855
873
|
reasoningMethod: {
|
|
856
874
|
type: "string",
|
|
857
875
|
description: "How this was determined",
|
|
858
|
-
enum: [
|
|
876
|
+
enum: [...REASONING_METHODS]
|
|
877
|
+
},
|
|
878
|
+
metadata: {
|
|
879
|
+
type: "object",
|
|
880
|
+
description: "Optional edge metadata."
|
|
859
881
|
}
|
|
860
882
|
},
|
|
861
|
-
required: ["
|
|
883
|
+
required: ["from", "to", "edgeType"],
|
|
862
884
|
response: {
|
|
863
885
|
description: "The created edge",
|
|
864
886
|
fields: {
|
|
@@ -872,6 +894,240 @@ var CREATE_EDGE = {
|
|
|
872
894
|
ontologyPrimitive: "edge",
|
|
873
895
|
tier: "showcase"
|
|
874
896
|
};
|
|
897
|
+
var UPDATE_EDGE = {
|
|
898
|
+
name: "update_edge",
|
|
899
|
+
description: "Amend metadata on an existing graph edge. Like `git commit --amend` \u2014 changes the edge annotation without recreating the relationship.",
|
|
900
|
+
parameters: {
|
|
901
|
+
edgeId: { type: "string", description: "Edge ID or global ID to update" },
|
|
902
|
+
weight: { type: "number", description: "Updated edge weight" },
|
|
903
|
+
confidence: { type: "number", description: "Updated confidence" },
|
|
904
|
+
context: { type: "string", description: "Updated human-readable context" },
|
|
905
|
+
derivationType: { type: "string", description: "Updated derivation type" },
|
|
906
|
+
metadata: { type: "object", description: "Updated metadata" }
|
|
907
|
+
},
|
|
908
|
+
required: ["edgeId"],
|
|
909
|
+
response: {
|
|
910
|
+
description: "Edge update result",
|
|
911
|
+
fields: { success: "boolean" }
|
|
912
|
+
},
|
|
913
|
+
ownerModule: "graph-primitives",
|
|
914
|
+
ontologyPrimitive: "edge",
|
|
915
|
+
tier: "workhorse"
|
|
916
|
+
};
|
|
917
|
+
var REMOVE_EDGE = {
|
|
918
|
+
name: "remove_edge",
|
|
919
|
+
description: "Remove one graph edge by ID. Like `git rm` \u2014 deletes a single explicit relationship from the spine.",
|
|
920
|
+
parameters: {
|
|
921
|
+
edgeId: { type: "string", description: "Edge ID or global ID to remove" }
|
|
922
|
+
},
|
|
923
|
+
required: ["edgeId"],
|
|
924
|
+
response: {
|
|
925
|
+
description: "Edge removal result",
|
|
926
|
+
fields: { success: "boolean" }
|
|
927
|
+
},
|
|
928
|
+
ownerModule: "graph-primitives",
|
|
929
|
+
ontologyPrimitive: "edge",
|
|
930
|
+
tier: "workhorse"
|
|
931
|
+
};
|
|
932
|
+
var REMOVE_EDGES_BETWEEN = {
|
|
933
|
+
name: "remove_edges_between",
|
|
934
|
+
description: "Remove graph edges between two nodes. Like `git rm <pathspec>` \u2014 deletes relationships matching a source, target, and optional type.",
|
|
935
|
+
parameters: {
|
|
936
|
+
fromNodeId: { type: "string", description: "Source node ID or global ID" },
|
|
937
|
+
toNodeId: { type: "string", description: "Target node ID or global ID" },
|
|
938
|
+
edgeType: { type: "string", description: "Optional edge type filter" }
|
|
939
|
+
},
|
|
940
|
+
required: ["fromNodeId", "toNodeId"],
|
|
941
|
+
response: {
|
|
942
|
+
description: "Matched edge removal result",
|
|
943
|
+
fields: { deleted: "number" }
|
|
944
|
+
},
|
|
945
|
+
ownerModule: "graph-primitives",
|
|
946
|
+
ontologyPrimitive: "edge",
|
|
947
|
+
tier: "workhorse"
|
|
948
|
+
};
|
|
949
|
+
var BATCH_CREATE_EDGES = {
|
|
950
|
+
name: "batch_create_edges",
|
|
951
|
+
description: "Commit multiple typed graph edges. Like `git commit` with many staged paths \u2014 writes a batch of explicit relationships atomically per edge.",
|
|
952
|
+
parameters: {
|
|
953
|
+
edges: {
|
|
954
|
+
type: "array",
|
|
955
|
+
description: "Edges to create, each with from, to, edgeType, and optional weight/confidence/context."
|
|
956
|
+
},
|
|
957
|
+
skipLayerValidation: {
|
|
958
|
+
type: "boolean",
|
|
959
|
+
description: "Skip kernel layer validation for trusted materialization flows."
|
|
960
|
+
}
|
|
961
|
+
},
|
|
962
|
+
required: ["edges"],
|
|
963
|
+
response: {
|
|
964
|
+
description: "Batch edge creation result",
|
|
965
|
+
fields: {
|
|
966
|
+
created: "number",
|
|
967
|
+
results: "array",
|
|
968
|
+
errors: "array"
|
|
969
|
+
}
|
|
970
|
+
},
|
|
971
|
+
ownerModule: "graph-primitives",
|
|
972
|
+
ontologyPrimitive: "edge",
|
|
973
|
+
tier: "workhorse"
|
|
974
|
+
};
|
|
975
|
+
var CREATE_EPISTEMIC_NODE = {
|
|
976
|
+
name: "create_epistemic_node",
|
|
977
|
+
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.",
|
|
978
|
+
parameters: {
|
|
979
|
+
globalId: { type: "string", description: "Optional idempotent node global ID" },
|
|
980
|
+
nodeType: { type: "string", description: "Public epistemic node type" },
|
|
981
|
+
canonicalText: { type: "string", description: "Canonical node text" },
|
|
982
|
+
text: { type: "string", description: "Alias for canonicalText" },
|
|
983
|
+
contentHash: { type: "string", description: "Optional idempotency content hash" },
|
|
984
|
+
sourceType: { type: "string", description: "Source type for provenance" },
|
|
985
|
+
topicId: { type: "string", description: "Optional topic scope" },
|
|
986
|
+
content: { type: "string", description: "Extended content" },
|
|
987
|
+
title: { type: "string", description: "Display title" },
|
|
988
|
+
metadata: { type: "object", description: "Optional node metadata" }
|
|
989
|
+
},
|
|
990
|
+
required: ["nodeType"],
|
|
991
|
+
response: {
|
|
992
|
+
description: "Created node result",
|
|
993
|
+
fields: {
|
|
994
|
+
nodeId: "string",
|
|
995
|
+
nodeGlobalId: "string",
|
|
996
|
+
isDuplicate: "boolean"
|
|
997
|
+
}
|
|
998
|
+
},
|
|
999
|
+
ownerModule: "reasoning-kernel",
|
|
1000
|
+
ontologyPrimitive: "graph",
|
|
1001
|
+
tier: "showcase"
|
|
1002
|
+
};
|
|
1003
|
+
var GET_EPISTEMIC_NODE = {
|
|
1004
|
+
name: "get_epistemic_node",
|
|
1005
|
+
description: "Read one epistemic graph node. Like `git show` \u2014 resolves a canonical spine node by ID or global ID.",
|
|
1006
|
+
parameters: {
|
|
1007
|
+
nodeId: { type: "string", description: "Node ID or global ID" }
|
|
1008
|
+
},
|
|
1009
|
+
required: ["nodeId"],
|
|
1010
|
+
response: {
|
|
1011
|
+
description: "The resolved node",
|
|
1012
|
+
fields: { node: "object" }
|
|
1013
|
+
},
|
|
1014
|
+
ownerModule: "reasoning-kernel",
|
|
1015
|
+
ontologyPrimitive: "graph",
|
|
1016
|
+
tier: "workhorse"
|
|
1017
|
+
};
|
|
1018
|
+
var LIST_EPISTEMIC_NODES = {
|
|
1019
|
+
name: "list_epistemic_nodes",
|
|
1020
|
+
description: "List epistemic graph nodes. Like `git ls-tree` \u2014 lists canonical spine nodes by topic, type, status, or search query.",
|
|
1021
|
+
parameters: {
|
|
1022
|
+
topicId: { type: "string", description: "Optional topic scope" },
|
|
1023
|
+
nodeType: { type: "string", description: "Optional node type filter" },
|
|
1024
|
+
status: { type: "string", description: "Optional lifecycle status" },
|
|
1025
|
+
searchQuery: { type: "string", description: "Optional text search query" },
|
|
1026
|
+
limit: { type: "number", description: "Maximum nodes to return" }
|
|
1027
|
+
},
|
|
1028
|
+
required: [],
|
|
1029
|
+
response: {
|
|
1030
|
+
description: "Matching nodes",
|
|
1031
|
+
fields: { nodes: "array" }
|
|
1032
|
+
},
|
|
1033
|
+
ownerModule: "reasoning-kernel",
|
|
1034
|
+
ontologyPrimitive: "graph",
|
|
1035
|
+
tier: "workhorse"
|
|
1036
|
+
};
|
|
1037
|
+
var UPDATE_EPISTEMIC_NODE = {
|
|
1038
|
+
name: "update_epistemic_node",
|
|
1039
|
+
description: "Amend an epistemic graph node. Like `git commit --amend` \u2014 updates mutable node metadata, text, status, or verification fields.",
|
|
1040
|
+
parameters: {
|
|
1041
|
+
nodeId: { type: "string", description: "Node ID or global ID" },
|
|
1042
|
+
canonicalText: { type: "string", description: "Updated canonical text" },
|
|
1043
|
+
text: { type: "string", description: "Alias for canonicalText" },
|
|
1044
|
+
contentHash: { type: "string", description: "Updated content hash" },
|
|
1045
|
+
content: { type: "string", description: "Updated content" },
|
|
1046
|
+
title: { type: "string", description: "Updated display title" },
|
|
1047
|
+
metadata: { type: "object", description: "Updated metadata" },
|
|
1048
|
+
confidence: { type: "number", description: "Updated confidence" },
|
|
1049
|
+
verificationStatus: { type: "string", description: "Updated verification status" },
|
|
1050
|
+
status: { type: "string", description: "Updated lifecycle status" }
|
|
1051
|
+
},
|
|
1052
|
+
required: ["nodeId"],
|
|
1053
|
+
response: {
|
|
1054
|
+
description: "Node update result",
|
|
1055
|
+
fields: { success: "boolean" }
|
|
1056
|
+
},
|
|
1057
|
+
ownerModule: "reasoning-kernel",
|
|
1058
|
+
ontologyPrimitive: "graph",
|
|
1059
|
+
tier: "workhorse"
|
|
1060
|
+
};
|
|
1061
|
+
var ARCHIVE_EPISTEMIC_NODE = {
|
|
1062
|
+
name: "archive_epistemic_node",
|
|
1063
|
+
description: "Archive an epistemic graph node. Like `git rm --cached` \u2014 removes a node from active traversal without hard-deleting it.",
|
|
1064
|
+
parameters: {
|
|
1065
|
+
nodeId: { type: "string", description: "Node ID or global ID" }
|
|
1066
|
+
},
|
|
1067
|
+
required: ["nodeId"],
|
|
1068
|
+
response: {
|
|
1069
|
+
description: "Archive result",
|
|
1070
|
+
fields: { success: "boolean", effectiveStatus: "string" }
|
|
1071
|
+
},
|
|
1072
|
+
ownerModule: "reasoning-kernel",
|
|
1073
|
+
ontologyPrimitive: "graph",
|
|
1074
|
+
tier: "workhorse"
|
|
1075
|
+
};
|
|
1076
|
+
var VERIFY_EPISTEMIC_NODE = {
|
|
1077
|
+
name: "verify_epistemic_node",
|
|
1078
|
+
description: "Record verification state on an epistemic graph node. Like `git tag` \u2014 marks the node with a reviewed verification state.",
|
|
1079
|
+
parameters: {
|
|
1080
|
+
nodeId: { type: "string", description: "Node ID or global ID" },
|
|
1081
|
+
verificationStatus: { type: "string", description: "Verification status" },
|
|
1082
|
+
confidence: { type: "number", description: "Optional confidence update" }
|
|
1083
|
+
},
|
|
1084
|
+
required: ["nodeId", "verificationStatus"],
|
|
1085
|
+
response: {
|
|
1086
|
+
description: "Verification result",
|
|
1087
|
+
fields: { success: "boolean" }
|
|
1088
|
+
},
|
|
1089
|
+
ownerModule: "reasoning-kernel",
|
|
1090
|
+
ontologyPrimitive: "graph",
|
|
1091
|
+
tier: "workhorse"
|
|
1092
|
+
};
|
|
1093
|
+
var SUPERSEDE_EPISTEMIC_NODE = {
|
|
1094
|
+
name: "supersede_epistemic_node",
|
|
1095
|
+
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.",
|
|
1096
|
+
parameters: {
|
|
1097
|
+
oldNodeId: { type: "string", description: "Node ID or global ID to supersede" },
|
|
1098
|
+
newGlobalId: { type: "string", description: "Optional replacement global ID" },
|
|
1099
|
+
newCanonicalText: { type: "string", description: "Replacement canonical text" },
|
|
1100
|
+
text: { type: "string", description: "Alias for newCanonicalText" },
|
|
1101
|
+
newContentHash: { type: "string", description: "Optional replacement content hash" },
|
|
1102
|
+
reason: { type: "string", description: "Reason for superseding" }
|
|
1103
|
+
},
|
|
1104
|
+
required: ["oldNodeId"],
|
|
1105
|
+
response: {
|
|
1106
|
+
description: "Supersede result",
|
|
1107
|
+
fields: { oldNodeId: "string", newNodeId: "string" }
|
|
1108
|
+
},
|
|
1109
|
+
ownerModule: "reasoning-kernel",
|
|
1110
|
+
ontologyPrimitive: "graph",
|
|
1111
|
+
tier: "workhorse"
|
|
1112
|
+
};
|
|
1113
|
+
var BATCH_CREATE_EPISTEMIC_NODES = {
|
|
1114
|
+
name: "batch_create_epistemic_nodes",
|
|
1115
|
+
description: "Commit multiple epistemic graph nodes. Like `git commit` with many staged files \u2014 writes a batch of canonical spine nodes.",
|
|
1116
|
+
parameters: {
|
|
1117
|
+
nodes: {
|
|
1118
|
+
type: "array",
|
|
1119
|
+
description: "Nodes to create with nodeType, canonicalText/text, and optional metadata."
|
|
1120
|
+
}
|
|
1121
|
+
},
|
|
1122
|
+
required: ["nodes"],
|
|
1123
|
+
response: {
|
|
1124
|
+
description: "Batch node creation result",
|
|
1125
|
+
fields: { created: "number", results: "array" }
|
|
1126
|
+
},
|
|
1127
|
+
ownerModule: "reasoning-kernel",
|
|
1128
|
+
ontologyPrimitive: "graph",
|
|
1129
|
+
tier: "workhorse"
|
|
1130
|
+
};
|
|
875
1131
|
var RECORD_JUDGMENT = {
|
|
876
1132
|
name: "record_judgment",
|
|
877
1133
|
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).",
|
|
@@ -2071,8 +2327,8 @@ var IDENTITY_WHOAMI = {
|
|
|
2071
2327
|
response: {
|
|
2072
2328
|
description: "Canonical identity summary for the current session",
|
|
2073
2329
|
fields: {
|
|
2074
|
-
principalId: "string \u2014 canonical
|
|
2075
|
-
principalType: "string \u2014 human, service, or
|
|
2330
|
+
principalId: "string \u2014 canonical principal identifier; for humans this is the Clerk user_... ID",
|
|
2331
|
+
principalType: "string \u2014 human, service, agent, group, or external_viewer",
|
|
2076
2332
|
tenantId: "string | undefined \u2014 resolved tenant scope",
|
|
2077
2333
|
workspaceId: "string | undefined \u2014 resolved workspace scope",
|
|
2078
2334
|
scopes: "string[] | undefined \u2014 granted scopes for this session",
|
|
@@ -2083,6 +2339,49 @@ var IDENTITY_WHOAMI = {
|
|
|
2083
2339
|
ontologyPrimitive: "identity",
|
|
2084
2340
|
tier: "workhorse"
|
|
2085
2341
|
};
|
|
2342
|
+
var RESOLVE_INTERACTIVE_PRINCIPAL = {
|
|
2343
|
+
name: "resolve_interactive_principal",
|
|
2344
|
+
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.",
|
|
2345
|
+
parameters: {
|
|
2346
|
+
clerkId: {
|
|
2347
|
+
type: "string",
|
|
2348
|
+
description: "Authenticated Clerk subject (`sub`). Clerk proves identity only; it is not the authorization record."
|
|
2349
|
+
},
|
|
2350
|
+
tenantId: {
|
|
2351
|
+
type: "string",
|
|
2352
|
+
description: "Optional tenant scope. Omit only when the Clerk alias is globally unambiguous."
|
|
2353
|
+
},
|
|
2354
|
+
workspaceId: {
|
|
2355
|
+
type: "string",
|
|
2356
|
+
description: "Optional workspace scope. Required when the principal has access to multiple workspaces and no default can be inferred."
|
|
2357
|
+
},
|
|
2358
|
+
providerProjectId: {
|
|
2359
|
+
type: "string",
|
|
2360
|
+
description: "Optional Clerk project or provider instance id for tenants with multiple identity providers."
|
|
2361
|
+
}
|
|
2362
|
+
},
|
|
2363
|
+
required: ["clerkId"],
|
|
2364
|
+
response: {
|
|
2365
|
+
description: "Permit-backed Lucern principal context for tenant SDK bootstrap",
|
|
2366
|
+
fields: {
|
|
2367
|
+
principalId: "string \u2014 canonical Clerk user_... ID for human sessions",
|
|
2368
|
+
principalType: "string \u2014 human, service, agent, group, or external_viewer",
|
|
2369
|
+
clerkId: "string \u2014 authenticated Clerk subject alias",
|
|
2370
|
+
tenantId: "string \u2014 resolved tenant scope",
|
|
2371
|
+
workspaceId: "string | null \u2014 resolved workspace scope",
|
|
2372
|
+
roles: "string[] \u2014 effective Permit roles",
|
|
2373
|
+
scopes: "string[] \u2014 effective scopes derived from Permit/control-plane projection",
|
|
2374
|
+
groupIds: "string[] \u2014 active Permit group memberships",
|
|
2375
|
+
principalStatus: "string \u2014 active, invited, suspended, disabled, revoked, or missing",
|
|
2376
|
+
tenantStatus: "string \u2014 projected tenant resource status",
|
|
2377
|
+
workspaceStatus: "string \u2014 projected workspace resource status",
|
|
2378
|
+
permit: "object \u2014 Permit subject, tenant, and optional workspace tuple"
|
|
2379
|
+
}
|
|
2380
|
+
},
|
|
2381
|
+
ownerModule: "control-plane",
|
|
2382
|
+
ontologyPrimitive: "identity",
|
|
2383
|
+
tier: "workhorse"
|
|
2384
|
+
};
|
|
2086
2385
|
var COMPILE_CONTEXT = {
|
|
2087
2386
|
name: "compile_context",
|
|
2088
2387
|
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.",
|
|
@@ -2344,6 +2643,10 @@ var CREATE_TASK = {
|
|
|
2344
2643
|
tags: {
|
|
2345
2644
|
type: "array",
|
|
2346
2645
|
description: "Free-form string tags"
|
|
2646
|
+
},
|
|
2647
|
+
metadata: {
|
|
2648
|
+
type: "object",
|
|
2649
|
+
description: "Structured task metadata for handoff context and routing hints"
|
|
2347
2650
|
}
|
|
2348
2651
|
},
|
|
2349
2652
|
required: ["title"],
|
|
@@ -2417,6 +2720,10 @@ var UPDATE_TASK = {
|
|
|
2417
2720
|
type: "string",
|
|
2418
2721
|
description: "Updated status",
|
|
2419
2722
|
enum: ["todo", "in_progress", "blocked", "done"]
|
|
2723
|
+
},
|
|
2724
|
+
metadata: {
|
|
2725
|
+
type: "object",
|
|
2726
|
+
description: "Structured task metadata to replace or refine"
|
|
2420
2727
|
}
|
|
2421
2728
|
},
|
|
2422
2729
|
required: ["taskId"],
|
|
@@ -2464,6 +2771,10 @@ var CREATE_TOPIC = {
|
|
|
2464
2771
|
name: "create_topic",
|
|
2465
2772
|
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.",
|
|
2466
2773
|
parameters: {
|
|
2774
|
+
globalId: {
|
|
2775
|
+
type: "string",
|
|
2776
|
+
description: "Optional idempotent topic global ID"
|
|
2777
|
+
},
|
|
2467
2778
|
name: { type: "string", description: "Topic name" },
|
|
2468
2779
|
type: {
|
|
2469
2780
|
type: "string",
|
|
@@ -2474,6 +2785,18 @@ var CREATE_TOPIC = {
|
|
|
2474
2785
|
type: "string",
|
|
2475
2786
|
description: "Optional parent topic for nesting"
|
|
2476
2787
|
},
|
|
2788
|
+
parentTopicGlobalId: {
|
|
2789
|
+
type: "string",
|
|
2790
|
+
description: "Optional parent topic global ID for nesting"
|
|
2791
|
+
},
|
|
2792
|
+
tenantId: { type: "string", description: "Optional tenant scope" },
|
|
2793
|
+
workspaceId: { type: "string", description: "Optional workspace scope" },
|
|
2794
|
+
visibility: {
|
|
2795
|
+
type: "string",
|
|
2796
|
+
description: "Topic visibility",
|
|
2797
|
+
enum: ["private", "team", "firm", "external", "public"]
|
|
2798
|
+
},
|
|
2799
|
+
metadata: { type: "object", description: "Optional topic metadata" },
|
|
2477
2800
|
createdBy: { type: "string", description: "Who created this topic" }
|
|
2478
2801
|
},
|
|
2479
2802
|
required: ["name", "type"],
|
|
@@ -2482,6 +2805,9 @@ var CREATE_TOPIC = {
|
|
|
2482
2805
|
fields: {
|
|
2483
2806
|
id: "string \u2014 topic ID",
|
|
2484
2807
|
globalId: "string \u2014 globally unique ID",
|
|
2808
|
+
topicGlobalId: "string \u2014 topic global ID",
|
|
2809
|
+
epistemicNodeId: "string \u2014 materialized topic node ID",
|
|
2810
|
+
epistemicNodeGlobalId: "string \u2014 materialized topic node global ID",
|
|
2485
2811
|
depth: "number \u2014 nesting depth"
|
|
2486
2812
|
}
|
|
2487
2813
|
},
|
|
@@ -2612,6 +2938,65 @@ var GET_TOPIC_TREE = {
|
|
|
2612
2938
|
ontologyPrimitive: "graph",
|
|
2613
2939
|
tier: "workhorse"
|
|
2614
2940
|
};
|
|
2941
|
+
var MATERIALIZE_TOPIC_GRAPH = {
|
|
2942
|
+
name: "materialize_topic_graph",
|
|
2943
|
+
description: "Backfill the topic graph spine. Like `git fsck --connectivity-only` with repair enabled \u2014 creates missing topic nodes and parent-child edges idempotently.",
|
|
2944
|
+
parameters: {
|
|
2945
|
+
rootTopicId: {
|
|
2946
|
+
type: "string",
|
|
2947
|
+
description: "Optional root topic for a bounded materialization pass"
|
|
2948
|
+
},
|
|
2949
|
+
dryRun: {
|
|
2950
|
+
type: "boolean",
|
|
2951
|
+
description: "When true, report missing rows without writing them"
|
|
2952
|
+
}
|
|
2953
|
+
},
|
|
2954
|
+
required: [],
|
|
2955
|
+
response: {
|
|
2956
|
+
description: "Topic graph materialization counts",
|
|
2957
|
+
fields: {
|
|
2958
|
+
topicsSeen: "number",
|
|
2959
|
+
nodesCreated: "number",
|
|
2960
|
+
nodesExisting: "number",
|
|
2961
|
+
edgesCreated: "number",
|
|
2962
|
+
edgesExisting: "number",
|
|
2963
|
+
errors: "array"
|
|
2964
|
+
}
|
|
2965
|
+
},
|
|
2966
|
+
ownerModule: "reasoning-kernel",
|
|
2967
|
+
ontologyPrimitive: "graph",
|
|
2968
|
+
tier: "workhorse"
|
|
2969
|
+
};
|
|
2970
|
+
var GET_TOPIC_GRAPH_SPINE = {
|
|
2971
|
+
name: "get_topic_graph_spine",
|
|
2972
|
+
description: "Verify the topic graph spine. Like `git fsck` \u2014 reads topics, materialized topic nodes, parent-child edges, and missing spine rows.",
|
|
2973
|
+
parameters: {
|
|
2974
|
+
rootTopicId: {
|
|
2975
|
+
type: "string",
|
|
2976
|
+
description: "Optional root topic for a bounded verifier pass"
|
|
2977
|
+
},
|
|
2978
|
+
includeTopicBeliefEdges: {
|
|
2979
|
+
type: "boolean",
|
|
2980
|
+
description: "Include topic -> belief edges in the verifier payload"
|
|
2981
|
+
}
|
|
2982
|
+
},
|
|
2983
|
+
required: [],
|
|
2984
|
+
response: {
|
|
2985
|
+
description: "Topic graph spine verification payload",
|
|
2986
|
+
fields: {
|
|
2987
|
+
ok: "boolean",
|
|
2988
|
+
counts: "object",
|
|
2989
|
+
topics: "array",
|
|
2990
|
+
topicNodes: "array",
|
|
2991
|
+
parentEdges: "array",
|
|
2992
|
+
missingTopicNodes: "array",
|
|
2993
|
+
missingParentEdges: "array"
|
|
2994
|
+
}
|
|
2995
|
+
},
|
|
2996
|
+
ownerModule: "reasoning-kernel",
|
|
2997
|
+
ontologyPrimitive: "graph",
|
|
2998
|
+
tier: "workhorse"
|
|
2999
|
+
};
|
|
2615
3000
|
var GET_CODE_CONTEXT = {
|
|
2616
3001
|
name: "get_code_context",
|
|
2617
3002
|
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.",
|
|
@@ -2807,7 +3192,7 @@ var MANAGE_WRITE_POLICY = {
|
|
|
2807
3192
|
},
|
|
2808
3193
|
role: {
|
|
2809
3194
|
type: "string",
|
|
2810
|
-
description: "Role to set policy for (required for 'set'). E.g. 'agent:internal'
|
|
3195
|
+
description: "Role to set policy for (required for 'set'). E.g. 'agent:internal' or a Permit role key such as 'workspace_admin'."
|
|
2811
3196
|
},
|
|
2812
3197
|
permission: {
|
|
2813
3198
|
type: "string",
|
|
@@ -3794,6 +4179,9 @@ var BEGIN_BUILD_SESSION = {
|
|
|
3794
4179
|
sessionMode: "string \u2014 async | interactive",
|
|
3795
4180
|
targetBeliefIds: "array \u2014 scoped belief IDs",
|
|
3796
4181
|
targetQuestionIds: "array \u2014 scoped question IDs",
|
|
4182
|
+
taskIds: "array \u2014 assigned task IDs for this worktree",
|
|
4183
|
+
incompleteTaskIds: "array \u2014 assigned task IDs that still require done/deferred/blocked proof",
|
|
4184
|
+
tasks: "array \u2014 assigned task packet with id, title, status, priority, links, and summaries",
|
|
3797
4185
|
topBeliefs: "array \u2014 highest-confidence scoped beliefs",
|
|
3798
4186
|
openQuestions: "array \u2014 open scoped questions",
|
|
3799
4187
|
resolvedDecisions: "array \u2014 answered questions summarized for the session",
|
|
@@ -3849,6 +4237,19 @@ var MCP_TOOL_CONTRACTS = {
|
|
|
3849
4237
|
bisect_confidence: BISECT_CONFIDENCE,
|
|
3850
4238
|
// Edges (commit)
|
|
3851
4239
|
create_edge: CREATE_EDGE,
|
|
4240
|
+
update_edge: UPDATE_EDGE,
|
|
4241
|
+
remove_edge: REMOVE_EDGE,
|
|
4242
|
+
remove_edges_between: REMOVE_EDGES_BETWEEN,
|
|
4243
|
+
batch_create_edges: BATCH_CREATE_EDGES,
|
|
4244
|
+
// Epistemic node spine (commit/amend/show)
|
|
4245
|
+
create_epistemic_node: CREATE_EPISTEMIC_NODE,
|
|
4246
|
+
get_epistemic_node: GET_EPISTEMIC_NODE,
|
|
4247
|
+
list_epistemic_nodes: LIST_EPISTEMIC_NODES,
|
|
4248
|
+
update_epistemic_node: UPDATE_EPISTEMIC_NODE,
|
|
4249
|
+
archive_epistemic_node: ARCHIVE_EPISTEMIC_NODE,
|
|
4250
|
+
verify_epistemic_node: VERIFY_EPISTEMIC_NODE,
|
|
4251
|
+
supersede_epistemic_node: SUPERSEDE_EPISTEMIC_NODE,
|
|
4252
|
+
batch_create_epistemic_nodes: BATCH_CREATE_EPISTEMIC_NODES,
|
|
3852
4253
|
// Judgments (tag)
|
|
3853
4254
|
record_judgment: RECORD_JUDGMENT,
|
|
3854
4255
|
// Graph intelligence (showcase)
|
|
@@ -3883,6 +4284,7 @@ var MCP_TOOL_CONTRACTS = {
|
|
|
3883
4284
|
update_worktree_targets: UPDATE_WORKTREE_TARGETS,
|
|
3884
4285
|
update_worktree_metadata: UPDATE_WORKTREE_METADATA,
|
|
3885
4286
|
identity_whoami: IDENTITY_WHOAMI,
|
|
4287
|
+
resolve_interactive_principal: RESOLVE_INTERACTIVE_PRINCIPAL,
|
|
3886
4288
|
compile_context: COMPILE_CONTEXT,
|
|
3887
4289
|
record_scope_learning: RECORD_SCOPE_LEARNING,
|
|
3888
4290
|
pipeline_snapshot: PIPELINE_SNAPSHOT,
|
|
@@ -3922,6 +4324,8 @@ var MCP_TOOL_CONTRACTS = {
|
|
|
3922
4324
|
get_topic: GET_TOPIC,
|
|
3923
4325
|
update_topic: UPDATE_TOPIC,
|
|
3924
4326
|
get_topic_tree: GET_TOPIC_TREE,
|
|
4327
|
+
materialize_topic_graph: MATERIALIZE_TOPIC_GRAPH,
|
|
4328
|
+
get_topic_graph_spine: GET_TOPIC_GRAPH_SPINE,
|
|
3925
4329
|
// Coding intelligence (code-grounded knowledge)
|
|
3926
4330
|
get_code_context: GET_CODE_CONTEXT,
|
|
3927
4331
|
get_change_history: GET_CHANGE_HISTORY,
|
|
@@ -3998,6 +4402,7 @@ function entries(names, surfaceClass, surfaceIntent, surfaces, rationale) {
|
|
|
3998
4402
|
var MCP_CORE_OPERATION_NAMES = [
|
|
3999
4403
|
"compile_context",
|
|
4000
4404
|
"identity_whoami",
|
|
4405
|
+
"resolve_interactive_principal",
|
|
4001
4406
|
"check_permission",
|
|
4002
4407
|
"filter_by_permission",
|
|
4003
4408
|
"create_belief",
|
|
@@ -4026,14 +4431,28 @@ var MCP_CORE_OPERATION_NAMES = [
|
|
|
4026
4431
|
"find_missing_questions",
|
|
4027
4432
|
"get_high_priority_questions",
|
|
4028
4433
|
"get_falsification_questions",
|
|
4434
|
+
"create_epistemic_node",
|
|
4435
|
+
"get_epistemic_node",
|
|
4436
|
+
"list_epistemic_nodes",
|
|
4437
|
+
"update_epistemic_node",
|
|
4438
|
+
"archive_epistemic_node",
|
|
4439
|
+
"verify_epistemic_node",
|
|
4440
|
+
"supersede_epistemic_node",
|
|
4441
|
+
"batch_create_epistemic_nodes",
|
|
4029
4442
|
"create_topic",
|
|
4030
4443
|
"get_topic",
|
|
4031
4444
|
"list_topics",
|
|
4032
4445
|
"update_topic",
|
|
4033
|
-
"get_topic_tree"
|
|
4446
|
+
"get_topic_tree",
|
|
4447
|
+
"materialize_topic_graph",
|
|
4448
|
+
"get_topic_graph_spine"
|
|
4034
4449
|
];
|
|
4035
4450
|
var MCP_ANALYSIS_PLATFORM_OPERATION_NAMES = [
|
|
4036
4451
|
"create_edge",
|
|
4452
|
+
"update_edge",
|
|
4453
|
+
"remove_edge",
|
|
4454
|
+
"remove_edges_between",
|
|
4455
|
+
"batch_create_edges",
|
|
4037
4456
|
"query_lineage",
|
|
4038
4457
|
"traverse_graph",
|
|
4039
4458
|
"get_graph_neighborhood",
|
|
@@ -4269,6 +4688,13 @@ var LUCERN_OPERATION_MANIFEST = {
|
|
|
4269
4688
|
"Lucern MCP-only platform operation for local agent/bootstrap or verification workflows. Hidden from public discovery."
|
|
4270
4689
|
)
|
|
4271
4690
|
};
|
|
4691
|
+
z.enum(["decision", "belief", "question", "theme", "deal", "topic", "claim", "evidence", "synthesis", "answer", "atomic_fact", "excerpt", "source", "company", "person", "investor", "function", "value_chain"]);
|
|
4692
|
+
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"];
|
|
4693
|
+
var STORAGE_EDGE_TYPE_VALUES = [...EDGE_TYPE_VALUES, "extracted_from"];
|
|
4694
|
+
z.enum(EDGE_TYPE_VALUES);
|
|
4695
|
+
z.enum(STORAGE_EDGE_TYPE_VALUES);
|
|
4696
|
+
z.enum(["active", "archived", "watching"]);
|
|
4697
|
+
z.enum(["private", "team", "firm", "external", "public"]);
|
|
4272
4698
|
|
|
4273
4699
|
// src/function-registry/helpers.ts
|
|
4274
4700
|
var jsonObjectSchema = z.record(z.unknown());
|
|
@@ -4365,12 +4791,20 @@ function unwrapMcpParameterSchema(schema) {
|
|
|
4365
4791
|
current = current._def.schema;
|
|
4366
4792
|
continue;
|
|
4367
4793
|
default:
|
|
4368
|
-
return {
|
|
4794
|
+
return {
|
|
4795
|
+
schema: current,
|
|
4796
|
+
required,
|
|
4797
|
+
description: description ?? current.description
|
|
4798
|
+
};
|
|
4369
4799
|
}
|
|
4370
4800
|
}
|
|
4371
4801
|
}
|
|
4372
4802
|
function mcpParameterFromZod(fieldName, schema, contractName) {
|
|
4373
|
-
const {
|
|
4803
|
+
const {
|
|
4804
|
+
schema: unwrapped,
|
|
4805
|
+
required,
|
|
4806
|
+
description: schemaDescription
|
|
4807
|
+
} = unwrapMcpParameterSchema(schema);
|
|
4374
4808
|
const description = schemaDescription ?? unwrapped.description ?? fieldName;
|
|
4375
4809
|
switch (unwrapped._def.typeName) {
|
|
4376
4810
|
case z.ZodFirstPartyTypeKind.ZodString:
|
|
@@ -4415,10 +4849,12 @@ function mcpContractFromArgsSchema(base, args, contractName) {
|
|
|
4415
4849
|
const entries2 = Object.entries(getObjectShape(args)).sort(
|
|
4416
4850
|
([left], [right]) => left.localeCompare(right)
|
|
4417
4851
|
);
|
|
4418
|
-
const converted = entries2.map(
|
|
4419
|
-
fieldName,
|
|
4420
|
-
|
|
4421
|
-
|
|
4852
|
+
const converted = entries2.map(
|
|
4853
|
+
([fieldName, schema]) => [
|
|
4854
|
+
fieldName,
|
|
4855
|
+
mcpParameterFromZod(fieldName, schema, contractName)
|
|
4856
|
+
]
|
|
4857
|
+
);
|
|
4422
4858
|
return {
|
|
4423
4859
|
...base,
|
|
4424
4860
|
parameters: Object.fromEntries(
|
|
@@ -4524,9 +4960,16 @@ function surfaceContract(args) {
|
|
|
4524
4960
|
scopes: args.scopes ?? [
|
|
4525
4961
|
args.kind === "query" ? `${args.domain}.read` : `${args.domain}.write`
|
|
4526
4962
|
],
|
|
4527
|
-
allowedPrincipalTypes: [
|
|
4963
|
+
allowedPrincipalTypes: [
|
|
4964
|
+
"user",
|
|
4965
|
+
"service",
|
|
4966
|
+
"agent",
|
|
4967
|
+
"group",
|
|
4968
|
+
"external_viewer"
|
|
4969
|
+
]
|
|
4528
4970
|
},
|
|
4529
4971
|
convex: args.convex,
|
|
4972
|
+
gateway: args.gateway,
|
|
4530
4973
|
args: canonicalArgs,
|
|
4531
4974
|
returns: canonicalReturns,
|
|
4532
4975
|
input,
|
|
@@ -4560,6 +5003,19 @@ var worktreeEvidenceSignalInputSchema = z.object({
|
|
|
4560
5003
|
progress: z.string().optional().describe("Collection progress note for the signal."),
|
|
4561
5004
|
notes: z.string().optional().describe("Additional evidence collection notes.")
|
|
4562
5005
|
}).passthrough().describe("Evidence signal embedded in the worktree plan.");
|
|
5006
|
+
var worktreeDocCompanionTargetSchema = z.object({
|
|
5007
|
+
docPath: z.string().describe(
|
|
5008
|
+
"Repo-relative path to a documentation file the worktree promises to update."
|
|
5009
|
+
),
|
|
5010
|
+
sectionAnchor: z.string().optional().describe(
|
|
5011
|
+
"Markdown heading anchor (e.g. '## Function-surface manifest') that scopes the promised update."
|
|
5012
|
+
),
|
|
5013
|
+
reason: z.string().describe(
|
|
5014
|
+
"Why this doc section must be updated for the worktree to be complete."
|
|
5015
|
+
)
|
|
5016
|
+
}).passthrough().describe(
|
|
5017
|
+
"Intent-driven docs companion target. pr-gate-reviewer verifies that the PR actually touches each declared (docPath, sectionAnchor). Distinct from the touch-driven docs-loop. See docs/development/docs-sync-discipline.md Lock 3."
|
|
5018
|
+
);
|
|
4563
5019
|
var worktreeDecisionGateInputSchema = z.object({
|
|
4564
5020
|
goCriteria: z.array(z.string()).describe("Criteria that must hold for the worktree to proceed."),
|
|
4565
5021
|
noGoSignals: z.array(z.string()).describe("Signals that stop or redirect the worktree."),
|
|
@@ -4592,6 +5048,9 @@ var addWorktreeArgs = z.object({
|
|
|
4592
5048
|
keyQuestions: z.array(worktreeKeyQuestionInputSchema).optional().describe("Inline key questions captured as part of the worktree plan."),
|
|
4593
5049
|
evidenceSignals: z.array(worktreeEvidenceSignalInputSchema).optional().describe("Evidence signals the worktree needs to collect or validate."),
|
|
4594
5050
|
decisionGate: worktreeDecisionGateInputSchema.optional(),
|
|
5051
|
+
docCompanionTargets: z.array(worktreeDocCompanionTargetSchema).optional().describe(
|
|
5052
|
+
"Doc sections the worktree promises to update at PR time. Enforced by pr-gate-reviewer (Lock 3)."
|
|
5053
|
+
),
|
|
4595
5054
|
goCriteria: z.array(z.string()).optional().describe("Shorthand go criteria used to build decisionGate."),
|
|
4596
5055
|
noGoSignals: z.array(z.string()).optional().describe("Shorthand no-go signals used to build decisionGate."),
|
|
4597
5056
|
proofArtifacts: z.array(z.unknown()).optional().describe("Expected proof artifacts required to close the worktree."),
|