@elevasis/sdk 1.33.0 → 1.34.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/cli.cjs +587 -294
- package/dist/index.d.ts +8 -9
- package/dist/index.js +23 -14
- package/dist/node/index.d.ts +3 -4
- package/dist/test-utils/index.d.ts +2 -3
- package/dist/test-utils/index.js +22 -13
- package/package.json +4 -4
- package/reference/claude-config/Overview.md +2 -2
- package/reference/claude-config/skills/om/SKILL.md +85 -47
- package/reference/claude-config/skills/project/SKILL.md +16 -14
- package/reference/claude-config/sync-notes/2026-06-04-scaffold-registry-lane-severity.md +34 -0
- package/reference/claude-config/sync-notes/2026-06-05-appearance-app-mode-decouple.md +29 -0
- package/reference/claude-config/sync-notes/2026-06-05-ontology-endpoint-rename-and-knowledge-browser-ui.md +86 -0
- package/reference/claude-config/sync-notes/2026-06-06-om-item-copy-references.md +50 -0
- package/reference/scaffold/core/organization-graph.mdx +9 -8
- package/reference/scaffold/operations/propagation-pipeline.md +13 -9
- package/reference/scaffold/operations/scaffold-maintenance.md +8 -7
- package/reference/sdk/cli-management.mdx +44 -2
- package/reference/sdk/cli.mdx +2 -1
package/dist/index.d.ts
CHANGED
|
@@ -6546,7 +6546,7 @@ declare const OntologyGroupSchema: z.ZodObject<{
|
|
|
6546
6546
|
aliases: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
6547
6547
|
members: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString>>>;
|
|
6548
6548
|
}, z.core.$loose>;
|
|
6549
|
-
declare const
|
|
6549
|
+
declare const OntologyEndpointTypeSchema: z.ZodObject<{
|
|
6550
6550
|
id: z.ZodString;
|
|
6551
6551
|
label: z.ZodOptional<z.ZodString>;
|
|
6552
6552
|
description: z.ZodOptional<z.ZodString>;
|
|
@@ -6637,7 +6637,7 @@ declare const OntologyScopeSchema: z.ZodDefault<z.ZodObject<{
|
|
|
6637
6637
|
aliases: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
6638
6638
|
members: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString>>>;
|
|
6639
6639
|
}, z.core.$loose>>>>;
|
|
6640
|
-
|
|
6640
|
+
endpoints: z.ZodOptional<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
6641
6641
|
id: z.ZodString;
|
|
6642
6642
|
label: z.ZodOptional<z.ZodString>;
|
|
6643
6643
|
description: z.ZodOptional<z.ZodString>;
|
|
@@ -6655,7 +6655,7 @@ type OntologyInterfaceType = z.infer<typeof OntologyInterfaceTypeSchema>;
|
|
|
6655
6655
|
type OntologyValueType = z.infer<typeof OntologyValueTypeSchema>;
|
|
6656
6656
|
type OntologySharedProperty = z.infer<typeof OntologySharedPropertySchema>;
|
|
6657
6657
|
type OntologyGroup = z.infer<typeof OntologyGroupSchema>;
|
|
6658
|
-
type
|
|
6658
|
+
type OntologyEndpointType = z.infer<typeof OntologyEndpointTypeSchema>;
|
|
6659
6659
|
type OntologyScope = z.infer<typeof OntologyScopeSchema>;
|
|
6660
6660
|
type ResolvedOntologyIndex = {
|
|
6661
6661
|
objectTypes: Record<OntologyId, ResolvedOntologyRecord<OntologyObjectType>>;
|
|
@@ -6667,7 +6667,7 @@ type ResolvedOntologyIndex = {
|
|
|
6667
6667
|
valueTypes: Record<OntologyId, ResolvedOntologyRecord<OntologyValueType>>;
|
|
6668
6668
|
sharedProperties: Record<OntologyId, ResolvedOntologyRecord<OntologySharedProperty>>;
|
|
6669
6669
|
groups: Record<OntologyId, ResolvedOntologyRecord<OntologyGroup>>;
|
|
6670
|
-
|
|
6670
|
+
endpoints: Record<OntologyId, ResolvedOntologyRecord<OntologyEndpointType>>;
|
|
6671
6671
|
};
|
|
6672
6672
|
type OntologyRecordOrigin = {
|
|
6673
6673
|
kind: 'authored' | 'projected';
|
|
@@ -6728,7 +6728,6 @@ interface SystemEntry {
|
|
|
6728
6728
|
status?: 'active' | 'deprecated' | 'archived';
|
|
6729
6729
|
path?: string;
|
|
6730
6730
|
icon?: string;
|
|
6731
|
-
color?: string;
|
|
6732
6731
|
uiPosition?: 'sidebar-primary' | 'sidebar-bottom';
|
|
6733
6732
|
enabled?: boolean;
|
|
6734
6733
|
devOnly?: boolean;
|
|
@@ -7335,7 +7334,7 @@ declare const OrganizationModelSchema$1: z.ZodObject<{
|
|
|
7335
7334
|
aliases: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
7336
7335
|
members: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString>>>;
|
|
7337
7336
|
}, z.core.$loose>>>>;
|
|
7338
|
-
|
|
7337
|
+
endpoints: z.ZodOptional<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
7339
7338
|
id: z.ZodString;
|
|
7340
7339
|
label: z.ZodOptional<z.ZodString>;
|
|
7341
7340
|
description: z.ZodOptional<z.ZodString>;
|
|
@@ -12224,7 +12223,7 @@ declare const ResourceOntologyBindingSchema = z
|
|
|
12224
12223
|
/**
|
|
12225
12224
|
* Optional typed contract binding for this resource's workflow I/O.
|
|
12226
12225
|
* Each ref is a `package/subpath#ExportName` string that resolves to a
|
|
12227
|
-
* Zod schema in
|
|
12226
|
+
* Zod schema in the tenant-owned organization model package.
|
|
12228
12227
|
*
|
|
12229
12228
|
* Absence of this field preserves all existing behavior — it is additive + optional.
|
|
12230
12229
|
* Tier-1 validation (schema.ts): ref-string shape only (browser-safe, no imports).
|
|
@@ -12476,7 +12475,7 @@ declare const ActionSchema = z.object({
|
|
|
12476
12475
|
})
|
|
12477
12476
|
type Action = z.infer<typeof ActionSchema>
|
|
12478
12477
|
|
|
12479
|
-
// CRM stage/state catalogs are model-owned (authored in
|
|
12478
|
+
// CRM stage/state catalogs are model-owned (authored in the tenant-owned organization model package
|
|
12480
12479
|
// canonicalOrganizationModel). The published core schema validates only the
|
|
12481
12480
|
// transport shape; closed-catalog membership is enforced by the caller/API
|
|
12482
12481
|
// layer via model-injected validators (mirrors LeadGenStageKeySchema).
|
|
@@ -12517,7 +12516,7 @@ declare function projectDeploymentSpec(options: ProjectDeploymentSpecOptions): D
|
|
|
12517
12516
|
/**
|
|
12518
12517
|
* Browser-safe generic workflow config helper.
|
|
12519
12518
|
*
|
|
12520
|
-
* Promoted from
|
|
12519
|
+
* Promoted from the tenant-owned organization model layer so any workflow family (lead-gen, CRM, etc.)
|
|
12521
12520
|
* can derive resourceId, actions, primaryAction, name, and description from
|
|
12522
12521
|
* the canonical OM Resource descriptor without duplicating validation logic.
|
|
12523
12522
|
*
|
package/dist/index.js
CHANGED
|
@@ -31,16 +31,13 @@ var OntologyKindSchema = z.enum([
|
|
|
31
31
|
"value-type",
|
|
32
32
|
"property",
|
|
33
33
|
"group",
|
|
34
|
-
"
|
|
34
|
+
"endpoint"
|
|
35
35
|
]);
|
|
36
36
|
var SYSTEM_PATH_PATTERN = "[a-z0-9][a-z0-9-]*(?:\\.[a-z0-9][a-z0-9-]*)*";
|
|
37
37
|
var LOCAL_ID_PATTERN = "[a-z0-9][a-z0-9._-]*";
|
|
38
38
|
var ONTOLOGY_ID_PATTERN = `^(global|${SYSTEM_PATH_PATTERN}):(${OntologyKindSchema.options.join("|")})\\/(${LOCAL_ID_PATTERN})$`;
|
|
39
39
|
var ONTOLOGY_ID_REGEX = new RegExp(ONTOLOGY_ID_PATTERN);
|
|
40
|
-
var OntologyIdSchema = z.string().trim().min(1).max(300).regex(
|
|
41
|
-
ONTOLOGY_ID_REGEX,
|
|
42
|
-
"Ontology IDs must use <system-path>:<kind>/<local-id> or global:<kind>/<local-id>"
|
|
43
|
-
);
|
|
40
|
+
var OntologyIdSchema = z.string().trim().min(1).max(300).regex(ONTOLOGY_ID_REGEX, "Ontology IDs must use <system-path>:<kind>/<local-id> or global:<kind>/<local-id>");
|
|
44
41
|
function parseOntologyId(id) {
|
|
45
42
|
const normalized = OntologyIdSchema.parse(id);
|
|
46
43
|
const match = ONTOLOGY_ID_REGEX.exec(normalized);
|
|
@@ -103,7 +100,7 @@ var OntologySharedPropertySchema = OntologyRecordBaseSchema.extend({
|
|
|
103
100
|
var OntologyGroupSchema = OntologyRecordBaseSchema.extend({
|
|
104
101
|
members: OntologyReferenceListSchema
|
|
105
102
|
});
|
|
106
|
-
var
|
|
103
|
+
var OntologyEndpointTypeSchema = OntologyRecordBaseSchema.extend({
|
|
107
104
|
route: z.string().trim().min(1).max(500).optional()
|
|
108
105
|
});
|
|
109
106
|
var OntologyScopeSchema = z.object({
|
|
@@ -116,7 +113,7 @@ var OntologyScopeSchema = z.object({
|
|
|
116
113
|
valueTypes: z.record(OntologyIdSchema, OntologyValueTypeSchema).default({}).optional(),
|
|
117
114
|
sharedProperties: z.record(OntologyIdSchema, OntologySharedPropertySchema).default({}).optional(),
|
|
118
115
|
groups: z.record(OntologyIdSchema, OntologyGroupSchema).default({}).optional(),
|
|
119
|
-
|
|
116
|
+
endpoints: z.record(OntologyIdSchema, OntologyEndpointTypeSchema).default({}).optional()
|
|
120
117
|
}).default({});
|
|
121
118
|
var SCOPE_KIND = {
|
|
122
119
|
objectTypes: "object",
|
|
@@ -128,7 +125,7 @@ var SCOPE_KIND = {
|
|
|
128
125
|
valueTypes: "value-type",
|
|
129
126
|
sharedProperties: "property",
|
|
130
127
|
groups: "group",
|
|
131
|
-
|
|
128
|
+
endpoints: "endpoint"
|
|
132
129
|
};
|
|
133
130
|
var SCOPE_KEYS = Object.keys(SCOPE_KIND);
|
|
134
131
|
function originFromContext(context) {
|
|
@@ -151,7 +148,7 @@ function createEmptyIndex() {
|
|
|
151
148
|
valueTypes: {},
|
|
152
149
|
sharedProperties: {},
|
|
153
150
|
groups: {},
|
|
154
|
-
|
|
151
|
+
endpoints: {}
|
|
155
152
|
};
|
|
156
153
|
}
|
|
157
154
|
function sortResolvedOntologyIndex(index) {
|
|
@@ -682,8 +679,6 @@ var SystemEntrySchema = z.object({
|
|
|
682
679
|
path: PathSchema.optional(),
|
|
683
680
|
/** @deprecated Use ui.icon. Kept for one-cycle Feature compatibility. */
|
|
684
681
|
icon: IconNameSchema.optional(),
|
|
685
|
-
/** @deprecated Feature color token, retained for one-cycle compatibility. */
|
|
686
|
-
color: ColorTokenSchema.optional(),
|
|
687
682
|
/** @deprecated UI placement hint, retained for one-cycle compatibility. */
|
|
688
683
|
uiPosition: UiPositionSchema.optional(),
|
|
689
684
|
/** @deprecated Use lifecycle. */
|
|
@@ -779,7 +774,7 @@ var ResourceOntologyBindingSchema = z.object({
|
|
|
779
774
|
/**
|
|
780
775
|
* Optional typed contract binding for this resource's workflow I/O.
|
|
781
776
|
* Each ref is a `package/subpath#ExportName` string that resolves to a
|
|
782
|
-
* Zod schema in
|
|
777
|
+
* Zod schema in the tenant-owned organization model package.
|
|
783
778
|
*
|
|
784
779
|
* Absence of this field preserves all existing behavior — it is additive + optional.
|
|
785
780
|
* Tier-1 validation (schema.ts): ref-string shape only (browser-safe, no imports).
|
|
@@ -2254,8 +2249,8 @@ function ontologyIndexForKind(index, kind) {
|
|
|
2254
2249
|
return index.sharedProperties;
|
|
2255
2250
|
case "group":
|
|
2256
2251
|
return index.groups;
|
|
2257
|
-
case "
|
|
2258
|
-
return index.
|
|
2252
|
+
case "endpoint":
|
|
2253
|
+
return index.endpoints;
|
|
2259
2254
|
}
|
|
2260
2255
|
}
|
|
2261
2256
|
function sameJson(left, right) {
|
|
@@ -2526,6 +2521,20 @@ function validateDeclaredSystemInterfaceReadiness(orgName, organizationModel) {
|
|
|
2526
2521
|
for (const { path, system } of listAllSystems(model)) {
|
|
2527
2522
|
if (system.apiInterface === void 0) continue;
|
|
2528
2523
|
const interfaceKey = "api";
|
|
2524
|
+
const resourceIds = system.apiInterface.resourceIds ?? [];
|
|
2525
|
+
if (resourceIds.length === 0) {
|
|
2526
|
+
const readinessProfile = system.apiInterface.readinessProfile;
|
|
2527
|
+
if (readinessProfile !== void 0 && !SYSTEM_INTERFACE_PROFILES.some((profile) => profile.readinessProfile === readinessProfile)) {
|
|
2528
|
+
addSystemInterfaceIssue(issues, orgName, path, interfaceKey, {
|
|
2529
|
+
family: "SYSTEM_INTERFACE_INVALID",
|
|
2530
|
+
code: "unknown-readiness-profile",
|
|
2531
|
+
path: `systems.${path}.apiInterface.readinessProfile`,
|
|
2532
|
+
ref: readinessProfile,
|
|
2533
|
+
message: `System Interface "${path}/${interfaceKey}" references unknown readiness profile "${readinessProfile}".`
|
|
2534
|
+
});
|
|
2535
|
+
}
|
|
2536
|
+
continue;
|
|
2537
|
+
}
|
|
2529
2538
|
const result = computeInterfaceReadiness(model, { systemPath: path, interfaceKey });
|
|
2530
2539
|
for (const issue of result.issues) {
|
|
2531
2540
|
addSystemInterfaceIssue(issues, orgName, path, interfaceKey, issue);
|
package/dist/node/index.d.ts
CHANGED
|
@@ -1377,7 +1377,7 @@ declare const OntologyScopeSchema: z.ZodDefault<z.ZodObject<{
|
|
|
1377
1377
|
aliases: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1378
1378
|
members: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString>>>;
|
|
1379
1379
|
}, z.core.$loose>>>>;
|
|
1380
|
-
|
|
1380
|
+
endpoints: z.ZodOptional<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
1381
1381
|
id: z.ZodString;
|
|
1382
1382
|
label: z.ZodOptional<z.ZodString>;
|
|
1383
1383
|
description: z.ZodOptional<z.ZodString>;
|
|
@@ -1436,7 +1436,6 @@ interface SystemEntry {
|
|
|
1436
1436
|
status?: 'active' | 'deprecated' | 'archived';
|
|
1437
1437
|
path?: string;
|
|
1438
1438
|
icon?: string;
|
|
1439
|
-
color?: string;
|
|
1440
1439
|
uiPosition?: 'sidebar-primary' | 'sidebar-bottom';
|
|
1441
1440
|
enabled?: boolean;
|
|
1442
1441
|
devOnly?: boolean;
|
|
@@ -2043,7 +2042,7 @@ declare const OrganizationModelSchema$1: z.ZodObject<{
|
|
|
2043
2042
|
aliases: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
2044
2043
|
members: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString>>>;
|
|
2045
2044
|
}, z.core.$loose>>>>;
|
|
2046
|
-
|
|
2045
|
+
endpoints: z.ZodOptional<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
2047
2046
|
id: z.ZodString;
|
|
2048
2047
|
label: z.ZodOptional<z.ZodString>;
|
|
2049
2048
|
description: z.ZodOptional<z.ZodString>;
|
|
@@ -3222,7 +3221,7 @@ declare const ResourceOntologyBindingSchema = z
|
|
|
3222
3221
|
/**
|
|
3223
3222
|
* Optional typed contract binding for this resource's workflow I/O.
|
|
3224
3223
|
* Each ref is a `package/subpath#ExportName` string that resolves to a
|
|
3225
|
-
* Zod schema in
|
|
3224
|
+
* Zod schema in the tenant-owned organization model package.
|
|
3226
3225
|
*
|
|
3227
3226
|
* Absence of this field preserves all existing behavior — it is additive + optional.
|
|
3228
3227
|
* Tier-1 validation (schema.ts): ref-string shape only (browser-safe, no imports).
|
|
@@ -5864,7 +5864,7 @@ declare const OntologyScopeSchema: z.ZodDefault<z.ZodObject<{
|
|
|
5864
5864
|
aliases: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
5865
5865
|
members: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString>>>;
|
|
5866
5866
|
}, z.core.$loose>>>>;
|
|
5867
|
-
|
|
5867
|
+
endpoints: z.ZodOptional<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
5868
5868
|
id: z.ZodString;
|
|
5869
5869
|
label: z.ZodOptional<z.ZodString>;
|
|
5870
5870
|
description: z.ZodOptional<z.ZodString>;
|
|
@@ -5923,7 +5923,6 @@ interface SystemEntry {
|
|
|
5923
5923
|
status?: 'active' | 'deprecated' | 'archived';
|
|
5924
5924
|
path?: string;
|
|
5925
5925
|
icon?: string;
|
|
5926
|
-
color?: string;
|
|
5927
5926
|
uiPosition?: 'sidebar-primary' | 'sidebar-bottom';
|
|
5928
5927
|
enabled?: boolean;
|
|
5929
5928
|
devOnly?: boolean;
|
|
@@ -6530,7 +6529,7 @@ declare const OrganizationModelSchema: z.ZodObject<{
|
|
|
6530
6529
|
aliases: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
6531
6530
|
members: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString>>>;
|
|
6532
6531
|
}, z.core.$loose>>>>;
|
|
6533
|
-
|
|
6532
|
+
endpoints: z.ZodOptional<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
6534
6533
|
id: z.ZodString;
|
|
6535
6534
|
label: z.ZodOptional<z.ZodString>;
|
|
6536
6535
|
description: z.ZodOptional<z.ZodString>;
|
package/dist/test-utils/index.js
CHANGED
|
@@ -8325,16 +8325,13 @@ var OntologyKindSchema = z.enum([
|
|
|
8325
8325
|
"value-type",
|
|
8326
8326
|
"property",
|
|
8327
8327
|
"group",
|
|
8328
|
-
"
|
|
8328
|
+
"endpoint"
|
|
8329
8329
|
]);
|
|
8330
8330
|
var SYSTEM_PATH_PATTERN = "[a-z0-9][a-z0-9-]*(?:\\.[a-z0-9][a-z0-9-]*)*";
|
|
8331
8331
|
var LOCAL_ID_PATTERN = "[a-z0-9][a-z0-9._-]*";
|
|
8332
8332
|
var ONTOLOGY_ID_PATTERN = `^(global|${SYSTEM_PATH_PATTERN}):(${OntologyKindSchema.options.join("|")})\\/(${LOCAL_ID_PATTERN})$`;
|
|
8333
8333
|
var ONTOLOGY_ID_REGEX = new RegExp(ONTOLOGY_ID_PATTERN);
|
|
8334
|
-
var OntologyIdSchema = z.string().trim().min(1).max(300).regex(
|
|
8335
|
-
ONTOLOGY_ID_REGEX,
|
|
8336
|
-
"Ontology IDs must use <system-path>:<kind>/<local-id> or global:<kind>/<local-id>"
|
|
8337
|
-
);
|
|
8334
|
+
var OntologyIdSchema = z.string().trim().min(1).max(300).regex(ONTOLOGY_ID_REGEX, "Ontology IDs must use <system-path>:<kind>/<local-id> or global:<kind>/<local-id>");
|
|
8338
8335
|
function parseOntologyId(id) {
|
|
8339
8336
|
const normalized = OntologyIdSchema.parse(id);
|
|
8340
8337
|
const match = ONTOLOGY_ID_REGEX.exec(normalized);
|
|
@@ -8397,7 +8394,7 @@ var OntologySharedPropertySchema = OntologyRecordBaseSchema.extend({
|
|
|
8397
8394
|
var OntologyGroupSchema = OntologyRecordBaseSchema.extend({
|
|
8398
8395
|
members: OntologyReferenceListSchema
|
|
8399
8396
|
});
|
|
8400
|
-
var
|
|
8397
|
+
var OntologyEndpointTypeSchema = OntologyRecordBaseSchema.extend({
|
|
8401
8398
|
route: z.string().trim().min(1).max(500).optional()
|
|
8402
8399
|
});
|
|
8403
8400
|
var OntologyScopeSchema = z.object({
|
|
@@ -8410,7 +8407,7 @@ var OntologyScopeSchema = z.object({
|
|
|
8410
8407
|
valueTypes: z.record(OntologyIdSchema, OntologyValueTypeSchema).default({}).optional(),
|
|
8411
8408
|
sharedProperties: z.record(OntologyIdSchema, OntologySharedPropertySchema).default({}).optional(),
|
|
8412
8409
|
groups: z.record(OntologyIdSchema, OntologyGroupSchema).default({}).optional(),
|
|
8413
|
-
|
|
8410
|
+
endpoints: z.record(OntologyIdSchema, OntologyEndpointTypeSchema).default({}).optional()
|
|
8414
8411
|
}).default({});
|
|
8415
8412
|
var SCOPE_KIND = {
|
|
8416
8413
|
objectTypes: "object",
|
|
@@ -8422,7 +8419,7 @@ var SCOPE_KIND = {
|
|
|
8422
8419
|
valueTypes: "value-type",
|
|
8423
8420
|
sharedProperties: "property",
|
|
8424
8421
|
groups: "group",
|
|
8425
|
-
|
|
8422
|
+
endpoints: "endpoint"
|
|
8426
8423
|
};
|
|
8427
8424
|
var SCOPE_KEYS = Object.keys(SCOPE_KIND);
|
|
8428
8425
|
function originFromContext(context) {
|
|
@@ -8445,7 +8442,7 @@ function createEmptyIndex() {
|
|
|
8445
8442
|
valueTypes: {},
|
|
8446
8443
|
sharedProperties: {},
|
|
8447
8444
|
groups: {},
|
|
8448
|
-
|
|
8445
|
+
endpoints: {}
|
|
8449
8446
|
};
|
|
8450
8447
|
}
|
|
8451
8448
|
function sortResolvedOntologyIndex(index2) {
|
|
@@ -8735,8 +8732,6 @@ var SystemEntrySchema = z.object({
|
|
|
8735
8732
|
path: PathSchema.optional(),
|
|
8736
8733
|
/** @deprecated Use ui.icon. Kept for one-cycle Feature compatibility. */
|
|
8737
8734
|
icon: IconNameSchema.optional(),
|
|
8738
|
-
/** @deprecated Feature color token, retained for one-cycle compatibility. */
|
|
8739
|
-
color: ColorTokenSchema.optional(),
|
|
8740
8735
|
/** @deprecated UI placement hint, retained for one-cycle compatibility. */
|
|
8741
8736
|
uiPosition: UiPositionSchema.optional(),
|
|
8742
8737
|
/** @deprecated Use lifecycle. */
|
|
@@ -9388,8 +9383,8 @@ function ontologyIndexForKind(index2, kind) {
|
|
|
9388
9383
|
return index2.sharedProperties;
|
|
9389
9384
|
case "group":
|
|
9390
9385
|
return index2.groups;
|
|
9391
|
-
case "
|
|
9392
|
-
return index2.
|
|
9386
|
+
case "endpoint":
|
|
9387
|
+
return index2.endpoints;
|
|
9393
9388
|
}
|
|
9394
9389
|
}
|
|
9395
9390
|
function sameJson(left, right) {
|
|
@@ -9660,6 +9655,20 @@ function validateDeclaredSystemInterfaceReadiness(orgName, organizationModel) {
|
|
|
9660
9655
|
for (const { path, system } of listAllSystems(model)) {
|
|
9661
9656
|
if (system.apiInterface === void 0) continue;
|
|
9662
9657
|
const interfaceKey = "api";
|
|
9658
|
+
const resourceIds = system.apiInterface.resourceIds ?? [];
|
|
9659
|
+
if (resourceIds.length === 0) {
|
|
9660
|
+
const readinessProfile = system.apiInterface.readinessProfile;
|
|
9661
|
+
if (readinessProfile !== void 0 && !SYSTEM_INTERFACE_PROFILES.some((profile) => profile.readinessProfile === readinessProfile)) {
|
|
9662
|
+
addSystemInterfaceIssue(issues, orgName, path, interfaceKey, {
|
|
9663
|
+
family: "SYSTEM_INTERFACE_INVALID",
|
|
9664
|
+
code: "unknown-readiness-profile",
|
|
9665
|
+
path: `systems.${path}.apiInterface.readinessProfile`,
|
|
9666
|
+
ref: readinessProfile,
|
|
9667
|
+
message: `System Interface "${path}/${interfaceKey}" references unknown readiness profile "${readinessProfile}".`
|
|
9668
|
+
});
|
|
9669
|
+
}
|
|
9670
|
+
continue;
|
|
9671
|
+
}
|
|
9663
9672
|
const result = computeInterfaceReadiness(model, { systemPath: path, interfaceKey });
|
|
9664
9673
|
for (const issue of result.issues) {
|
|
9665
9674
|
addSystemInterfaceIssue(issues, orgName, path, interfaceKey, issue);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elevasis/sdk",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.34.0",
|
|
4
4
|
"description": "SDK for building Elevasis organization resources",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -58,9 +58,9 @@
|
|
|
58
58
|
"tsup": "^8.0.0",
|
|
59
59
|
"typescript": "5.9.2",
|
|
60
60
|
"zod": "^4.1.0",
|
|
61
|
-
"@repo/core": "0.
|
|
62
|
-
"@repo/
|
|
63
|
-
"@repo/
|
|
61
|
+
"@repo/core": "0.46.0",
|
|
62
|
+
"@repo/typescript-config": "0.0.0",
|
|
63
|
+
"@repo/eslint-config": "0.0.0"
|
|
64
64
|
},
|
|
65
65
|
"scripts": {
|
|
66
66
|
"lint": "eslint src --max-warnings 0",
|
|
@@ -119,5 +119,5 @@ Use the owning skill instead of guessing from the name alone:
|
|
|
119
119
|
| Refresh the Skills + Rules lists above | `pnpm gen:overview` (run from the monorepo) |
|
|
120
120
|
|
|
121
121
|
The Skills section is generated from `external/_template/.claude/skills/*/SKILL.md` frontmatter, and
|
|
122
|
-
the Rules section from the bundled rule source `packages/sdk/docs/agent-rules/*.md`, both by
|
|
123
|
-
|
|
122
|
+
the Rules section from the bundled rule source `packages/sdk/docs/agent-rules/*.md`, both by the
|
|
123
|
+
monorepo `pnpm gen:overview` generator. Do not hand-edit the generated blocks.
|
|
@@ -92,13 +92,13 @@ Auto-invocation is driven by frontmatter `description`, `metadata.pathPatterns`,
|
|
|
92
92
|
Once invoked, classify the user's input into ONE of these buckets and dispatch the matching
|
|
93
93
|
primitive. When two buckets fit, prefer the higher one (more specific → more general).
|
|
94
94
|
|
|
95
|
-
| # | Bucket | Trigger
|
|
96
|
-
| --- | ------------------------------ |
|
|
97
|
-
| 1 | Named knowledge/role/policy id | User names `knowledge.<id>`, `role.<id>`, `policy.<id>` directly
|
|
98
|
-
| 2 | Named system | User names a system path (`sales.crm`, `sales.lead-gen`)
|
|
99
|
-
| 3 | Named ontology id | Id contains `:object/`, `:action/`, `:event/`, `:catalog/`, `:interface/`, `:link/`, `:
|
|
100
|
-
| 4 | Kind keyword | "playbooks", "strategies", "all references", "list policies"
|
|
101
|
-
| 5 | Free-text discovery | Anything else ("lead gen", "outreach", "what governs X?")
|
|
95
|
+
| # | Bucket | Trigger | Dispatch |
|
|
96
|
+
| --- | ------------------------------ | ------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- |
|
|
97
|
+
| 1 | Named knowledge/role/policy id | User names `knowledge.<id>`, `role.<id>`, `policy.<id>` directly | `om:cat <id>` for body, `om:describe <id>` for neighborhood |
|
|
98
|
+
| 2 | Named system | User names a system path (`sales.crm`, `sales.lead-gen`) | `om:describe <id>` |
|
|
99
|
+
| 3 | Named ontology id | Id contains `:object/`, `:action/`, `:event/`, `:catalog/`, `:interface/`, `:link/`, `:endpoint/` | `om:describe <id>` (or `om:ls /by-ontology/<id> --ids-only` then `om:cat` each) |
|
|
100
|
+
| 4 | Kind keyword | "playbooks", "strategies", "all references", "list policies" | `om:ls /by-kind/<kind> --ids-only` then `om:cat` each |
|
|
101
|
+
| 5 | Free-text discovery | Anything else ("lead gen", "outreach", "what governs X?") | `om:search "<query>"` then drill into top hit with `om:describe` |
|
|
102
102
|
|
|
103
103
|
On ambiguous input, default to **bucket 5 (search)** and surface the top hits. Codify and Toggle
|
|
104
104
|
intents are write paths -- see "Write Power" below.
|
|
@@ -107,17 +107,20 @@ intents are write paths -- see "Write Power" below.
|
|
|
107
107
|
|
|
108
108
|
## CLI Surface
|
|
109
109
|
|
|
110
|
-
All commands run with `pnpm
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
|
116
|
-
|
|
|
117
|
-
| `om:
|
|
118
|
-
| `om:
|
|
119
|
-
| `om:
|
|
120
|
-
| `om:
|
|
110
|
+
All commands run with `pnpm elevasis-sdk <cmd>` from the tenant project root (uses the root script
|
|
111
|
+
alias). Alternatively, use `pnpm -C operations exec elevasis-sdk <cmd>` from the monorepo root.
|
|
112
|
+
Do NOT use `pnpm exec elevasis-sdk <cmd>` at the project root -- `@elevasis/sdk` is a dependency of
|
|
113
|
+
`operations/` only; the binary is not found from the project root without the alias.
|
|
114
|
+
|
|
115
|
+
| Command | Alias | Purpose |
|
|
116
|
+
| ------------------ | -------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
117
|
+
| `om:search <q>` | `knowledge:search` | Universal keyword search across all 6 OM surfaces |
|
|
118
|
+
| `om:describe <id>` | `knowledge:describe` | Structured neighborhood view; kind auto-detected from id shape; also resolves `item:<domain>:<id>` and bare `<prefix>:<uuid>` domain-item forms |
|
|
119
|
+
| `om:cat <id>` | `knowledge:cat` | Raw MDX body of a knowledge node |
|
|
120
|
+
| `om:ls <path>` | `knowledge:ls` | List by mount path. Enumeration: `/all-systems`, `/all-resources`, `/all-roles`. Scoped: `/by-system/`, `/by-kind/`, `/by-ontology/`, `/by-owner/`, `/by-domain/`, `/by-item/`, `/graph/<id>/{governs,governed-by}` |
|
|
121
|
+
| `om:graph <id>` | `knowledge:graph` | Show outgoing + incoming graph edges |
|
|
122
|
+
| `om:skills <id>` | `knowledge:skills` | Show callable invocations on graph neighbors |
|
|
123
|
+
| `om:generate` | `knowledge:generate` | Regenerate `_generated/nodes.ts` from MDX sources |
|
|
121
124
|
|
|
122
125
|
Common flags: `--json`, `--ids-only`, `--limit <n>`, `--kinds <list>`.
|
|
123
126
|
|
|
@@ -128,23 +131,42 @@ Common flags: `--json`, `--ids-only`, `--limit <n>`, `--kinds <list>`.
|
|
|
128
131
|
### Free-text discovery (default for natural-language queries)
|
|
129
132
|
|
|
130
133
|
```bash
|
|
131
|
-
pnpm
|
|
132
|
-
pnpm
|
|
133
|
-
pnpm
|
|
134
|
+
pnpm elevasis-sdk om:search "lead gen"
|
|
135
|
+
pnpm elevasis-sdk om:search outreach --kinds knowledge --limit 5
|
|
136
|
+
pnpm elevasis-sdk om:search apollo --ids-only
|
|
134
137
|
```
|
|
135
138
|
|
|
136
139
|
### Neighborhood view for any OM node
|
|
137
140
|
|
|
138
141
|
```bash
|
|
139
|
-
pnpm
|
|
140
|
-
pnpm
|
|
141
|
-
pnpm
|
|
142
|
+
pnpm elevasis-sdk om:describe sales.crm
|
|
143
|
+
pnpm elevasis-sdk om:describe knowledge.outreach-playbook
|
|
144
|
+
pnpm elevasis-sdk om:describe sales.crm:object/deal
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
### Domain-item profile (clients, roles, policies, customers, offerings, goals)
|
|
148
|
+
|
|
149
|
+
Use `om:describe item:<domain>:<id>` to read a rich domain-item profile -- identity, branding,
|
|
150
|
+
location, and governing knowledge. The bare `<prefix>:<uuid>` form (e.g. `client:<uuid>`) is
|
|
151
|
+
accepted as a back-compat alias and resolves identically.
|
|
152
|
+
|
|
153
|
+
```bash
|
|
154
|
+
pnpm elevasis-sdk om:describe item:clients:<uuid> # full ClientProfile + location + governing knowledge
|
|
155
|
+
pnpm elevasis-sdk om:describe item:roles:<id>
|
|
156
|
+
pnpm elevasis-sdk om:describe item:policies:<id>
|
|
157
|
+
pnpm elevasis-sdk om:describe item:customers:<id>
|
|
158
|
+
pnpm elevasis-sdk om:describe item:offerings:<id>
|
|
159
|
+
pnpm elevasis-sdk om:describe item:goals:<id>
|
|
142
160
|
```
|
|
143
161
|
|
|
162
|
+
Do not confuse this with `client:get <uuid>` (the portfolio/DB surface for status, lineage, and
|
|
163
|
+
deals). `om:describe item:clients:<uuid>` returns the org-model `ClientProfile`; `client:get`
|
|
164
|
+
returns a sparse DB record. They share the same `id` and can be cross-linked by it.
|
|
165
|
+
|
|
144
166
|
### Read a single knowledge node body
|
|
145
167
|
|
|
146
168
|
```bash
|
|
147
|
-
pnpm
|
|
169
|
+
pnpm elevasis-sdk om:cat knowledge.outreach-playbook
|
|
148
170
|
```
|
|
149
171
|
|
|
150
172
|
### Top-level enumeration (drill-down entry point)
|
|
@@ -153,10 +175,10 @@ Start here when an agent needs to discover what this tenant's custom OM contains
|
|
|
153
175
|
building on it -- list everything in a domain, then narrow with `om:describe` / `om:cat`:
|
|
154
176
|
|
|
155
177
|
```bash
|
|
156
|
-
pnpm
|
|
157
|
-
pnpm
|
|
158
|
-
pnpm
|
|
159
|
-
pnpm
|
|
178
|
+
pnpm elevasis-sdk om:ls /all-systems # every System (path + label)
|
|
179
|
+
pnpm elevasis-sdk om:ls /all-resources # every resource (id, kind, title)
|
|
180
|
+
pnpm elevasis-sdk om:ls /all-roles # every role (id, title)
|
|
181
|
+
pnpm elevasis-sdk om:ls /all-systems --ids-only # pipe paths into om:describe
|
|
160
182
|
```
|
|
161
183
|
|
|
162
184
|
These resolve against this tenant's resolved model -- they enumerate the project's own custom
|
|
@@ -165,11 +187,13 @@ OM, not the platform's. Use `--json` for the wrapped envelope or `--ids-only` fo
|
|
|
165
187
|
### Scoped mount-path listings
|
|
166
188
|
|
|
167
189
|
```bash
|
|
168
|
-
pnpm
|
|
169
|
-
pnpm
|
|
170
|
-
pnpm
|
|
171
|
-
pnpm
|
|
172
|
-
pnpm
|
|
190
|
+
pnpm elevasis-sdk om:ls /by-system/sales.crm
|
|
191
|
+
pnpm elevasis-sdk om:ls /by-kind/playbook --ids-only
|
|
192
|
+
pnpm elevasis-sdk om:ls /by-ontology/sales.crm:object/deal --ids-only
|
|
193
|
+
pnpm elevasis-sdk om:ls /by-owner/role.ops-lead --ids-only
|
|
194
|
+
pnpm elevasis-sdk om:ls /by-domain/clients # enumerate all client domain items
|
|
195
|
+
pnpm elevasis-sdk om:ls /by-item/clients/<uuid> # single item record (same as om:describe item:clients:<uuid>)
|
|
196
|
+
pnpm elevasis-sdk om:graph knowledge.outreach-playbook
|
|
173
197
|
```
|
|
174
198
|
|
|
175
199
|
When a query clearly names an ontology id such as `sales.crm:object/deal`, route through
|
|
@@ -179,17 +203,31 @@ When a query clearly names an ontology id such as `sales.crm:object/deal`, route
|
|
|
179
203
|
|
|
180
204
|
### `/om read-folder` (chat shorthand from the Knowledge Browser)
|
|
181
205
|
|
|
182
|
-
The Knowledge Browser's copy button on a top-level system
|
|
183
|
-
`/om read-folder <axis>:<id>` line (or the legacy `/knowledge read-folder ...`
|
|
184
|
-
N per-node `read` lines. Resolve it by
|
|
206
|
+
The Knowledge Browser's copy button on a top-level system, kind group, or domain-item node
|
|
207
|
+
emits a single `/om read-folder <axis>:<id>` line (or the legacy `/knowledge read-folder ...`
|
|
208
|
+
form) instead of N per-node `read` lines. Resolve it by the table below:
|
|
209
|
+
|
|
210
|
+
| Copy form | Resolution |
|
|
211
|
+
| ------------------------------------ | -------------------------------------------------------------------------------------------------------------------------- |
|
|
212
|
+
| `/om read-folder system:<id>` | `pnpm elevasis-sdk om:ls /by-system/<id> --ids-only`, then `om:cat` each |
|
|
213
|
+
| `/om read-folder kind:<kind>` | `pnpm elevasis-sdk om:ls /by-kind/<kind> --ids-only`, then `om:cat` each |
|
|
214
|
+
| `/om read-folder owner:<id>` | `pnpm elevasis-sdk om:ls /by-owner/<id> --ids-only`, then `om:cat` each |
|
|
215
|
+
| `/om read-folder ontology:<id>` | `pnpm elevasis-sdk om:ls /by-ontology/<id> --ids-only`, then `om:cat` each |
|
|
216
|
+
| `/om read-folder item:<domain>:<id>` | `pnpm elevasis-sdk om:describe item:<domain>:<id>` -- returns profile + location + governing knowledge |
|
|
217
|
+
| `/om read-folder graph:<id>` | inspect `/graph/<id>/governs` and `/graph/<id>/governed-by`; read returned knowledge ids |
|
|
218
|
+
| `/om read-folder group:<id>` | browser overview reference only; resolve by visible children -- `pnpm elevasis-sdk om:ls /by-system/<id> --ids-only` |
|
|
219
|
+
| `/om read-folder domain:<domain>` | browser overview reference only; resolve by enumerating domain -- `pnpm elevasis-sdk om:ls /by-domain/<domain> --ids-only` |
|
|
220
|
+
| `/om read-folder folder:<id>` | browser overview reference only; treat as `domain:<id>` and enumerate with `/by-domain/<id>` |
|
|
221
|
+
|
|
222
|
+
**Legacy bridge -- `graph:client:<uuid>` and other `graph:<prefix>:<uuid>` domain-item forms:**
|
|
223
|
+
Older Knowledge Browser builds emitted `graph:client:<uuid>` for client items. This is a
|
|
224
|
+
graph-neighborhood shorthand, not a profile read. When you receive such a reference:
|
|
225
|
+
|
|
226
|
+
1. Resolve the graph neighborhood: `pnpm elevasis-sdk om:graph client:<uuid>` (may return empty or only `contains` edges -- that is expected; no `ClientProfile` is accessible this way).
|
|
227
|
+
2. For the rich profile, pivot to: `pnpm elevasis-sdk om:describe item:clients:<uuid>`.
|
|
185
228
|
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
| `/om read-folder system:<id>` | `pnpm exec elevasis-sdk om:ls /by-system/<id> --ids-only`, then `om:cat` each |
|
|
189
|
-
| `/om read-folder kind:<kind>` | `pnpm exec elevasis-sdk om:ls /by-kind/<kind> --ids-only`, then `om:cat` each |
|
|
190
|
-
| `/om read-folder owner:<id>` | `pnpm exec elevasis-sdk om:ls /by-owner/<id> --ids-only`, then `om:cat` each |
|
|
191
|
-
| `/om read-folder ontology:<id>` | `pnpm exec elevasis-sdk om:ls /by-ontology/<id> --ids-only`, then `om:cat` each |
|
|
192
|
-
| `/om read-folder graph:<id>` | inspect `/graph/<id>/governs` and `/graph/<id>/governed-by`; read returned knowledge ids |
|
|
229
|
+
In short: `graph:client:<uuid>` points to the graph node; `item:clients:<uuid>` resolves the
|
|
230
|
+
full org-model profile. Always use `item:` for profile reads going forward.
|
|
193
231
|
|
|
194
232
|
Dotted system ids may use either dots or slashes (`sales.crm` and `sales/crm` both work).
|
|
195
233
|
Legacy `feature:<id>` copy lines from older browser builds are compatibility aliases for
|
|
@@ -261,8 +299,8 @@ Placement examples:
|
|
|
261
299
|
|
|
262
300
|
Before adding a System:
|
|
263
301
|
|
|
264
|
-
1. Run `pnpm
|
|
265
|
-
2. Run `pnpm
|
|
302
|
+
1. Run `pnpm elevasis-sdk om:ls /all-systems`.
|
|
303
|
+
2. Run `pnpm elevasis-sdk om:describe <candidate-parent-or-owner>`.
|
|
266
304
|
3. If the proposed System name is a resource kind, shell group, or catch-all, do not create it;
|
|
267
305
|
attach or create a Resource under the real owning System.
|
|
268
306
|
4. Create a new System only when no existing System owns the capability and the new System has
|
|
@@ -414,4 +452,4 @@ classification names a specific domain.
|
|
|
414
452
|
|
|
415
453
|
---
|
|
416
454
|
|
|
417
|
-
**Last Updated:** 2026-
|
|
455
|
+
**Last Updated:** 2026-06-06
|