@elevasis/sdk 0.4.5 → 0.4.7

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.
Files changed (40) hide show
  1. package/dist/cli.cjs +829 -413
  2. package/dist/index.d.ts +79 -14
  3. package/dist/index.js +17 -12
  4. package/dist/templates.js +747 -0
  5. package/dist/types/templates.d.ts +1 -0
  6. package/dist/types/worker/index.d.ts +6 -0
  7. package/dist/types/worker/platform.d.ts +32 -0
  8. package/dist/worker/index.js +4701 -9
  9. package/package.json +10 -3
  10. package/reference/_index.md +95 -0
  11. package/reference/_navigation.md +104 -0
  12. package/reference/cli/index.mdx +497 -0
  13. package/reference/concepts/index.mdx +203 -0
  14. package/reference/deployment/api.mdx +297 -0
  15. package/reference/deployment/index.mdx +153 -0
  16. package/reference/developer/interaction-guidance.mdx +213 -0
  17. package/reference/framework/agent.mdx +175 -0
  18. package/reference/framework/documentation.mdx +92 -0
  19. package/reference/framework/index.mdx +95 -0
  20. package/reference/framework/memory.mdx +337 -0
  21. package/reference/framework/project-structure.mdx +294 -0
  22. package/reference/getting-started/index.mdx +148 -0
  23. package/reference/index.mdx +113 -0
  24. package/reference/platform-tools/examples.mdx +187 -0
  25. package/reference/platform-tools/index.mdx +182 -0
  26. package/reference/resources/index.mdx +289 -0
  27. package/reference/resources/patterns.mdx +341 -0
  28. package/reference/resources/types.mdx +207 -0
  29. package/reference/roadmap/index.mdx +147 -0
  30. package/reference/runtime/index.mdx +141 -0
  31. package/reference/runtime/limits.mdx +77 -0
  32. package/reference/security/credentials.mdx +141 -0
  33. package/reference/templates/data-enrichment.mdx +162 -0
  34. package/reference/templates/email-sender.mdx +135 -0
  35. package/reference/templates/lead-scorer.mdx +175 -0
  36. package/reference/templates/pdf-generator.mdx +151 -0
  37. package/reference/templates/recurring-job.mdx +189 -0
  38. package/reference/templates/text-classifier.mdx +147 -0
  39. package/reference/templates/web-scraper.mdx +135 -0
  40. package/reference/troubleshooting/common-errors.mdx +210 -0
