@elevasis/sdk 1.8.2 → 1.8.3
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 +1 -1
- package/dist/index.d.ts +88 -39
- package/dist/types/worker/adapters/lead.d.ts +1 -1
- package/dist/worker/index.js +2 -0
- package/package.json +2 -2
- package/reference/_navigation.md +7 -1
- package/reference/_reference-manifest.json +14 -0
- package/reference/claude-config/logs/scaffold-registry-reminder.log +3 -0
- package/reference/claude-config/rules/agent-start-here.md +254 -254
- package/reference/claude-config/rules/frontend.md +43 -43
- package/reference/claude-config/rules/operations.md +64 -64
- package/reference/claude-config/rules/organization-model.md +42 -43
- package/reference/claude-config/rules/organization-os.md +107 -107
- package/reference/claude-config/rules/shared-types.md +2 -2
- package/reference/claude-config/rules/task-tracking.md +1 -1
- package/reference/claude-config/rules/ui.md +202 -202
- package/reference/claude-config/rules/vibe.md +202 -202
- package/reference/claude-config/skills/configure/SKILL.md +98 -98
- package/reference/claude-config/skills/configure/operations/codify-level-a.md +100 -100
- package/reference/claude-config/skills/configure/operations/codify-level-b.md +158 -158
- package/reference/claude-config/skills/configure/operations/customers.md +150 -150
- package/reference/claude-config/skills/configure/operations/features.md +162 -162
- package/reference/claude-config/skills/configure/operations/goals.md +147 -147
- package/reference/claude-config/skills/configure/operations/identity.md +133 -133
- package/reference/claude-config/skills/configure/operations/labels.md +128 -128
- package/reference/claude-config/skills/configure/operations/offerings.md +159 -159
- package/reference/claude-config/skills/configure/operations/roles.md +153 -153
- package/reference/claude-config/skills/configure/operations/techStack.md +139 -139
- package/reference/claude-config/skills/explore/SKILL.md +78 -78
- package/reference/claude-config/skills/git-sync/SKILL.md +126 -0
- package/reference/claude-config/skills/save/SKILL.md +183 -183
- package/reference/claude-config/skills/setup/SKILL.md +275 -275
- package/reference/claude-config/skills/sync/SKILL.md +10 -44
- package/reference/claude-config/sync-notes/2026-04-22-git-sync-and-sync-notes.md +27 -0
- package/reference/claude-config/sync-notes/2026-04-22-lead-gen-deliverability-removal.md +30 -0
- package/reference/claude-config/sync-notes/README.md +43 -0
- package/reference/packages/core/src/README.md +39 -36
- package/reference/packages/core/src/business/README.md +52 -52
- package/reference/packages/core/src/organization-model/README.md +97 -97
- package/reference/packages/core/src/test-utils/README.md +42 -0
- package/reference/scaffold/core/organization-graph.mdx +272 -272
- package/reference/scaffold/core/organization-model.mdx +320 -320
- package/reference/scaffold/index.mdx +64 -64
- package/reference/scaffold/operations/propagation-pipeline.md +125 -104
- package/reference/scaffold/operations/scaffold-maintenance.md +122 -122
- package/reference/scaffold/operations/workflow-recipes.md +436 -436
- package/reference/scaffold/recipes/add-a-feature.md +158 -158
- package/reference/scaffold/recipes/add-a-resource.md +158 -158
- package/reference/scaffold/recipes/customize-organization-model.md +400 -400
- package/reference/scaffold/recipes/extend-a-base-entity.md +140 -140
- package/reference/scaffold/recipes/gate-by-feature-or-admin.md +158 -158
- package/reference/scaffold/recipes/index.md +32 -32
- package/reference/scaffold/reference/contracts.md +608 -607
- package/reference/scaffold/reference/feature-registry.md +2 -0
- package/reference/scaffold/reference/glossary.md +105 -105
- package/reference/scaffold/ui/composition-extensibility.mdx +1 -1
- package/reference/scaffold/ui/feature-flags-and-gating.md +1 -1
|
@@ -1,122 +1,122 @@
|
|
|
1
|
-
---
|
|
2
|
-
title: Scaffold Maintenance
|
|
3
|
-
description: How scaffold documentation is organized, generated, and bundled into the SDK -- content placement map, auto-generation pipeline, and instructions for adding new scaffold docs.
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Scaffold Maintenance
|
|
7
|
-
|
|
8
|
-
`🟢 Stable` -- Use this when adding or modifying scaffold documentation.
|
|
9
|
-
|
|
10
|
-
---
|
|
11
|
-
|
|
12
|
-
## Content Placement Model
|
|
13
|
-
|
|
14
|
-
Scaffold docs are co-located with their owning package and copied into the SDK reference at build time. This makes each package owner responsible for their docs and avoids a single monolithic directory.
|
|
15
|
-
|
|
16
|
-
### Placement Rules
|
|
17
|
-
|
|
18
|
-
- If a doc explains a single abstraction boundary, **co-locate it** with the owning package.
|
|
19
|
-
- If a doc explains relationships between multiple abstractions, **centralize it** in `packages/sdk/docs/scaffold/`.
|
|
20
|
-
- If a doc can be derived from code or manifests, **generate it**.
|
|
21
|
-
- Hand-authored docs should point to generated maps rather than restating them.
|
|
22
|
-
|
|
23
|
-
### Source-to-Destination Map
|
|
24
|
-
|
|
25
|
-
| Content | Source | SDK Reference Destination |
|
|
26
|
-
| --------------------------- | --------------------------------------------------------------- | --------------------------------------------- |
|
|
27
|
-
| Organization Model | `packages/core/src/organization-model/organization-model.mdx` | `scaffold/core/organization-model.mdx` |
|
|
28
|
-
| Organization Graph | `packages/core/src/organization-model/organization-graph.mdx` | `scaffold/core/organization-graph.mdx` |
|
|
29
|
-
| Glossary | `packages/core/src/reference/glossary.md` | `scaffold/reference/glossary.md` |
|
|
30
|
-
| Contracts (auto-gen) | `packages/core/src/reference/_generated/contracts.md` | `scaffold/reference/contracts.md` |
|
|
31
|
-
| UI Recipes | `packages/ui/src/scaffold/recipes.md` | `scaffold/ui/recipes.md` |
|
|
32
|
-
| Feature Flags & Gating | `packages/ui/src/scaffold/feature-flags-and-gating.md` | `scaffold/ui/feature-flags-and-gating.md` |
|
|
33
|
-
| Customization | `packages/ui/src/scaffold/customization.md` | `scaffold/ui/customization.md` |
|
|
34
|
-
| Feature Shell | `packages/ui/src/scaffold/feature-shell.mdx` | `scaffold/ui/feature-shell.mdx` |
|
|
35
|
-
| Composition & Extensibility | `packages/ui/src/scaffold/composition-extensibility.mdx` | `scaffold/ui/composition-extensibility.mdx` |
|
|
36
|
-
| Feature Registry (auto-gen) | `packages/ui/src/scaffold/_generated/feature-registry.md` | `scaffold/reference/feature-registry.md` |
|
|
37
|
-
| Scaffold Index | `packages/sdk/docs/scaffold/index.mdx` | `scaffold/index.mdx` |
|
|
38
|
-
| Pathway Recipes (4) | `packages/sdk/docs/scaffold/recipes/` | `scaffold/recipes/` |
|
|
39
|
-
| Workflow Recipes | `packages/sdk/docs/scaffold/operations/workflow-recipes.md` | `scaffold/operations/workflow-recipes.md` |
|
|
40
|
-
| Propagation Pipeline | `packages/sdk/docs/scaffold/operations/propagation-pipeline.md` | `scaffold/operations/propagation-pipeline.md` |
|
|
41
|
-
| This doc | `packages/sdk/docs/scaffold/operations/scaffold-maintenance.md` | `scaffold/operations/scaffold-maintenance.md` |
|
|
42
|
-
|
|
43
|
-
---
|
|
44
|
-
|
|
45
|
-
## Auto-Generation Pipeline
|
|
46
|
-
|
|
47
|
-
Two types of docs are auto-generated from source:
|
|
48
|
-
|
|
49
|
-
### Contracts (`contracts.md`)
|
|
50
|
-
|
|
51
|
-
Generated by `scripts/monorepo/generate-scaffold-contracts.js` from TypeScript source types:
|
|
52
|
-
|
|
53
|
-
- `packages/core/src/organization-model/types.ts` -- Organization Model, Feature System
|
|
54
|
-
- `packages/ui/src/features/registry/types.ts` -- Feature Registry
|
|
55
|
-
- `packages/core/src/platform/registry/types.ts` -- Resource Registry, Deployment Spec
|
|
56
|
-
|
|
57
|
-
Output: `packages/core/src/reference/_generated/contracts.md`
|
|
58
|
-
|
|
59
|
-
### Feature Registry (`feature-registry.md`)
|
|
60
|
-
|
|
61
|
-
Generated by `scripts/monorepo/generate-scaffold-feature-registry.js` from feature manifests:
|
|
62
|
-
|
|
63
|
-
- `packages/ui/src/features/*/manifest.ts` -- individual feature manifests
|
|
64
|
-
- `packages/core/src/organization-model/domains/features.ts` -- feature key definitions
|
|
65
|
-
|
|
66
|
-
Output: `packages/ui/src/scaffold/_generated/feature-registry.md`
|
|
67
|
-
|
|
68
|
-
### Reference Artifacts
|
|
69
|
-
|
|
70
|
-
Generated by `scripts/monorepo/generate-reference-artifacts.js`:
|
|
71
|
-
|
|
72
|
-
- `packages/sdk/reference/_reference-manifest.json` -- machine-readable catalog of all reference entries
|
|
73
|
-
- `packages/sdk/reference/_navigation.md` -- navigation table
|
|
74
|
-
|
|
75
|
-
### Running Generators
|
|
76
|
-
|
|
77
|
-
```bash
|
|
78
|
-
pnpm scaffold:generate # Run both generators
|
|
79
|
-
pnpm scaffold:sync # Generate + validate (the full loop)
|
|
80
|
-
pnpm sdk-ref:generate # Reference artifacts only
|
|
81
|
-
```
|
|
82
|
-
|
|
83
|
-
Generated files should never be edited manually. If the output is wrong, fix the source types or the generator script.
|
|
84
|
-
|
|
85
|
-
---
|
|
86
|
-
|
|
87
|
-
## SDK Build Pipeline (Reference Copy)
|
|
88
|
-
|
|
89
|
-
`packages/sdk/scripts/copy-reference-docs.mjs` runs during `pnpm --filter @elevasis/sdk build` and has three phases:
|
|
90
|
-
|
|
91
|
-
1. **Phase 1:** Copies SDK public docs from `apps/docs/content/docs/sdk/` with link rewriting and MDX escape stripping
|
|
92
|
-
2. **Phase 2:** Copies package-owned reference docs declared in reference manifests
|
|
93
|
-
3. **Phase 3:** Copies scaffold docs from co-located package sources using the `SCAFFOLD_COPIES` map
|
|
94
|
-
|
|
95
|
-
The output lands in `packages/sdk/reference/` which is included in the npm package's `files` array. External projects access it via `node_modules/@elevasis/sdk/reference/`.
|
|
96
|
-
|
|
97
|
-
---
|
|
98
|
-
|
|
99
|
-
## Adding New Scaffold Docs
|
|
100
|
-
|
|
101
|
-
1. **Create the source doc** in the appropriate package:
|
|
102
|
-
- Core concepts: `packages/core/src/...`
|
|
103
|
-
- UI patterns: `packages/ui/src/scaffold/...`
|
|
104
|
-
- Cross-package or SDK-owned: `packages/sdk/docs/scaffold/...`
|
|
105
|
-
|
|
106
|
-
2. **Add to `SCAFFOLD_COPIES`** in `packages/sdk/scripts/copy-reference-docs.mjs`:
|
|
107
|
-
|
|
108
|
-
```javascript
|
|
109
|
-
{ source: 'packages/sdk/docs/scaffold/operations/my-doc.md', target: 'scaffold/operations/my-doc.md' }
|
|
110
|
-
```
|
|
111
|
-
|
|
112
|
-
3. **Update the scaffold index** in `packages/sdk/docs/scaffold/index.mdx` with a link and description.
|
|
113
|
-
|
|
114
|
-
4. **Rebuild the SDK** to verify: `pnpm --filter @elevasis/sdk build`
|
|
115
|
-
|
|
116
|
-
5. **Update the permanent architecture docs** if the new doc covers a concept already referenced in `apps/docs/content/docs/technical/architecture/scaffold-reference.mdx`.
|
|
117
|
-
|
|
118
|
-
---
|
|
119
|
-
|
|
120
|
-
## Freshness Validation
|
|
121
|
-
|
|
122
|
-
At the monorepo level, `pnpm scaffold:sync` followed by `pnpm sync:verify` confirms that all artifacts are current and all downstream projects are consistent. The SDK no longer ships doc validation because external projects no longer carry a `docs/` tree.
|
|
1
|
+
---
|
|
2
|
+
title: Scaffold Maintenance
|
|
3
|
+
description: How scaffold documentation is organized, generated, and bundled into the SDK -- content placement map, auto-generation pipeline, and instructions for adding new scaffold docs.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Scaffold Maintenance
|
|
7
|
+
|
|
8
|
+
`🟢 Stable` -- Use this when adding or modifying scaffold documentation.
|
|
9
|
+
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
## Content Placement Model
|
|
13
|
+
|
|
14
|
+
Scaffold docs are co-located with their owning package and copied into the SDK reference at build time. This makes each package owner responsible for their docs and avoids a single monolithic directory.
|
|
15
|
+
|
|
16
|
+
### Placement Rules
|
|
17
|
+
|
|
18
|
+
- If a doc explains a single abstraction boundary, **co-locate it** with the owning package.
|
|
19
|
+
- If a doc explains relationships between multiple abstractions, **centralize it** in `packages/sdk/docs/scaffold/`.
|
|
20
|
+
- If a doc can be derived from code or manifests, **generate it**.
|
|
21
|
+
- Hand-authored docs should point to generated maps rather than restating them.
|
|
22
|
+
|
|
23
|
+
### Source-to-Destination Map
|
|
24
|
+
|
|
25
|
+
| Content | Source | SDK Reference Destination |
|
|
26
|
+
| --------------------------- | --------------------------------------------------------------- | --------------------------------------------- |
|
|
27
|
+
| Organization Model | `packages/core/src/organization-model/organization-model.mdx` | `scaffold/core/organization-model.mdx` |
|
|
28
|
+
| Organization Graph | `packages/core/src/organization-model/organization-graph.mdx` | `scaffold/core/organization-graph.mdx` |
|
|
29
|
+
| Glossary | `packages/core/src/reference/glossary.md` | `scaffold/reference/glossary.md` |
|
|
30
|
+
| Contracts (auto-gen) | `packages/core/src/reference/_generated/contracts.md` | `scaffold/reference/contracts.md` |
|
|
31
|
+
| UI Recipes | `packages/ui/src/scaffold/recipes.md` | `scaffold/ui/recipes.md` |
|
|
32
|
+
| Feature Flags & Gating | `packages/ui/src/scaffold/feature-flags-and-gating.md` | `scaffold/ui/feature-flags-and-gating.md` |
|
|
33
|
+
| Customization | `packages/ui/src/scaffold/customization.md` | `scaffold/ui/customization.md` |
|
|
34
|
+
| Feature Shell | `packages/ui/src/scaffold/feature-shell.mdx` | `scaffold/ui/feature-shell.mdx` |
|
|
35
|
+
| Composition & Extensibility | `packages/ui/src/scaffold/composition-extensibility.mdx` | `scaffold/ui/composition-extensibility.mdx` |
|
|
36
|
+
| Feature Registry (auto-gen) | `packages/ui/src/scaffold/_generated/feature-registry.md` | `scaffold/reference/feature-registry.md` |
|
|
37
|
+
| Scaffold Index | `packages/sdk/docs/scaffold/index.mdx` | `scaffold/index.mdx` |
|
|
38
|
+
| Pathway Recipes (4) | `packages/sdk/docs/scaffold/recipes/` | `scaffold/recipes/` |
|
|
39
|
+
| Workflow Recipes | `packages/sdk/docs/scaffold/operations/workflow-recipes.md` | `scaffold/operations/workflow-recipes.md` |
|
|
40
|
+
| Propagation Pipeline | `packages/sdk/docs/scaffold/operations/propagation-pipeline.md` | `scaffold/operations/propagation-pipeline.md` |
|
|
41
|
+
| This doc | `packages/sdk/docs/scaffold/operations/scaffold-maintenance.md` | `scaffold/operations/scaffold-maintenance.md` |
|
|
42
|
+
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
## Auto-Generation Pipeline
|
|
46
|
+
|
|
47
|
+
Two types of docs are auto-generated from source:
|
|
48
|
+
|
|
49
|
+
### Contracts (`contracts.md`)
|
|
50
|
+
|
|
51
|
+
Generated by `scripts/monorepo/generate-scaffold-contracts.js` from TypeScript source types:
|
|
52
|
+
|
|
53
|
+
- `packages/core/src/organization-model/types.ts` -- Organization Model, Feature System
|
|
54
|
+
- `packages/ui/src/features/registry/types.ts` -- Feature Registry
|
|
55
|
+
- `packages/core/src/platform/registry/types.ts` -- Resource Registry, Deployment Spec
|
|
56
|
+
|
|
57
|
+
Output: `packages/core/src/reference/_generated/contracts.md`
|
|
58
|
+
|
|
59
|
+
### Feature Registry (`feature-registry.md`)
|
|
60
|
+
|
|
61
|
+
Generated by `scripts/monorepo/generate-scaffold-feature-registry.js` from feature manifests:
|
|
62
|
+
|
|
63
|
+
- `packages/ui/src/features/*/manifest.ts` -- individual feature manifests
|
|
64
|
+
- `packages/core/src/organization-model/domains/features.ts` -- feature key definitions
|
|
65
|
+
|
|
66
|
+
Output: `packages/ui/src/scaffold/_generated/feature-registry.md`
|
|
67
|
+
|
|
68
|
+
### Reference Artifacts
|
|
69
|
+
|
|
70
|
+
Generated by `scripts/monorepo/generate-reference-artifacts.js`:
|
|
71
|
+
|
|
72
|
+
- `packages/sdk/reference/_reference-manifest.json` -- machine-readable catalog of all reference entries
|
|
73
|
+
- `packages/sdk/reference/_navigation.md` -- navigation table
|
|
74
|
+
|
|
75
|
+
### Running Generators
|
|
76
|
+
|
|
77
|
+
```bash
|
|
78
|
+
pnpm scaffold:generate # Run both generators
|
|
79
|
+
pnpm scaffold:sync # Generate + validate (the full loop)
|
|
80
|
+
pnpm sdk-ref:generate # Reference artifacts only
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
Generated files should never be edited manually. If the output is wrong, fix the source types or the generator script.
|
|
84
|
+
|
|
85
|
+
---
|
|
86
|
+
|
|
87
|
+
## SDK Build Pipeline (Reference Copy)
|
|
88
|
+
|
|
89
|
+
`packages/sdk/scripts/copy-reference-docs.mjs` runs during `pnpm --filter @elevasis/sdk build` and has three phases:
|
|
90
|
+
|
|
91
|
+
1. **Phase 1:** Copies SDK public docs from `apps/docs/content/docs/sdk/` with link rewriting and MDX escape stripping
|
|
92
|
+
2. **Phase 2:** Copies package-owned reference docs declared in reference manifests
|
|
93
|
+
3. **Phase 3:** Copies scaffold docs from co-located package sources using the `SCAFFOLD_COPIES` map
|
|
94
|
+
|
|
95
|
+
The output lands in `packages/sdk/reference/` which is included in the npm package's `files` array. External projects access it via `node_modules/@elevasis/sdk/reference/`.
|
|
96
|
+
|
|
97
|
+
---
|
|
98
|
+
|
|
99
|
+
## Adding New Scaffold Docs
|
|
100
|
+
|
|
101
|
+
1. **Create the source doc** in the appropriate package:
|
|
102
|
+
- Core concepts: `packages/core/src/...`
|
|
103
|
+
- UI patterns: `packages/ui/src/scaffold/...`
|
|
104
|
+
- Cross-package or SDK-owned: `packages/sdk/docs/scaffold/...`
|
|
105
|
+
|
|
106
|
+
2. **Add to `SCAFFOLD_COPIES`** in `packages/sdk/scripts/copy-reference-docs.mjs`:
|
|
107
|
+
|
|
108
|
+
```javascript
|
|
109
|
+
{ source: 'packages/sdk/docs/scaffold/operations/my-doc.md', target: 'scaffold/operations/my-doc.md' }
|
|
110
|
+
```
|
|
111
|
+
|
|
112
|
+
3. **Update the scaffold index** in `packages/sdk/docs/scaffold/index.mdx` with a link and description.
|
|
113
|
+
|
|
114
|
+
4. **Rebuild the SDK** to verify: `pnpm --filter @elevasis/sdk build`
|
|
115
|
+
|
|
116
|
+
5. **Update the permanent architecture docs** if the new doc covers a concept already referenced in `apps/docs/content/docs/technical/architecture/scaffold-reference.mdx`.
|
|
117
|
+
|
|
118
|
+
---
|
|
119
|
+
|
|
120
|
+
## Freshness Validation
|
|
121
|
+
|
|
122
|
+
At the monorepo level, `pnpm scaffold:sync` followed by `pnpm sync:verify` confirms that all artifacts are current and all downstream projects are consistent. The SDK no longer ships doc validation because external projects no longer carry a `docs/` tree.
|