@elevasis/sdk 1.22.0 → 1.23.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 +980 -42
- package/dist/index.d.ts +1221 -220
- package/dist/index.js +390 -15
- package/dist/test-utils/index.d.ts +964 -211
- package/dist/test-utils/index.js +257 -14
- package/dist/worker/index.js +122 -14
- package/package.json +3 -3
- package/reference/claude-config/rules/operations.md +3 -3
- package/reference/claude-config/rules/organization-model.md +88 -85
- package/reference/claude-config/rules/organization-os.md +104 -104
- package/reference/claude-config/rules/vibe.md +235 -235
- package/reference/claude-config/skills/om/SKILL.md +324 -0
- package/reference/claude-config/skills/{knowledge → om}/operations/customers.md +110 -109
- package/reference/claude-config/skills/{knowledge → om}/operations/features.md +77 -76
- package/reference/claude-config/skills/{knowledge → om}/operations/goals.md +119 -118
- package/reference/claude-config/skills/{knowledge → om}/operations/identity.md +94 -93
- package/reference/claude-config/skills/{knowledge → om}/operations/labels.md +94 -94
- package/reference/claude-config/skills/{knowledge → om}/operations/offerings.md +110 -109
- package/reference/claude-config/skills/{knowledge → om}/operations/roles.md +100 -99
- package/reference/claude-config/skills/{knowledge → om}/operations/techStack.md +30 -30
- package/reference/claude-config/skills/project/SKILL.md +1088 -1088
- package/reference/claude-config/skills/setup/SKILL.md +275 -275
- package/reference/claude-config/skills/tutorial/SKILL.md +259 -259
- package/reference/claude-config/skills/tutorial/progress-template.md +74 -74
- package/reference/claude-config/skills/tutorial/technical.md +1303 -1303
- package/reference/claude-config/skills/tutorial/vibe-coder.md +890 -890
- package/reference/claude-config/sync-notes/2026-05-14-organization-model-ontology-refactor.md +7 -4
- package/reference/claude-config/sync-notes/2026-05-15-om-skill-rename-and-write-family.md +52 -0
- package/reference/examples/organization-model.ts +26 -2
- package/reference/scaffold/core/organization-model.mdx +16 -11
- package/reference/scaffold/recipes/add-a-feature.md +28 -26
- package/reference/scaffold/recipes/add-a-resource.md +26 -16
- package/reference/scaffold/recipes/customize-organization-model.md +5 -3
- package/reference/scaffold/recipes/extend-lead-gen.md +9 -9
- package/reference/scaffold/recipes/index.md +1 -1
- package/reference/scaffold/recipes/query-the-knowledge-graph.md +189 -185
- package/reference/scaffold/reference/contracts.md +139 -101
- package/reference/scaffold/reference/glossary.md +74 -72
- package/reference/claude-config/skills/knowledge/SKILL.md +0 -345
- /package/reference/claude-config/skills/{knowledge → om}/operations/codify-level-a.md +0 -0
- /package/reference/claude-config/skills/{knowledge → om}/operations/codify-level-b.md +0 -0
package/reference/claude-config/sync-notes/2026-05-14-organization-model-ontology-refactor.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
## Why this note exists
|
|
4
4
|
|
|
5
|
-
The template now demonstrates the Organization Model ontology bridge. New semantic contracts should be authored in `System.ontology
|
|
5
|
+
The template now demonstrates the Organization Model ontology and topology bridge. New semantic contracts should be authored in `System.ontology`; executable Resources bind through `resource.ontology.actions` and optional `resource.ontology.primaryAction`; durable operational wiring belongs in `organizationModel.topology.relationships`. Legacy `entities`, `actions`, and `System.content` remain compatibility mirrors for current consumers.
|
|
6
6
|
|
|
7
7
|
## Applies to
|
|
8
8
|
|
|
@@ -14,13 +14,15 @@ The template now demonstrates the Organization Model ontology bridge. New semant
|
|
|
14
14
|
- `operations/src/resource-registry.test.ts`
|
|
15
15
|
- `operations/src/README.md`
|
|
16
16
|
- `.claude/rules/organization-model.md`
|
|
17
|
+
- `.claude/rules/operations.md`
|
|
17
18
|
|
|
18
19
|
## Required actions
|
|
19
20
|
|
|
20
21
|
1. Preserve system-colocated ontology scopes when syncing template organization-model changes.
|
|
21
|
-
2.
|
|
22
|
-
3.
|
|
23
|
-
4.
|
|
22
|
+
2. Migrate Resource descriptors from `ontology.implements` / `actionKey` to `ontology.actions` / `ontology.primaryAction`; keep `codeRefs` with the Resource descriptor.
|
|
23
|
+
3. Preserve `organizationModel.topology.relationships` when syncing template organization-model changes; keep secrets, credential values, provider webhook mechanics, and per-run state outside the OM.
|
|
24
|
+
4. Keep `entities`, `actions`, and `System.content` aligned as compatibility mirrors until downstream consumers move fully to compiled ontology indexes.
|
|
25
|
+
5. Do not overwrite project-owned `core/config/extensions/**` files.
|
|
24
26
|
|
|
25
27
|
## Verification
|
|
26
28
|
|
|
@@ -38,5 +40,6 @@ pnpm sync:verify --pre
|
|
|
38
40
|
## Not handled by /git-sync
|
|
39
41
|
|
|
40
42
|
- Choosing project-specific ontology IDs for tenant-owned systems.
|
|
43
|
+
- Choosing project-specific topology relationships for tenant-owned workflows, checkpoints, integrations, or schedules.
|
|
41
44
|
- Migrating project-owned extension files under `core/config/extensions/**`.
|
|
42
45
|
- Retiring compatibility mirrors before the full internal, SDK, scaffold, and external template-family green cycle.
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# OM Skill Rename + Write Family Release Train
|
|
2
|
+
|
|
3
|
+
## Why this note exists
|
|
4
|
+
|
|
5
|
+
This release train renames the tenant `/knowledge` skill to `/om` and broadens it, ports `om:search` / `om:describe` to the `elevasis-sdk` CLI, and bumps the `@elevasis/core` and `@elevasis/sdk` dependency baselines. The template `.claude` skill surface changed shape (a directory was renamed and slash-command references were rewritten across CLAUDE.md, rules, and adjacent skills), and `@elevasis/core` / `@elevasis/sdk` published new exports and CLI commands. Ordinary git merge does not reconcile a managed `.claude` skill rename or pull republished package baselines, so template-derived projects need an operative note.
|
|
6
|
+
|
|
7
|
+
This note covers the `om-skill` workstream (the `/knowledge` -> `/om` rename + SDK CLI port) and the package-baseline cascades from the same train (`@elevasis/core` minor from `om-skill` + `om-create-skill`; `@elevasis/sdk` minor from `om-skill`). It does NOT cover the unrelated Shared-UI-Migration changes under `external/_template/ui/**`, which are a separate workstream and not part of this train.
|
|
8
|
+
|
|
9
|
+
## Applies to
|
|
10
|
+
|
|
11
|
+
- `external/_template/.claude/skills/om/SKILL.md` (renamed from `external/_template/.claude/skills/knowledge/SKILL.md`; canonical 5-bucket decision tree with the tenant Codify/Toggle ceremony preserved)
|
|
12
|
+
- `external/_template/.claude/skills/om/operations/*.md` (10 files moved from `knowledge/operations/`; `elevasis-sdk knowledge:*` references rewritten to `elevasis-sdk om:*`, `/knowledge` footers rewritten to `/om`)
|
|
13
|
+
- `external/_template/.claude/skills/knowledge/` (DELETED — directory removed; tombstone, do not re-create on sync)
|
|
14
|
+
- `external/_template/CLAUDE.md` (Slash Commands table — `/knowledge` -> `/om`)
|
|
15
|
+
- `external/_template/.claude/rules/{organization-model,organization-os,vibe}.md` (slash-command references)
|
|
16
|
+
- `external/_template/.claude/skills/{setup,project,tutorial}/*.md` (slash-command references)
|
|
17
|
+
- `external/_template/core/package.json` (`@elevasis/core` baseline -> 0.25.0)
|
|
18
|
+
- `external/_template/operations/package.json` (`@elevasis/core` -> 0.25.0 and `@elevasis/sdk` -> 1.23.0 baselines)
|
|
19
|
+
|
|
20
|
+
Package baselines become concrete only after the `core` and `sdk` publish stages of `/sdk ship` complete; the `.claude` skill rename is template-authored and already present in `external/_template`.
|
|
21
|
+
|
|
22
|
+
## Required actions
|
|
23
|
+
|
|
24
|
+
1. Apply the managed `.claude` skill rename atomically: create `.claude/skills/om/` (SKILL.md + `operations/`) and delete `.claude/skills/knowledge/` in the same sync. Never leave both directories present — two skills advertising the same scope is the exact confusion the rename removes.
|
|
25
|
+
2. Preserve any tenant-owned Codify/Toggle ceremony content in the project's `om/SKILL.md` Write-Power section; do not overwrite project-authored knowledge node content under `core/config/knowledge/**` (the content directory is separate from the slash-command name).
|
|
26
|
+
3. Rewrite `/knowledge` -> `/om` and `elevasis-sdk knowledge:*` -> `elevasis-sdk om:*` references in managed surfaces only; `knowledge:*` CLI aliases remain valid, so do not hard-fail on legacy invocations in project-owned files.
|
|
27
|
+
4. After the `/sdk ship` publish stages land, bump the `@elevasis/core` (0.25.0) and `@elevasis/sdk` (1.23.0) baselines in `core/package.json` and `operations/package.json`, then reinstall.
|
|
28
|
+
5. The `/om` write sub-skill family (`verify` / `create` / `rename` / `deprecate`) is intentionally NOT ported to the tenant template in this train (deferred to a dedicated task). Do not scaffold those tenant operations from this sync.
|
|
29
|
+
|
|
30
|
+
## Verification
|
|
31
|
+
|
|
32
|
+
Run the template verification lane after applying this sync:
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
pnpm sync:verify --pre
|
|
36
|
+
pnpm external:verify
|
|
37
|
+
pnpm -C external/_template/operations check-types
|
|
38
|
+
pnpm -C external/_template/operations test
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
Then confirm in each downstream project:
|
|
42
|
+
|
|
43
|
+
- `.claude/skills/om/` exists with `SKILL.md` + `operations/`; `.claude/skills/knowledge/` is gone.
|
|
44
|
+
- `elevasis-sdk om:search "<query>"` and `elevasis-sdk om:describe <id>` resolve against the tenant's organization model; legacy `elevasis-sdk knowledge:*` still aliases.
|
|
45
|
+
- `@elevasis/core` resolves to >= 0.25.0 and `@elevasis/sdk` to >= 1.23.0.
|
|
46
|
+
|
|
47
|
+
## Not handled by /git-sync
|
|
48
|
+
|
|
49
|
+
- Publishing `@elevasis/core` (0.25.0) or `@elevasis/sdk` (1.23.0) — owned by `/sdk ship` publish stages.
|
|
50
|
+
- Redeploying the SDK resources bundle (`elevasis-operations`) after the `@elevasis/sdk` publish.
|
|
51
|
+
- Tenant-specific conflict resolution in dirty external project worktrees, including reconciling any project-authored edits to the former `knowledge/SKILL.md`.
|
|
52
|
+
- The unrelated Shared-UI-Migration changes under `external/_template/ui/**` (separate workstream; not in this train's scope).
|
|
@@ -217,13 +217,15 @@ export const customersAndOfferingsExample = defineOrganizationModel({
|
|
|
217
217
|
export const workflowResourceDescriptorsExample = defineResources({
|
|
218
218
|
leadEnrichment: {
|
|
219
219
|
id: 'lead-enrichment-workflow',
|
|
220
|
+
title: 'Lead Enrichment',
|
|
221
|
+
description: 'Enriches lead records and writes qualified opportunities into CRM.',
|
|
220
222
|
kind: 'workflow',
|
|
221
223
|
systemPath: 'sales.lead-gen',
|
|
222
224
|
ownerRoleId: 'role-ops-lead',
|
|
223
|
-
actionKey: 'prospecting.lead-enrichment',
|
|
224
225
|
status: 'active' as const,
|
|
225
226
|
ontology: {
|
|
226
|
-
|
|
227
|
+
actions: ['sales.lead-gen:action/lead.enrich'],
|
|
228
|
+
primaryAction: 'sales.lead-gen:action/lead.enrich',
|
|
227
229
|
reads: ['sales.lead-gen:object/lead'],
|
|
228
230
|
writes: ['sales.crm:object/deal'],
|
|
229
231
|
usesCatalogs: ['sales.crm:catalog/pipeline'],
|
|
@@ -256,6 +258,28 @@ export const compatibilityGraphLinksExample = {
|
|
|
256
258
|
]
|
|
257
259
|
}
|
|
258
260
|
|
|
261
|
+
export const topologyRelationshipsExample = defineOrganizationModel({
|
|
262
|
+
topology: {
|
|
263
|
+
relationships: [
|
|
264
|
+
{
|
|
265
|
+
source: { kind: 'trigger', id: 'daily-lead-enrichment' },
|
|
266
|
+
target: { kind: 'resource', id: workflowResourceDescriptorsExample.leadEnrichment.id },
|
|
267
|
+
kind: 'triggers'
|
|
268
|
+
},
|
|
269
|
+
{
|
|
270
|
+
source: { kind: 'resource', id: workflowResourceDescriptorsExample.leadEnrichment.id },
|
|
271
|
+
target: { kind: 'externalResource', id: 'apollo' },
|
|
272
|
+
kind: 'uses'
|
|
273
|
+
},
|
|
274
|
+
{
|
|
275
|
+
source: { kind: 'resource', id: workflowResourceDescriptorsExample.leadEnrichment.id },
|
|
276
|
+
target: { kind: 'role', id: 'role-ops-lead' },
|
|
277
|
+
kind: 'approval'
|
|
278
|
+
}
|
|
279
|
+
]
|
|
280
|
+
}
|
|
281
|
+
})
|
|
282
|
+
|
|
259
283
|
// ---------------------------------------------------------------------------
|
|
260
284
|
// Roles and goals
|
|
261
285
|
// ---------------------------------------------------------------------------
|
|
@@ -138,17 +138,22 @@ Resource identity is authored in the OM Resources domain. Operations imports des
|
|
|
138
138
|
```ts
|
|
139
139
|
import { defineResources } from '@elevasis/core/organization-model'
|
|
140
140
|
|
|
141
|
-
export const resourceDescriptors = defineResources({
|
|
142
|
-
leadImport: {
|
|
143
|
-
id: 'lgn-01c-apollo-import-workflow',
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
141
|
+
export const resourceDescriptors = defineResources({
|
|
142
|
+
leadImport: {
|
|
143
|
+
id: 'lgn-01c-apollo-import-workflow',
|
|
144
|
+
title: 'Apollo Import',
|
|
145
|
+
description: 'Imports Apollo company records into the lead generation pipeline.',
|
|
146
|
+
kind: 'workflow',
|
|
147
|
+
systemPath: 'sales.lead-gen',
|
|
148
|
+
ownerRoleId: 'role-ops-lead',
|
|
149
|
+
status: 'active',
|
|
150
|
+
ontology: {
|
|
151
|
+
actions: ['sales.lead-gen:action/company.apollo-import'],
|
|
152
|
+
primaryAction: 'sales.lead-gen:action/company.apollo-import'
|
|
153
|
+
},
|
|
154
|
+
codeRefs: [
|
|
155
|
+
{
|
|
156
|
+
path: 'packages/elevasis-operations/src/sales/prospecting/scrape/apollo-import.ts',
|
|
152
157
|
role: 'entrypoint',
|
|
153
158
|
symbol: 'lgnApolloImportWorkflow'
|
|
154
159
|
}
|
|
@@ -176,15 +176,16 @@ Resources are governed descriptors for executable workflows, agents, integration
|
|
|
176
176
|
import { defineResources } from '@elevasis/core/organization-model'
|
|
177
177
|
|
|
178
178
|
export const resourceDescriptors = defineResources({
|
|
179
|
-
approveReviewItem: {
|
|
180
|
-
id: 'approve-review-item-workflow',
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
179
|
+
approveReviewItem: {
|
|
180
|
+
id: 'approve-review-item-workflow',
|
|
181
|
+
title: 'Approve review item',
|
|
182
|
+
description: 'Routes a review item through the operations approval workflow.',
|
|
183
|
+
order: 10,
|
|
184
|
+
kind: 'workflow',
|
|
185
|
+
systemPath: 'operations.review',
|
|
186
|
+
ownerRoleId: 'role-ops-lead',
|
|
187
|
+
status: 'active',
|
|
188
|
+
codeRefs: [
|
|
188
189
|
{
|
|
189
190
|
path: 'operations/src/review/approve-review-item/index.ts',
|
|
190
191
|
role: 'entrypoint',
|
|
@@ -194,9 +195,10 @@ export const resourceDescriptors = defineResources({
|
|
|
194
195
|
path: 'operations/src/review/approve-review-item/approve-review-item.test.ts',
|
|
195
196
|
role: 'test'
|
|
196
197
|
}
|
|
197
|
-
],
|
|
198
|
+
],
|
|
198
199
|
ontology: {
|
|
199
|
-
|
|
200
|
+
actions: ['operations.review:action/review-item.approve'],
|
|
201
|
+
primaryAction: 'operations.review:action/review-item.approve',
|
|
200
202
|
reads: ['operations.review:object/review-item'],
|
|
201
203
|
writes: ['operations.review:object/review-item'],
|
|
202
204
|
emits: ['operations.review:event/review-item.approved']
|
|
@@ -205,15 +207,15 @@ export const resourceDescriptors = defineResources({
|
|
|
205
207
|
})
|
|
206
208
|
```
|
|
207
209
|
|
|
208
|
-
Use `
|
|
210
|
+
Use descriptor `title` and `description` for executable display metadata.
|
|
209
211
|
|
|
210
|
-
Use nested `resource.ontology` bindings for the semantic actions, objects, catalogs, and events a Resource
|
|
212
|
+
Use nested `resource.ontology` bindings for the semantic actions, objects, catalogs, and events a Resource performs, reads, writes, uses, or emits. `resource.ontology.primaryAction` is the default/selectable ontology action and must be included in `resource.ontology.actions`. Top-level resource `emits` remains readable for bridge-era descriptors, but new descriptors should keep event bindings in `resource.ontology.emits`.
|
|
211
213
|
|
|
212
214
|
Use `codeRefs` as repo-relative breadcrumbs for agents and operators. They point from the governed Resource descriptor to implementation files; they do not define resource identity, System membership, runtime topology, or graph links.
|
|
213
215
|
|
|
214
216
|
## 6. Bind Runtime to the Descriptor
|
|
215
217
|
|
|
216
|
-
Workflow and agent code owns schemas, handlers, steps, and runtime behavior. It should import the descriptor and derive `resourceId`, `type`, and
|
|
218
|
+
Workflow and agent code owns schemas, handlers, steps, and runtime behavior. It should import the descriptor and derive `resourceId`, `type`, and display metadata from it.
|
|
217
219
|
|
|
218
220
|
```ts
|
|
219
221
|
import type { WorkflowDefinition } from '@elevasis/sdk'
|
|
@@ -221,15 +223,15 @@ import { resourceDescriptors } from '@core/config/organization-model'
|
|
|
221
223
|
|
|
222
224
|
export const approveReviewItemWorkflow: WorkflowDefinition = {
|
|
223
225
|
config: {
|
|
224
|
-
resource: resourceDescriptors.approveReviewItem,
|
|
225
|
-
resourceId: resourceDescriptors.approveReviewItem.id,
|
|
226
|
-
name:
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
},
|
|
226
|
+
resource: resourceDescriptors.approveReviewItem,
|
|
227
|
+
resourceId: resourceDescriptors.approveReviewItem.id,
|
|
228
|
+
name: resourceDescriptors.approveReviewItem.title,
|
|
229
|
+
description: resourceDescriptors.approveReviewItem.description,
|
|
230
|
+
type: resourceDescriptors.approveReviewItem.kind,
|
|
231
|
+
version: '1.0.0',
|
|
232
|
+
status: 'dev',
|
|
233
|
+
category: 'production'
|
|
234
|
+
},
|
|
233
235
|
contract: {
|
|
234
236
|
inputSchema,
|
|
235
237
|
outputSchema
|
|
@@ -255,7 +257,7 @@ export const org = {
|
|
|
255
257
|
}
|
|
256
258
|
```
|
|
257
259
|
|
|
258
|
-
Use `relationships` for execution topology.
|
|
260
|
+
Use `organizationModel.topology.relationships` for durable execution topology. The initial topology relationship kinds are `triggers`, `uses`, and `approval`; use `systemPath` and `resource.ontology` for semantic binding. Existing compatibility graph links can stay readable while old consumers migrate.
|
|
259
261
|
|
|
260
262
|
## 7. Add UI Wiring
|
|
261
263
|
|
|
@@ -304,7 +306,7 @@ function ReviewLayout() {
|
|
|
304
306
|
Add tests for the boundaries you changed:
|
|
305
307
|
|
|
306
308
|
- OM config tests for systems, ontology object/action/catalog records, resources, and any compatibility `System.content`.
|
|
307
|
-
- Runtime registry tests that deployed workflows import descriptors and keep `resourceId`, `type`, and `
|
|
309
|
+
- Runtime registry tests that deployed workflows import descriptors and keep `resourceId`, `type`, title, description, and `resource.ontology.primaryAction` aligned.
|
|
308
310
|
- UI tests or type checks for route, manifest, and guard wiring.
|
|
309
311
|
- Graph or knowledge tests when new ontology records, resources, compatibility content nodes, or emitted events should appear in Command View.
|
|
310
312
|
- Scaffold sync when new docs or generated scaffold references are affected.
|
|
@@ -327,7 +329,7 @@ pnpm verify:scaffold-reference
|
|
|
327
329
|
- Ontology catalog types contain local vocabularies such as pipelines, stages, templates, and status flows.
|
|
328
330
|
- Compatibility `System.content` is used only for existing bridge-era local catalogs or schemas.
|
|
329
331
|
- Each executable workflow or agent has an OM Resource descriptor with `systemPath`.
|
|
330
|
-
-
|
|
332
|
+
- Executable Resources use descriptor `title` / `description`, `resource.ontology.actions`, and `resource.ontology.primaryAction`.
|
|
331
333
|
- `codeRefs` point to useful entrypoints, handlers, schemas, tests, docs, or config.
|
|
332
334
|
- Runtime assembly imports descriptors and derives identity from them.
|
|
333
335
|
- UI routes, manifests, and guards use the same System ID.
|
|
@@ -20,16 +20,18 @@ Add the descriptor in `core/config/organization-model.ts`:
|
|
|
20
20
|
import { defineResources } from '@elevasis/core/organization-model'
|
|
21
21
|
|
|
22
22
|
export const resourceDescriptors = defineResources({
|
|
23
|
-
myWorkflow: {
|
|
23
|
+
myWorkflow: {
|
|
24
24
|
id: 'my-workflow',
|
|
25
|
+
title: 'My Workflow',
|
|
26
|
+
description: 'Runs the governed work item workflow.',
|
|
25
27
|
order: 10,
|
|
26
28
|
kind: 'workflow',
|
|
27
29
|
systemPath: 'operations',
|
|
28
30
|
ownerRoleId: 'role-ops-lead',
|
|
29
31
|
status: 'active',
|
|
30
|
-
actionKey: 'operations.my-workflow',
|
|
31
32
|
ontology: {
|
|
32
|
-
|
|
33
|
+
actions: ['operations:action/my-workflow.run'],
|
|
34
|
+
primaryAction: 'operations:action/my-workflow.run',
|
|
33
35
|
reads: ['operations:object/work-item'],
|
|
34
36
|
writes: ['operations:object/work-item'],
|
|
35
37
|
usesCatalogs: ['operations:catalog/workflow-status'],
|
|
@@ -63,7 +65,7 @@ Use `organizationModel.resources` as the Resources descriptor catalog. Graph ref
|
|
|
63
65
|
|
|
64
66
|
Use `codeRefs` as repo-relative implementation breadcrumbs for agents and operators. They do not define resource identity, System membership, runtime topology, or graph links; they point from the governed Resource descriptor to the files that implement, validate, or document it.
|
|
65
67
|
|
|
66
|
-
Use `
|
|
68
|
+
Use descriptor `title` and `description` for executable display metadata. Use nested `resource.ontology` bindings to declare which ontology actions, objects, catalogs, and events the resource performs, reads, writes, uses, or emits. `resource.ontology.primaryAction` is the default/selectable ontology action and must be included in `resource.ontology.actions`. Optional top-level resource `emits` remains readable for bridge-era event descriptors, but new descriptors should keep event bindings in `resource.ontology.emits`.
|
|
67
69
|
|
|
68
70
|
## 2. Author executable behavior
|
|
69
71
|
|
|
@@ -124,18 +126,26 @@ Use `.js` extensions in TypeScript source imports for ESM compatibility.
|
|
|
124
126
|
|
|
125
127
|
## 4. Declare runtime relationships
|
|
126
128
|
|
|
127
|
-
Use `
|
|
128
|
-
|
|
129
|
-
```ts
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
129
|
+
Use `organizationModel.topology.relationships` for durable execution topology:
|
|
130
|
+
|
|
131
|
+
```ts
|
|
132
|
+
topology: {
|
|
133
|
+
relationships: [
|
|
134
|
+
{
|
|
135
|
+
source: { kind: 'trigger', id: 'daily-work-item-import' },
|
|
136
|
+
target: { kind: 'resource', id: 'my-workflow' },
|
|
137
|
+
kind: 'triggers'
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
source: { kind: 'resource', id: 'my-workflow' },
|
|
141
|
+
target: { kind: 'externalResource', id: 'hubspot' },
|
|
142
|
+
kind: 'uses'
|
|
143
|
+
}
|
|
144
|
+
]
|
|
145
|
+
}
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
Use relationship kinds `triggers`, `uses`, and `approval` for the initial topology vocabulary. For semantic graph binding, prefer OM ontology IDs in `resource.ontology`; keep `config.links` only when maintaining older descriptors that still need the legacy graph bridge.
|
|
139
149
|
|
|
140
150
|
## 5. Verify
|
|
141
151
|
|
|
@@ -206,14 +206,16 @@ import { defineResources } from '@elevasis/core/organization-model'
|
|
|
206
206
|
export const resourceDescriptors = defineResources({
|
|
207
207
|
leadImport: {
|
|
208
208
|
id: 'lead-import',
|
|
209
|
+
title: 'Lead Import',
|
|
210
|
+
description: 'Updates CRM deal stage data from imported lead records.',
|
|
209
211
|
order: 10,
|
|
210
212
|
kind: 'workflow',
|
|
211
213
|
systemPath: 'sales.crm',
|
|
212
214
|
ownerRoleId: 'role-ops-lead',
|
|
213
215
|
status: 'active',
|
|
214
|
-
actionKey: 'sales.crm.deal.update-stage',
|
|
215
216
|
ontology: {
|
|
216
|
-
|
|
217
|
+
actions: ['sales.crm:action/deal.update-stage'],
|
|
218
|
+
primaryAction: 'sales.crm:action/deal.update-stage',
|
|
217
219
|
reads: ['sales.crm:object/deal'],
|
|
218
220
|
writes: ['sales.crm:object/deal'],
|
|
219
221
|
usesCatalogs: ['sales.crm:catalog/pipeline'],
|
|
@@ -243,7 +245,7 @@ Use kind-prefixed graph IDs for cross-collection links:
|
|
|
243
245
|
|
|
244
246
|
`category` is one of `production`, `diagnostic`, `internal`, or `testing`.
|
|
245
247
|
|
|
246
|
-
`
|
|
248
|
+
Descriptor `title` and `description` own executable display metadata. Use nested `resource.ontology` bindings to declare which ontology actions, objects, catalogs, and events the resource performs, reads, writes, uses, or emits. `resource.ontology.primaryAction` names the default/selectable action and must be included in `resource.ontology.actions`. Resource event emissions can still be declared through top-level `emits` for older descriptors, but new descriptors should use `resource.ontology.emits`.
|
|
247
249
|
|
|
248
250
|
## Compatibility Domain Mirrors
|
|
249
251
|
|
|
@@ -210,15 +210,15 @@ const companyCleanupLayout: StepConfigLayout<CompanyCleanupInput> = {
|
|
|
210
210
|
}
|
|
211
211
|
|
|
212
212
|
const listActions: ListBuilderRegistry = [
|
|
213
|
-
{
|
|
214
|
-
resourceId: companyCleanupResource.id,
|
|
215
|
-
workflowId: companyCleanupResource.id,
|
|
216
|
-
actionKey:
|
|
217
|
-
label:
|
|
218
|
-
description:
|
|
219
|
-
category: 'utility',
|
|
220
|
-
stagesAffected: ['populated'],
|
|
221
|
-
schema: companyCleanupInputSchema,
|
|
213
|
+
{
|
|
214
|
+
resourceId: companyCleanupResource.id,
|
|
215
|
+
workflowId: companyCleanupResource.id,
|
|
216
|
+
actionKey: companyCleanupResource.ontology.primaryAction ?? companyCleanupResource.ontology.actions[0],
|
|
217
|
+
label: companyCleanupResource.title,
|
|
218
|
+
description: companyCleanupResource.description,
|
|
219
|
+
category: 'utility',
|
|
220
|
+
stagesAffected: ['populated'],
|
|
221
|
+
schema: companyCleanupInputSchema,
|
|
222
222
|
layout: companyCleanupLayout,
|
|
223
223
|
defaultInput: (list) => ({
|
|
224
224
|
listId: list.id,
|
|
@@ -17,7 +17,7 @@ Before starting, read [glossary.md](../reference/glossary.md) to disambiguate ov
|
|
|
17
17
|
## Recipes
|
|
18
18
|
|
|
19
19
|
**[Add an OM-Backed System](add-a-feature.md)**
|
|
20
|
-
You want a new system with cohesive Organization Model semantics, executable resources, and optional UI. Covers Systems, System-owned ontology and config, Resource descriptors with `resource.ontology`, `
|
|
20
|
+
You want a new system with cohesive Organization Model semantics, executable resources, and optional UI. Covers Systems, System-owned ontology and config, Resource descriptors with `title`, `description`, `resource.ontology.actions`, `primaryAction`, `codeRefs`, OM topology, runtime assembly, manifests, routes, guards, tests, and compatibility notes for old `System.content` consumers.
|
|
21
21
|
|
|
22
22
|
**[Add a Resource](add-a-resource.md)**
|
|
23
23
|
You want a new workflow or agent deployed to the platform. Covers OM Resource descriptor authoring, descriptor-backed `WorkflowDefinition` binding, `DeploymentSpec` assembly, relationship declarations, and CLI verification.
|