@@ -0,0 +1,297 @@
1
+ ---
2
+ title: Execution API
3
+ description: REST endpoints for executing resources, querying execution history, and managing deployments via the Elevasis external API
4
+ loadWhen: "Calling the API directly or debugging API responses"
5
+ ---
6
+
7
+ The Elevasis external API exposes REST endpoints under `/api/external/` for executing your deployed resources and inspecting results. All endpoints require your `ELEVASIS_API_KEY` sent as a Bearer token. Organization is resolved server-side from the API key -- you never pass an org identifier in requests.
8
+
9
+ **Authentication header:**
10
+
11
+ ```
12
+ Authorization: Bearer sk_...
13
+ ```
14
+
15
+ ---
16
+
17
+ ## API Base URL
18
+
19
+ | Environment | Base URL |
20
+ | ----------- | -------- |
21
+ | Production | `https://api.elevasis.io` |
22
+ | Development | `http://localhost:<port>` |
23
+
24
+ Override the base URL by setting `ELEVASIS_API_URL` in your environment or passing `--api-url` to any CLI command.
25
+
26
+ ---
27
+
28
+ ## Endpoints
29
+
30
+ | Method | Path | Purpose |
31
+ | ------ | ---- | ------- |
32
+ | `GET` | `/api/external/resources` | List all resources for your organization |
33
+ | `GET` | `/api/external/resources/:resourceId/definition` | Get resource metadata and schemas |
34
+ | `POST` | `/api/external/execute` | Execute a resource synchronously |
35
+ | `POST` | `/api/external/execute-async` | Execute a resource asynchronously |
36
+ | `POST` | `/api/external/executions/:resourceId/:executionId/cancel` | Cancel a running execution |
37
+ | `GET` | `/api/external/executions/:resourceId` | List execution history for a resource |
38
+ | `GET` | `/api/external/executions/:resourceId/:executionId` | Get full execution detail |
39
+ | `POST` | `/api/external/deploy` | Upload bundle and deploy resources |
40
+ | `GET` | `/api/external/deployments` | List all deployments |
41
+ | `GET` | `/api/external/deployments/:id` | Get a deployment by ID |
42
+
43
+ ---
44
+
45
+ ## Execution Endpoints
46
+
47
+ ### POST /api/external/execute
48
+
49
+ Execute a resource synchronously. The request waits for the resource to complete and returns the full result.
50
+
51
+ **Request body:**
52
+
53
+ ```json
54
+ {
55
+ "resourceId": "onboard-client",
56
+ "input": {
57
+ "clientName": "Jane",
58
+ "email": "jane@example.com"
59
+ }
60
+ }
61
+ ```
62
+
63
+ **Response:**
64
+
65
+ ```json
66
+ {
67
+ "executionId": "550e8400-e29b-41d4-a716-446655440000",
68
+ "success": true,
69
+ "data": {
70
+ "success": true,
71
+ "clientId": "client_1708521600000",
72
+ "welcomeEmailSent": true
73
+ }
74
+ }
75
+ ```
76
+
77
+ ### POST /api/external/execute-async
78
+
79
+ Execute a resource asynchronously. Returns immediately with an `executionId`. Poll `GET /executions/:resourceId/:executionId` to check status and retrieve output.
80
+
81
+ **Request body:**
82
+
83
+ ```json
84
+ {
85
+ "resourceId": "onboard-client",
86
+ "input": { "clientName": "Jane" }
87
+ }
88
+ ```
89
+
90
+ **Response:**
91
+
92
+ ```json
93
+ {
94
+ "executionId": "550e8400-e29b-41d4-a716-446655440000",
95
+ "status": "running"
96
+ }
97
+ ```
98
+
99
+ ### POST /api/external/executions/:resourceId/:executionId/cancel
100
+
101
+ Cancel a running execution. If the execution is found in memory, sends a cancellation signal immediately. Falls back to a database status update if no in-memory signal is found.
102
+
103
+ **Response:**
104
+
105
+ ```json
106
+ {
107
+ "success": true
108
+ }
109
+ ```
110
+
111
+ ---
112
+
113
+ ## Resource Endpoints
114
+
115
+ ### GET /api/external/resources
116
+
117
+ List all resources registered to your organization. In production, only `status: 'prod'` resources are returned.
118
+
119
+ **Response:**
120
+
121
+ ```json
122
+ [
123
+ {
124
+ "resourceId": "onboard-client",
125
+ "resourceType": "workflow",
126
+ "name": "Onboard Client",
127
+ "status": "prod"
128
+ },
129
+ {
130
+ "resourceId": "email-assistant",
131
+ "resourceType": "agent",
132
+ "name": "Email Assistant",
133
+ "status": "prod"
134
+ }
135
+ ]
136
+ ```
137
+
138
+ ### GET /api/external/resources/:resourceId/definition
139
+
140
+ Get the full definition for a single resource: metadata, input schema, and output schema.
141
+
142
+ **Response:**
143
+
144
+ ```json
145
+ {
146
+ "resourceId": "onboard-client",
147
+ "resourceType": "workflow",
148
+ "name": "Onboard Client",
149
+ "description": "Creates a client record and sends a welcome email",
150
+ "status": "prod",
151
+ "inputSchema": {
152
+ "type": "object",
153
+ "properties": {
154
+ "clientName": { "type": "string" },
155
+ "email": { "type": "string", "format": "email" }
156
+ },
157
+ "required": ["clientName", "email"]
158
+ },
159
+ "outputSchema": {
160
+ "type": "object",
161
+ "properties": {
162
+ "success": { "type": "boolean" },
163
+ "clientId": { "type": "string" }
164
+ }
165
+ }
166
+ }
167
+ ```
168
+
169
+ Returns `404` if the resource is not found.
170
+
171
+ ---
172
+
173
+ ## Execution History Endpoints
174
+
175
+ ### GET /api/external/executions/:resourceId
176
+
177
+ List execution history for a resource.
178
+
179
+ **Query parameters:**
180
+
181
+ | Parameter | Description |
182
+ | --------- | ----------- |
183
+ | `limit` | Maximum number of results (default: 20) |
184
+ | `status` | Filter by status: `running`, `completed`, `failed`, `cancelled` |
185
+
186
+ **Response:**
187
+
188
+ ```json
189
+ [
190
+ {
191
+ "executionId": "550e8400-e29b-41d4-a716-446655440000",
192
+ "resourceId": "onboard-client",
193
+ "status": "completed",
194
+ "createdAt": "2026-02-25T14:32:01Z",
195
+ "durationMs": 1234
196
+ }
197
+ ]
198
+ ```
199
+
200
+ ### GET /api/external/executions/:resourceId/:executionId
201
+
202
+ Get the full detail for a single execution including input, output, logs, and error.
203
+
204
+ **Response:**
205
+
206
+ ```json
207
+ {
208
+ "executionId": "550e8400-e29b-41d4-a716-446655440000",
209
+ "resourceId": "onboard-client",
210
+ "status": "completed",
211
+ "createdAt": "2026-02-25T14:32:01Z",
212
+ "durationMs": 1234,
213
+ "input": {
214
+ "clientName": "Jane",
215
+ "email": "jane@example.com"
216
+ },
217
+ "output": {
218
+ "success": true,
219
+ "clientId": "client_1708521600000",
220
+ "welcomeEmailSent": true
221
+ },
222
+ "logs": [
223
+ { "timestamp": "2026-02-25T14:32:01.123Z", "message": "Starting onboard-client workflow" },
224
+ { "timestamp": "2026-02-25T14:32:01.456Z", "message": "Created client record" }
225
+ ],
226
+ "error": null
227
+ }
228
+ ```
229
+
230
+ ---
231
+
232
+ ## Deployment Endpoints
233
+
234
+ ### POST /api/external/deploy
235
+
236
+ Upload a resource bundle and deploy it. Accepts a multipart request with the compiled bundle and resource metadata.
237
+
238
+ **Response:**
239
+
240
+ ```json
241
+ {
242
+ "deployId": "deploy_abc123",
243
+ "status": "active",
244
+ "resources": 4
245
+ }
246
+ ```
247
+
248
+ Use `elevasis deploy` from the CLI rather than calling this endpoint directly -- the CLI handles bundling, metadata generation, and status streaming automatically.
249
+
250
+ ### GET /api/external/deployments
251
+
252
+ List all deployments for your organization.
253
+
254
+ **Response:**
255
+
256
+ ```json
257
+ [
258
+ {
259
+ "id": "deploy_abc123",
260
+ "status": "active",
261
+ "createdAt": "2026-02-25T14:00:00Z",
262
+ "resources": 4
263
+ },
264
+ {
265
+ "id": "deploy_abc122",
266
+ "status": "stopped",
267
+ "createdAt": "2026-02-24T09:30:00Z",
268
+ "resources": 3
269
+ }
270
+ ]
271
+ ```
272
+
273
+ ### GET /api/external/deployments/:id
274
+
275
+ Get a single deployment by ID.
276
+
277
+ **Response shape:** Same as a single item from `GET /deployments`.
278
+
279
+ ---
280
+
281
+ ## CLI Execution Commands
282
+
283
+ The SDK CLI wraps all execution endpoints. Use these commands instead of calling the API directly during development:
284
+
285
+ | Command | API call | Purpose |
286
+ | ------- | -------- | ------- |
287
+ | `elevasis resources` | `GET /api/external/resources` | List all resources |
288
+ | `elevasis describe <resource>` | `GET /api/external/resources/:id/definition` | Show resource definition |
289
+ | `elevasis exec <resource> --input '...'` | `POST /api/external/execute` | Execute synchronously |
290
+ | `elevasis exec <resource> --input '...' --async` | `POST /api/external/execute-async` | Execute asynchronously |
291
+ | `elevasis executions <resource>` | `GET /api/external/executions/:id` | List execution history |
292
+ | `elevasis execution <resource> <id>` | `GET /api/external/executions/:id/:execId` | Get execution detail |
293
+ | `elevasis deployments` | `GET /api/external/deployments` | List deployments |
294
+
295
+ ---
296
+
297
+ **Last Updated:** 2026-02-25
@@ -0,0 +1,153 @@
1
+ ---
2
+ title: Deploying Resources
3
+ description: How to deploy your Elevasis SDK resources to the platform using elevasis deploy, including configuration, validation, and environment setup
4
+ loadWhen: "Preparing to deploy or debugging deploy failures"
5
+ ---
6
+
7
+ Deploying your resources makes them live on the Elevasis platform and immediately available for execution. The deploy process validates your resource definitions, bundles your code into a single self-contained file, and uploads it to the platform -- no server-side dependency installation required.
8
+
9
+ ---
10
+
11
+ ## How Deployment Works
12
+
13
+ When you run `elevasis deploy`, the CLI performs these steps in order:
14
+
15
+ 1. **Authenticate** -- calls the API with your `ELEVASIS_API_KEY` to verify credentials and resolve your organization name
16
+ 2. **Validate** -- runs your `src/index.ts` through `ResourceRegistry`, catching the same errors as the platform
17
+ 3. **Bundle** -- uses esbuild to produce a single self-contained `dist/bundle.js` file (~50-200 KB) containing your code and all dependencies
18
+ 4. **Upload** -- sends the bundle and resource metadata to the platform via `POST /api/external/deploy`
19
+ 5. **Go live** -- the platform registers your resources; they are immediately available for execution
20
+
21
+ There is no local dev server and no separate staging environment. Deployed resources run directly on the platform. Local testing uses `tsc --noEmit` and Vitest with direct handler calls.
22
+
23
+ ---
24
+
25
+ ## Running a Deploy
26
+
27
+ ```bash
28
+ elevasis deploy
29
+ ```
30
+
31
+ **Successful deploy output:**
32
+
33
+ ```
34
+ Authenticating... done (acme-corp)
35
+ Validating... done (4 resources, 0 errors)
36
+ Bundling... done (142 KB)
37
+ Uploading... done
38
+
39
+ Deployed! 4 resources live.
40
+ Deployment: deploy_abc123
41
+ ```
42
+
43
+ Each deploy creates a new deployment record. The previous active deployment is automatically stopped. You can view all deployments with `elevasis deployments`.
44
+
45
+ ---
46
+
47
+ ## Validation
48
+
49
+ The CLI validates your resources before bundling. Validation uses the same `ResourceRegistry` as the platform, so errors caught locally are the same errors that would be caught at deploy time.
50
+
51
+ **Validation checks:**
52
+
53
+ - Duplicate `resourceId` within your organization
54
+ - Invalid model configuration (temperature and token bounds out of range)
55
+ - `ExecutionInterface` form fields not matching `inputSchema`
56
+ - Broken workflow step chains (`next` referencing a step that does not exist)
57
+ - Relationship declarations referencing resources that do not exist
58
+
59
+ **Validation failure output:**
60
+
61
+ ```
62
+ Authenticating... done (acme-corp)
63
+ Validating...
64
+ ERROR Duplicate resource ID 'onboard-client' in organization 'Acme Corp'
65
+ ERROR Workflow step 'send-email' references non-existent next step 'notify'
66
+
67
+ 2 errors. Deploy aborted.
68
+ ```
69
+
70
+ Run `elevasis check` at any time to validate without deploying.
71
+
72
+ ---
73
+
74
+ ## Configuration
75
+
76
+ The CLI reads `elevasis.config.ts` from your project root. All fields are optional -- the organization name is resolved from your API key, not from config.
77
+
78
+ ```typescript
79
+ // elevasis.config.ts
80
+ import type { ElevasConfig } from '@elevasis/sdk'
81
+
82
+ export default {} satisfies ElevasConfig
83
+ ```
84
+
85
+ The `ElevasConfig` type is exported from `@elevasis/sdk`. You can leave the config empty or extend it as options are added in future SDK versions.
86
+
87
+ ---
88
+
89
+ ## Environment Variables
90
+
91
+ | Variable | Required | Description |
92
+ | -------- | -------- | ----------- |
93
+ | `ELEVASIS_API_KEY` | Yes | Your `sk_...` API key. Used for authentication and organization resolution. |
94
+ | `ELEVASIS_API_URL` | No | Override the API base URL. Useful for pointing at a staging environment. |
95
+
96
+ The CLI also accepts a `--api-url` flag on every command, which takes priority over `ELEVASIS_API_URL`.
97
+
98
+ **API URL resolution order:**
99
+
100
+ 1. `--api-url` flag (highest priority)
101
+ 2. `ELEVASIS_API_URL` environment variable
102
+ 3. `NODE_ENV`-based default (production: `https://api.elevasis.io`, development: localhost)
103
+
104
+ **Setting `ELEVASIS_API_KEY` via `.env` file:**
105
+
106
+ ```
107
+ ELEVASIS_API_KEY=sk_***
108
+ ```
109
+
110
+ Place `.env` in your project root. The CLI reads it automatically. Never commit this file.
111
+
112
+ ---
113
+
114
+ ## Deployment Lifecycle
115
+
116
+ Each call to `elevasis deploy` creates a new deployment. The platform tracks all deployments for your organization.
117
+
118
+ | Status | Meaning |
119
+ | ------ | ------- |
120
+ | `deploying` | Bundle is being processed and resources are being registered |
121
+ | `active` | Resources are live and available for execution |
122
+ | `stopped` | Superseded by a newer deployment |
123
+ | `failed` | Deploy did not complete (validation or bundle error) |
124
+
125
+ Only one deployment can be `active` at a time. Deploying again automatically moves the previous active deployment to `stopped`.
126
+
127
+ **View deployment history:**
128
+
129
+ ```bash
130
+ elevasis deployments
131
+ ```
132
+
133
+ ```
134
+ deploy_abc123 active 2026-02-25 14:00:00 4 resources
135
+ deploy_abc122 stopped 2026-02-24 09:30:00 3 resources
136
+ deploy_abc121 stopped 2026-02-23 11:15:00 3 resources
137
+ ```
138
+
139
+ ---
140
+
141
+ ## Bundle Details
142
+
143
+ The deploy bundle is a single CJS file produced by esbuild. It includes:
144
+
145
+ - Your resource definitions from `src/index.ts`
146
+ - The `@elevasis/sdk/worker` runtime that handles execution messages from the platform
147
+ - All your npm dependencies (fully self-contained, no `node_modules` needed on the server)
148
+
149
+ The bundle is stored on the platform for durability and restart recovery. If the platform API restarts, it re-downloads your bundle and re-registers your resources automatically -- no action required on your part.
150
+
151
+ ---
152
+
153
+ **Last Updated:** 2026-02-25
@@ -0,0 +1,213 @@
1
+ ---
2
+ title: "Interaction Guidance"
3
+ description: "Full dimensional adaptation rules per skill axis -- programming, TypeScript, API integration, automation concepts, domain expertise -- with growth tracking protocol"
4
+ loadWhen: "Unsure how to adapt for a skill combination"
5
+ ---
6
+
7
+ This reference defines how to adapt every interaction based on the dimensions in `.claude/memory/profile/skills.md`. Read it when the compact directive in CLAUDE.md is not enough to decide how to handle an unusual skill combination.
8
+
9
+ ---
10
+
11
+ ## Skill Dimensions
12
+
13
+ The user profile stores five independent skill dimensions. Each dimension has its own adaptation rules. Do not collapse them into a single beginner/intermediate/advanced rating.
14
+
15
+ ### Programming Fundamentals (none / minimal / comfortable / advanced)
16
+
17
+ **none** -- Has not written code. May have used no-code tools.
18
+
19
+ - Explain what functions, variables, and objects are when they appear in code
20
+ - Use analogies for every technical concept (see Analogies section below)
21
+ - Show complete, working files with every import included
22
+ - Never show code fragments they cannot place
23
+ - Walk through each line in plain English before showing code
24
+ - Do not assume they can read code independently
25
+
26
+ **minimal** -- Has written HTML, CSS, Excel formulas, or simple scripts.
27
+
28
+ - Briefly explain language constructs that differ from what they know
29
+ - Show complete files with inline comments on non-obvious parts
30
+ - Avoid assuming they know what async/await, imports, or type annotations do
31
+ - Skip explanations of basic web/formula concepts they likely know
32
+
33
+ **comfortable** -- Has written programs in at least one general-purpose language.
34
+
35
+ - Brief inline comments for non-obvious SDK-specific parts
36
+ - Skip explanations of variables, functions, loops, and basic data structures
37
+ - Focus on what is different about TypeScript and the SDK API
38
+
39
+ **advanced** -- Writes production software professionally.
40
+
41
+ - Concise code, no commentary on language features
42
+ - Focus only on SDK-specific patterns and constraints
43
+ - Trust them to infer context from types and naming
44
+
45
+ ---
46
+
47
+ ### TypeScript (none / exposure / proficient)
48
+
49
+ **none** -- Has not used TypeScript or any statically typed language.
50
+
51
+ - Show complete files with every import
52
+ - Explain type annotations as "labels that describe what kind of data this is"
53
+ - Never use generics without a plain-English explanation
54
+ - Explain `z.infer` every time it appears: "This creates a TypeScript type from the schema so you get autocomplete and error checking"
55
+ - Explain the difference between runtime validation (Zod) and compile-time checking (TypeScript)
56
+
57
+ **exposure** -- Has read TypeScript or used a typed language (Java, C#, Go).
58
+
59
+ - Show code with brief type annotation comments for SDK-specific types
60
+ - Explain `WorkflowDefinition`, `StepType`, and `OrganizationResources` on first use
61
+ - Trust them to understand basic type syntax
62
+
63
+ **proficient** -- Has written TypeScript projects.
64
+
65
+ - Types without explanation
66
+ - Focus on SDK API surface, not language features
67
+ - Trust them to read type definitions
68
+
69
+ ---
70
+
71
+ ### API and Integration (none / basic / proficient)
72
+
73
+ **none** -- Has not called an API directly. Uses tools with built-in integrations.
74
+
75
+ - Explain what credentials are and why they exist before any integration code
76
+ - Walk through credential creation in the platform command center step by step
77
+ - Explain what "calling an API" means in plain English
78
+ - Explain why `.env` exists and what `ELEVASIS_API_KEY` is for
79
+ - Do not assume they understand HTTP methods, JSON, or authentication headers
80
+
81
+ **basic** -- Has used APIs with documentation or built simple integrations.
82
+
83
+ - Show `platform.call()` patterns with brief notes on credential names
84
+ - Reference the platform credential system for setup without full walkthrough
85
+ - Explain SDK-specific credential patterns (how the platform injects secrets server-side)
86
+
87
+ **proficient** -- Has built production integrations, understands REST and auth patterns.
88
+
89
+ - Just the code and credential name
90
+ - Trust them to set up credentials in the command center without guidance
91
+ - Focus on SDK-specific behavior (timeout, error types, server-side injection)
92
+
93
+ ---
94
+
95
+ ### Automation Concepts (none / low-code / custom)
96
+
97
+ **none** -- Has not used automation tools. Thinks in manual processes.
98
+
99
+ - Use analogies before any technical explanation (see Analogies section)
100
+ - Explain the execution model early: "Your code runs on Elevasis servers, not your computer"
101
+ - Define Workflow, Step, Trigger, Schema, Credential on first use
102
+ - Explain why automation is valuable for their specific use case before building anything
103
+ - Explain deploy: "After deploy, your workflow is live and can be triggered"
104
+
105
+ **low-code** -- Has used Zapier, Make, or similar tools.
106
+
107
+ - Map Elevasis concepts to tools they know: "Steps are like Zapier actions. The workflow is the Zap."
108
+ - Focus on what is different: code is more flexible but requires TypeScript
109
+ - Explain schema validation: "Zapier has field mapping; Elevasis has schemas that validate the shape of data"
110
+
111
+ **custom** -- Has written custom automation scripts or integrations.
112
+
113
+ - Skip analogies
114
+ - Focus on the SDK execution model: worker threads, postMessage, ephemeral processes
115
+ - Explain the credential security model (server-side injection, no env vars in workers)
116
+ - Discuss error handling patterns and retry behavior
117
+
118
+ ---
119
+
120
+ ### Domain Expertise
121
+
122
+ Domain expertise is not a code skill. It is the user's depth of knowledge in their industry or business function (sales, finance, operations, marketing, etc.).
123
+
124
+ When domain expertise is high:
125
+
126
+ - Ask for business process descriptions before designing schemas
127
+ - Let them drive the "what" (business logic); you handle the "how" (implementation)
128
+ - Translate their process description into workflow steps, schemas, and tool choices
129
+ - Validate your understanding: "So the workflow should: receive a new lead from the CRM, score it based on these criteria, and send a Slack alert if the score is above 80?"
130
+ - Trust their judgment on what the workflow should do; never second-guess business logic
131
+
132
+ When domain expertise is low:
133
+
134
+ - Ask clarifying questions about the business process before designing anything
135
+ - Do not assume what "a lead" or "a deal" or "an invoice" means in their context
136
+ - Confirm edge cases explicitly: "What should happen if the lead has no email address?"
137
+
138
+ ---
139
+
140
+ ## Analogies for Non-Technical Users
141
+
142
+ Use these when programming level is none or minimal, or when automation level is none.
143
+
144
+ | Concept | Analogy |
145
+ | --- | --- |
146
+ | Workflow | A recipe: ingredients go in (input), steps are instructions, finished dish comes out (output) |
147
+ | Step | One instruction in a recipe: "add salt," "stir for 2 minutes" |
148
+ | Schema | A form template: it defines what fields exist and what type of data each field accepts |
149
+ | Deployment | Publishing: like publishing a document so others can access it |
150
+ | Execution | One run: like baking the recipe once |
151
+ | Platform tool | A kitchen appliance: you use the mixer (tool) without knowing how it works inside |
152
+ | Credential | A key: you give Elevasis the key to your Gmail account; it unlocks the door when needed |
153
+ | Assembly line | Raw material goes in one end (input), each station does one job (step), finished product comes out (output) |
154
+
155
+ Choose the analogy that fits the user's domain. A sales operations person will relate more to "a form template" than a developer would.
156
+
157
+ ---
158
+
159
+ ## Growth Tracking Protocol
160
+
161
+ ### Observations
162
+
163
+ During each session, note behaviors that reveal skill level changes. Examples:
164
+
165
+ - User wrote a handler without asking for help
166
+ - User independently caught a type error before you pointed it out
167
+ - User suggested using StepType.CONDITIONAL without prompting
168
+ - User asked a question that shows they now understand the execution model
169
+
170
+ ### Promotion Rules
171
+
172
+ Do not automatically update the skill profile for every observation. Update when:
173
+
174
+ - The user independently performs a task they previously needed explicit help with
175
+ - The behavior is consistent across at least two instances (not a one-off)
176
+ - The observation demonstrates understanding, not just copying a pattern
177
+
178
+ ### Update Format
179
+
180
+ When updating `.claude/memory/profile/skills.md` Growth Log:
181
+
182
+ ```
183
+ | Date | Observation | Skill Updated |
184
+ | 2026-03-01 | Wrote complete handler with correct types independently | TypeScript: none -> exposure |
185
+ ```
186
+
187
+ Also update the dimension's Level field and Evidence field to reflect the new assessment.
188
+
189
+ ### Celebration
190
+
191
+ When growth is observed, acknowledge it briefly:
192
+
193
+ - "You just wrote that handler without any help -- your TypeScript is definitely improving."
194
+ - "Good catch on the optional field -- that is exactly the kind of thing that trips people up."
195
+
196
+ Keep it natural. One sentence is enough. Do not over-celebrate.
197
+
198
+ ---
199
+
200
+ ## When This Reference is Needed
201
+
202
+ Load this file when:
203
+
204
+ - Starting `/meta init` to understand how to phrase the competency assessment questions
205
+ - The user's skill combination is unusual and the compact CLAUDE.md directive is not enough to decide how to respond
206
+ - Reassessing skill levels after several sessions
207
+ - Writing the initial profile during onboarding
208
+
209
+ For routine sessions, the compact directive in CLAUDE.md plus the user's stored `skills.md` is sufficient.
210
+
211
+ ---
212
+
213
+ **Last Updated:** 2026-02-26