@elevasis/sdk 1.15.0 → 1.16.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 +2325 -124
- package/dist/index.d.ts +882 -794
- package/dist/index.js +170 -46
- package/dist/node/index.d.ts +69 -0
- package/dist/node/index.js +273 -0
- package/dist/test-utils/index.d.ts +857 -711
- package/dist/test-utils/index.js +2 -0
- package/dist/types/worker/adapters/lead.d.ts +1 -1
- package/dist/types/worker/platform.d.ts +2 -9
- package/dist/worker/index.js +1 -0
- package/package.json +12 -3
- package/reference/_navigation.md +23 -1
- package/reference/_reference-manifest.json +98 -0
- package/reference/claude-config/rules/agent-start-here.md +13 -0
- package/reference/claude-config/rules/organization-model.md +40 -40
- package/reference/claude-config/rules/organization-os.md +16 -16
- package/reference/claude-config/rules/ui.md +2 -6
- package/reference/claude-config/rules/vibe.md +13 -13
- package/reference/claude-config/skills/knowledge/SKILL.md +253 -0
- package/reference/claude-config/skills/{configure → knowledge}/operations/codify-level-a.md +100 -100
- package/reference/claude-config/skills/{configure → knowledge}/operations/codify-level-b.md +158 -158
- package/reference/claude-config/skills/knowledge/operations/customers.md +109 -0
- package/reference/claude-config/skills/knowledge/operations/features.md +113 -0
- package/reference/claude-config/skills/knowledge/operations/goals.md +118 -0
- package/reference/claude-config/skills/knowledge/operations/identity.md +93 -0
- package/reference/claude-config/skills/knowledge/operations/labels.md +89 -0
- package/reference/claude-config/skills/knowledge/operations/offerings.md +109 -0
- package/reference/claude-config/skills/knowledge/operations/roles.md +99 -0
- package/reference/claude-config/skills/knowledge/operations/techStack.md +102 -0
- package/reference/claude-config/skills/run-ui/SKILL.md +73 -0
- package/reference/claude-config/skills/setup/SKILL.md +270 -270
- package/reference/claude-config/skills/tutorial/SKILL.md +249 -0
- package/reference/claude-config/skills/tutorial/progress-template.md +74 -0
- package/reference/claude-config/skills/tutorial/technical.md +1309 -0
- package/reference/claude-config/skills/tutorial/vibe-coder.md +890 -0
- package/reference/claude-config/sync-notes/2026-05-02-crm-ownership-next-action.md +58 -0
- package/reference/claude-config/sync-notes/2026-05-02-template-hardcode-workos-config.md +56 -0
- package/reference/claude-config/sync-notes/2026-05-04-elevasis-workspace.md +71 -0
- package/reference/claude-config/sync-notes/2026-05-04-template-skills-run-ui-and-tutorial.md +59 -0
- package/reference/deployment/index.mdx +5 -5
- package/reference/examples/organization-model.ts +40 -0
- package/reference/framework/index.mdx +1 -1
- package/reference/framework/tutorial-system.mdx +86 -173
- package/reference/packages/core/src/knowledge/README.md +32 -0
- package/reference/packages/ui/src/knowledge/README.md +31 -0
- package/reference/packages/ui/src/theme/presets/README.md +19 -0
- package/reference/scaffold/core/organization-model.mdx +1 -1
- package/reference/scaffold/recipes/add-a-feature.md +1 -1
- package/reference/scaffold/recipes/customize-crm-actions.md +3 -3
- package/reference/scaffold/recipes/customize-organization-model.md +3 -3
- package/reference/scaffold/recipes/extend-crm.md +12 -8
- package/reference/scaffold/recipes/extend-lead-gen.md +129 -20
- package/reference/scaffold/recipes/gate-by-feature-or-admin.md +1 -1
- package/reference/scaffold/recipes/index.md +6 -0
- package/reference/scaffold/reference/contracts.md +829 -595
- package/reference/scaffold/reference/feature-registry.md +2 -1
- package/reference/scaffold/ui/composition-extensibility.mdx +17 -0
- package/reference/claude-config/skills/configure/SKILL.md +0 -98
- package/reference/claude-config/skills/configure/operations/customers.md +0 -150
- package/reference/claude-config/skills/configure/operations/features.md +0 -162
- package/reference/claude-config/skills/configure/operations/goals.md +0 -147
- package/reference/claude-config/skills/configure/operations/identity.md +0 -133
- package/reference/claude-config/skills/configure/operations/labels.md +0 -128
- package/reference/claude-config/skills/configure/operations/offerings.md +0 -159
- package/reference/claude-config/skills/configure/operations/roles.md +0 -153
- package/reference/claude-config/skills/configure/operations/techStack.md +0 -139
package/dist/test-utils/index.js
CHANGED
|
@@ -6752,6 +6752,7 @@ createAdapter("acqDb", [
|
|
|
6752
6752
|
"markProposalReviewed",
|
|
6753
6753
|
"updateCloseLostReason",
|
|
6754
6754
|
"updateFees",
|
|
6755
|
+
"cacheInstantlyThreadIds",
|
|
6755
6756
|
"transitionItem",
|
|
6756
6757
|
"setContactNurture",
|
|
6757
6758
|
"cancelSchedulesAndHitlByEmail",
|
|
@@ -24262,6 +24263,7 @@ var mockAcqDb = (overrides) => createMockAdapter(
|
|
|
24262
24263
|
"markProposalReviewed",
|
|
24263
24264
|
"updateCloseLostReason",
|
|
24264
24265
|
"updateFees",
|
|
24266
|
+
"cacheInstantlyThreadIds",
|
|
24265
24267
|
"transitionItem",
|
|
24266
24268
|
"setContactNurture",
|
|
24267
24269
|
"cancelSchedulesAndHitlByEmail",
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Typed wrapper over platform.call() for acquisition lead management.
|
|
5
5
|
* Singleton export -- no credential needed (platform tool).
|
|
6
6
|
*
|
|
7
|
-
*
|
|
7
|
+
* 56 methods covering lists, companies, contacts, deals, list-stage updates, deal-sync, deal notes, deal tasks, enrichment, and social monitoring operations.
|
|
8
8
|
* organizationId is injected server-side by the dispatcher -- never sent from the SDK.
|
|
9
9
|
*/
|
|
10
10
|
import { type TypedAdapter } from './create-adapter.js';
|
|
@@ -5,14 +5,7 @@
|
|
|
5
5
|
* from within worker threads. Communicates with the parent process via
|
|
6
6
|
* postMessage() -- the parent dispatches to the real service layer.
|
|
7
7
|
*/
|
|
8
|
-
|
|
9
|
-
interface ToolResultMessage {
|
|
10
|
-
type: 'tool-result';
|
|
11
|
-
id: string;
|
|
12
|
-
result?: unknown;
|
|
13
|
-
error?: string;
|
|
14
|
-
code?: string;
|
|
15
|
-
}
|
|
8
|
+
import type { ToolCallResponse } from '@repo/core/execution/engine/tools/messages';
|
|
16
9
|
/** Inbound credential-result from parent */
|
|
17
10
|
interface CredentialResultMessage {
|
|
18
11
|
type: 'credential-result';
|
|
@@ -42,7 +35,7 @@ export declare class PlatformToolError extends Error {
|
|
|
42
35
|
* Handle a tool-result message from the parent process.
|
|
43
36
|
* Called from the parentPort.on('message') handler in index.ts.
|
|
44
37
|
*/
|
|
45
|
-
export declare function handleToolResult(msg:
|
|
38
|
+
export declare function handleToolResult(msg: ToolCallResponse): void;
|
|
46
39
|
/**
|
|
47
40
|
* Handle a credential-result message from the parent process.
|
|
48
41
|
* Called from the parentPort.on('message') handler in index.ts.
|
package/dist/worker/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elevasis/sdk",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.16.0",
|
|
4
4
|
"description": "SDK for building Elevasis organization resources",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -18,6 +18,10 @@
|
|
|
18
18
|
"./test-utils": {
|
|
19
19
|
"types": "./dist/test-utils/index.d.ts",
|
|
20
20
|
"import": "./dist/test-utils/index.js"
|
|
21
|
+
},
|
|
22
|
+
"./node": {
|
|
23
|
+
"types": "./dist/node/index.d.ts",
|
|
24
|
+
"import": "./dist/node/index.js"
|
|
21
25
|
}
|
|
22
26
|
},
|
|
23
27
|
"files": [
|
|
@@ -29,11 +33,14 @@
|
|
|
29
33
|
"dist/types/worker/adapters/",
|
|
30
34
|
"dist/test-utils/index.js",
|
|
31
35
|
"dist/test-utils/index.d.ts",
|
|
36
|
+
"dist/node/",
|
|
32
37
|
"dist/cli.cjs",
|
|
33
38
|
"reference/"
|
|
34
39
|
],
|
|
35
40
|
"dependencies": {
|
|
36
|
-
"
|
|
41
|
+
"@mdx-js/mdx": "^3.1.1",
|
|
42
|
+
"esbuild": "^0.25.0",
|
|
43
|
+
"remark-gfm": "^4.0.1"
|
|
37
44
|
},
|
|
38
45
|
"peerDependencies": {
|
|
39
46
|
"zod": "^4.1.0"
|
|
@@ -50,10 +57,12 @@
|
|
|
50
57
|
"tsup": "^8.0.0",
|
|
51
58
|
"typescript": "5.9.2",
|
|
52
59
|
"zod": "^4.1.0",
|
|
53
|
-
"@repo/core": "0.
|
|
60
|
+
"@repo/core": "0.16.0",
|
|
61
|
+
"@repo/eslint-config": "0.0.0",
|
|
54
62
|
"@repo/typescript-config": "0.0.0"
|
|
55
63
|
},
|
|
56
64
|
"scripts": {
|
|
65
|
+
"lint": "eslint src --max-warnings 0",
|
|
57
66
|
"build": "node -e \"require('fs').rmSync('dist',{recursive:true,force:true})\" && tsc -p tsconfig.core-dts.json && tsc -p tsconfig.build.json && tsup && rollup -c rollup.dts.config.mjs && esbuild src/cli/index.ts --bundle --platform=node --outfile=dist/cli.cjs --format=cjs --external:esbuild --banner:js=\"#!/usr/bin/env node\" && node scripts/copy-reference-docs.mjs && node ../../scripts/monorepo/generate-reference-artifacts.js",
|
|
58
67
|
"type-check": "tsc --noEmit",
|
|
59
68
|
"check-types": "pnpm type-check",
|
package/reference/_navigation.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Auto-generated from the package reference manifests.
|
|
4
4
|
|
|
5
|
-
Package entries indexed:
|
|
5
|
+
Package entries indexed: 54.
|
|
6
6
|
|
|
7
7
|
## @elevasis/core / Core
|
|
8
8
|
|
|
@@ -16,6 +16,12 @@ Package entries indexed: 47.
|
|
|
16
16
|
| --- | --- | --- | --- |
|
|
17
17
|
| Entities | `packages/core/src/business/README.md` | Published base entity contracts (Project, Milestone, Task, Deal, Company, Contact) generic over a metadata extension slot. | (not specified) |
|
|
18
18
|
|
|
19
|
+
## @elevasis/core / Knowledge
|
|
20
|
+
|
|
21
|
+
| Resource | Location | Description | When to Load |
|
|
22
|
+
| --- | --- | --- | --- |
|
|
23
|
+
| Knowledge | `packages/core/src/knowledge/README.md` | Published knowledge query layer: byFeature/byKind/byOwner/governs/governedBy queries, parsePath, and output formatters. | (not specified) |
|
|
24
|
+
|
|
19
25
|
## @elevasis/core / Organization Model
|
|
20
26
|
|
|
21
27
|
| Resource | Location | Description | When to Load |
|
|
@@ -46,6 +52,19 @@ Package entries indexed: 47.
|
|
|
46
52
|
| --- | --- | --- | --- |
|
|
47
53
|
| Test Utils | `runtime.mdx` | Workflow runner, registry assertion, and typed adapter mocks for SDK consumers. | (not specified) |
|
|
48
54
|
|
|
55
|
+
## @elevasis/sdk / Tooling
|
|
56
|
+
|
|
57
|
+
| Resource | Location | Description | When to Load |
|
|
58
|
+
| --- | --- | --- | --- |
|
|
59
|
+
| Node Build Tooling | `cli.mdx` | Node-only build helpers: knowledge codegen and other fs/path/process utilities. Not browser-safe. | (not specified) |
|
|
60
|
+
|
|
61
|
+
## @elevasis/ui / Build
|
|
62
|
+
|
|
63
|
+
| Resource | Location | Description | When to Load |
|
|
64
|
+
| --- | --- | --- | --- |
|
|
65
|
+
| Vite | `packages/ui/src/knowledge/README.md` | Composite Vite plugin factory (elevasisVite) that bundles all @elevasis/ui Vite plugins into a single array for consumer vite.config.ts files. | (not specified) |
|
|
66
|
+
| Vite Plugin Knowledge | `packages/ui/src/knowledge/README.md` | Vite plugin that regenerates the build-time knowledge MDX bodies and search index, with HMR support. | (not specified) |
|
|
67
|
+
|
|
49
68
|
## @elevasis/ui / Components
|
|
50
69
|
|
|
51
70
|
| Resource | Location | Description | When to Load |
|
|
@@ -70,6 +89,7 @@ Package entries indexed: 47.
|
|
|
70
89
|
| Features Monitoring Requests | `packages/ui/src/features/README.md` | Published submitted-requests list, detail, and triage surface for downstream shells. | (not specified) |
|
|
71
90
|
| Features SEO | `packages/ui/src/features/README.md` | Published SEO feature surface for downstream shells. | (not specified) |
|
|
72
91
|
| Features Settings | `packages/ui/src/features/README.md` | Published settings feature surface for downstream shells. | (not specified) |
|
|
92
|
+
| Features Knowledge | `packages/ui/src/features/README.md` | Published knowledge feature manifest for downstream shells. | (not specified) |
|
|
73
93
|
|
|
74
94
|
## @elevasis/ui / Foundation
|
|
75
95
|
|
|
@@ -120,6 +140,8 @@ Package entries indexed: 47.
|
|
|
120
140
|
| --- | --- | --- | --- |
|
|
121
141
|
| Theme | `packages/ui/src/theme/README.md` | Published theme entry for downstream applications. | (not specified) |
|
|
122
142
|
| Graph | `packages/ui/src/graph/README.md` | Published graph helper and visualization entry. | (not specified) |
|
|
143
|
+
| Theme Presets | `packages/ui/src/theme/presets/README.md` | Re-exports the canonical THEME_PRESETS tuple, ThemePresetName union, and ThemePresetEnum Zod enum from @repo/core. Single source of truth for preset names across UI, schemas, and Zustand state. | (not specified) |
|
|
144
|
+
| Knowledge | `packages/ui/src/knowledge/README.md` | Published knowledge browser primitives: Browser, Tree, NodeList, NodeView, SearchBar, MDX provider, and the generated KNOWLEDGE_BODIES map. | (not specified) |
|
|
123
145
|
|
|
124
146
|
---
|
|
125
147
|
|
|
@@ -29,6 +29,20 @@
|
|
|
29
29
|
"referencePath": "packages/core/src/business/README.md",
|
|
30
30
|
"publishedExportPath": "./dist/business/entities-published.js"
|
|
31
31
|
},
|
|
32
|
+
{
|
|
33
|
+
"packageName": "@elevasis/core",
|
|
34
|
+
"packageDir": "packages/core",
|
|
35
|
+
"subpath": "./knowledge",
|
|
36
|
+
"kind": "subpath",
|
|
37
|
+
"title": "Knowledge",
|
|
38
|
+
"description": "Published knowledge query layer: byFeature/byKind/byOwner/governs/governedBy queries, parsePath, and output formatters.",
|
|
39
|
+
"group": "Knowledge",
|
|
40
|
+
"order": 1,
|
|
41
|
+
"sourcePath": "packages/core/src/knowledge/index.ts",
|
|
42
|
+
"docPath": "packages/core/src/knowledge/README.md",
|
|
43
|
+
"referencePath": "packages/core/src/knowledge/README.md",
|
|
44
|
+
"publishedExportPath": "./dist/knowledge/index.js"
|
|
45
|
+
},
|
|
32
46
|
{
|
|
33
47
|
"packageName": "@elevasis/core",
|
|
34
48
|
"packageDir": "packages/core",
|
|
@@ -99,6 +113,48 @@
|
|
|
99
113
|
"referencePath": "runtime.mdx",
|
|
100
114
|
"publishedExportPath": "./dist/test-utils/index.js"
|
|
101
115
|
},
|
|
116
|
+
{
|
|
117
|
+
"packageName": "@elevasis/sdk",
|
|
118
|
+
"packageDir": "packages/sdk",
|
|
119
|
+
"subpath": "./node",
|
|
120
|
+
"kind": "subpath",
|
|
121
|
+
"title": "Node Build Tooling",
|
|
122
|
+
"description": "Node-only build helpers: knowledge codegen and other fs/path/process utilities. Not browser-safe.",
|
|
123
|
+
"group": "Tooling",
|
|
124
|
+
"order": 1,
|
|
125
|
+
"sourcePath": "packages/sdk/src/node/index.ts",
|
|
126
|
+
"docPath": "apps/docs/content/docs/sdk/cli.mdx",
|
|
127
|
+
"referencePath": "cli.mdx",
|
|
128
|
+
"publishedExportPath": "./dist/node/index.js"
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
"packageName": "@elevasis/ui",
|
|
132
|
+
"packageDir": "packages/ui",
|
|
133
|
+
"subpath": "./vite",
|
|
134
|
+
"kind": "subpath",
|
|
135
|
+
"title": "Vite",
|
|
136
|
+
"description": "Composite Vite plugin factory (elevasisVite) that bundles all @elevasis/ui Vite plugins into a single array for consumer vite.config.ts files.",
|
|
137
|
+
"group": "Build",
|
|
138
|
+
"order": 0,
|
|
139
|
+
"sourcePath": "packages/ui/src/vite/index.ts",
|
|
140
|
+
"docPath": "packages/ui/src/knowledge/README.md",
|
|
141
|
+
"referencePath": "packages/ui/src/knowledge/README.md",
|
|
142
|
+
"publishedExportPath": "./dist/vite/index.js"
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
"packageName": "@elevasis/ui",
|
|
146
|
+
"packageDir": "packages/ui",
|
|
147
|
+
"subpath": "./vite-plugin-knowledge",
|
|
148
|
+
"kind": "subpath",
|
|
149
|
+
"title": "Vite Plugin Knowledge",
|
|
150
|
+
"description": "Vite plugin that regenerates the build-time knowledge MDX bodies and search index, with HMR support.",
|
|
151
|
+
"group": "Build",
|
|
152
|
+
"order": 1,
|
|
153
|
+
"sourcePath": "packages/ui/src/vite-plugin-knowledge/index.ts",
|
|
154
|
+
"docPath": "packages/ui/src/knowledge/README.md",
|
|
155
|
+
"referencePath": "packages/ui/src/knowledge/README.md",
|
|
156
|
+
"publishedExportPath": "./dist/vite-plugin-knowledge/index.js"
|
|
157
|
+
},
|
|
102
158
|
{
|
|
103
159
|
"packageName": "@elevasis/ui",
|
|
104
160
|
"packageDir": "packages/ui",
|
|
@@ -309,6 +365,20 @@
|
|
|
309
365
|
"referencePath": "packages/ui/src/features/README.md",
|
|
310
366
|
"publishedExportPath": "./dist/features/settings/index.js"
|
|
311
367
|
},
|
|
368
|
+
{
|
|
369
|
+
"packageName": "@elevasis/ui",
|
|
370
|
+
"packageDir": "packages/ui",
|
|
371
|
+
"subpath": "./features/knowledge",
|
|
372
|
+
"kind": "subpath",
|
|
373
|
+
"title": "Features Knowledge",
|
|
374
|
+
"description": "Published knowledge feature manifest for downstream shells.",
|
|
375
|
+
"group": "Features",
|
|
376
|
+
"order": 11,
|
|
377
|
+
"sourcePath": "packages/ui/src/features/knowledge/index.ts",
|
|
378
|
+
"docPath": "packages/ui/src/features/README.md",
|
|
379
|
+
"referencePath": "packages/ui/src/features/README.md",
|
|
380
|
+
"publishedExportPath": "./dist/features/knowledge/index.js"
|
|
381
|
+
},
|
|
312
382
|
{
|
|
313
383
|
"packageName": "@elevasis/ui",
|
|
314
384
|
"packageDir": "packages/ui",
|
|
@@ -658,6 +728,34 @@
|
|
|
658
728
|
"docPath": "packages/ui/src/graph/README.md",
|
|
659
729
|
"referencePath": "packages/ui/src/graph/README.md",
|
|
660
730
|
"publishedExportPath": "./dist/graph/index.js"
|
|
731
|
+
},
|
|
732
|
+
{
|
|
733
|
+
"packageName": "@elevasis/ui",
|
|
734
|
+
"packageDir": "packages/ui",
|
|
735
|
+
"subpath": "./theme/presets",
|
|
736
|
+
"kind": "subpath",
|
|
737
|
+
"title": "Theme Presets",
|
|
738
|
+
"description": "Re-exports the canonical THEME_PRESETS tuple, ThemePresetName union, and ThemePresetEnum Zod enum from @repo/core. Single source of truth for preset names across UI, schemas, and Zustand state.",
|
|
739
|
+
"group": "Visual",
|
|
740
|
+
"order": 2,
|
|
741
|
+
"sourcePath": "packages/ui/src/theme/presets/index.ts",
|
|
742
|
+
"docPath": "packages/ui/src/theme/presets/README.md",
|
|
743
|
+
"referencePath": "packages/ui/src/theme/presets/README.md",
|
|
744
|
+
"publishedExportPath": "./dist/theme/presets/index.js"
|
|
745
|
+
},
|
|
746
|
+
{
|
|
747
|
+
"packageName": "@elevasis/ui",
|
|
748
|
+
"packageDir": "packages/ui",
|
|
749
|
+
"subpath": "./knowledge",
|
|
750
|
+
"kind": "subpath",
|
|
751
|
+
"title": "Knowledge",
|
|
752
|
+
"description": "Published knowledge browser primitives: Browser, Tree, NodeList, NodeView, SearchBar, MDX provider, and the generated KNOWLEDGE_BODIES map.",
|
|
753
|
+
"group": "Visual",
|
|
754
|
+
"order": 3,
|
|
755
|
+
"sourcePath": "packages/ui/src/knowledge/index.ts",
|
|
756
|
+
"docPath": "packages/ui/src/knowledge/README.md",
|
|
757
|
+
"referencePath": "packages/ui/src/knowledge/README.md",
|
|
758
|
+
"publishedExportPath": "./dist/knowledge/index.js"
|
|
661
759
|
}
|
|
662
760
|
]
|
|
663
761
|
}
|
|
@@ -6,6 +6,19 @@ description: Canonical first-read for agents entering the template scaffold -- p
|
|
|
6
6
|
|
|
7
7
|
Read this file first when entering a freshly scaffolded project.
|
|
8
8
|
|
|
9
|
+
## Project Profile
|
|
10
|
+
|
|
11
|
+
Before doing anything else, check for `.claude/memory/profile.md`. It is created by `/tutorial` on first invocation and persists across sessions.
|
|
12
|
+
|
|
13
|
+
If present, read it. The file declares which onboarding **track** is active -- `vibe-coder` (non-technical user, agent does the work) or `technical` (developer, code-first) -- and ships a tone block describing how to communicate.
|
|
14
|
+
|
|
15
|
+
Apply the tone block to ALL agent output for the rest of the session, not just inside `/tutorial`:
|
|
16
|
+
|
|
17
|
+
- **vibe-coder track:** never use technical vocabulary in user-facing dialogue (workflow -> automation, deploy -> make it live, schema -> "the information your automation needs"). Tool calls are made silently -- do not narrate slash commands, file paths, or build steps. The full swap table lives in `profile.md`.
|
|
18
|
+
- **technical track:** code-first, current command surface, real file paths. The user reads diffs and stacktraces; do not over-explain.
|
|
19
|
+
|
|
20
|
+
If the file does not exist, the user has not run `/tutorial` yet. Proceed normally and note that running `/tutorial` would establish a project tone for future sessions.
|
|
21
|
+
|
|
9
22
|
## First Action: Check Active Projects
|
|
10
23
|
|
|
11
24
|
Before loading any docs for a new session, check whether the user's ask resumes or relates to an in-flight client project. Project context (milestones, tasks, resume notes) is DB-canonical -- agents and CLI read/write it through the `elevasis-sdk project:*` surface.
|
|
@@ -1,43 +1,43 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Edits to the canonical organization model go through /
|
|
1
|
+
---
|
|
2
|
+
description: Edits to the canonical organization model go through /knowledge
|
|
3
3
|
paths:
|
|
4
4
|
- core/config/organization-model.ts
|
|
5
5
|
- core/config/extensions/**/*.ts
|
|
6
|
-
---
|
|
7
|
-
|
|
8
|
-
# Organization Model Edit Guide
|
|
9
|
-
|
|
10
|
-
`foundations/config/organization-model.ts` is the single source of truth for this
|
|
11
|
-
project's organizational identity -- it encodes customers, offerings, roles, goals,
|
|
12
|
-
features, statuses, and resource mappings that agents, workflows, and the UI shell all
|
|
13
|
-
consume at runtime.
|
|
14
|
-
|
|
15
|
-
## Preferred Entry Point: `/
|
|
16
|
-
|
|
17
|
-
Direct edits to `organization-model.ts` are discouraged. Instead, use `/
|
|
18
|
-
`/
|
|
19
|
-
|
|
20
|
-
1. The skill reads the current model so proposals start from ground truth.
|
|
21
|
-
2. It drafts only the specific block being changed, leaving everything else intact.
|
|
22
|
-
3. The user confirms before any file is written.
|
|
23
|
-
4. After writing, `pnpm -C operations check-types` runs and `OrganizationModelSchema.parse()`
|
|
24
|
-
is verified. On failure the file is rolled back automatically.
|
|
25
|
-
|
|
26
|
-
Use `/
|
|
27
|
-
`roles`, `goals`, `techStack`, `features`, or `labels`.
|
|
28
|
-
|
|
29
|
-
## Runtime Validation
|
|
30
|
-
|
|
31
|
-
The model is validated at startup via `resolveOrganizationModel()` followed by
|
|
32
|
-
`OrganizationModelSchema.parse()`. Cross-reference checks (segment ID refs in offerings,
|
|
33
|
-
role reporting lines, period ordering in goals) are runtime-only and not caught by tsc
|
|
34
|
-
alone -- always let the ceremony run both checks before treating a change as complete.
|
|
35
|
-
|
|
36
|
-
## Extension Files
|
|
37
|
-
|
|
38
|
-
New Zod extension files under `foundations/config/extensions/` are Level B codify
|
|
39
|
-
operations. Route these through `/
|
|
40
|
-
to explicit user confirmation before scaffolding a new `.ts` file.
|
|
41
|
-
|
|
42
|
-
This is a soft guide, not a hard block. The ceremony exists to prevent silent schema
|
|
43
|
-
drift and to keep the model's editorial history visible.
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# Organization Model Edit Guide
|
|
9
|
+
|
|
10
|
+
`foundations/config/organization-model.ts` is the single source of truth for this
|
|
11
|
+
project's organizational identity -- it encodes customers, offerings, roles, goals,
|
|
12
|
+
features, statuses, and resource mappings that agents, workflows, and the UI shell all
|
|
13
|
+
consume at runtime.
|
|
14
|
+
|
|
15
|
+
## Preferred Entry Point: `/knowledge`
|
|
16
|
+
|
|
17
|
+
Direct edits to `organization-model.ts` are discouraged. Instead, use `/knowledge` (or
|
|
18
|
+
`/knowledge <domain>`) to run the read → propose → confirm → write → validate ceremony:
|
|
19
|
+
|
|
20
|
+
1. The skill reads the current model so proposals start from ground truth.
|
|
21
|
+
2. It drafts only the specific block being changed, leaving everything else intact.
|
|
22
|
+
3. The user confirms before any file is written.
|
|
23
|
+
4. After writing, `pnpm -C operations check-types` runs and `OrganizationModelSchema.parse()`
|
|
24
|
+
is verified. On failure the file is rolled back automatically.
|
|
25
|
+
|
|
26
|
+
Use `/knowledge <domain>` for targeted edits: `identity`, `customers`, `offerings`,
|
|
27
|
+
`roles`, `goals`, `techStack`, `features`, or `labels`.
|
|
28
|
+
|
|
29
|
+
## Runtime Validation
|
|
30
|
+
|
|
31
|
+
The model is validated at startup via `resolveOrganizationModel()` followed by
|
|
32
|
+
`OrganizationModelSchema.parse()`. Cross-reference checks (segment ID refs in offerings,
|
|
33
|
+
role reporting lines, period ordering in goals) are runtime-only and not caught by tsc
|
|
34
|
+
alone -- always let the ceremony run both checks before treating a change as complete.
|
|
35
|
+
|
|
36
|
+
## Extension Files
|
|
37
|
+
|
|
38
|
+
New Zod extension files under `foundations/config/extensions/` are Level B codify
|
|
39
|
+
operations. Route these through `/knowledge <domain>` as well -- the skill gates Level B
|
|
40
|
+
to explicit user confirmation before scaffolding a new `.ts` file.
|
|
41
|
+
|
|
42
|
+
This is a soft guide, not a hard block. The ceremony exists to prevent silent schema
|
|
43
|
+
drift and to keep the model's editorial history visible.
|
|
@@ -42,7 +42,7 @@ Full Organization OS documentation ships with the SDK and is available locally a
|
|
|
42
42
|
All paths under `node_modules/@elevasis/sdk/reference/scaffold/`:
|
|
43
43
|
|
|
44
44
|
- `node_modules/@elevasis/sdk/reference/scaffold/index.mdx` -- scaffold root and navigation
|
|
45
|
-
- `node_modules/@elevasis/sdk/reference/scaffold/core/organization-model.mdx` -- semantic contract, all 14 domains, adapter authoring, validation gate, `/
|
|
45
|
+
- `node_modules/@elevasis/sdk/reference/scaffold/core/organization-model.mdx` -- semantic contract, all 14 domains, adapter authoring, validation gate, `/knowledge` entry point
|
|
46
46
|
- `node_modules/@elevasis/sdk/reference/scaffold/core/organization-graph.mdx` -- graph derivation, node/edge taxonomy, lenses
|
|
47
47
|
- `node_modules/@elevasis/sdk/reference/scaffold/ui/feature-shell.mdx` -- FeatureModule manifest, provider runtime
|
|
48
48
|
- `node_modules/@elevasis/sdk/reference/scaffold/ui/composition-extensibility.mdx` -- layout primitives, router abstraction
|
|
@@ -77,35 +77,35 @@ All paths under `node_modules/@elevasis/sdk/reference/scaffold/`:
|
|
|
77
77
|
|
|
78
78
|
## When Working with Organization OS
|
|
79
79
|
|
|
80
|
-
- **Changing org model (structural reality):** Use `/
|
|
80
|
+
- **Changing org model (structural reality):** Use `/knowledge` as the entry point. Direct edits to `foundations/config/organization-model.ts` are discouraged -- `/knowledge` runs the read → propose → confirm → write → validate ceremony. Run `/knowledge` for the full layered flow or `/knowledge \<domain>` for a targeted domain.
|
|
81
81
|
- **Building or extending CRM:** Start with `node_modules/@elevasis/sdk/reference/scaffold/recipes/extend-crm.md`. CRM spans Organization OS sales semantics, shared UI primitives, deal hooks, workflow adapters, and generated contracts.
|
|
82
82
|
- **Building or extending lead gen:** Start with `node_modules/@elevasis/sdk/reference/scaffold/recipes/extend-lead-gen.md`. Lead gen spans Organization OS prospecting semantics, shared UI primitives, list/member hooks, artifact hooks, workflow adapters, and generated contracts.
|
|
83
83
|
- **Customizing CRM deal actions:** Follow `node_modules/@elevasis/sdk/reference/scaffold/recipes/customize-crm-actions.md`. Do not add `sales.actions` to the org model; the v1 server-side override surface is intentionally deferred.
|
|
84
|
-
- **Adding a feature:** Follow `node_modules/@elevasis/sdk/reference/scaffold/recipes/add-a-feature.md`. For toggling an existing feature, use `/
|
|
84
|
+
- **Adding a feature:** Follow `node_modules/@elevasis/sdk/reference/scaffold/recipes/add-a-feature.md`. For toggling an existing feature, use `/knowledge features`.
|
|
85
85
|
- **Adding a resource:** Follow `node_modules/@elevasis/sdk/reference/scaffold/recipes/add-a-resource.md`.
|
|
86
86
|
- **Extending entities:** Start with `foundations/types/entities.ts` for the demo extension pattern. Base shapes come from `@elevasis/core/entities`.
|
|
87
87
|
- **Authoring a workflow that takes a Project/Deal/etc.:** Reference entity types from `foundations/types/entities.ts` in the input schema -- do not redeclare them.
|
|
88
88
|
- **Understanding contracts:** Check `node_modules/@elevasis/sdk/reference/scaffold/reference/contracts.md` for current type shapes.
|
|
89
89
|
- **Debugging sync issues:** Check `node_modules/@elevasis/sdk/reference/scaffold/operations/propagation-pipeline.md` for the verification pipeline.
|
|
90
90
|
|
|
91
|
-
## `/
|
|
91
|
+
## `/knowledge` -- Org Model QA Entry Point
|
|
92
92
|
|
|
93
|
-
`/
|
|
93
|
+
`/knowledge` is the recurring, safe-to-re-run org model editor for this project. It is a skill (not a command) at `.claude/skills/knowledge/SKILL.md`.
|
|
94
94
|
|
|
95
95
|
**Usage:**
|
|
96
96
|
|
|
97
|
-
- `/
|
|
98
|
-
- `/
|
|
99
|
-
- `/
|
|
100
|
-
- `/
|
|
101
|
-
- `/
|
|
102
|
-
- `/
|
|
103
|
-
- `/
|
|
104
|
-
- `/
|
|
105
|
-
- `/
|
|
97
|
+
- `/knowledge` -- layered flow: identity → customers → offerings → roles → goals → techStack
|
|
98
|
+
- `/knowledge identity` -- legal identity, mission/vision, industry, geography, timezone
|
|
99
|
+
- `/knowledge customers` -- customer segments with jobs-to-be-done, pains, gains, firmographics
|
|
100
|
+
- `/knowledge offerings` -- products and services with pricing model and segment references
|
|
101
|
+
- `/knowledge roles` -- role chart with responsibilities, reporting lines, and holders
|
|
102
|
+
- `/knowledge goals` -- organizational goals with period and measurable outcomes
|
|
103
|
+
- `/knowledge techStack` -- external-SaaS integration metadata on resource mappings
|
|
104
|
+
- `/knowledge features` -- enable, disable, or add features
|
|
105
|
+
- `/knowledge labels` -- edit display labels on enum entries (statuses, stages)
|
|
106
106
|
|
|
107
107
|
Every write is gated: `resolveOrganizationModel()` must succeed (Zod cross-refs pass) and `pnpm -C operations check-types` must pass. On failure the change is rolled back.
|
|
108
108
|
|
|
109
|
-
**Distinction from `/setup`:** `/setup` is first-time bootstrap only. After bootstrap it delegates here. `/
|
|
109
|
+
**Distinction from `/setup`:** `/setup` is first-time bootstrap only. After bootstrap it delegates here. `/knowledge` is idempotent and safe to re-run at any time.
|
|
110
110
|
|
|
111
|
-
The ambient vibe layer (`.claude/rules/vibe.md`) automatically detects Codify intent in plain language and delegates to `/
|
|
111
|
+
The ambient vibe layer (`.claude/rules/vibe.md`) automatically detects Codify intent in plain language and delegates to `/knowledge`. Power users can invoke `/knowledge` directly to bypass the ambient layer entirely.
|
|
@@ -104,13 +104,9 @@ For real-time updates, feature surfaces use the local singleton wrapper:
|
|
|
104
104
|
import { sseConnectionManager } from '@/lib/sse/SSEConnectionManager'
|
|
105
105
|
```
|
|
106
106
|
|
|
107
|
-
**
|
|
107
|
+
**WorkOS config:**
|
|
108
108
|
|
|
109
|
-
|
|
110
|
-
VITE_WORKOS_CLIENT_ID=client_...
|
|
111
|
-
VITE_WORKOS_REDIRECT_URI=http://localhost:4300/auth-redirect
|
|
112
|
-
VITE_WORKOS_SIGNOUT_URI=http://localhost:4300/login
|
|
113
|
-
```
|
|
109
|
+
WorkOS `clientId`, `redirectUri`, and `signoutUri` are hardcoded in `ui/src/config/workos.ts` -- no UI env vars are required to run the template. Edit that file if a fork needs a different WorkOS client. The dev server runs on port `4300` with Vite `strictPort: true`, so a second `pnpm -C ui dev` on the same machine fails fast instead of drifting.
|
|
114
110
|
|
|
115
111
|
The API URL is centralized in `ui/src/lib/constants/api.ts`. In the current template it is hard-coded to `https://api.elevasis.io`, so if the bootstrap is repointed to another API target, that file is the source of truth.
|
|
116
112
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Ambient intent classifier -- routes natural-language input to 7 intent buckets without a slash command; Codify and Toggle delegate to /
|
|
2
|
+
description: Ambient intent classifier -- routes natural-language input to 7 intent buckets without a slash command; Codify and Toggle delegate to /knowledge
|
|
3
3
|
paths:
|
|
4
4
|
- "**/*"
|
|
5
5
|
---
|
|
@@ -112,12 +112,12 @@ The user describes organizational reality that is not yet expressed in the model
|
|
|
112
112
|
| "We track deal stage as discovery, scoping, proposal, closed" | Describes custom CRM stages that should replace defaults |
|
|
113
113
|
| "Add a project type called 'retainer' with monthly billing and a contract field" | Explicit request to add a new entity extension |
|
|
114
114
|
|
|
115
|
-
**Agent action:** delegate immediately to `/
|
|
115
|
+
**Agent action:** delegate immediately to `/knowledge`. Do not attempt the ceremony yourself. Invoke with the relevant domain: `/knowledge crm` for deal/contact changes, `/knowledge projects` for project types, `/knowledge features` for feature toggles. Plain-language summary of what was detected is acceptable before delegating, but the actual draft-confirm-write ceremony belongs to `/knowledge`.
|
|
116
116
|
|
|
117
|
-
This routing applies to both codify levels (decision #21 -- Codify ceremony delegated to `/
|
|
117
|
+
This routing applies to both codify levels (decision #21 -- Codify ceremony delegated to `/knowledge`):
|
|
118
118
|
|
|
119
|
-
- **Level A** (config-only edits to `organization-model.ts`, feature toggles, label renames): delegate to `/
|
|
120
|
-
- **Level B** (new Zod extension files in `foundations/config/extensions/`): also delegate to `/
|
|
119
|
+
- **Level A** (config-only edits to `organization-model.ts`, feature toggles, label renames): delegate to `/knowledge <domain>` immediately.
|
|
120
|
+
- **Level B** (new Zod extension files in `foundations/config/extensions/`): also delegate to `/knowledge <domain>`; `/knowledge` gates Level B to explicit user asks before scaffolding a new TS file.
|
|
121
121
|
|
|
122
122
|
Vibe detects the intent and delegates in both cases. It does not run either pipeline itself.
|
|
123
123
|
|
|
@@ -127,7 +127,7 @@ For "build/extend lead gen" / "campaign creator" / "outbound list state" asks, c
|
|
|
127
127
|
|
|
128
128
|
For "add a custom CRM action" / "Send Quote button" asks, classify as Codify, then read `node_modules/@elevasis/sdk/reference/scaffold/recipes/customize-crm-actions.md` before editing. Start with the shared `crmActions` provider path for action visibility, labels, ordering, and render-time configuration. In v1, platform-known/default action endpoint behavior is server-constrained; use project-owned UI that calls the workflow directly when a custom key sits outside that server-dispatched set.
|
|
129
129
|
|
|
130
|
-
Heuristics for when to propose codification (passed to `/
|
|
130
|
+
Heuristics for when to propose codification (passed to `/knowledge` as context):
|
|
131
131
|
|
|
132
132
|
- First mention of a new attribute: note to `resume_context`, do not propose yet
|
|
133
133
|
- Second mention OR explicit declaration ("we're ecom"): propose extension
|
|
@@ -148,7 +148,7 @@ The user wants to enable or disable a feature.
|
|
|
148
148
|
| "Disable monitoring for now" | "Disable" + feature reference |
|
|
149
149
|
| "We don't use SEO, turn it off" | Declarative + "turn it off" = feature disable |
|
|
150
150
|
|
|
151
|
-
**Agent action:** delegate to `/
|
|
151
|
+
**Agent action:** delegate to `/knowledge features`. The ceremony (confirm + edit `foundations/config/organization-model.ts` + typecheck) belongs to `/knowledge`, not to the ambient rule.
|
|
152
152
|
|
|
153
153
|
## Quick Reference Table
|
|
154
154
|
|
|
@@ -159,8 +159,8 @@ The user wants to enable or disable a feature.
|
|
|
159
159
|
| Describe | "what is", "tell me about", "explain", "where am I" | Agent -- narrate from org model labels |
|
|
160
160
|
| Transition | "done", "stuck", "blocked", "finished", "complete" | Agent -- confirm + `project:task:save` |
|
|
161
161
|
| Navigate | "focus on", "switch to", "back to", "look at" | Agent -- update scope + narrate |
|
|
162
|
-
| Codify | "we are X", "we track Y", repeated attribute, "add type/field" | Delegate to `/
|
|
163
|
-
| Toggle | "enable", "disable", "turn on/off" + feature | Delegate to `/
|
|
162
|
+
| Codify | "we are X", "we track Y", repeated attribute, "add type/field" | Delegate to `/knowledge \<domain>` |
|
|
163
|
+
| Toggle | "enable", "disable", "turn on/off" + feature | Delegate to `/knowledge features` |
|
|
164
164
|
|
|
165
165
|
## Source of Truth for Plain Language
|
|
166
166
|
|
|
@@ -194,9 +194,9 @@ Override per project in `foundations/config/organization-model.ts` under `vibe.c
|
|
|
194
194
|
|
|
195
195
|
This rule covers Phase 1 of the vibe layer rollout. The layers the ambient classifier can narrate and codify in Phase 1 are:
|
|
196
196
|
|
|
197
|
-
- Layer 1 (Model): narrate schema shape, propose codification edits via `/
|
|
198
|
-
- Layer 4 (Features): describe which features are on/off, propose enabling one via `/
|
|
199
|
-
- Layer 7 (Foundations): explain and edit `organization-model.ts` and `extensions/` via `/
|
|
197
|
+
- Layer 1 (Model): narrate schema shape, propose codification edits via `/knowledge`
|
|
198
|
+
- Layer 4 (Features): describe which features are on/off, propose enabling one via `/knowledge`
|
|
199
|
+
- Layer 7 (Foundations): explain and edit `organization-model.ts` and `extensions/` via `/knowledge`
|
|
200
200
|
|
|
201
201
|
Layers 2 (Public API), 3 (UI Shell Runtime), 5 (Toolkit), and 6 (Graph) require runtime read APIs that are not yet available. Do not attempt to narrate or classify against those layers in Phase 1. If the user's input clearly references one of those layers, acknowledge the scope and explain that full support arrives in a later phase.
|
|
202
202
|
|
|
@@ -204,5 +204,5 @@ Layers 2 (Public API), 3 (UI Shell Runtime), 5 (Toolkit), and 6 (Graph) require
|
|
|
204
204
|
|
|
205
205
|
- Vibe is not a slash command. There is no `/vibe` invocation (decision #19 -- ambient rule, not a skill or command).
|
|
206
206
|
- Vibe is not a skill. It lives in this rule file + CLAUDE.md + the PreToolUse hook -- not in `.claude/skills/`.
|
|
207
|
-
- Vibe does not own the codify ceremony. `/
|
|
207
|
+
- Vibe does not own the codify ceremony. `/knowledge` owns draft, confirm, write, and typecheck for both Level A and Level B codify pipelines (decision #21 -- Codify ceremony delegated to `/knowledge`). Vibe detects intent and hands off.
|
|
208
208
|
- Vibe is not active in the monorepo. If working inside the monorepo (not an `external/` project), this ambient routing does not apply.
|