@sequenceholdings/studio-cli 0.3.0 → 0.4.1
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/README.md +465 -28
- package/dist/agents/commands.d.ts +1 -1
- package/dist/agents/commands.js +5 -0
- package/dist/agents/scaffold.js +5 -7
- package/dist/agents/voice-authoring.d.ts +5 -0
- package/dist/agents/voice-authoring.js +75 -0
- package/dist/agents/voice-publication.d.ts +5 -0
- package/dist/agents/voice-publication.js +63 -0
- package/dist/agents/voice-shared.d.ts +20 -0
- package/dist/agents/voice-shared.js +112 -0
- package/dist/agents/voice.d.ts +3 -0
- package/dist/agents/voice.js +57 -0
- package/dist/app/adapters.d.ts +6 -0
- package/dist/app/adapters.js +17 -2
- package/dist/app/agent-refs.d.ts +16 -0
- package/dist/app/agent-refs.js +36 -0
- package/dist/app/application-registration.d.ts +31 -5
- package/dist/app/application-registration.js +58 -14
- package/dist/app/commands.js +19 -2
- package/dist/app/deploy.d.ts +3 -0
- package/dist/app/deploy.js +18 -4
- package/dist/app/env-bindings.d.ts +21 -0
- package/dist/app/env-bindings.js +184 -0
- package/dist/app/manifest-validation.js +8 -0
- package/dist/app/manifest.d.ts +13 -9
- package/dist/app/manifest.js +1 -1
- package/dist/app/primitive-scaffold.d.ts +4 -1
- package/dist/app/primitive-scaffold.js +4 -4
- package/dist/app/readme.js +1 -0
- package/dist/app/scaffold-files.js +1 -1
- package/dist/app/scaffold.d.ts +6 -4
- package/dist/app/scaffold.js +7 -4
- package/dist/app/workspace-scaffold.js +12 -7
- package/dist/argv.d.ts +7 -0
- package/dist/argv.js +56 -0
- package/dist/artifact/delegate.js +8 -4
- package/dist/atlas-client.d.ts +6 -0
- package/dist/atlas-client.js +39 -2
- package/dist/auth.d.ts +32 -0
- package/dist/auth.js +170 -33
- package/dist/bin.js +23 -4
- package/dist/command-contract.d.ts +137 -0
- package/dist/command-contract.js +43 -0
- package/dist/command-help.d.ts +8 -0
- package/dist/command-help.js +71 -0
- package/dist/functions/commands.d.ts +1 -1
- package/dist/functions/commands.js +19 -3
- package/dist/functions/deploy-preflight.d.ts +21 -0
- package/dist/functions/deploy-preflight.js +58 -0
- package/dist/functions/egress-postgres.d.ts +7 -0
- package/dist/functions/egress-postgres.js +36 -0
- package/dist/functions/manifest.d.ts +8 -0
- package/dist/functions/manifest.js +9 -0
- package/dist/functions/source-selection.js +4 -1
- package/dist/main.js +58 -20
- package/dist/orm/delegate.d.ts +16 -0
- package/dist/orm/delegate.js +140 -7
- package/dist/pipeline/clone-deploy.d.ts +37 -0
- package/dist/pipeline/clone-deploy.js +125 -0
- package/dist/pipeline/codegen.js +6 -2
- package/dist/pipeline/commands.js +21 -5
- package/dist/pipeline/lifecycle.d.ts +1 -0
- package/dist/pipeline/lifecycle.js +95 -44
- package/dist/pipeline/repin-orm.js +6 -2
- package/dist/pipeline/stage-secrets.js +1 -1
- package/dist/process/build.js +17 -0
- package/dist/process/codegen.js +16 -0
- package/dist/process/commands.d.ts +15 -7
- package/dist/process/commands.js +291 -99
- package/dist/process/lint.js +35 -0
- package/dist/process/plan-diff.js +9 -0
- package/dist/process/simulate.js +8 -0
- package/dist/release-age.d.ts +12 -0
- package/dist/release-age.js +24 -0
- package/dist/repos/commands.d.ts +1 -1
- package/dist/repos/commands.js +36 -7
- package/dist/scaffold-guidance.d.ts +4 -0
- package/dist/scaffold-guidance.js +15 -0
- package/dist/storage/commands.js +23 -1
- package/dist/storage/gcs-download.d.ts +13 -0
- package/dist/storage/gcs-download.js +41 -0
- package/dist/storage/import-cycle.d.ts +41 -0
- package/dist/storage/import-cycle.js +123 -0
- package/dist/storage/import-files.d.ts +30 -0
- package/dist/storage/import-files.js +133 -0
- package/dist/storage/import-gcloud.d.ts +12 -0
- package/dist/storage/import-gcloud.js +54 -0
- package/dist/storage/import-identity.d.ts +12 -0
- package/dist/storage/import-identity.js +15 -0
- package/dist/storage/import-plan.d.ts +120 -0
- package/dist/storage/import-plan.js +189 -0
- package/dist/storage/import-preflight.d.ts +36 -0
- package/dist/storage/import-preflight.js +62 -0
- package/dist/storage/import-progress-map.d.ts +5 -0
- package/dist/storage/import-progress-map.js +22 -0
- package/dist/storage/import-recover.d.ts +97 -0
- package/dist/storage/import-recover.js +186 -0
- package/dist/storage/import-run.d.ts +14 -0
- package/dist/storage/import-run.js +140 -0
- package/dist/templates/guidance/AGENTS.md +10 -0
- package/dist/templates/guidance/CLAUDE.md +1 -0
- package/dist/templates/process/package.json +2 -2
- package/dist/templates/process/pnpm-workspace.yaml +7 -4
- package/dist/validation-detail.d.ts +2 -0
- package/dist/validation-detail.js +20 -0
- package/package.json +9 -9
- package/templates/guidance/AGENTS.md +10 -0
- package/templates/guidance/CLAUDE.md +1 -0
- package/templates/process/package.json +2 -2
- package/templates/process/pnpm-workspace.yaml +7 -4
package/README.md
CHANGED
|
@@ -27,6 +27,19 @@ seq-studio doctor
|
|
|
27
27
|
> Sequence-internal contributors: see `INTERNAL.md` in the monorepo for
|
|
28
28
|
> rollout SOPs, preview environments, and publishing docs.
|
|
29
29
|
|
|
30
|
+
`seq-studio capabilities` prints the versioned command/access summary; pass
|
|
31
|
+
`--json` for automation. It reports this CLI's command groups and does not imply
|
|
32
|
+
that the underlying platform HTTP routes are public contracts.
|
|
33
|
+
|
|
34
|
+
### Piped output
|
|
35
|
+
|
|
36
|
+
Commands with `--json` write their structured result to stdout. The executable
|
|
37
|
+
allows stdout and stderr to drain before normal exit, including for large
|
|
38
|
+
responses and nonzero command statuses. Check the exit status before using a
|
|
39
|
+
result; an interrupted process or a closed downstream pipe can still leave
|
|
40
|
+
incomplete output. CLI output delivery does not remove a server's row/page cap:
|
|
41
|
+
inspect `truncated` and pagination metadata where present.
|
|
42
|
+
|
|
30
43
|
## Install
|
|
31
44
|
|
|
32
45
|
```bash
|
|
@@ -50,6 +63,12 @@ guard.** Stick with pnpm so the policy actually applies.
|
|
|
50
63
|
those come from the Studio repo's own publish pipeline, so new `seq-studio`
|
|
51
64
|
releases install immediately.)
|
|
52
65
|
|
|
66
|
+
All initializers include a short `AGENTS.md` pointing to the target environment's
|
|
67
|
+
live `/docs` and `/docs/llms.txt`, plus a `CLAUDE.md` importing it. Agents should
|
|
68
|
+
read those docs at the start of each task and consult them as needed; platform
|
|
69
|
+
instructions stay in the hosted docs rather than being copied into scaffolds.
|
|
70
|
+
Existing agent instruction files are preserved or initialization is refused.
|
|
71
|
+
|
|
53
72
|
## Authenticate
|
|
54
73
|
|
|
55
74
|
Run the built-in browser login. `seq-studio` and `seqapi` share short-lived
|
|
@@ -67,6 +86,16 @@ seq-studio doctor # confirms config + auth + authori
|
|
|
67
86
|
Use `seq-studio logout` to remove the shared Sequence session, or
|
|
68
87
|
`seq-studio logout --env bsm-staging` to remove only that OpCo realm's session.
|
|
69
88
|
|
|
89
|
+
Pipeline plan, deploy and status use the realm and exact origin selected by
|
|
90
|
+
`-e`, just like discovery commands. A login for a different environment is not
|
|
91
|
+
a substitute for that environment's session.
|
|
92
|
+
|
|
93
|
+
`seq-studio doctor` reports the selected environment, auth-cache state, resolved
|
|
94
|
+
CLI/SDK versions and paths, and deployment-access checks without printing
|
|
95
|
+
tokens. Use `--json` for structured output. `--offline` reads local config and
|
|
96
|
+
credential metadata only; it makes no discovery or HTTP requests and does not
|
|
97
|
+
validate whether a credential is currently accepted by Atlas.
|
|
98
|
+
|
|
70
99
|
### Headless auth (CI) — M2M
|
|
71
100
|
|
|
72
101
|
When there's no interactive login (CI, automation), set the service-account
|
|
@@ -146,12 +175,12 @@ locations, dependencies, and deployment selection.
|
|
|
146
175
|
|
|
147
176
|
> **Availability:** App orchestration remains an internal workflow. Standalone
|
|
148
177
|
> primitives retain their documented public/Preview availability. This change
|
|
149
|
-
> does not publish app orchestration.
|
|
178
|
+
> does not publish app orchestration. Function-to-ORM execution is supported by two SDK helpers: `createFunctionOrmExecutor` acts as the invoking user, and `createFunctionServiceOrmExecutor` acts as the function's attached service account (for Lattice steps and other invocations with no human caller).
|
|
150
179
|
|
|
151
180
|
| Command | What it does |
|
|
152
181
|
|---------|--------------|
|
|
153
182
|
| `seq-studio init <dir> --with <kinds>` | Scaffold a version 2 app, root pnpm workspace, shared package, README, and selected primitives |
|
|
154
|
-
| `seq-studio add <kind> <name> [--depends-on <ids>]` | Add any primitive, including additional ORM namespaces and UIs |
|
|
183
|
+
| `seq-studio add <kind> <name> [--depends-on <ids>] [--template <t>]` | Add any primitive, including additional ORM namespaces and UIs |
|
|
155
184
|
| `seq-studio add package <name>` | Add a shared TypeScript package to the manifest and pnpm workspace |
|
|
156
185
|
| `seq-studio deploy -e <env> [--yes] [--only id1,id2] [--dry-run]` | Validate and deploy the selected app graph, including prerequisites |
|
|
157
186
|
|
|
@@ -160,6 +189,12 @@ a comma-separated `--with` list or boolean flags (`--agent --process`). The firs
|
|
|
160
189
|
function defaults to `hello` (`--function-name` changes it). Agent, process, and
|
|
161
190
|
pipeline folders use the app name. Pipelines default to transformation stages;
|
|
162
191
|
`--pipeline-type ingestion|transformation|serving` selects another template.
|
|
192
|
+
Artifacts default to the React/Vite template; `--template nextjs` (on `init` or
|
|
193
|
+
`add artifact`) scaffolds a Next.js application instead. A Next.js artifact keeps
|
|
194
|
+
its own `pnpm-workspace.yaml` and `pnpm-lock.yaml` and stays out of the app's root
|
|
195
|
+
workspace, because hosted builds require a standalone lockfile without `workspace:`
|
|
196
|
+
dependencies; run `pnpm install` inside its directory. App deploys send its
|
|
197
|
+
directory (for example `artifacts/admin`) so Atlas builds it from the app repository.
|
|
163
198
|
|
|
164
199
|
```bash
|
|
165
200
|
seq-studio init loan-tools --with orm,function,agent,process,artifact
|
|
@@ -273,6 +308,11 @@ idempotent upsert by name, so it needs the same authority as applying the file
|
|
|
273
308
|
yourself. Workspaces are never part of Application roles: their access depends
|
|
274
309
|
on the folders and files in them and is managed in Workspaces V2.
|
|
275
310
|
|
|
311
|
+
Workspaces V2 stores files; it does not index them yet. Agent `file_search`
|
|
312
|
+
searches Chat Workspaces only, so declaring a workspace primitive does not give
|
|
313
|
+
an app's agents retrieval over its files. Read the files you need from a managed
|
|
314
|
+
function and pass them to the agent explicitly.
|
|
315
|
+
|
|
276
316
|
### Runtime dependencies (`uses`)
|
|
277
317
|
|
|
278
318
|
`depends_on` orders deploys. `uses` says what a primitive uses while it runs,
|
|
@@ -292,8 +332,14 @@ primitives:
|
|
|
292
332
|
```
|
|
293
333
|
|
|
294
334
|
Every primitive appears in the graph, including agents, pipelines and
|
|
295
|
-
workspaces.
|
|
296
|
-
|
|
335
|
+
workspaces. `seq-studio deploy` and `seq-studio artifact deploy` resolve these
|
|
336
|
+
names in the selected environment and refuse the deployment when source still
|
|
337
|
+
points at another environment. An artifact's `targets.<environment>.url` is
|
|
338
|
+
that environment's API origin. The `targets` map may list every environment.
|
|
339
|
+
Application source may contain only the origin selected by `-e`. A `uses` edge
|
|
340
|
+
to a workspace resolves that workspace by name in the selected environment. A
|
|
341
|
+
workspace UUID in source must be one that exists there; an ID from another
|
|
342
|
+
environment fails the deployment. `uses` needs schema version 2 or later.
|
|
297
343
|
|
|
298
344
|
Before the first ORM deployment, and after changing its schema, run
|
|
299
345
|
`seq-studio orm generate <namespace-path>` followed by
|
|
@@ -358,11 +404,13 @@ in Atlas too, never in the manifest.
|
|
|
358
404
|
- Members are synced every deploy. Removing one removes every role's access
|
|
359
405
|
into it.
|
|
360
406
|
- A Next.js artifact is an ordinary `artifact` member. Its server calls ORM and
|
|
361
|
-
functions as the signed-in user unless it declares
|
|
362
|
-
role that includes it should also include `end_user`
|
|
363
|
-
`invoker` on every function
|
|
364
|
-
for any artifact's browser
|
|
365
|
-
`
|
|
407
|
+
functions, and starts processes, as the signed-in user unless it declares
|
|
408
|
+
`service_account`, so a role that includes it should also include `end_user`
|
|
409
|
+
on every namespace and `invoker` on every function and process its
|
|
410
|
+
`server.capabilities` reach (the same holds for any artifact's browser
|
|
411
|
+
`capabilities`). The deploy prints an `access_gap` warning for each missing
|
|
412
|
+
namespace or function grant; process starts aren't checked yet, so grant the
|
|
413
|
+
process `invoker` explicitly. It never adds grants for you.
|
|
366
414
|
|
|
367
415
|
#### Deprecated: role definitions in YAML
|
|
368
416
|
|
|
@@ -410,10 +458,16 @@ and inherits only other collaborator roles.
|
|
|
410
458
|
| `function` | `reader`, `editor` |
|
|
411
459
|
| `orm` | `reader`, `writer` |
|
|
412
460
|
| `process` (exactly one, `only: [<process-id>]`) | `editor` |
|
|
461
|
+
| `pipeline` (needs `repo`) | `viewer`, `operator`, `editor` |
|
|
413
462
|
|
|
414
463
|
- Never `admin` or `owner`: admin can share a member and bundle it into other
|
|
415
464
|
Applications, so it stays a direct grant. Workspaces are never bundled.
|
|
416
|
-
- Every tier includes
|
|
465
|
+
- Every tier includes the ones below it, and use where the member has any, so a
|
|
466
|
+
maintainer can always use what they maintain. A pipeline runs as a service
|
|
467
|
+
principal, so it has nothing to use and appears only in collaborator roles:
|
|
468
|
+
`viewer` sees its runs, `operator` runs its stages, `editor` deploys it.
|
|
469
|
+
- A pipeline member is its release unit, the same id deploy registers:
|
|
470
|
+
`pipelines/<name>`, or `apps/<name>@<path>` for one of an app's pipelines.
|
|
417
471
|
- Consent is stricter than for runtime roles: bundling a member's tiers needs
|
|
418
472
|
**admin** on it (owner, for a process), checked on every deploy.
|
|
419
473
|
- Only the Application's admins create, edit and grant collaborator roles in
|
|
@@ -473,6 +527,122 @@ pnpm exec seq-studio agents apply -e <env>
|
|
|
473
527
|
Use `--repo agents/<name> [--ref <ref>]` or `--git-url <url>` instead of
|
|
474
528
|
`--dir` to materialize reviewed source from the platform git service.
|
|
475
529
|
|
|
530
|
+
### Voice authoring (internal staging demo)
|
|
531
|
+
|
|
532
|
+
`agents voice` is restricted to the internal synthetic demo in the configured
|
|
533
|
+
Sequence staging environment. It is not a customer-facing Voice release. Use a
|
|
534
|
+
human `seq-studio login` session with current demo participant and Agent editor
|
|
535
|
+
access; publication additionally requires a demo operator. Machine/M2M credentials
|
|
536
|
+
are rejected. All network commands require an explicit environment. The server
|
|
537
|
+
uses the same authorization, supported catalogs, source resolution, dependency
|
|
538
|
+
reviews and publication service as the Atlas Voice builder.
|
|
539
|
+
|
|
540
|
+
Voice uses the same `defineAgent(...)`/`agent.ts` format and offline compiler as
|
|
541
|
+
text Agents. An Agent ID has one immutable mode. Generic `agents apply` does not
|
|
542
|
+
activate Voice; use `agents voice save` for revision-checked draft authoring and
|
|
543
|
+
the separate publication command when ready. No command creates a Skill or a
|
|
544
|
+
Managed Function. Create those with their existing authoring tools, then attach
|
|
545
|
+
their references. The built-in banking examples are documented in the contributor
|
|
546
|
+
guide; they contain fictional data and unresolved catalog/Skill placeholders.
|
|
547
|
+
|
|
548
|
+
| Command (append `-e <env>`) | Result |
|
|
549
|
+
|---|---|
|
|
550
|
+
| `agents voice inspect <id> [--out inspection.json]` | Captured draft, current source drift/access, supported catalogs and publication permission |
|
|
551
|
+
| `agents voice export <id> [--out agent.ts]` | Exact captured authored definition using the builder's source serializer |
|
|
552
|
+
| `agents voice save <id> --expected-revision <N\|new> [--dir .] [--yes]` | Compile that ID and save only its draft; `new` means create-only, `0` is a real revision |
|
|
553
|
+
| `agents voice capture <id> --request-file capture.json [--yes]` | Explicitly attach or refresh the current native Skill text |
|
|
554
|
+
| `agents voice validate <id> --expected-revision N [--out review.json]` | Current authored/projection hashes, source status and concrete tool bindings requiring review |
|
|
555
|
+
| `agents voice publish <id> --request-file publication.json [--yes]` | One explicit, revision-checked publication attempt |
|
|
556
|
+
| `agents voice status <id> --key <uuid>` or `--operation <uuid>` | Read-only recovery; never dispatches publication |
|
|
557
|
+
| `agents voice retry <id> --operation <uuid> [--yes]` | Resume the recorded publication under current operator/dependency checks |
|
|
558
|
+
|
|
559
|
+
`save` also accepts the usual `--repo agents/<name>` or `--git-url <url>` source,
|
|
560
|
+
`--ref`, and `--target <APP_ENV>`. It selects exactly the positional Agent ID after
|
|
561
|
+
environment selection. Output files are created with restricted permissions and
|
|
562
|
+
never overwrite an existing file. Export includes only the strict authored
|
|
563
|
+
definition, including captured SOP text, native source references and declared
|
|
564
|
+
Agent permissions. It excludes provider resource IDs, runtime grants, credentials,
|
|
565
|
+
call state and draft audit metadata. Treat source text as untrusted and review it
|
|
566
|
+
before executing anything from a repository.
|
|
567
|
+
|
|
568
|
+
Start in your existing standalone typed-Agent repository:
|
|
569
|
+
|
|
570
|
+
```sh
|
|
571
|
+
seq-studio agents voice help
|
|
572
|
+
seq-studio login
|
|
573
|
+
seq-studio agents voice inspect <id> -e staging --out inspection.json
|
|
574
|
+
seq-studio agents voice export <id> -e staging --out agent.ts
|
|
575
|
+
# Edit agent.ts, retaining its Voice mode and the same ID.
|
|
576
|
+
seq-studio agents validate --dir .
|
|
577
|
+
seq-studio agents voice save <id> -e staging --dir . --expected-revision 3
|
|
578
|
+
seq-studio agents voice inspect <id> -e staging
|
|
579
|
+
# Use the actual returned draft revision, not the illustrative number here.
|
|
580
|
+
seq-studio agents voice validate <id> -e staging --expected-revision 4 --out review.json
|
|
581
|
+
```
|
|
582
|
+
|
|
583
|
+
`inspect` never replaces captured text when a source Skill changes. `save` checks
|
|
584
|
+
current Skill access but also preserves that text. For an explicit refresh, write
|
|
585
|
+
`capture.json` using the actual ID/revision and the procedure's declared references:
|
|
586
|
+
|
|
587
|
+
```json
|
|
588
|
+
{
|
|
589
|
+
"agentId": "680000000000000000000001",
|
|
590
|
+
"expectedDraftRevision": 4,
|
|
591
|
+
"action": "REFRESH",
|
|
592
|
+
"skillId": "native-skill-id",
|
|
593
|
+
"procedureKey": "replacement_card",
|
|
594
|
+
"activationDescription": "When asked to request a replacement for an eligible fictional card.",
|
|
595
|
+
"toolAliases": ["prepare_demo_service_request", "confirm_demo_service_request"],
|
|
596
|
+
"subprocedures": []
|
|
597
|
+
}
|
|
598
|
+
```
|
|
599
|
+
|
|
600
|
+
Run `agents voice capture <id> -e staging --request-file capture.json`, inspect the
|
|
601
|
+
new draft and validate its returned revision. Use `ATTACH` for a new local key;
|
|
602
|
+
`REFRESH` must identify the Skill already attached to that key. Cross-environment
|
|
603
|
+
Skill or function references are not silently mapped. Resolve `SOURCE_MISSING`,
|
|
604
|
+
`SOURCE_FORBIDDEN` or `INVALID_BINDING` in the target environment before publication.
|
|
605
|
+
Editing captured text recalculates its content hash; restoring older source from
|
|
606
|
+
Git retains its text but still requires current access and dependency review.
|
|
607
|
+
|
|
608
|
+
Read `review.json`, including each binding's function version and authority policy.
|
|
609
|
+
Create `publication.json` with its actual draft/deployment revisions, a fresh UUID
|
|
610
|
+
for this intentional publication, and only the exact tool aliases/binding hashes
|
|
611
|
+
you reviewed. `toolReviewConfirmations` may be empty only when no confirmation is
|
|
612
|
+
required. `--yes` confirms the displayed action; it never manufactures reviews.
|
|
613
|
+
|
|
614
|
+
```json
|
|
615
|
+
{
|
|
616
|
+
"agentId": "680000000000000000000001",
|
|
617
|
+
"expectedDraftRevision": 5,
|
|
618
|
+
"expectedDeploymentRevision": 2,
|
|
619
|
+
"idempotencyKey": "ea9d0f81-75c3-4a15-bbef-dbac20c4353c",
|
|
620
|
+
"toolReviewConfirmations": []
|
|
621
|
+
}
|
|
622
|
+
```
|
|
623
|
+
|
|
624
|
+
Each confirmation has shape `{"toolAlias":"alias","bindingHash":"<64-hex hash from review>"}`.
|
|
625
|
+
Generate your own UUID (for example `node -e 'console.log(crypto.randomUUID())'`);
|
|
626
|
+
the example key is illustrative. Keep the exact request file before dispatch:
|
|
627
|
+
|
|
628
|
+
```sh
|
|
629
|
+
seq-studio agents voice publish <id> -e staging --request-file publication.json
|
|
630
|
+
seq-studio agents voice status <id> -e staging --key <uuid-from-file>
|
|
631
|
+
# Only when the recorded operation requires an explicit retry:
|
|
632
|
+
seq-studio agents voice retry <id> -e staging --operation <returned-operation-uuid>
|
|
633
|
+
```
|
|
634
|
+
|
|
635
|
+
Calls time out after 30 seconds and responses are bounded to 8 MiB. Voice requests
|
|
636
|
+
never automatically retry a 503, timeout or lost response. A status response may
|
|
637
|
+
be preparing/waiting; a successful CLI exit means the request/status was read,
|
|
638
|
+
not that publication is active. Status exits `2` when no operation is recorded;
|
|
639
|
+
an in-flight request may still arrive. Keep checking the same key. If retrying the
|
|
640
|
+
initial dispatch is necessary, explicitly resend the **unchanged** publication
|
|
641
|
+
file; do not allocate a new key to escape uncertainty. After a stale-revision
|
|
642
|
+
rejection, inspect and validate current state before preparing a different request.
|
|
643
|
+
Saving, capturing or publishing never enrolls callers, provisions phone numbers,
|
|
644
|
+
opens call admission, places calls, or changes the demo limits.
|
|
645
|
+
|
|
476
646
|
## ORM commands
|
|
477
647
|
|
|
478
648
|
`seq-studio orm` authors and deploys governed ORM v2 namespaces: TypeScript
|
|
@@ -484,7 +654,7 @@ compiled to canonical SQL before registration.
|
|
|
484
654
|
| Command | What it does |
|
|
485
655
|
|---------|--------------|
|
|
486
656
|
| `seq-studio orm init <dir>` | Scaffold one v2 namespace package (`sequence.config.ts`, `schema/*.ts`, `graphql/**`, and codegen config). |
|
|
487
|
-
| `seq-studio orm generate [dir]` | Generate `schema.graphql`, `operations.manifest.json`, `typePolicies.gen.ts`, and consumer codegen when `codegen.ts` is present. |
|
|
657
|
+
| `seq-studio orm generate [dir]` | Generate `schema.graphql`, `operations.manifest.json`, `typePolicies.gen.ts`, `namespace.contract.json`, `sql-operations.gen.ts`, and consumer codegen when `codegen.ts` is present. |
|
|
488
658
|
| `seq-studio orm generate [dir] --migration-export [--check]` | Export `orm.migration.json` after validating the committed ORM migration. Pipeline migration planning recompiles these declarative inputs. `--check` compares against the current source and operations without writing; use it in CI. |
|
|
489
659
|
| `seq-studio orm validate [dir]` | Parse and compile the namespace, then verify its committed migration chain is current. |
|
|
490
660
|
| `seq-studio orm plan [dir] -e <env>` | Compare the compiled namespace with registry state without applying database changes. |
|
|
@@ -492,6 +662,7 @@ compiled to canonical SQL before registration.
|
|
|
492
662
|
| `seq-studio orm apply [dir] -e <env>` | Author a migration if needed, register/apply the namespace, activate its operation set, publish roles/capabilities, and refresh generated outputs. |
|
|
493
663
|
| `seq-studio orm execute <operation> [dir] --variables-file <file> -e <env>` | Execute one named persisted operation from `operations.manifest.json` with variables from a JSON object file, as the signed-in caller. |
|
|
494
664
|
| `seq-studio orm migrate-from-yaml <dir>` | Convert a legacy YAML namespace to TypeScript authoring while preserving its committed migrations. |
|
|
665
|
+
| `seq-studio orm import [dir] --spec <file>` | Plan a batched copy from an existing Postgres relation (a synced warehouse table) into an owned ORM table. Writes a SQL script; it does not connect or apply row policies. |
|
|
495
666
|
|
|
496
667
|
Install the CLI and ORM package together:
|
|
497
668
|
|
|
@@ -518,10 +689,48 @@ the target environment's data. `apply --no-create` is the CI guard that refuses
|
|
|
518
689
|
to provision a missing namespace. Destructive DDL requires explicit
|
|
519
690
|
`--allow-destructive` consent.
|
|
520
691
|
|
|
692
|
+
Queued rehearsals wait at most 35 minutes for a recorded verdict. If that wait
|
|
693
|
+
expires, the CLI reports an unknown status; it does not apply the schema or
|
|
694
|
+
retry the job. Inspect the printed run ID and disposable-branch cleanup before
|
|
695
|
+
starting another rehearsal.
|
|
696
|
+
|
|
521
697
|
> **Preview:** ORM v2 is a Preview workflow. The generated namespace package
|
|
522
698
|
> depends on `@sequenceholdings/orm@^2.0.0`; use the matching published major
|
|
523
699
|
> version and keep generated manifests and migrations committed with source.
|
|
524
700
|
|
|
701
|
+
### Registered SQL operations in development builds
|
|
702
|
+
|
|
703
|
+
Development builds containing SQL operation support also discover exported
|
|
704
|
+
`defineOperation({ language: 'sql', kind: 'query', ... })` definitions under
|
|
705
|
+
`operations/**/*.ts`, or equivalent `*.operation.json` files. Import the
|
|
706
|
+
authoring helper from `@sequenceholdings/orm/authoring`. This addition is not yet
|
|
707
|
+
available in the published package versions listed above.
|
|
708
|
+
|
|
709
|
+
For runtime SQL, declare `mode: 'runtime'`, namespace, operation capability,
|
|
710
|
+
`ontology.read` object references, and `maxRows`. Register this contract once;
|
|
711
|
+
execute it with `{ sql, parameters: { name: { type: 'text', value: '...' } } }`
|
|
712
|
+
as the operation variables. Different projections, joins, and unions use the same
|
|
713
|
+
operation hash. Each query is compiled against the declared objects and checked
|
|
714
|
+
against current caller permissions. A cached plan never caches authorization or
|
|
715
|
+
parameter values. Runtime contracts require matching IR v5 compiler/runtime builds.
|
|
716
|
+
|
|
717
|
+
Fixed SQL remains supported: omit `mode`, declare `parameters` and `sql` in the
|
|
718
|
+
definition, and supply only parameter values at runtime. Bind values with
|
|
719
|
+
`:parameterName`; quote camelCase properties. `orm generate` emits
|
|
720
|
+
`sql-operations.gen.ts` with typed operation handles and
|
|
721
|
+
`namespace.contract.json` for cross-namespace composition, in addition to the
|
|
722
|
+
shared manifest. `orm apply` and `orm execute` use the same lifecycle as GraphQL.
|
|
723
|
+
|
|
724
|
+
SQL reads currently support inner/left/right/full joins with `ON`, cross joins,
|
|
725
|
+
`UNION`/`UNION ALL`, correlated EXISTS, non-recursive CTEs,
|
|
726
|
+
grouping, supported aggregates, ordering, and limits. Unsupported SQL and
|
|
727
|
+
unsupported policies fail compilation. Results use column metadata plus row
|
|
728
|
+
arrays, with bigint and numeric values represented as strings. SQL writes,
|
|
729
|
+
DDL, `INTERSECT`/`EXCEPT`, window functions, `NATURAL`/`USING`/lateral joins,
|
|
730
|
+
implicit source refresh, and cross-database joins are not
|
|
731
|
+
supported. Materialized policy scans prioritize isolation; benchmark large
|
|
732
|
+
datasets before adopting this path for latency-sensitive reads.
|
|
733
|
+
|
|
525
734
|
## Process commands
|
|
526
735
|
|
|
527
736
|
| Command | What it does |
|
|
@@ -957,25 +1166,33 @@ successfully. Help does not initialize files, authenticate, or deploy.
|
|
|
957
1166
|
| `seq-studio artifact deploy [dir] -e <env> [--skip-unchanged] [--no-create] [--project <id>]` | `deploy [dir] --env <env>` — `--skip-unchanged` no-ops (before building) when the remote active deployment's `sourceHash` **and** CLI/atlas-ui peer versions already match; `--no-create` errors instead of creating a missing project; `--project <id>` targets a project directly when duplicate slugs make the lookup ambiguous (slug must still match the manifest) |
|
|
958
1167
|
| `seq-studio artifact dev [dir] -e <env> [--link <pkgDir>[,<pkgDir>]] [--port <port>]` | React/HTML: rebuild preview on changes. Next.js: local development server and owner-only Atlas tunnel; `--port` selects its loopback port. |
|
|
959
1168
|
| `seq-studio artifact pull <project-id> -e <env> [--out <dir>]` | `pull <project-id> --env <env> [--out <dir>]` |
|
|
960
|
-
| `seq-studio artifact list -e <env
|
|
961
|
-
| `seq-studio artifact show <slug-or-id> -e <env
|
|
1169
|
+
| `seq-studio artifact list -e <env> [--json]` | `list --env <env>` — projects visible on the environment (slug, id, active version, visibility); `--json` emits the response object |
|
|
1170
|
+
| `seq-studio artifact show <slug-or-id> -e <env> [--json]` | `show <slug-or-id> --env <env>` — one project's detail incl. active deployment, git provenance, and (for newer deployments) the building `artifact-studio` / force-aliased `atlas-ui` versions; `--json` emits the response object |
|
|
1171
|
+
|
|
962
1172
|
| `seq-studio artifact promote <deployment-id> -e <env>` | `promote <deployment-id> --env <env>` |
|
|
963
1173
|
| `seq-studio artifact rollback <deployment-id> -e <env>` | `rollback <deployment-id> --env <env>` |
|
|
964
1174
|
|
|
1175
|
+
Artifact commands reject unknown options before authentication or network
|
|
1176
|
+
access, so a misspelled flag cannot be silently ignored. `seq-studio artifact
|
|
1177
|
+
deploy` also refuses source that still points at another environment's API
|
|
1178
|
+
origin or workspace UUID. Declare each environment's API origin under
|
|
1179
|
+
`targets.<environment>.url`. A workspace UUID in source must exist in the
|
|
1180
|
+
environment selected by `-e`.
|
|
1181
|
+
|
|
965
1182
|
`pull` writes the **active deployment's** source files (default out dir:
|
|
966
1183
|
`./<project-id>`) and errors when the project has no active deployment.
|
|
967
1184
|
`promote` and `rollback` resolve the target project from the current
|
|
968
1185
|
directory's `.artifact-studio/config.json` — run them from the linked artifact
|
|
969
1186
|
folder (or run `seq-studio artifact link` first).
|
|
970
1187
|
|
|
971
|
-
**React/HTML active (official) deploys to deployed environments require `main
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
deployed environments
|
|
1188
|
+
**React/HTML active (official) deploys to deployed environments require `main`,
|
|
1189
|
+
or `staging` when the target is a staging environment, with a resolved git
|
|
1190
|
+
commit and a clean artifact source directory** for both Git Service (`--repo`)
|
|
1191
|
+
and local sources. When a local source is nested in a larger checkout, dirty
|
|
1192
|
+
files outside that source directory are ignored with a warning. Deployments
|
|
1193
|
+
targeting `local` may use any branch, including dirty working trees. Feature
|
|
1194
|
+
branches, dirty artifact source trees, non-git sources, and detached checkouts
|
|
1195
|
+
that cannot be attributed to an allowed branch are preview-only for deployed environments
|
|
979
1196
|
(`seq-studio artifact dev` / preview channel); promotion applies the same
|
|
980
1197
|
provenance check.
|
|
981
1198
|
|
|
@@ -1103,10 +1320,17 @@ Git Service verification required for an official release:
|
|
|
1103
1320
|
| `--repo <ns>/<name>` | a repo in the platform Git Service, e.g. `--repo artifacts/accounts` |
|
|
1104
1321
|
| `--git-url <url>` | a public, credential-free HTTPS git URL (cloned to a temp dir) |
|
|
1105
1322
|
|
|
1323
|
+
`--path <dir>` selects the application directory inside a `--repo` / `--git-url`
|
|
1324
|
+
repository (default: its root), for example `--repo apps/loan-tools --path artifacts/admin`.
|
|
1325
|
+
A Next.js release from a Git Service repository records that directory with the
|
|
1326
|
+
commit. A local `[dir]` nested in a Git Service checkout is sent the same way,
|
|
1327
|
+
relative to the checkout root.
|
|
1328
|
+
|
|
1106
1329
|
For React/HTML, `--ref <branch\|tag\|commit>` selects the revision for `build` and `plan`
|
|
1107
1330
|
(default: the repo's default branch). Active deploys to deployed environments
|
|
1108
|
-
require `main
|
|
1109
|
-
|
|
1331
|
+
require `main`, or `staging` when the target is a staging environment; local
|
|
1332
|
+
active deploys scope dirty-file checks to the source directory and warn about
|
|
1333
|
+
unrelated changes elsewhere in the checkout.
|
|
1110
1334
|
`--env local` accepts any local source ref. Other refs are preview-only for
|
|
1111
1335
|
deployed environments. A remote source is materialized to a
|
|
1112
1336
|
temp dir, built, and torn down;
|
|
@@ -1178,6 +1402,19 @@ The raw token is printed **once** on create.
|
|
|
1178
1402
|
|
|
1179
1403
|
## Repos commands
|
|
1180
1404
|
|
|
1405
|
+
`repos create` creates the hosted repository; it does not configure Git in your
|
|
1406
|
+
current folder. For a new local checkout, use `repos clone` with `ATLAS_GIT_PAT`
|
|
1407
|
+
and `--full` to get `origin`, branch tracking, and complete history for your
|
|
1408
|
+
editor's Git graph. For an existing folder, discover the clone URL with
|
|
1409
|
+
`repos show`, inspect `git remote -v`, and add a missing `origin` with
|
|
1410
|
+
`git remote add origin <clone-url>`, then `git fetch origin`. Fetching does not
|
|
1411
|
+
set an upstream: inspect the local and remote histories before using
|
|
1412
|
+
`git branch --set-upstream-to=origin/<remote-branch> <local-branch>`.
|
|
1413
|
+
See [Connect an existing folder](https://docs.seqholdings.com/seq-studio/repositories#connect-an-existing-folder)
|
|
1414
|
+
for handling folders with no commits or separate local history. Verify with
|
|
1415
|
+
`git branch -vv` and `git status --short --branch`. Plain Git needs its own
|
|
1416
|
+
credential-manager or PAT prompt setup; it does not read `ATLAS_GIT_PAT`.
|
|
1417
|
+
|
|
1181
1418
|
`seq-studio repos <sub>` manages repos in the platform Git Service over the
|
|
1182
1419
|
JSON API — the same repos `--repo <ns>/<name>` sources build from.
|
|
1183
1420
|
|
|
@@ -1187,7 +1424,7 @@ JSON API — the same repos `--repo <ns>/<name>` sources build from.
|
|
|
1187
1424
|
| `seq-studio repos namespaces [create <slug>] -e <env>` | list namespaces, or create one (creator becomes owner) |
|
|
1188
1425
|
| `seq-studio repos show <ns>/<name> -e <env>` | detail: id, branches, clone URL; artifact project id when slug matches |
|
|
1189
1426
|
| `seq-studio repos create <ns>/<name> -e <env> [--default-branch <b>] [--git-backend walgit]` | create a repo, seeded with a README on `main`. The server picks the backend (walgit wherever it is configured). `--git-backend walgit` creates it empty, for pushing existing history. Needs namespace write. |
|
|
1190
|
-
| `seq-studio repos clone <ns>/<name> \| --url <clone-url> \| --id <uuid> -e <env> [--ref <r>] [--output <dir>] [--force] [--full]` | smart-HTTP `git clone --depth 1` when `ATLAS_GIT_PAT` is set (`--full` fetches history; a commit SHA stays full). `--url`/`--id` need no seqapi. Otherwise JSON materialize + PAT hint. `--out` remains an alias for `--output`. |
|
|
1427
|
+
| `seq-studio repos clone <ns>/<name> \| --url <clone-url> \| --id <uuid> -e <env> [--ref <r>] [--output <dir>] [--force] [--full] [--transport auto\|git\|json]` | smart-HTTP `git clone --depth 1` when `ATLAS_GIT_PAT` is set (`--full` fetches history; a commit SHA stays full). `--url`/`--id` need no seqapi. Otherwise JSON materialize + PAT hint. `--out` remains an alias for `--output`. |
|
|
1191
1428
|
| `seq-studio repos pull <ns>/<name> -e <env> [--ref <r>] [--out <dir>] [--force]` | always materialize via JSON API (no `.git` dir); refuses a non-empty destination unless `--force` |
|
|
1192
1429
|
| `seq-studio repos delete <ns>/<name> -e <env> [--yes]` | delete a repo — interactive confirm unless `--yes` |
|
|
1193
1430
|
| `seq-studio repos ci show <ns>/<name> -e <env> [--ref <r>]` | preview CI checks discovered from the ref |
|
|
@@ -1232,6 +1469,18 @@ Validation logic lives in
|
|
|
1232
1469
|
install it alongside the CLI for local spec authoring and validation. The
|
|
1233
1470
|
discovery and data-reading commands below do not require the optional SDK.
|
|
1234
1471
|
|
|
1472
|
+
Pipeline packages discover `*.stage.yml` and `*.stage.yaml` files from their
|
|
1473
|
+
root by default. To place stage specs in specific subdirectories, add a
|
|
1474
|
+
`pipeline.config.yml` at the package root with `schema_version: 1` and an
|
|
1475
|
+
explicit `stage_directories` list, for example `config/stages`. Paths are
|
|
1476
|
+
relative to the package root; absolute paths, traversal, duplicates, and
|
|
1477
|
+
symlinks escaping the package are rejected. `documentation/` and `migrations/`
|
|
1478
|
+
are reserved metadata roots and cannot contain stage directories. Only listed
|
|
1479
|
+
directories are scanned. Stage `entrypoint` paths and `src/` resources remain
|
|
1480
|
+
relative to the package root. Validation, planning, deployment, migrations,
|
|
1481
|
+
and ORM repinning share the same loader. `pipeline init` scaffolds into the
|
|
1482
|
+
first listed stage directory; without config it keeps using the package root.
|
|
1483
|
+
|
|
1235
1484
|
| Command | What it does |
|
|
1236
1485
|
|---------|--------------|
|
|
1237
1486
|
| `seq-studio pipeline list -e <env> [--limit <count>] [--offset <count>] [--json]` | List available pipelines and their source repositories; default 50 results, maximum 200, with the next offset shown when more exist |
|
|
@@ -1241,24 +1490,168 @@ discovery and data-reading commands below do not require the optional SDK.
|
|
|
1241
1490
|
| `seq-studio pipeline schema <assetId> -e <env> [--target <id>] [--json]` | Inspect the deployed asset's columns, types, nullability, and table/column descriptions when returned by the server |
|
|
1242
1491
|
| `seq-studio pipeline sample <assetId> -e <env> [--target <id>] [--limit <rows>] [--json]` | Preview rows from the deployed asset; default 25, capped at 100 by the server |
|
|
1243
1492
|
| `seq-studio pipeline query <assetId> --sql <sql> -e <env> [--target <id>] [--limit <rows>] [--json]` | Run a read-only query against the virtual relation `asset`; default and maximum 1,000 result rows |
|
|
1244
|
-
| `seq-studio pipeline init --type ingestion\|transformation\|serving <name> [--dir <dir>]` | Scaffold `<name>.stage.yml` (
|
|
1493
|
+
| `seq-studio pipeline init --type ingestion\|transformation\|serving <name> [--dir <dir>]` | Scaffold `<name>.stage.yml` in the first configured stage directory (or package root without config), plus a package-root-relative `src/` Databricks-notebook entrypoint stub (begins with `# Databricks notebook source`; serving stages are declarative — no stub). Refuses to overwrite an existing spec |
|
|
1494
|
+
| `seq-studio pipeline codegen tables [--from <authoring.ts>] [--dir <dir>] [--dry-run] [--force]` | Generate one ingestion stage spec per table from a `PerTableIngestionAuthoring` TypeScript module. `--from` defaults to `authoring.tables.ts`; `--dir` defaults to the current package root and writes into its first configured stage directory (or the root without config). `--dry-run` lists output files without writing; existing files are preserved unless `--force` is supplied |
|
|
1245
1495
|
| `seq-studio pipeline validate [dir] [--assets <file\|url>] [--orm-contracts <file\|url>] [--json]` | Run the full offline spec gate: envelope + body validation, `schema_ref` resolution, and repo-level graph validation (reference resolution, single-writer, cycles, column subsets, serving projection checks). Auto-loads `orm-contracts.json` from the pipeline dir when present. Exit 0/1 |
|
|
1246
1496
|
| `seq-studio pipeline repin-orm [dir] -e <env> [--target <id>] [--dry-run]` | Resolve the environment's pipeline target (or use `--target` when ambiguous), fetch its active ORM v2 contracts, verify those serving projections remain compatible, then update `orm-contracts.json` and their `satisfies.content_hash` pins. Refuses to write when compatibility fails |
|
|
1247
1497
|
| `seq-studio pipeline plan --repo <namespace>/<slug> --ref <sha\|branch> [--root <directory>] -e <env> [--target <id>] [--json]` | Enqueue and poll a durable Pipeline plan (materialize → SDK/`validateSpecGraph` → compile → live-diff → provision findings). `<namespace>` is `pipelines` or `apps`. Fails closed listing **every** missing target binding (alert channels, workspace, Databricks `source.credential`) plus Data Sync edge-worker machine/operation/`credEnvFamilies` mismatches before registry writes. Does **not** run Databricks `bundle validate` (that is a Trigger deploy-path hard gate). Exit 1 on destructive findings (CI-safe). `--json` emits the completed stable plan envelope |
|
|
1248
|
-
| `seq-studio pipeline deploy --repo <namespace>/<slug> --ref <sha\|branch> [--root <directory>] -e <env> [--target <id>] [--approved-by <sub>] [--allow-destructive <resource-key> ...] [--run-now] [--wait-timeout <duration>] [--no-wait]` | Plan then enqueue deploy; Trigger runs `bundle validate` then `bundle deploy` against reviewed bytes. `<namespace>` is `pipelines` or `apps`. Default is plant-only (jobs are created, not run). `--run-now` runs in-unit producer roots after bundle deploy; serving refresh provisioning completes before producer trigger.after tasks can run. If a producer fails, the terminal status includes the remote Databricks task/event error when available. `--allow-destructive` is repeatable and must exactly name every deletion/recreation finding in the immutable plan; only authenticated `@seqholdings.com` users may authorize it; permission, ownership, schedule-drift, and provisioning blockers cannot be overridden. Polls to terminal unless `--no-wait`. Targets that require approval need `--approved-by` naming the authenticated caller. |
|
|
1498
|
+
| `seq-studio pipeline deploy --repo <namespace>/<slug> --ref <sha\|branch> [--root <directory>] -e <env> [--target <id>] [--approved-by <sub>] [--allow-destructive <resource-key> ...] [--run-now] [--wait-timeout <duration>] [--no-wait] [--json]` | Plan then enqueue deploy; Trigger runs `bundle validate` then `bundle deploy` against reviewed bytes. `<namespace>` is `pipelines` or `apps`. Default is plant-only (jobs are created, not run). `--run-now` runs in-unit producer roots after bundle deploy; serving refresh provisioning completes before producer trigger.after tasks can run. If a producer fails, the terminal status includes the remote Databricks task/event error when available. `--allow-destructive` is repeatable and must exactly name every deletion/recreation finding in the immutable plan; only authenticated `@seqholdings.com` users may authorize it; permission, ownership, schedule-drift, and provisioning blockers cannot be overridden. Polls to terminal unless `--no-wait`. Targets that require approval need `--approved-by` naming the authenticated caller. |
|
|
1249
1499
|
|
|
1250
1500
|
`--root` selects a contained Pipeline package inside the repository. The directory becomes the package and Databricks bundle root, so its `*.stage.yml`, `src/`, manifests, contracts, schemas, and extra resources keep their normal root-relative layout. Each repository/root pair is an independent release unit; sibling pipelines and unrelated app files are not included in its bundle. Omitting `--root` preserves the historical whole-repository release unit.
|
|
1501
|
+
|
|
1502
|
+
`seq-studio pipeline deploy --dir <checkout> --repo <namespace>/<slug> -e <env>` publishes a clean local checkout into that environment's git service, then deploys the published commit through the same path. It is available on targets that do not require approval (`dev`, `staging`). BankSouth and production still deploy a commit that already exists in that environment's git service. Set `ATLAS_GIT_PAT` (repo:write) before publishing. Do not pass `--ref` with `--dir`. When the repository is created by this command, `main` is set to the published commit so a later clone without `--ref` resolves; an existing repository's default branch is left unchanged.
|
|
1251
1503
|
| `seq-studio pipeline status --deployment-id <id> -e <env> [--json]` | Fetch the current remote deployment status without changing it. Use this public command to continue monitoring after local polling stops |
|
|
1252
1504
|
| `seq-studio pipeline adopt --stage <slug> --ref <sha\|branch> [--root <directory>] -e <env> [--target <id>] --native-id <id> --approved-by <you> [--resource-key <key>] [--kind job\|dlt_pipeline] [--old-source-removal-pr <url>] [--repo <namespace>/<slug>]` | Bind a live Databricks job/pipeline into the stage without recreation (`bundle deployment bind` on Trigger). Always requires `--approved-by` naming the caller. When the key is still in the monorepo DAB, pass `--old-source-removal-pr` and follow the returned cutover checklist: unbind the old bundle state without deleting the remote, then remove its DAB declaration and add the target-specific adopted-resource entry in the same PR before redeploying. |
|
|
1253
1505
|
| `seq-studio pipeline unbind --stage <slug> --ref <sha\|branch> [--root <directory>] -e <env> [--target <id>] --approved-by <you> [--resource-key <key>] [--repo <namespace>/<slug>]` | Release an adopted binding on Trigger; the remote object stays live (never deleted) |
|
|
1254
1506
|
| `seq-studio pipeline run-now --stage <slug> -e <env> [--target <id>] [--repo <namespace>/<slug>] [--json]` | Run the stage's active job or DLT pipeline immediately and print its Databricks run URL |
|
|
1255
|
-
| `seq-studio pipeline promote --stage <slug> --version <v> -e <env> [--target <id>] [--repo <namespace>/<slug>] [--approved-by <you>] [--wait-timeout <duration>] [--no-wait]` | Promote a validated version to another target. Targets that require approval need `--approved-by`; `--repo` disambiguates a slug that exists in multiple Pipelines |
|
|
1256
|
-
| `seq-studio pipeline rollback --stage <slug> -e <env> [--target <id>] [--repo <namespace>/<slug>] [--approved-by <you>] [--wait-timeout <duration>] [--no-wait]` | Redeploy the previously retired deployment's version. Targets that require approval need `--approved-by`. |
|
|
1507
|
+
| `seq-studio pipeline promote --stage <slug> --version <v> -e <env> [--target <id>] [--repo <namespace>/<slug>] [--approved-by <you>] [--wait-timeout <duration>] [--no-wait] [--json]` | Promote a validated version to another target. Targets that require approval need `--approved-by`; `--repo` disambiguates a slug that exists in multiple Pipelines |
|
|
1508
|
+
| `seq-studio pipeline rollback --stage <slug> -e <env> [--target <id>] [--repo <namespace>/<slug>] [--approved-by <you>] [--wait-timeout <duration>] [--no-wait] [--json]` | Redeploy the previously retired deployment's version. Targets that require approval need `--approved-by`. |
|
|
1257
1509
|
|
|
1258
1510
|
`-e/--env` selects the Atlas connection. `--target` selects the logical
|
|
1259
1511
|
pipeline target advertised by that endpoint. It is optional when the alias
|
|
1260
1512
|
matches a target id or when the endpoint has exactly one target.
|
|
1261
1513
|
|
|
1514
|
+
If Git authentication fails for a named repository, inspect its source with
|
|
1515
|
+
`seq-studio repos clone pipelines/<name> -e <env> --transport json --output ./source`.
|
|
1516
|
+
This explicitly uses your Atlas session and creates no `.git` directory. It is
|
|
1517
|
+
suitable for source inspection; obtain a Git checkout with a PAT valid for that
|
|
1518
|
+
environment when you need to push commits. URL/id-only clones require Git
|
|
1519
|
+
transport and a PAT. Avoid issuing more PATs without diagnosing the rejection.
|
|
1520
|
+
|
|
1521
|
+
### Run a repository through the managed pipeline workflow
|
|
1522
|
+
|
|
1523
|
+
Start with `seq-studio doctor --offline --json` and `seq-studio capabilities --json`
|
|
1524
|
+
to check the executable version, resolved SDK paths, cached environment, and
|
|
1525
|
+
available commands. If installed commands differ from the guide, update the CLI
|
|
1526
|
+
and SDK packages before retrying. `doctor -e <env>` checks the selected connection
|
|
1527
|
+
and authentication without opening a browser. A cache permission error needs a
|
|
1528
|
+
filesystem fix; an expired session needs login. Complete one login before retrying.
|
|
1529
|
+
|
|
1530
|
+
Edit and commit locally, then push to the selected environment's git service.
|
|
1531
|
+
For targets that allow local-checkout publishing, the CLI can publish and deploy:
|
|
1532
|
+
|
|
1533
|
+
```bash
|
|
1534
|
+
seq-studio pipeline deploy --dir . --repo pipelines/<name> -e <env> --run-now --json > deployment.json
|
|
1535
|
+
```
|
|
1536
|
+
|
|
1537
|
+
Otherwise deploy the pushed commit with `--repo pipelines/<name> --ref <commit>`.
|
|
1538
|
+
`--run-now` uses the managed worker to run in-unit producers in dependency order.
|
|
1539
|
+
Closing the local client stops polling; the remote work continues. Retain the
|
|
1540
|
+
returned deployment id and inspect it with `pipeline status --deployment-id <id>`.
|
|
1541
|
+
Deployment, serving provisioning, registry activation, and ORM readiness are
|
|
1542
|
+
separate phases; a failure after bundle deployment can leave native resources
|
|
1543
|
+
updated. Follow the returned remediation and check the serving/ORM read path.
|
|
1544
|
+
|
|
1545
|
+
For `plan`, `deploy`, `promote`, and `rollback`, `--json` writes one result to
|
|
1546
|
+
stdout and progress to stderr. A waited deployment returns its terminal detail,
|
|
1547
|
+
including failure detail with exit code 1. `--no-wait --json` returns the enqueue
|
|
1548
|
+
receipt. Keep stderr visible when redirecting or piping stdout.
|
|
1549
|
+
|
|
1550
|
+
```bash
|
|
1551
|
+
seq-studio pipeline plan --repo pipelines/<name> --ref <commit> -e <env> --json > plan.json
|
|
1552
|
+
seq-studio pipeline plan --plan-request-id <id> -e <env> --json > plan.json
|
|
1553
|
+
```
|
|
1554
|
+
|
|
1555
|
+
The second command reads the original durable plan; it does not enqueue another
|
|
1556
|
+
plan or attach credentials. Use it after a local poll/output failure, with the
|
|
1557
|
+
request id printed on stderr. Do not combine it with source, target, migration,
|
|
1558
|
+
or provisioning options. Completing a read of the plan does not deploy it.
|
|
1559
|
+
|
|
1560
|
+
### Declared external source schema checks
|
|
1561
|
+
|
|
1562
|
+
Transformation stages can opt into `source_contracts` in their stage spec (see
|
|
1563
|
+
`@sequenceholdings/pipeline-spec`). `pipeline validate` validates these declarations
|
|
1564
|
+
offline. `pipeline plan` checks the selected native column names/types against
|
|
1565
|
+
Unity Catalog metadata in the destination environment and includes all discovered
|
|
1566
|
+
mismatches in its provisioning findings. Missing tables, required columns,
|
|
1567
|
+
incompatible types, or unavailable metadata block the enrolled deployment; added
|
|
1568
|
+
unused columns are compatible.
|
|
1569
|
+
|
|
1570
|
+
Managed deployment pins the reviewed declarations and repeats the schema check
|
|
1571
|
+
before provisioning, before bundle deployment, and before producers requested by
|
|
1572
|
+
`deploy --run-now`. A plan created without the declaration fingerprint must be
|
|
1573
|
+
recreated before deploying stages with source contracts. Stages without source
|
|
1574
|
+
contracts keep their existing behavior and have no new source verification claim.
|
|
1575
|
+
|
|
1576
|
+
Execution rechecks persist source-preflight receipts with target, revision,
|
|
1577
|
+
contract fingerprint, phase, time, and structured findings. This includes early
|
|
1578
|
+
manual-run refusals without creating an invocation. `pipeline status
|
|
1579
|
+
--deployment-id <id> -e <env> --json` returns the latest 50 observations for that
|
|
1580
|
+
deployment in `sourcePreflightChecks`; the reviewed plan keeps plan-time findings.
|
|
1581
|
+
Receipt storage failure blocks the affected deployment or native submission.
|
|
1582
|
+
|
|
1583
|
+
These checks prove metadata compatibility only. They do not prove SELECT access
|
|
1584
|
+
as the job identity, row/key validity, or that arbitrary Python reads only declared
|
|
1585
|
+
sources. Standalone `pipeline run-now` rechecks the active stage before invocation
|
|
1586
|
+
creation and immediately before native submission. These manual checks cover
|
|
1587
|
+
that stage only; downstream trigger tails, native scheduled runs, and unmanaged
|
|
1588
|
+
Databricks execution still need runtime enforcement. Checks do not freeze source data or
|
|
1589
|
+
prevent schemas changing after observation.
|
|
1590
|
+
|
|
1591
|
+
### Generic serving installation lifecycle (draft)
|
|
1592
|
+
|
|
1593
|
+
This lifecycle has unit/PGlite coverage; it has not been exercised against a
|
|
1594
|
+
live installation as part of this change. Backing/dependent-view access checks
|
|
1595
|
+
cover captured dependencies, ORM ownership, explicit grants, and runtime role
|
|
1596
|
+
membership. A physical column/type/key audit is separate future hardening.
|
|
1597
|
+
Generic producer outputs and ORM source references accept safe lowercase
|
|
1598
|
+
`schema.table` identifiers, with each component limited to 63 characters.
|
|
1599
|
+
Syntax does not prove existence or authorize a relation: enrollment is limited
|
|
1600
|
+
to an active same-repo transformation producer and pins the exact declared
|
|
1601
|
+
output plus resolved physical relation. External/cross-repo sources are not
|
|
1602
|
+
supported. Legacy serving declarations and existing installations are
|
|
1603
|
+
unchanged.
|
|
1604
|
+
|
|
1605
|
+
Generic `serving` stages require an explicitly registered destination and an
|
|
1606
|
+
enrollment that pins both the serving version and its active producer. This is
|
|
1607
|
+
an operator-mediated handoff, not destination provisioning: registration
|
|
1608
|
+
inspects an existing UC catalog/schema and Lakebase schema, and fails closed if
|
|
1609
|
+
their identity or owner-only access checks do not match. It does not create a
|
|
1610
|
+
schema, change ACLs, accept connection details, or grant public access. Only a
|
|
1611
|
+
Sequence platform operator can register/revoke installations or enroll serving
|
|
1612
|
+
versions; ordinary Pipeline editor access and ORM namespace-admin access are
|
|
1613
|
+
also checked where applicable. The `reviewRef` is audit metadata, not proof of
|
|
1614
|
+
permission.
|
|
1615
|
+
|
|
1616
|
+
The intended bootstrap sequence is:
|
|
1617
|
+
|
|
1618
|
+
1. As a Sequence platform operator, register the already-existing private
|
|
1619
|
+
destination with `POST /api/data-pipelines/serving-installations`, supplying
|
|
1620
|
+
only `environment`, `catalog`, `schema`, and `reviewRef`. Save the returned
|
|
1621
|
+
server-minted `key`; do not choose the key yourself.
|
|
1622
|
+
2. With that installation key, register the serving stage shell and immutable
|
|
1623
|
+
serving version using the stage and stage-version APIs. Its transformation
|
|
1624
|
+
producer must already have an active deployment in the same repo and
|
|
1625
|
+
environment. Register the immutable ORM candidate without activating it;
|
|
1626
|
+
candidate registration does not require the serving backing to exist.
|
|
1627
|
+
3. Enroll the immutable serving stage version with
|
|
1628
|
+
`POST /api/data-pipelines/serving-installations/<key>/enrollments`, supplying
|
|
1629
|
+
`servingRepo`, `servingStage`, `sourceCommit`, and `reviewRef`. For
|
|
1630
|
+
`orm_only` or `both` exposure, also supply the explicit immutable
|
|
1631
|
+
`ormVersionId`; dataset-only enrollment must omit it. The server resolves
|
|
1632
|
+
and verifies source deployments, candidate table contracts, and serving
|
|
1633
|
+
pins. An unchanged retry is idempotent.
|
|
1634
|
+
4. Use the normal `pipeline plan` and reviewed deploy flow.
|
|
1635
|
+
Initial private creation retains acknowledgement
|
|
1636
|
+
and pending checks. Materialized resources must pass adoption verification
|
|
1637
|
+
before an active binding is advertised. Do not bypass the acknowledgement
|
|
1638
|
+
gate by switching exposure or directly writing registry rows.
|
|
1639
|
+
|
|
1640
|
+
To intentionally enroll a new serving version, use `PUT` on the same
|
|
1641
|
+
`/<key>/enrollments` path. Include the POST fields plus the
|
|
1642
|
+
`expectedPreviousSpecHash`, `expectedPreviousContractHash`,
|
|
1643
|
+
`expectedPreviousSourceSpecHash`, `expectedPreviousSourceContractHash`, and
|
|
1644
|
+
`expectedPreviousOrmVersionId` (UUID or `null`) returned by the prior
|
|
1645
|
+
enrollment. These compare-and-swap pins prevent a stale update from replacing
|
|
1646
|
+
a concurrent source or ORM-candidate repin. A revoked/expired enrollment cannot
|
|
1647
|
+
be reactivated by PUT; revoke an installation with
|
|
1648
|
+
`DELETE /api/data-pipelines/serving-installations?key=<key>` when retiring it.
|
|
1649
|
+
After changing the serving declaration or enrollment, re-plan before deploying.
|
|
1650
|
+
|
|
1651
|
+
Manual refresh uses the existing `pipeline run-now --stage <slug> -e <env>`
|
|
1652
|
+
flow. Refresh execution rechecks the active installation/enrollment and source
|
|
1653
|
+
pins. A revoked, expired, changed, or unmaterialized binding fails closed.
|
|
1654
|
+
|
|
1262
1655
|
### Discover inputs before authoring
|
|
1263
1656
|
|
|
1264
1657
|
For both people and agents, search deployed documentation to find likely inputs,
|
|
@@ -1486,6 +1879,30 @@ For local Atlas development, `-e local` uses the server's isolated `dev`
|
|
|
1486
1879
|
deployment target. Plan, deploy, and `run-now` therefore operate on the same
|
|
1487
1880
|
personal dev Databricks catalog and Lakebase branch configured for local Atlas.
|
|
1488
1881
|
|
|
1882
|
+
## Ontology consumer contracts
|
|
1883
|
+
|
|
1884
|
+
Artifact Studio manifests, `managed-function.yml`, and Pipeline `*.stage.yml`
|
|
1885
|
+
specs may opt into an explicit ontology dependency declaration:
|
|
1886
|
+
|
|
1887
|
+
```yaml
|
|
1888
|
+
ontology:
|
|
1889
|
+
version: 1
|
|
1890
|
+
read: [lending/loans]
|
|
1891
|
+
write: [lending/loan_summary]
|
|
1892
|
+
invoke: [refresh-loan-index]
|
|
1893
|
+
```
|
|
1894
|
+
|
|
1895
|
+
Object references are exact `namespace/object` names, without wildcards;
|
|
1896
|
+
function references are slugs. `produce` uses the same object-reference form
|
|
1897
|
+
but is valid only in Pipeline stage specs. The block is optional, so omitting
|
|
1898
|
+
it preserves legacy behavior. When present, deployment checks declared
|
|
1899
|
+
objects against active ORM definitions and functions against the registered
|
|
1900
|
+
functions; unresolved declarations fail deployment, including previews.
|
|
1901
|
+
|
|
1902
|
+
This records explicit consumer intent. It does not replace capabilities or
|
|
1903
|
+
permissions, and this release does not enforce declarations on runtime ORM
|
|
1904
|
+
requests.
|
|
1905
|
+
|
|
1489
1906
|
## Authorization
|
|
1490
1907
|
|
|
1491
1908
|
The CLI carries no permissions of its own: every request is authorized
|
|
@@ -1510,6 +1927,9 @@ Opt in with `cache: { enabled: true }` in `managed-function.yml` for a dedicated
|
|
|
1510
1927
|
`seq-studio functions dev --dir ./my-function --port 8080` compiles the project's TypeScript and starts a local HTTP server with the same context. Enabled caching without an explicit Valkey configuration uses bounded per-process TTL/LRU memory, only in this local harness. It never allocates cloud resources. See the Managed Functions SDK README for contracts, failure semantics, and optional private Valkey development connections.
|
|
1511
1928
|
## Blob storage / Workspaces V2
|
|
1512
1929
|
|
|
1930
|
+
Workspaces V2 is file storage, separate from Chat Workspaces. It has no content
|
|
1931
|
+
search yet, and agent `file_search` cannot read it.
|
|
1932
|
+
|
|
1513
1933
|
The initial storage package and CLI additions are pending publication and public
|
|
1514
1934
|
contract review. With a CLI build containing this feature, use the normal Atlas
|
|
1515
1935
|
environment and credentials:
|
|
@@ -1519,6 +1939,7 @@ seq-studio storage init application-documents
|
|
|
1519
1939
|
seq-studio storage validate workspace.yml
|
|
1520
1940
|
seq-studio storage apply workspace.yml -e local
|
|
1521
1941
|
seq-studio storage upload ./report.pdf --workspace <id> --path reports/report.pdf -e local
|
|
1942
|
+
seq-studio storage import ./exports --workspace <id> --path imported --yes -e local
|
|
1522
1943
|
seq-studio storage list --workspace <id> -e local
|
|
1523
1944
|
seq-studio storage download --workspace <id> --node <file-id> --out ./copy.pdf -e local
|
|
1524
1945
|
```
|
|
@@ -1538,6 +1959,18 @@ replaces content with optimistic concurrency; it preserves prior immutable versi
|
|
|
1538
1959
|
Ctrl-C stops transfer without throwing away the resumable session. `storage abort`
|
|
1539
1960
|
explicitly cancels it. Do not log session URLs or signed downloads.
|
|
1540
1961
|
|
|
1962
|
+
`storage import <directory|gs://bucket/prefix>` copies many objects into one
|
|
1963
|
+
workspace. It always prints where it will write (Atlas URL, environment, gcloud
|
|
1964
|
+
identity, source, workspace, and the pending-upload caps) and does nothing else
|
|
1965
|
+
until `--yes`. A GCS source uses your gcloud credentials to read objects; the CLI
|
|
1966
|
+
uploads those bytes with the sessions Atlas reserves in batches of 20. Applying a
|
|
1967
|
+
workspace does not cut an application over from its old bucket. Point the
|
|
1968
|
+
application at the workspace id after the import, and keep or delete the old
|
|
1969
|
+
bucket separately. `storage uploads` lists your unfinished sessions, and
|
|
1970
|
+
`storage reconcile --abort-incomplete` releases ones whose bytes never arrived.
|
|
1971
|
+
Re-run the same import to resume; progress defaults to
|
|
1972
|
+
`storage-import-progress.json`.
|
|
1973
|
+
|
|
1541
1974
|
`storage trash` and `restore` are reversible. `purge --yes` and workspace
|
|
1542
1975
|
`delete --yes` return durable Temporal receipts; inspect `storage operations` and
|
|
1543
1976
|
use `--retry <operation-id>` after correcting a failed cleanup. Each destructive
|
|
@@ -1566,6 +1999,10 @@ unreleased packages do not prove a public-registry workflow.
|
|
|
1566
1999
|
authority. Construct it inside the handler, supply the trusted configured
|
|
1567
2000
|
environment origin, and declare a service-account binding and data scopes.
|
|
1568
2001
|
It does not choose service mode or authenticate arbitrary public HTTP ingress.
|
|
2002
|
+
- `createFunctionServiceOrmExecutor({request, baseUrl, namespace, manifest})`
|
|
2003
|
+
from the same module acts as the function's attached service account. Use it
|
|
2004
|
+
for a Lattice step or another invocation with no human caller; declare data
|
|
2005
|
+
scopes and enforce any per-user rule in the handler.
|
|
1569
2006
|
- The shared execution dependency contains no ORM authoring/compiler dependencies.
|
|
1570
2007
|
Keep namespace generation in the development package, outside the Function runtime.
|
|
1571
2008
|
|