@sixb/core 0.1.3 → 0.1.5
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/actions/index.d.ts +2 -2
- package/dist/actions/index.d.ts.map +1 -1
- package/dist/actions/index.js +17 -18
- package/dist/actions/index.js.map +1 -1
- package/dist/actions/read-facade.d.ts +10 -2
- package/dist/actions/read-facade.d.ts.map +1 -1
- package/dist/actions/types/context.d.ts +45 -2
- package/dist/actions/types/context.d.ts.map +1 -1
- package/dist/actions/worker.js +4 -4
- package/dist/actions/worker.js.map +1 -1
- package/dist/agents/context-compaction.d.ts +40 -0
- package/dist/agents/context-compaction.d.ts.map +1 -0
- package/dist/agents/ids.d.ts +2 -0
- package/dist/agents/ids.d.ts.map +1 -1
- package/dist/agents/index.d.ts +6 -5
- package/dist/agents/index.d.ts.map +1 -1
- package/dist/agents/index.js +42 -37
- package/dist/agents/index.js.map +1 -1
- package/dist/agents/streams.d.ts +17 -1
- package/dist/agents/streams.d.ts.map +1 -1
- package/dist/agents/streams.js +4 -2
- package/dist/agents/streams.js.map +1 -1
- package/dist/agents/types.d.ts +11 -0
- package/dist/agents/types.d.ts.map +1 -1
- package/dist/agents/validation.d.ts +1 -1
- package/dist/agents/validation.d.ts.map +1 -1
- package/dist/auth/index.js +7 -3
- package/dist/auth/index.js.map +1 -1
- package/dist/authorization/index.js +6 -2
- package/dist/authorization/index.js.map +1 -1
- package/dist/bootstrap/index.js +30 -31
- package/dist/bootstrap/index.js.map +1 -1
- package/dist/{chunk-d6y2wsfg.js → chunk-1q02e95s.js} +12 -7
- package/dist/{chunk-d6y2wsfg.js.map → chunk-1q02e95s.js.map} +4 -3
- package/dist/{chunk-c6cfqydk.js → chunk-4h947jd8.js} +1 -1
- package/dist/{chunk-gqdd7508.js → chunk-4rh2m6zg.js} +1 -1
- package/dist/{chunk-f1cyvnrk.js → chunk-6d5xdj1q.js} +259 -9
- package/dist/chunk-6d5xdj1q.js.map +14 -0
- package/dist/{chunk-fmx1sz2h.js → chunk-72q2y8hn.js} +3 -3
- package/dist/{chunk-fmx1sz2h.js.map → chunk-72q2y8hn.js.map} +3 -3
- package/dist/{chunk-ttba8x6z.js → chunk-78c6xvyr.js} +68 -3
- package/dist/chunk-78c6xvyr.js.map +15 -0
- package/dist/{chunk-wb4051cx.js → chunk-819wnjz8.js} +11 -5
- package/dist/chunk-819wnjz8.js.map +12 -0
- package/dist/{chunk-177ed2mp.js → chunk-84h6qhmp.js} +233 -97
- package/dist/{chunk-177ed2mp.js.map → chunk-84h6qhmp.js.map} +9 -9
- package/dist/{chunk-pxtrxm3p.js → chunk-a09jx26t.js} +1 -1
- package/dist/{chunk-bv41fmjn.js → chunk-am6eczah.js} +59 -22
- package/dist/{chunk-bv41fmjn.js.map → chunk-am6eczah.js.map} +8 -7
- package/dist/{chunk-zpw39qhj.js → chunk-dm72y8wt.js} +25 -2
- package/dist/chunk-dm72y8wt.js.map +10 -0
- package/dist/{chunk-kqxgf6kv.js → chunk-drjqm1aa.js} +16 -1
- package/dist/{chunk-kqxgf6kv.js.map → chunk-drjqm1aa.js.map} +3 -3
- package/dist/chunk-dysw7nsm.js.map +1 -1
- package/dist/{chunk-4p9rh7jj.js → chunk-ea73pzk7.js} +1 -1
- package/dist/{chunk-4aw0jwk0.js → chunk-f6erf2vv.js} +1 -1
- package/dist/{chunk-4z3n1dzt.js → chunk-f83ka50g.js} +131 -25
- package/dist/chunk-f83ka50g.js.map +23 -0
- package/dist/{chunk-c8bw2b6c.js → chunk-gadsm794.js} +2 -2
- package/dist/{chunk-1ywq4hzk.js → chunk-h6h91mfy.js} +8 -10
- package/dist/{chunk-1ywq4hzk.js.map → chunk-h6h91mfy.js.map} +2 -2
- package/dist/{chunk-n5x5y80a.js → chunk-nzw7sm3b.js} +2 -2
- package/dist/{chunk-63te770v.js → chunk-qewtks41.js} +8 -8
- package/dist/{chunk-63te770v.js.map → chunk-qewtks41.js.map} +2 -2
- package/dist/{chunk-261ag4t4.js → chunk-r0rry8dn.js} +3 -3
- package/dist/{chunk-88ppkr54.js → chunk-rte5sm3z.js} +26 -2
- package/dist/chunk-rte5sm3z.js.map +12 -0
- package/dist/chunk-t0jjkep3.js.map +1 -1
- package/dist/{chunk-ettb0cy4.js → chunk-tbv03sx2.js} +59 -29
- package/dist/{chunk-ettb0cy4.js.map → chunk-tbv03sx2.js.map} +5 -5
- package/dist/{chunk-d2adj15j.js → chunk-tkdscva6.js} +1 -1
- package/dist/{chunk-xmggaxg4.js → chunk-v0egge8b.js} +201 -38
- package/dist/{chunk-xmggaxg4.js.map → chunk-v0egge8b.js.map} +8 -6
- package/dist/{chunk-z8j83gzd.js → chunk-x2yw73hy.js} +1 -1
- package/dist/{chunk-qer6am8w.js → chunk-xdf9yswn.js} +1 -1
- package/dist/{chunk-3rsf30p4.js → chunk-z3ga9q5m.js} +18 -21
- package/dist/{chunk-3rsf30p4.js.map → chunk-z3ga9q5m.js.map} +4 -5
- package/dist/{chunk-km4rkj4t.js → chunk-zp2v2rv6.js} +3 -3
- package/dist/execution/agent.js +26 -27
- package/dist/execution/agent.js.map +1 -1
- package/dist/execution/primitive.js +26 -27
- package/dist/execution/primitive.js.map +2 -2
- package/dist/execution/request.js +27 -28
- package/dist/execution/request.js.map +2 -2
- package/dist/http/index.js +1 -1
- package/dist/index.d.ts +6 -5
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +54 -55
- package/dist/index.js.map +1 -1
- package/dist/lake-storage/types.d.ts +2 -1
- package/dist/lake-storage/types.d.ts.map +1 -1
- package/dist/materializer/index.js +15 -16
- package/dist/materializer/index.js.map +1 -1
- package/dist/models/index.d.ts +40 -0
- package/dist/models/index.d.ts.map +1 -0
- package/dist/objects/execution.d.ts +6 -1
- package/dist/objects/execution.d.ts.map +1 -1
- package/dist/objects/index.js +19 -20
- package/dist/objects/index.js.map +1 -1
- package/dist/objects/link/endpoints.d.ts.map +1 -1
- package/dist/objects/query/executor.d.ts +1 -0
- package/dist/objects/query/executor.d.ts.map +1 -1
- package/dist/objects/query/explain.d.ts +1 -0
- package/dist/objects/query/explain.d.ts.map +1 -1
- package/dist/objects/query/index.d.ts +3 -1
- package/dist/objects/query/index.d.ts.map +1 -1
- package/dist/objects/query/index.js +30 -5
- package/dist/objects/query/index.js.map +1 -1
- package/dist/objects/query/ir.d.ts +14 -1
- package/dist/objects/query/ir.d.ts.map +1 -1
- package/dist/objects/query/links.d.ts +25 -0
- package/dist/objects/query/links.d.ts.map +1 -0
- package/dist/objects/query/normalize.d.ts.map +1 -1
- package/dist/objects/query/planner.d.ts.map +1 -1
- package/dist/objects/query/validate.d.ts +1 -0
- package/dist/objects/query/validate.d.ts.map +1 -1
- package/dist/ontology/internal.d.ts +1 -1
- package/dist/ontology/internal.d.ts.map +1 -1
- package/dist/ontology/internal.js +14 -6
- package/dist/ontology/internal.js.map +3 -3
- package/dist/ontology/json-schema.d.ts +10 -0
- package/dist/ontology/json-schema.d.ts.map +1 -1
- package/dist/pipelines/index.js +15 -16
- package/dist/pipelines/index.js.map +1 -1
- package/dist/projections/builders.d.ts +33 -4
- package/dist/projections/builders.d.ts.map +1 -1
- package/dist/projections/index.d.ts +1 -1
- package/dist/projections/index.d.ts.map +1 -1
- package/dist/projections/internal.js +15 -16
- package/dist/projections/internal.js.map +1 -1
- package/dist/projections/run-dispatch.d.ts +1 -0
- package/dist/projections/run-dispatch.d.ts.map +1 -1
- package/dist/projections/types.d.ts +12 -9
- package/dist/projections/types.d.ts.map +1 -1
- package/dist/projections/validation.d.ts +6 -5
- package/dist/projections/validation.d.ts.map +1 -1
- package/dist/query.d.ts +2 -1
- package/dist/query.d.ts.map +1 -1
- package/dist/query.js +2 -2
- package/dist/runtime/create.d.ts +3 -0
- package/dist/runtime/create.d.ts.map +1 -1
- package/dist/runtime/definitions.d.ts +3 -0
- package/dist/runtime/definitions.d.ts.map +1 -1
- package/dist/runtime/host.d.ts +2 -0
- package/dist/runtime/host.d.ts.map +1 -1
- package/dist/runtime/resolve-definitions.d.ts +2 -0
- package/dist/runtime/resolve-definitions.d.ts.map +1 -1
- package/dist/storage/agents/in-memory.d.ts +4 -0
- package/dist/storage/agents/in-memory.d.ts.map +1 -1
- package/dist/storage/agents/provider.js +9 -5
- package/dist/storage/agents/provider.js.map +1 -1
- package/dist/storage/agents/types.d.ts +5 -0
- package/dist/storage/agents/types.d.ts.map +1 -1
- package/dist/storage/ai-cost/provider.js +1 -1
- package/dist/storage/ai-usage/in-memory.d.ts +2 -1
- package/dist/storage/ai-usage/in-memory.d.ts.map +1 -1
- package/dist/storage/ai-usage/index.d.ts +1 -1
- package/dist/storage/ai-usage/index.d.ts.map +1 -1
- package/dist/storage/ai-usage/types.d.ts +6 -0
- package/dist/storage/ai-usage/types.d.ts.map +1 -1
- package/dist/storage/index.d.ts +3 -2
- package/dist/storage/index.d.ts.map +1 -1
- package/dist/storage/index.js +19 -14
- package/dist/storage/index.js.map +1 -1
- package/dist/storage/objects/in-memory.d.ts +6 -3
- package/dist/storage/objects/in-memory.d.ts.map +1 -1
- package/dist/storage/objects/index.d.ts +3 -1
- package/dist/storage/objects/index.d.ts.map +1 -1
- package/dist/storage/objects/keys.d.ts +16 -0
- package/dist/storage/objects/keys.d.ts.map +1 -0
- package/dist/storage/objects/types.d.ts +33 -6
- package/dist/storage/objects/types.d.ts.map +1 -1
- package/dist/storage/ontology/provider.js +1 -1
- package/dist/storage/workflow-runs/provider.js +9 -5
- package/dist/storage/workflow-runs/provider.js.map +1 -1
- package/dist/syncs/index.js +15 -16
- package/dist/syncs/index.js.map +1 -1
- package/dist/testing/agent-storage-contract.d.ts.map +1 -1
- package/dist/testing/ai-usage-storage-contract.d.ts.map +1 -1
- package/dist/testing/effective-storage-contract.d.ts +1 -1
- package/dist/testing/effective-storage-contract.d.ts.map +1 -1
- package/dist/testing/index.js +455 -40
- package/dist/testing/index.js.map +7 -7
- package/dist/testing/lake-storage-contract.d.ts.map +1 -1
- package/dist/testing/object-query-contract.d.ts +1 -1
- package/dist/testing/object-query-contract.d.ts.map +1 -1
- package/dist/webhooks/internal.js +13 -14
- package/dist/webhooks/internal.js.map +2 -2
- package/dist/workflows/index.js +27 -28
- package/dist/workflows/index.js.map +1 -1
- package/package.json +1 -1
- package/src/actions/index.ts +10 -1
- package/src/actions/read-facade.ts +125 -3
- package/src/actions/types/context.ts +69 -2
- package/src/agents/builders.ts +3 -3
- package/src/agents/context-compaction.ts +261 -0
- package/src/agents/ids.ts +5 -0
- package/src/agents/index.ts +18 -9
- package/src/agents/streams.ts +56 -0
- package/src/agents/types.ts +12 -0
- package/src/agents/validation.ts +39 -5
- package/src/http/api-routes.ts +7 -7
- package/src/index.ts +19 -0
- package/src/lake-storage/types.ts +2 -1
- package/src/materializer/telemetry/append.ts +33 -16
- package/src/models/index.ts +71 -0
- package/src/objects/execution.ts +20 -0
- package/src/objects/link/endpoints.ts +2 -1
- package/src/objects/query/executor.ts +42 -11
- package/src/objects/query/explain.ts +11 -0
- package/src/objects/query/index.ts +6 -0
- package/src/objects/query/ir.ts +16 -0
- package/src/objects/query/links.ts +308 -0
- package/src/objects/query/normalize.ts +40 -1
- package/src/objects/query/planner.ts +5 -0
- package/src/objects/query/validate.ts +58 -2
- package/src/ontology/internal.ts +1 -1
- package/src/ontology/json-schema.ts +27 -5
- package/src/projections/builders.ts +220 -15
- package/src/projections/index.ts +1 -0
- package/src/projections/ownership.ts +5 -5
- package/src/projections/registry.ts +9 -3
- package/src/projections/revision.ts +31 -5
- package/src/projections/run-dispatch.ts +10 -1
- package/src/projections/types.ts +13 -9
- package/src/projections/validation.ts +61 -19
- package/src/query.ts +2 -0
- package/src/runtime/create.ts +4 -0
- package/src/runtime/definitions.ts +3 -0
- package/src/runtime/host.ts +2 -0
- package/src/runtime/resolve-definitions.ts +28 -0
- package/src/storage/agents/in-memory.ts +15 -0
- package/src/storage/agents/types.ts +5 -0
- package/src/storage/ai-usage/in-memory.ts +23 -0
- package/src/storage/ai-usage/index.ts +1 -0
- package/src/storage/ai-usage/types.ts +10 -0
- package/src/storage/index.ts +11 -0
- package/src/storage/objects/in-memory.ts +103 -16
- package/src/storage/objects/index.ts +9 -0
- package/src/storage/objects/keys.ts +36 -0
- package/src/storage/objects/types.ts +34 -6
- package/src/storage/ontology/provider-header-validation.ts +2 -2
- package/src/storage/timeseries/store.ts +6 -6
- package/src/testing/agent-storage-contract.ts +12 -0
- package/src/testing/ai-usage-storage-contract.ts +35 -0
- package/src/testing/effective-storage-contract.ts +194 -4
- package/src/testing/lake-storage-contract.ts +56 -0
- package/src/testing/object-query-contract.ts +208 -1
- package/dist/agents/prompt.d.ts +0 -21
- package/dist/agents/prompt.d.ts.map +0 -1
- package/dist/chunk-4z3n1dzt.js.map +0 -23
- package/dist/chunk-6wetht33.js +0 -89
- package/dist/chunk-6wetht33.js.map +0 -10
- package/dist/chunk-88ppkr54.js.map +0 -12
- package/dist/chunk-f1cyvnrk.js.map +0 -13
- package/dist/chunk-ttba8x6z.js.map +0 -15
- package/dist/chunk-wb4051cx.js.map +0 -12
- package/dist/chunk-zpw39qhj.js.map +0 -10
- package/src/agents/prompt.ts +0 -85
- /package/dist/{chunk-c6cfqydk.js.map → chunk-4h947jd8.js.map} +0 -0
- /package/dist/{chunk-gqdd7508.js.map → chunk-4rh2m6zg.js.map} +0 -0
- /package/dist/{chunk-pxtrxm3p.js.map → chunk-a09jx26t.js.map} +0 -0
- /package/dist/{chunk-4p9rh7jj.js.map → chunk-ea73pzk7.js.map} +0 -0
- /package/dist/{chunk-4aw0jwk0.js.map → chunk-f6erf2vv.js.map} +0 -0
- /package/dist/{chunk-c8bw2b6c.js.map → chunk-gadsm794.js.map} +0 -0
- /package/dist/{chunk-n5x5y80a.js.map → chunk-nzw7sm3b.js.map} +0 -0
- /package/dist/{chunk-261ag4t4.js.map → chunk-r0rry8dn.js.map} +0 -0
- /package/dist/{chunk-d2adj15j.js.map → chunk-tkdscva6.js.map} +0 -0
- /package/dist/{chunk-z8j83gzd.js.map → chunk-x2yw73hy.js.map} +0 -0
- /package/dist/{chunk-qer6am8w.js.map → chunk-xdf9yswn.js.map} +0 -0
- /package/dist/{chunk-km4rkj4t.js.map → chunk-zp2v2rv6.js.map} +0 -0
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
} from "./chunk-9t8f5xfx.js";
|
|
5
5
|
import {
|
|
6
6
|
registerProjectionRegistry
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-819wnjz8.js";
|
|
8
8
|
import {
|
|
9
9
|
LoggingService
|
|
10
10
|
} from "./chunk-ghteq96b.js";
|
|
@@ -16,7 +16,7 @@ import {
|
|
|
16
16
|
discoverOntologySources,
|
|
17
17
|
discoverProjectDefinitions,
|
|
18
18
|
validateRulesAtStartup
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-h6h91mfy.js";
|
|
20
20
|
import {
|
|
21
21
|
validateSchedulesAtStartup
|
|
22
22
|
} from "./chunk-5sz8ta9r.js";
|
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
validateAgentGroupReferences,
|
|
29
29
|
validateAgentToolsAtStartup,
|
|
30
30
|
validateWorkflowsAtStartup
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-84h6qhmp.js";
|
|
32
32
|
import {
|
|
33
33
|
ConnectorError,
|
|
34
34
|
ConnectorNotFoundError,
|
|
@@ -41,10 +41,7 @@ import {
|
|
|
41
41
|
providerFailureCode,
|
|
42
42
|
recoverConnectorFailure,
|
|
43
43
|
storageBoundaryError
|
|
44
|
-
} from "./chunk-
|
|
45
|
-
import {
|
|
46
|
-
RuntimeError
|
|
47
|
-
} from "./chunk-3rsf30p4.js";
|
|
44
|
+
} from "./chunk-zp2v2rv6.js";
|
|
48
45
|
import {
|
|
49
46
|
createOntologyMutationRuntime,
|
|
50
47
|
registerOntologyMutationRuntime
|
|
@@ -58,18 +55,21 @@ import {
|
|
|
58
55
|
} from "./chunk-nf4r78r4.js";
|
|
59
56
|
import {
|
|
60
57
|
ActionRegistry
|
|
61
|
-
} from "./chunk-
|
|
58
|
+
} from "./chunk-78c6xvyr.js";
|
|
59
|
+
import {
|
|
60
|
+
RuntimeError
|
|
61
|
+
} from "./chunk-1q02e95s.js";
|
|
62
62
|
import {
|
|
63
63
|
ProjectionRegistry,
|
|
64
64
|
createOntologyMaterializer
|
|
65
|
-
} from "./chunk-
|
|
65
|
+
} from "./chunk-tbv03sx2.js";
|
|
66
66
|
import {
|
|
67
67
|
ensureExecutionRecord
|
|
68
|
-
} from "./chunk-
|
|
68
|
+
} from "./chunk-f6erf2vv.js";
|
|
69
69
|
import {
|
|
70
70
|
checkStorageSchema,
|
|
71
71
|
isMigrationCapableStorage
|
|
72
|
-
} from "./chunk-
|
|
72
|
+
} from "./chunk-v0egge8b.js";
|
|
73
73
|
import {
|
|
74
74
|
CONNECTOR_CONNECTION_RUN_FAILURE_CODES,
|
|
75
75
|
ConnectorConnectionStorageError
|
|
@@ -87,7 +87,7 @@ import {
|
|
|
87
87
|
import {
|
|
88
88
|
AuthRuntime,
|
|
89
89
|
SecurityRegistry
|
|
90
|
-
} from "./chunk-
|
|
90
|
+
} from "./chunk-tkdscva6.js";
|
|
91
91
|
import {
|
|
92
92
|
AuthRuntimeError,
|
|
93
93
|
isMagicLinkAuthStrategy,
|
|
@@ -96,7 +96,7 @@ import {
|
|
|
96
96
|
import {
|
|
97
97
|
AuthorizationError,
|
|
98
98
|
resolveExecutionScopeAuthorization
|
|
99
|
-
} from "./chunk-
|
|
99
|
+
} from "./chunk-f83ka50g.js";
|
|
100
100
|
import {
|
|
101
101
|
captureSixbFailure,
|
|
102
102
|
isSixbError
|
|
@@ -2802,6 +2802,36 @@ async function captureFailure(run, failures, fallback) {
|
|
|
2802
2802
|
return fallback;
|
|
2803
2803
|
}
|
|
2804
2804
|
}
|
|
2805
|
+
// src/runtime/definitions.ts
|
|
2806
|
+
function createDefinitionCatalog(definitionsById) {
|
|
2807
|
+
return Object.freeze({
|
|
2808
|
+
list: () => [...definitionsById.values()],
|
|
2809
|
+
getById: (id) => definitionsById.get(id) ?? null
|
|
2810
|
+
});
|
|
2811
|
+
}
|
|
2812
|
+
|
|
2813
|
+
// src/models/index.ts
|
|
2814
|
+
function modelRef(model) {
|
|
2815
|
+
return `${model.provider}/${model.modelId}`;
|
|
2816
|
+
}
|
|
2817
|
+
function createModelCatalog(input) {
|
|
2818
|
+
const byRef = new Map;
|
|
2819
|
+
for (const model of input.language) {
|
|
2820
|
+
const ref = modelRef(model);
|
|
2821
|
+
if (byRef.has(ref)) {
|
|
2822
|
+
throw new RuntimeError(`[Sixb] Duplicate language model '${ref}' in 'models'. Each provider and model id pair may be configured once.`);
|
|
2823
|
+
}
|
|
2824
|
+
byRef.set(ref, Object.freeze({ ref, provider: model.provider, modelId: model.modelId, model }));
|
|
2825
|
+
}
|
|
2826
|
+
const [defaultEntry] = byRef.values();
|
|
2827
|
+
if (defaultEntry === undefined) {
|
|
2828
|
+
throw new RuntimeError("[Sixb] 'models.language' needs at least one model. Configure one or omit 'models' from createSixb().");
|
|
2829
|
+
}
|
|
2830
|
+
return Object.freeze({
|
|
2831
|
+
language: Object.freeze({ ...createDefinitionCatalog(byRef), default: defaultEntry })
|
|
2832
|
+
});
|
|
2833
|
+
}
|
|
2834
|
+
|
|
2805
2835
|
// src/syncs/validation.ts
|
|
2806
2836
|
function validateKeyedDatasetWriterTopology(input) {
|
|
2807
2837
|
for (const sync of input.syncs) {
|
|
@@ -2846,14 +2876,6 @@ function* datasetWriters(syncs, pipelines) {
|
|
|
2846
2876
|
}
|
|
2847
2877
|
}
|
|
2848
2878
|
|
|
2849
|
-
// src/runtime/definitions.ts
|
|
2850
|
-
function createDefinitionCatalog(definitionsById) {
|
|
2851
|
-
return Object.freeze({
|
|
2852
|
-
list: () => [...definitionsById.values()],
|
|
2853
|
-
getById: (id) => definitionsById.get(id) ?? null
|
|
2854
|
-
});
|
|
2855
|
-
}
|
|
2856
|
-
|
|
2857
2879
|
// src/runtime/resolve-definitions.ts
|
|
2858
2880
|
function resolveDefinitions(options) {
|
|
2859
2881
|
const ontology = new OntologyRegistry({ sources: options.ontology });
|
|
@@ -2861,6 +2883,8 @@ function resolveDefinitions(options) {
|
|
|
2861
2883
|
const registeredActionIds = new Set(actionRegistry.list().map((action) => action.id));
|
|
2862
2884
|
const agents = options.agents ?? [];
|
|
2863
2885
|
validateAgentToolsAtStartup(agents);
|
|
2886
|
+
const models = options.models === undefined ? undefined : createModelCatalog(options.models);
|
|
2887
|
+
validateAgentModelReferences(agents, models);
|
|
2864
2888
|
const agentsById = indexUniqueDefinitions("agent", agents);
|
|
2865
2889
|
const connectorsById = indexUniqueDefinitions("connector", options.connectors ?? []);
|
|
2866
2890
|
const datasetsById = new Map;
|
|
@@ -2941,6 +2965,7 @@ function resolveDefinitions(options) {
|
|
|
2941
2965
|
agents: createDefinitionCatalog(agentsById),
|
|
2942
2966
|
connectors: createDefinitionCatalog(connectorsById),
|
|
2943
2967
|
datasets: createDefinitionCatalog(datasetsById),
|
|
2968
|
+
...models === undefined ? {} : { models },
|
|
2944
2969
|
pipelines: createDefinitionCatalog(pipelinesById),
|
|
2945
2970
|
projections: projectionRegistry,
|
|
2946
2971
|
rules: createDefinitionCatalog(rulesById),
|
|
@@ -2991,6 +3016,17 @@ function validateScheduleReferences(consumerKind, consumerId, references, schedu
|
|
|
2991
3016
|
}
|
|
2992
3017
|
}
|
|
2993
3018
|
}
|
|
3019
|
+
function validateAgentModelReferences(agents, models) {
|
|
3020
|
+
if (models === undefined) {
|
|
3021
|
+
return;
|
|
3022
|
+
}
|
|
3023
|
+
for (const agent of agents) {
|
|
3024
|
+
const ref = modelRef(agent.model);
|
|
3025
|
+
if (models.language.getById(ref) === null) {
|
|
3026
|
+
throw new RuntimeError(`[Sixb] Agent '${agent.id}' uses unknown language model '${ref}'. Add it to 'models.language' in createSixb().`);
|
|
3027
|
+
}
|
|
3028
|
+
}
|
|
3029
|
+
}
|
|
2994
3030
|
|
|
2995
3031
|
// src/runtime/storage-readiness.ts
|
|
2996
3032
|
var DEFAULT_SCHEMA_RETRY_DELAY_MS = 60000;
|
|
@@ -3286,9 +3322,10 @@ async function createSixb(options) {
|
|
|
3286
3322
|
roles: [...options.roles ?? [], ...definitions.roles],
|
|
3287
3323
|
membershipPolicies: [...options.membershipPolicies ?? [], ...definitions.membershipPolicies],
|
|
3288
3324
|
agents: [...options.agents ?? [], ...definitions.agents],
|
|
3325
|
+
models: options.models,
|
|
3289
3326
|
auth: options.auth
|
|
3290
3327
|
});
|
|
3291
3328
|
}
|
|
3292
3329
|
export { WebhookValidationError, defineWebhook, webhookConnector, UnverifiedWebhookError, resolveWebhookVerification, warnUnverifiedWebhook, SixbHost, createSixb };
|
|
3293
3330
|
|
|
3294
|
-
//# debugId=
|
|
3331
|
+
//# debugId=44FA1D0A5E5FF34064756E2164756E21
|