@nicia-ai/typegraph 0.26.0 → 0.27.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/dist/{chunk-3W6AIFT2.js → chunk-X53YKGHR.js} +74 -8
- package/dist/chunk-X53YKGHR.js.map +1 -0
- package/dist/{chunk-4TJI44WP.cjs → chunk-ZGEMI7MJ.cjs} +75 -7
- package/dist/chunk-ZGEMI7MJ.cjs.map +1 -0
- package/dist/index.cjs +83 -61
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +4 -4
- package/dist/index.d.ts +4 -4
- package/dist/index.js +25 -4
- package/dist/index.js.map +1 -1
- package/dist/interchange/index.d.cts +2 -2
- package/dist/interchange/index.d.ts +2 -2
- package/dist/{manager-Aqzmztkb.d.cts → manager-CWa9cgwb.d.cts} +34 -10
- package/dist/{manager-C3LxzPcX.d.ts → manager-Cfcb2sJL.d.ts} +34 -10
- package/dist/profiler/index.d.cts +2 -2
- package/dist/profiler/index.d.ts +2 -2
- package/dist/schema/index.cjs +28 -24
- package/dist/schema/index.d.cts +2 -2
- package/dist/schema/index.d.ts +2 -2
- package/dist/schema/index.js +2 -2
- package/dist/{store-CiS_AGNH.d.ts → store-C57kdvAa.d.ts} +44 -2
- package/dist/{store-DbQLsSor.d.cts → store-Ojf0NOKk.d.cts} +44 -2
- package/package.json +1 -1
- package/dist/chunk-3W6AIFT2.js.map +0 -1
- package/dist/chunk-4TJI44WP.cjs.map +0 -1
package/dist/index.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var chunkHTGDWIDE_cjs = require('./chunk-HTGDWIDE.cjs');
|
|
4
|
-
var
|
|
4
|
+
var chunkZGEMI7MJ_cjs = require('./chunk-ZGEMI7MJ.cjs');
|
|
5
5
|
var chunkWFUN6DCM_cjs = require('./chunk-WFUN6DCM.cjs');
|
|
6
6
|
var chunk4FJVSF3K_cjs = require('./chunk-4FJVSF3K.cjs');
|
|
7
7
|
var chunkPYJOBZR3_cjs = require('./chunk-PYJOBZR3.cjs');
|
|
@@ -28,7 +28,7 @@ function metaEdge(name, options = {}) {
|
|
|
28
28
|
description: options.description
|
|
29
29
|
};
|
|
30
30
|
return Object.freeze({
|
|
31
|
-
[
|
|
31
|
+
[chunkZGEMI7MJ_cjs.META_EDGE_BRAND]: true,
|
|
32
32
|
name,
|
|
33
33
|
properties
|
|
34
34
|
});
|
|
@@ -4298,7 +4298,7 @@ function planRemovals(graph, names) {
|
|
|
4298
4298
|
if (namesSet.size === 0) {
|
|
4299
4299
|
return { document, removedNodeKinds: [], removedEdgeKinds: [] };
|
|
4300
4300
|
}
|
|
4301
|
-
const { nodes: runtimeNodeNames, edges: runtimeEdgeNames } =
|
|
4301
|
+
const { nodes: runtimeNodeNames, edges: runtimeEdgeNames } = chunkZGEMI7MJ_cjs.extensionKindNames(document);
|
|
4302
4302
|
const compileTimeNodeNames = new Set(
|
|
4303
4303
|
Object.keys(graph.nodes).filter((name) => !runtimeNodeNames.has(name))
|
|
4304
4304
|
);
|
|
@@ -4398,8 +4398,8 @@ function planRemovals(graph, names) {
|
|
|
4398
4398
|
function stripGraphExtension(graph) {
|
|
4399
4399
|
const document = graph.extension;
|
|
4400
4400
|
if (document === void 0) return graph;
|
|
4401
|
-
const { nodes: runtimeNodeNames, edges: runtimeEdgeNames } =
|
|
4402
|
-
const runtimeOntologyKeys =
|
|
4401
|
+
const { nodes: runtimeNodeNames, edges: runtimeEdgeNames } = chunkZGEMI7MJ_cjs.extensionKindNames(document);
|
|
4402
|
+
const runtimeOntologyKeys = chunkZGEMI7MJ_cjs.buildGraphExtensionOntologyKeySet(document);
|
|
4403
4403
|
const compileNodes = {};
|
|
4404
4404
|
for (const [name, registration] of Object.entries(graph.nodes)) {
|
|
4405
4405
|
if (runtimeNodeNames.has(name)) continue;
|
|
@@ -4411,7 +4411,7 @@ function stripGraphExtension(graph) {
|
|
|
4411
4411
|
compileEdges[name] = registration;
|
|
4412
4412
|
}
|
|
4413
4413
|
const compileOntology = graph.ontology.filter(
|
|
4414
|
-
(relation) => !runtimeOntologyKeys.has(
|
|
4414
|
+
(relation) => !runtimeOntologyKeys.has(chunkZGEMI7MJ_cjs.compileTimeOntologyKey(relation))
|
|
4415
4415
|
);
|
|
4416
4416
|
const compileIndexes = (graph.indexes ?? []).filter(
|
|
4417
4417
|
(index) => index.origin !== "runtime"
|
|
@@ -4451,13 +4451,13 @@ function buildCompileTimeReferentIndex(graph, runtimeEdgeNames) {
|
|
|
4451
4451
|
append(endpoint.kind, referent);
|
|
4452
4452
|
}
|
|
4453
4453
|
}
|
|
4454
|
-
const runtimeOntologyKeys =
|
|
4454
|
+
const runtimeOntologyKeys = chunkZGEMI7MJ_cjs.buildGraphExtensionOntologyKeySet(
|
|
4455
4455
|
graph.extension
|
|
4456
4456
|
);
|
|
4457
4457
|
for (const relation of graph.ontology) {
|
|
4458
|
-
if (runtimeOntologyKeys.has(
|
|
4459
|
-
const fromName =
|
|
4460
|
-
const toName =
|
|
4458
|
+
if (runtimeOntologyKeys.has(chunkZGEMI7MJ_cjs.compileTimeOntologyKey(relation))) continue;
|
|
4459
|
+
const fromName = chunkZGEMI7MJ_cjs.getTypeName(relation.from);
|
|
4460
|
+
const toName = chunkZGEMI7MJ_cjs.getTypeName(relation.to);
|
|
4461
4461
|
const referent = {
|
|
4462
4462
|
type: "compile-time-ontology",
|
|
4463
4463
|
name: `${relation.metaEdge.name}(${fromName}, ${toName})`
|
|
@@ -9996,8 +9996,8 @@ function createQueryBuilder(graphId, registry, options) {
|
|
|
9996
9996
|
function buildKindRegistry(graph) {
|
|
9997
9997
|
const nodeTypes = extractNodeTypes(graph);
|
|
9998
9998
|
const edgeTypes = extractEdgeTypes(graph);
|
|
9999
|
-
const closures = graph.ontology.length > 0 ?
|
|
10000
|
-
return new
|
|
9999
|
+
const closures = graph.ontology.length > 0 ? chunkZGEMI7MJ_cjs.computeClosuresFromOntology(graph.ontology) : chunkZGEMI7MJ_cjs.createEmptyClosures();
|
|
10000
|
+
return new chunkZGEMI7MJ_cjs.KindRegistry(nodeTypes, edgeTypes, closures);
|
|
10001
10001
|
}
|
|
10002
10002
|
function extractNodeTypes(graph) {
|
|
10003
10003
|
const result = /* @__PURE__ */ new Map();
|
|
@@ -10992,7 +10992,7 @@ function createEdgeCollectionsProxy(graph, graphId, registry, backend, operation
|
|
|
10992
10992
|
// src/store/introspect.ts
|
|
10993
10993
|
function introspectSchema(graph, context) {
|
|
10994
10994
|
const extension = graph.extension;
|
|
10995
|
-
const { nodes: runtimeNodeNames, edges: runtimeEdgeNames } =
|
|
10995
|
+
const { nodes: runtimeNodeNames, edges: runtimeEdgeNames } = chunkZGEMI7MJ_cjs.extensionKindNames(extension);
|
|
10996
10996
|
const deprecated = graph.deprecatedKinds;
|
|
10997
10997
|
const kinds = [];
|
|
10998
10998
|
for (const [name, registration] of Object.entries(graph.nodes)) {
|
|
@@ -11003,7 +11003,7 @@ function introspectSchema(graph, context) {
|
|
|
11003
11003
|
description: reg.type.description,
|
|
11004
11004
|
annotations: reg.type.annotations,
|
|
11005
11005
|
deprecated: deprecated.has(name),
|
|
11006
|
-
properties:
|
|
11006
|
+
properties: chunkZGEMI7MJ_cjs.serializeSchemaProperties(reg.type.schema),
|
|
11007
11007
|
unique: (reg.unique ?? []).map((constraint) => ({
|
|
11008
11008
|
name: constraint.name,
|
|
11009
11009
|
fields: [...constraint.fields],
|
|
@@ -11024,17 +11024,17 @@ function introspectSchema(graph, context) {
|
|
|
11024
11024
|
to: reg.to.map((entry2) => entry2.kind),
|
|
11025
11025
|
cardinality: reg.cardinality ?? "many",
|
|
11026
11026
|
endpointExistence: reg.endpointExistence ?? "notDeleted",
|
|
11027
|
-
properties:
|
|
11027
|
+
properties: chunkZGEMI7MJ_cjs.serializeSchemaProperties(edgeType.schema),
|
|
11028
11028
|
annotations: edgeType.annotations,
|
|
11029
11029
|
deprecated: deprecated.has(name)
|
|
11030
11030
|
});
|
|
11031
11031
|
}
|
|
11032
|
-
const runtimeOntologyKeys =
|
|
11032
|
+
const runtimeOntologyKeys = chunkZGEMI7MJ_cjs.buildGraphExtensionOntologyKeySet(extension);
|
|
11033
11033
|
const ontology = graph.ontology.map((relation) => ({
|
|
11034
11034
|
metaEdge: relation.metaEdge.name,
|
|
11035
|
-
from:
|
|
11036
|
-
to:
|
|
11037
|
-
origin: runtimeOntologyKeys.has(
|
|
11035
|
+
from: chunkZGEMI7MJ_cjs.getTypeName(relation.from),
|
|
11036
|
+
to: chunkZGEMI7MJ_cjs.getTypeName(relation.to),
|
|
11037
|
+
origin: runtimeOntologyKeys.has(chunkZGEMI7MJ_cjs.compileTimeOntologyKey(relation)) ? "runtime" : "compile-time"
|
|
11038
11038
|
}));
|
|
11039
11039
|
return {
|
|
11040
11040
|
graphId: context.graphId,
|
|
@@ -11429,14 +11429,14 @@ async function reconcilePendingRemovals(context) {
|
|
|
11429
11429
|
const reconciliations = [];
|
|
11430
11430
|
const stopAtVersion = marker ?? 1;
|
|
11431
11431
|
let currentRow = activeRow;
|
|
11432
|
-
let currentSchema =
|
|
11432
|
+
let currentSchema = chunkZGEMI7MJ_cjs.parseSerializedSchema(activeRow.schema_doc);
|
|
11433
11433
|
while (currentRow.version > stopAtVersion) {
|
|
11434
11434
|
const priorRow = await backend.getSchemaVersion(
|
|
11435
11435
|
graphId,
|
|
11436
11436
|
currentRow.version - 1
|
|
11437
11437
|
);
|
|
11438
11438
|
if (priorRow === void 0) break;
|
|
11439
|
-
const priorSchema =
|
|
11439
|
+
const priorSchema = chunkZGEMI7MJ_cjs.parseSerializedSchema(priorRow.schema_doc);
|
|
11440
11440
|
for (const entity of ENTITY_KINDS) {
|
|
11441
11441
|
const priorEntries = priorSchema[entity === "node" ? "nodes" : "edges"];
|
|
11442
11442
|
const currentEntries = currentSchema[entity === "node" ? "nodes" : "edges"];
|
|
@@ -11952,7 +11952,7 @@ async function validateAndPrepareEdgeCreate(ctx, input, id, backend) {
|
|
|
11952
11952
|
nodeId: input.toId
|
|
11953
11953
|
});
|
|
11954
11954
|
}
|
|
11955
|
-
const validatedProps =
|
|
11955
|
+
const validatedProps = chunkZGEMI7MJ_cjs.validateEdgeProps(edgeKind.schema, input.props, {
|
|
11956
11956
|
kind,
|
|
11957
11957
|
operation: "create"
|
|
11958
11958
|
});
|
|
@@ -12102,7 +12102,7 @@ async function executeEdgeUpdate(ctx, input, backend) {
|
|
|
12102
12102
|
const edgeKind = registration.type;
|
|
12103
12103
|
const existingProps = JSON.parse(existing.props);
|
|
12104
12104
|
const mergedProps = { ...existingProps, ...input.props };
|
|
12105
|
-
const validatedProps =
|
|
12105
|
+
const validatedProps = chunkZGEMI7MJ_cjs.validateEdgeProps(edgeKind.schema, mergedProps, {
|
|
12106
12106
|
kind: existing.kind,
|
|
12107
12107
|
operation: "update",
|
|
12108
12108
|
id
|
|
@@ -12128,7 +12128,7 @@ async function executeEdgeUpsertUpdate(ctx, input, backend, options) {
|
|
|
12128
12128
|
const edgeKind = registration.type;
|
|
12129
12129
|
const existingProps = JSON.parse(existing.props);
|
|
12130
12130
|
const mergedProps = { ...existingProps, ...input.props };
|
|
12131
|
-
const validatedProps =
|
|
12131
|
+
const validatedProps = chunkZGEMI7MJ_cjs.validateEdgeProps(edgeKind.schema, mergedProps, {
|
|
12132
12132
|
kind: existing.kind,
|
|
12133
12133
|
operation: "update",
|
|
12134
12134
|
id
|
|
@@ -12285,7 +12285,7 @@ async function executeEdgeGetOrCreateByEndpoints(ctx, kind, fromKind, fromId, to
|
|
|
12285
12285
|
const matchOn = options?.matchOn ?? [];
|
|
12286
12286
|
const registration = getEdgeRegistration(ctx.graph, kind);
|
|
12287
12287
|
const edgeKind = registration.type;
|
|
12288
|
-
const validatedProps =
|
|
12288
|
+
const validatedProps = chunkZGEMI7MJ_cjs.validateEdgeProps(edgeKind.schema, props, {
|
|
12289
12289
|
kind,
|
|
12290
12290
|
operation: "create"
|
|
12291
12291
|
});
|
|
@@ -12367,7 +12367,7 @@ async function executeEdgeBulkGetOrCreateByEndpoints(ctx, kind, items, backend,
|
|
|
12367
12367
|
validateMatchOnFields(edgeKind.schema, matchOn, kind);
|
|
12368
12368
|
const validated = [];
|
|
12369
12369
|
for (const item of items) {
|
|
12370
|
-
const validatedProps =
|
|
12370
|
+
const validatedProps = chunkZGEMI7MJ_cjs.validateEdgeProps(edgeKind.schema, item.props, {
|
|
12371
12371
|
kind,
|
|
12372
12372
|
operation: "create"
|
|
12373
12373
|
});
|
|
@@ -13014,7 +13014,7 @@ async function validateAndPrepareNodeCreate(ctx, input, id, backend) {
|
|
|
13014
13014
|
const kind = input.kind;
|
|
13015
13015
|
const registration = getNodeRegistration(ctx.graph, kind);
|
|
13016
13016
|
const nodeKind = registration.type;
|
|
13017
|
-
const validatedProps =
|
|
13017
|
+
const validatedProps = chunkZGEMI7MJ_cjs.validateNodeProps(nodeKind.schema, input.props, {
|
|
13018
13018
|
kind,
|
|
13019
13019
|
operation: "create"
|
|
13020
13020
|
});
|
|
@@ -13088,7 +13088,7 @@ async function performNodeUpdate(ctx, input, backend, options) {
|
|
|
13088
13088
|
const existingProps = JSON.parse(existing.props);
|
|
13089
13089
|
const mergedProps = { ...existingProps, ...input.props };
|
|
13090
13090
|
const nodeKind = registration.type;
|
|
13091
|
-
const validatedProps =
|
|
13091
|
+
const validatedProps = chunkZGEMI7MJ_cjs.validateNodeProps(nodeKind.schema, mergedProps, {
|
|
13092
13092
|
kind,
|
|
13093
13093
|
operation: "update",
|
|
13094
13094
|
id
|
|
@@ -13361,7 +13361,7 @@ async function executeNodeGetOrCreateByConstraint(ctx, kind, constraintName, pro
|
|
|
13361
13361
|
const ifExists = options?.ifExists ?? "return";
|
|
13362
13362
|
const registration = getNodeRegistration(ctx.graph, kind);
|
|
13363
13363
|
const nodeKind = registration.type;
|
|
13364
|
-
const validatedProps =
|
|
13364
|
+
const validatedProps = chunkZGEMI7MJ_cjs.validateNodeProps(nodeKind.schema, props, {
|
|
13365
13365
|
kind,
|
|
13366
13366
|
operation: "create"
|
|
13367
13367
|
});
|
|
@@ -13433,7 +13433,7 @@ async function executeNodeGetOrCreateByConstraint(ctx, kind, constraintName, pro
|
|
|
13433
13433
|
async function executeNodeFindByConstraint(ctx, kind, constraintName, props, backend) {
|
|
13434
13434
|
const registration = getNodeRegistration(ctx.graph, kind);
|
|
13435
13435
|
const nodeKind = registration.type;
|
|
13436
|
-
const validatedProps =
|
|
13436
|
+
const validatedProps = chunkZGEMI7MJ_cjs.validateNodeProps(nodeKind.schema, props, {
|
|
13437
13437
|
kind,
|
|
13438
13438
|
operation: "create"
|
|
13439
13439
|
});
|
|
@@ -13470,7 +13470,7 @@ async function executeNodeFindByConstraint(ctx, kind, constraintName, props, bac
|
|
|
13470
13470
|
function validateAndComputeKeys(nodeKind, kind, constraint, items) {
|
|
13471
13471
|
const validated = [];
|
|
13472
13472
|
for (const item of items) {
|
|
13473
|
-
const validatedProps =
|
|
13473
|
+
const validatedProps = chunkZGEMI7MJ_cjs.validateNodeProps(nodeKind.schema, item.props, {
|
|
13474
13474
|
kind,
|
|
13475
13475
|
operation: "create"
|
|
13476
13476
|
});
|
|
@@ -14982,7 +14982,7 @@ var Store = class _Store {
|
|
|
14982
14982
|
*/
|
|
14983
14983
|
async evolve(extension, options) {
|
|
14984
14984
|
const { activeRow, baseline } = await this.#loadCaughtUp("evolve");
|
|
14985
|
-
const merged =
|
|
14985
|
+
const merged = chunkZGEMI7MJ_cjs.mergeGraphExtension(baseline, extension);
|
|
14986
14986
|
if (merged === baseline) {
|
|
14987
14987
|
if (baseline === this.#graph) {
|
|
14988
14988
|
if (options?.ref !== void 0) options.ref.current = this;
|
|
@@ -15018,7 +15018,7 @@ var Store = class _Store {
|
|
|
15018
15018
|
);
|
|
15019
15019
|
if (error !== void 0) throw error;
|
|
15020
15020
|
}
|
|
15021
|
-
const committed = await
|
|
15021
|
+
const committed = await chunkZGEMI7MJ_cjs.commitNewSchemaVersion(
|
|
15022
15022
|
this.#backend,
|
|
15023
15023
|
merged,
|
|
15024
15024
|
activeRow.version
|
|
@@ -15170,9 +15170,9 @@ var Store = class _Store {
|
|
|
15170
15170
|
);
|
|
15171
15171
|
}
|
|
15172
15172
|
const compileTimeGraph = stripGraphExtension(this.#graph);
|
|
15173
|
-
const merged = plan.document === void 0 ? compileTimeGraph :
|
|
15174
|
-
const finalGraph =
|
|
15175
|
-
const committedRow = await
|
|
15173
|
+
const merged = plan.document === void 0 ? compileTimeGraph : chunkZGEMI7MJ_cjs.mergeGraphExtension(compileTimeGraph, plan.document);
|
|
15174
|
+
const finalGraph = chunkZGEMI7MJ_cjs.applyDeprecatedKinds(merged, baseline.deprecatedKinds);
|
|
15175
|
+
const committedRow = await chunkZGEMI7MJ_cjs.commitNewSchemaVersion(
|
|
15176
15176
|
this.#backend,
|
|
15177
15177
|
finalGraph,
|
|
15178
15178
|
activeRow.version
|
|
@@ -15255,8 +15255,8 @@ var Store = class _Store {
|
|
|
15255
15255
|
schemaMetadataFromRow(activeRow)
|
|
15256
15256
|
);
|
|
15257
15257
|
}
|
|
15258
|
-
const merged =
|
|
15259
|
-
const result = await
|
|
15258
|
+
const merged = chunkZGEMI7MJ_cjs.applyDeprecatedKinds(baseline, nextSet);
|
|
15259
|
+
const result = await chunkZGEMI7MJ_cjs.ensureSchema(this.#backend, merged, {
|
|
15260
15260
|
preloaded: { activeRow, storedSchema },
|
|
15261
15261
|
autoMigrate: true
|
|
15262
15262
|
});
|
|
@@ -15265,8 +15265,8 @@ var Store = class _Store {
|
|
|
15265
15265
|
}
|
|
15266
15266
|
#catchUpToStored(storedSchema) {
|
|
15267
15267
|
const compileTimeGraph = stripGraphExtension(this.#graph);
|
|
15268
|
-
const withGraphExtension = storedSchema.extension === void 0 ? compileTimeGraph :
|
|
15269
|
-
return
|
|
15268
|
+
const withGraphExtension = storedSchema.extension === void 0 ? compileTimeGraph : chunkZGEMI7MJ_cjs.mergeGraphExtension(compileTimeGraph, storedSchema.extension);
|
|
15269
|
+
return chunkZGEMI7MJ_cjs.applyDeprecatedKinds(
|
|
15270
15270
|
withGraphExtension,
|
|
15271
15271
|
storedSchema.deprecatedKinds
|
|
15272
15272
|
);
|
|
@@ -15284,7 +15284,7 @@ var Store = class _Store {
|
|
|
15284
15284
|
* serializes the actual commit.
|
|
15285
15285
|
*/
|
|
15286
15286
|
async #loadCaughtUp(verb) {
|
|
15287
|
-
const activeRow = await
|
|
15287
|
+
const activeRow = await chunkZGEMI7MJ_cjs.loadActiveSchemaWithBootstrap(
|
|
15288
15288
|
this.#backend,
|
|
15289
15289
|
this.graphId
|
|
15290
15290
|
);
|
|
@@ -15295,7 +15295,7 @@ var Store = class _Store {
|
|
|
15295
15295
|
{ code }
|
|
15296
15296
|
);
|
|
15297
15297
|
}
|
|
15298
|
-
const storedSchema =
|
|
15298
|
+
const storedSchema = chunkZGEMI7MJ_cjs.parseSerializedSchema(activeRow.schema_doc);
|
|
15299
15299
|
const baseline = this.#catchUpToStored(storedSchema);
|
|
15300
15300
|
return { activeRow, storedSchema, baseline };
|
|
15301
15301
|
}
|
|
@@ -15461,17 +15461,24 @@ function schemaMetadataForResult(activeRow, result) {
|
|
|
15461
15461
|
}
|
|
15462
15462
|
return schemaMetadataFromRow(activeRow);
|
|
15463
15463
|
}
|
|
15464
|
+
async function materializeRuntimeContributions(backend, graphId) {
|
|
15465
|
+
if (backend.ensureRuntimeContributions) {
|
|
15466
|
+
await backend.ensureRuntimeContributions(graphId);
|
|
15467
|
+
return;
|
|
15468
|
+
}
|
|
15469
|
+
await backend.ensureFulltextTable?.(graphId);
|
|
15470
|
+
}
|
|
15464
15471
|
async function createStoreWithSchema(graph, backend, options) {
|
|
15465
15472
|
const {
|
|
15466
15473
|
graph: merged,
|
|
15467
15474
|
activeRow,
|
|
15468
15475
|
storedSchema
|
|
15469
|
-
} = await
|
|
15470
|
-
const result = await
|
|
15476
|
+
} = await chunkZGEMI7MJ_cjs.loadAndMergeGraphExtensionDocument(backend, graph);
|
|
15477
|
+
const result = await chunkZGEMI7MJ_cjs.ensureSchema(backend, merged, {
|
|
15471
15478
|
...options,
|
|
15472
15479
|
preloaded: { activeRow, storedSchema }
|
|
15473
15480
|
});
|
|
15474
|
-
await backend
|
|
15481
|
+
await materializeRuntimeContributions(backend, merged.id);
|
|
15475
15482
|
const store = new Store(
|
|
15476
15483
|
merged,
|
|
15477
15484
|
backend,
|
|
@@ -15480,70 +15487,84 @@ async function createStoreWithSchema(graph, backend, options) {
|
|
|
15480
15487
|
);
|
|
15481
15488
|
return [store, result];
|
|
15482
15489
|
}
|
|
15490
|
+
async function createVerifiedStore(graph, backend, options) {
|
|
15491
|
+
const {
|
|
15492
|
+
graph: merged,
|
|
15493
|
+
activeRow,
|
|
15494
|
+
result
|
|
15495
|
+
} = await chunkZGEMI7MJ_cjs.loadAndVerifyGraph(backend, graph);
|
|
15496
|
+
const store = new Store(
|
|
15497
|
+
merged,
|
|
15498
|
+
backend,
|
|
15499
|
+
options,
|
|
15500
|
+
schemaMetadataFromRow(activeRow)
|
|
15501
|
+
);
|
|
15502
|
+
return [store, result];
|
|
15503
|
+
}
|
|
15483
15504
|
|
|
15484
15505
|
Object.defineProperty(exports, "broader", {
|
|
15485
15506
|
enumerable: true,
|
|
15486
|
-
get: function () { return
|
|
15507
|
+
get: function () { return chunkZGEMI7MJ_cjs.broader; }
|
|
15487
15508
|
});
|
|
15488
15509
|
Object.defineProperty(exports, "core", {
|
|
15489
15510
|
enumerable: true,
|
|
15490
|
-
get: function () { return
|
|
15511
|
+
get: function () { return chunkZGEMI7MJ_cjs.core; }
|
|
15491
15512
|
});
|
|
15492
15513
|
Object.defineProperty(exports, "defineEdge", {
|
|
15493
15514
|
enumerable: true,
|
|
15494
|
-
get: function () { return
|
|
15515
|
+
get: function () { return chunkZGEMI7MJ_cjs.defineEdge; }
|
|
15495
15516
|
});
|
|
15496
15517
|
Object.defineProperty(exports, "defineNode", {
|
|
15497
15518
|
enumerable: true,
|
|
15498
|
-
get: function () { return
|
|
15519
|
+
get: function () { return chunkZGEMI7MJ_cjs.defineNode; }
|
|
15499
15520
|
});
|
|
15500
15521
|
Object.defineProperty(exports, "differentFrom", {
|
|
15501
15522
|
enumerable: true,
|
|
15502
|
-
get: function () { return
|
|
15523
|
+
get: function () { return chunkZGEMI7MJ_cjs.differentFrom; }
|
|
15503
15524
|
});
|
|
15504
15525
|
Object.defineProperty(exports, "disjointWith", {
|
|
15505
15526
|
enumerable: true,
|
|
15506
|
-
get: function () { return
|
|
15527
|
+
get: function () { return chunkZGEMI7MJ_cjs.disjointWith; }
|
|
15507
15528
|
});
|
|
15508
15529
|
Object.defineProperty(exports, "equivalentTo", {
|
|
15509
15530
|
enumerable: true,
|
|
15510
|
-
get: function () { return
|
|
15531
|
+
get: function () { return chunkZGEMI7MJ_cjs.equivalentTo; }
|
|
15511
15532
|
});
|
|
15512
15533
|
Object.defineProperty(exports, "hasPart", {
|
|
15513
15534
|
enumerable: true,
|
|
15514
|
-
get: function () { return
|
|
15535
|
+
get: function () { return chunkZGEMI7MJ_cjs.hasPart; }
|
|
15515
15536
|
});
|
|
15516
15537
|
Object.defineProperty(exports, "implies", {
|
|
15517
15538
|
enumerable: true,
|
|
15518
|
-
get: function () { return
|
|
15539
|
+
get: function () { return chunkZGEMI7MJ_cjs.implies; }
|
|
15519
15540
|
});
|
|
15520
15541
|
Object.defineProperty(exports, "inverseOf", {
|
|
15521
15542
|
enumerable: true,
|
|
15522
|
-
get: function () { return
|
|
15543
|
+
get: function () { return chunkZGEMI7MJ_cjs.inverseOf; }
|
|
15523
15544
|
});
|
|
15524
15545
|
Object.defineProperty(exports, "isMetaEdge", {
|
|
15525
15546
|
enumerable: true,
|
|
15526
|
-
get: function () { return
|
|
15547
|
+
get: function () { return chunkZGEMI7MJ_cjs.isMetaEdge; }
|
|
15527
15548
|
});
|
|
15528
15549
|
Object.defineProperty(exports, "narrower", {
|
|
15529
15550
|
enumerable: true,
|
|
15530
|
-
get: function () { return
|
|
15551
|
+
get: function () { return chunkZGEMI7MJ_cjs.narrower; }
|
|
15531
15552
|
});
|
|
15532
15553
|
Object.defineProperty(exports, "partOf", {
|
|
15533
15554
|
enumerable: true,
|
|
15534
|
-
get: function () { return
|
|
15555
|
+
get: function () { return chunkZGEMI7MJ_cjs.partOf; }
|
|
15535
15556
|
});
|
|
15536
15557
|
Object.defineProperty(exports, "relatedTo", {
|
|
15537
15558
|
enumerable: true,
|
|
15538
|
-
get: function () { return
|
|
15559
|
+
get: function () { return chunkZGEMI7MJ_cjs.relatedTo; }
|
|
15539
15560
|
});
|
|
15540
15561
|
Object.defineProperty(exports, "sameAs", {
|
|
15541
15562
|
enumerable: true,
|
|
15542
|
-
get: function () { return
|
|
15563
|
+
get: function () { return chunkZGEMI7MJ_cjs.sameAs; }
|
|
15543
15564
|
});
|
|
15544
15565
|
Object.defineProperty(exports, "subClassOf", {
|
|
15545
15566
|
enumerable: true,
|
|
15546
|
-
get: function () { return
|
|
15567
|
+
get: function () { return chunkZGEMI7MJ_cjs.subClassOf; }
|
|
15547
15568
|
});
|
|
15548
15569
|
Object.defineProperty(exports, "defineGraph", {
|
|
15549
15570
|
enumerable: true,
|
|
@@ -15834,6 +15855,7 @@ exports.createQueryBuilder = createQueryBuilder;
|
|
|
15834
15855
|
exports.createSqlSchema = createSqlSchema;
|
|
15835
15856
|
exports.createStore = createStore;
|
|
15836
15857
|
exports.createStoreWithSchema = createStoreWithSchema;
|
|
15858
|
+
exports.createVerifiedStore = createVerifiedStore;
|
|
15837
15859
|
exports.defineSubgraphProject = defineSubgraphProject;
|
|
15838
15860
|
exports.exists = exists;
|
|
15839
15861
|
exports.externalRef = externalRef;
|