@lucern/contracts 1.0.43 → 1.0.44
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/dist/function-registry/context.js +7 -3
- package/dist/generated/convexSchemas.d.ts +115 -115
- package/dist/generated/convexSchemas.js +6 -6
- package/dist/generated/schema-manifest.json +3 -1
- package/dist/index.js +23 -12
- package/dist/proof-attestation.json +1 -1
- package/dist/schemas/index.js +23 -12
- package/dist/schemas/manifest.d.ts +55 -55
- package/dist/schemas/manifest.js +23 -12
- package/dist/schemas/tables/kernel/decision.d.ts +2 -2
- package/dist/schemas/tables/kernel/decision.js +2 -2
- package/dist/schemas/tables/kernel/embedding.d.ts +1 -1
- package/dist/schemas/tables/kernel/embedding.js +12 -13
- package/dist/schemas/tables/kernel/intelligence.d.ts +5 -5
- package/dist/schemas/tables/kernel/intelligence.js +6 -5
- package/dist/schemas/tables/kernel/spine.d.ts +2 -2
- package/dist/schemas/tables/kernel/spine.js +2 -13
- package/dist/schemas/tables/kernel/workflow.d.ts +1 -1
- package/dist/schemas/tables/kernel/workflow.js +1 -1
- package/dist/schemas.values.js +23 -12
- package/package.json +1 -1
|
@@ -25,11 +25,12 @@ var crossProjectConnections = defineTable({
|
|
|
25
25
|
category: "intelligence",
|
|
26
26
|
shape: z.object({
|
|
27
27
|
sourceProjectId: z.string().optional(),
|
|
28
|
-
|
|
29
|
-
|
|
28
|
+
// globalId references (UUIDv7), resolved via by_globalId — not Convex Ids.
|
|
29
|
+
sourceTopicId: z.string().optional(),
|
|
30
|
+
sourceNodeId: z.string(),
|
|
30
31
|
targetProjectId: z.string().optional(),
|
|
31
|
-
targetTopicId:
|
|
32
|
-
targetNodeId:
|
|
32
|
+
targetTopicId: z.string().optional(),
|
|
33
|
+
targetNodeId: z.string(),
|
|
33
34
|
semanticSimilarity: z.number(),
|
|
34
35
|
matchSignals: z.object({
|
|
35
36
|
beliefTextSimilarity: z.number(),
|
|
@@ -44,7 +45,7 @@ var crossProjectConnections = defineTable({
|
|
|
44
45
|
suggestedWeight: z.number().optional(),
|
|
45
46
|
rationale: z.string(),
|
|
46
47
|
decision: z.enum(["pending", "accepted", "declined"]),
|
|
47
|
-
acceptedEdgeId:
|
|
48
|
+
acceptedEdgeId: z.string().optional(),
|
|
48
49
|
declineReason: z.string().optional(),
|
|
49
50
|
declineCategory: z.enum([
|
|
50
51
|
"not_relevant",
|
|
@@ -213,7 +213,7 @@ export declare const epistemicNodes: import("../../../dsl.js").TableContract<{
|
|
|
213
213
|
sourceType: z.ZodEnum<["human", "ai_extracted", "ai_generated", "imported", "system", "verified", "proprietary"]>;
|
|
214
214
|
externalSourceType: z.ZodOptional<z.ZodString>;
|
|
215
215
|
aiProvider: z.ZodOptional<z.ZodString>;
|
|
216
|
-
extractedFromNodeId: z.ZodOptional<
|
|
216
|
+
extractedFromNodeId: z.ZodOptional<z.ZodString>;
|
|
217
217
|
extractionModel: z.ZodOptional<z.ZodString>;
|
|
218
218
|
extractionPromptName: z.ZodOptional<z.ZodString>;
|
|
219
219
|
extractionPromptVersion: z.ZodOptional<z.ZodNumber>;
|
|
@@ -228,7 +228,7 @@ export declare const epistemicNodes: import("../../../dsl.js").TableContract<{
|
|
|
228
228
|
confidence: z.ZodOptional<z.ZodNumber>;
|
|
229
229
|
verificationStatus: z.ZodOptional<z.ZodEnum<["unverified", "human_verified", "ai_verified", "contradicted", "outdated"]>>;
|
|
230
230
|
status: z.ZodEnum<["active", "superseded", "archived", "deleted"]>;
|
|
231
|
-
supersededBy: z.ZodOptional<
|
|
231
|
+
supersededBy: z.ZodOptional<z.ZodString>;
|
|
232
232
|
topicId: z.ZodOptional<z.ZodString>;
|
|
233
233
|
projectId: z.ZodOptional<z.ZodString>;
|
|
234
234
|
createdBy: z.ZodString;
|
|
@@ -1,17 +1,6 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
|
|
3
3
|
// src/schemas/tables/kernel/spine.ts
|
|
4
|
-
var CONVEX_ID_TABLE = /* @__PURE__ */ Symbol.for("lucern.contracts.convexIdTable");
|
|
5
|
-
function idOf(table) {
|
|
6
|
-
const schema = z.string().brand();
|
|
7
|
-
Object.defineProperty(schema, CONVEX_ID_TABLE, {
|
|
8
|
-
configurable: false,
|
|
9
|
-
enumerable: false,
|
|
10
|
-
value: table,
|
|
11
|
-
writable: false
|
|
12
|
-
});
|
|
13
|
-
return schema;
|
|
14
|
-
}
|
|
15
4
|
|
|
16
5
|
// src/dsl/defineTable.ts
|
|
17
6
|
function defineTable(spec) {
|
|
@@ -6627,7 +6616,7 @@ var epistemicNodes = defineTable({
|
|
|
6627
6616
|
]),
|
|
6628
6617
|
externalSourceType: z.string().optional(),
|
|
6629
6618
|
aiProvider: z.string().optional(),
|
|
6630
|
-
extractedFromNodeId:
|
|
6619
|
+
extractedFromNodeId: z.string().optional(),
|
|
6631
6620
|
extractionModel: z.string().optional(),
|
|
6632
6621
|
extractionPromptName: z.string().optional(),
|
|
6633
6622
|
extractionPromptVersion: z.number().optional(),
|
|
@@ -6648,7 +6637,7 @@ var epistemicNodes = defineTable({
|
|
|
6648
6637
|
"outdated"
|
|
6649
6638
|
]).optional(),
|
|
6650
6639
|
status: z.enum(["active", "superseded", "archived", "deleted"]),
|
|
6651
|
-
supersededBy:
|
|
6640
|
+
supersededBy: z.string().optional(),
|
|
6652
6641
|
topicId: z.string().optional(),
|
|
6653
6642
|
projectId: z.string().optional(),
|
|
6654
6643
|
createdBy: z.string(),
|
|
@@ -19,7 +19,7 @@ export declare const workflowDefinitions: import("../../../dsl.js").TableContrac
|
|
|
19
19
|
}>;
|
|
20
20
|
export declare const workflowPullRequests: import("../../../dsl.js").TableContract<{
|
|
21
21
|
topicId: z.ZodOptional<z.ZodString>;
|
|
22
|
-
worktreeId:
|
|
22
|
+
worktreeId: z.ZodString;
|
|
23
23
|
status: z.ZodEnum<["pending_review", "changes_requested", "approved", "blocked"]>;
|
|
24
24
|
summary: z.ZodString;
|
|
25
25
|
reviewers: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
package/dist/schemas.values.js
CHANGED
|
@@ -1912,7 +1912,7 @@ var beliefVotes = defineTable({
|
|
|
1912
1912
|
"recorder"
|
|
1913
1913
|
]).optional(),
|
|
1914
1914
|
stakeholderGroupId: idOf("stakeholderGroups").optional(),
|
|
1915
|
-
beliefId:
|
|
1915
|
+
beliefId: z.string(),
|
|
1916
1916
|
domainCategory: z.string().optional(),
|
|
1917
1917
|
voteDirection: z.enum(["support", "oppose", "abstain", "uncertain"]),
|
|
1918
1918
|
confidence: z.number(),
|
|
@@ -2190,7 +2190,7 @@ var decisionRiskLedger = defineTable({
|
|
|
2190
2190
|
workspaceId: z.string().optional(),
|
|
2191
2191
|
riskType: z.string(),
|
|
2192
2192
|
riskDescription: z.string(),
|
|
2193
|
-
relatedBeliefId:
|
|
2193
|
+
relatedBeliefId: z.string().optional(),
|
|
2194
2194
|
probabilityBand: z.enum(["very_low", "low", "medium", "high", "very_high"]),
|
|
2195
2195
|
impactBand: z.enum(["very_low", "low", "medium", "high", "very_high"]),
|
|
2196
2196
|
ownerPrincipalId: z.string().optional(),
|
|
@@ -2386,7 +2386,11 @@ var epistemicNodeEmbeddings = defineTable({
|
|
|
2386
2386
|
component: "kernel",
|
|
2387
2387
|
category: "embedding",
|
|
2388
2388
|
shape: z.object({
|
|
2389
|
-
|
|
2389
|
+
// Canonical UUIDv7 globalId of the embedded node (not a Convex Id). Every
|
|
2390
|
+
// cross-row reference in the graph is the node's globalId, resolved via the
|
|
2391
|
+
// `by_globalId` index — see resolveNodeGlobalId/resolveNodeDocSoft. This
|
|
2392
|
+
// keeps embeddings stable across extract/rebuild and carbon-copies.
|
|
2393
|
+
nodeId: z.string(),
|
|
2390
2394
|
tenantId: z.string().optional(),
|
|
2391
2395
|
workspaceId: z.string().optional(),
|
|
2392
2396
|
topicId: z.string().optional(),
|
|
@@ -2441,7 +2445,13 @@ var epistemicNodeEmbeddings = defineTable({
|
|
|
2441
2445
|
name: "by_embedding",
|
|
2442
2446
|
vectorField: "embedding",
|
|
2443
2447
|
dimensions: 1024,
|
|
2444
|
-
filterFields: [
|
|
2448
|
+
filterFields: [
|
|
2449
|
+
"nodeType",
|
|
2450
|
+
"createdBy",
|
|
2451
|
+
"topicId",
|
|
2452
|
+
"tenantId",
|
|
2453
|
+
"workspaceId"
|
|
2454
|
+
]
|
|
2445
2455
|
}
|
|
2446
2456
|
]
|
|
2447
2457
|
});
|
|
@@ -3187,11 +3197,12 @@ var crossProjectConnections = defineTable({
|
|
|
3187
3197
|
category: "intelligence",
|
|
3188
3198
|
shape: z.object({
|
|
3189
3199
|
sourceProjectId: z.string().optional(),
|
|
3190
|
-
|
|
3191
|
-
|
|
3200
|
+
// globalId references (UUIDv7), resolved via by_globalId — not Convex Ids.
|
|
3201
|
+
sourceTopicId: z.string().optional(),
|
|
3202
|
+
sourceNodeId: z.string(),
|
|
3192
3203
|
targetProjectId: z.string().optional(),
|
|
3193
|
-
targetTopicId:
|
|
3194
|
-
targetNodeId:
|
|
3204
|
+
targetTopicId: z.string().optional(),
|
|
3205
|
+
targetNodeId: z.string(),
|
|
3195
3206
|
semanticSimilarity: z.number(),
|
|
3196
3207
|
matchSignals: z.object({
|
|
3197
3208
|
beliefTextSimilarity: z.number(),
|
|
@@ -3206,7 +3217,7 @@ var crossProjectConnections = defineTable({
|
|
|
3206
3217
|
suggestedWeight: z.number().optional(),
|
|
3207
3218
|
rationale: z.string(),
|
|
3208
3219
|
decision: z.enum(["pending", "accepted", "declined"]),
|
|
3209
|
-
acceptedEdgeId:
|
|
3220
|
+
acceptedEdgeId: z.string().optional(),
|
|
3210
3221
|
declineReason: z.string().optional(),
|
|
3211
3222
|
declineCategory: z.enum([
|
|
3212
3223
|
"not_relevant",
|
|
@@ -10686,7 +10697,7 @@ var epistemicNodes = defineTable({
|
|
|
10686
10697
|
]),
|
|
10687
10698
|
externalSourceType: z.string().optional(),
|
|
10688
10699
|
aiProvider: z.string().optional(),
|
|
10689
|
-
extractedFromNodeId:
|
|
10700
|
+
extractedFromNodeId: z.string().optional(),
|
|
10690
10701
|
extractionModel: z.string().optional(),
|
|
10691
10702
|
extractionPromptName: z.string().optional(),
|
|
10692
10703
|
extractionPromptVersion: z.number().optional(),
|
|
@@ -10707,7 +10718,7 @@ var epistemicNodes = defineTable({
|
|
|
10707
10718
|
"outdated"
|
|
10708
10719
|
]).optional(),
|
|
10709
10720
|
status: z.enum(["active", "superseded", "archived", "deleted"]),
|
|
10710
|
-
supersededBy:
|
|
10721
|
+
supersededBy: z.string().optional(),
|
|
10711
10722
|
topicId: z.string().optional(),
|
|
10712
10723
|
projectId: z.string().optional(),
|
|
10713
10724
|
createdBy: z.string(),
|
|
@@ -11129,7 +11140,7 @@ var workflowPullRequests = defineTable({
|
|
|
11129
11140
|
category: "workflow",
|
|
11130
11141
|
shape: z.object({
|
|
11131
11142
|
topicId: z.string().optional(),
|
|
11132
|
-
worktreeId:
|
|
11143
|
+
worktreeId: z.string(),
|
|
11133
11144
|
status: z.enum([
|
|
11134
11145
|
"pending_review",
|
|
11135
11146
|
"changes_requested",
|