Developer Docs

Golden Dataset

The ds golden CLI: a scoped, generator-driven demo/test fixture built around the Acme org — what each subcommand does and where the deep-dive docs live.

Golden Dataset

The golden dataset is a deterministic demo and testing fixture — a fully-populated org (Acme) generated from a spec, not hand-edited in a live database. Its source of truth is the generator code in the main devstride repo (backend/tests/golden/), driven through the ds golden CLI (cli/commands/golden.ts).

This page exists only to orient you to the 12 ds golden subcommands and the safety model around them. For everything else — build internals, env flags, the assertion gate, extending the dataset — see Where to Learn More below.

The ds golden Subcommands

All 12 subcommands are scoped to the golden persona org(s) (primarily Acme) and are lazy-imported so only the one you run pays the cost of loading the backend graph.

CommandWhat it does
ds golden build (alias load)Scoped rebuild of the golden Acme org from the generator — resets and rebuilds only Acme's rows.
ds golden pushFast whole-DB dump/restore: pg_dumps the locally-built golden template and pg_restores it into the bound stage, then re-seeds AI chats and Cognito logins. Destructive — disposable stages only.
ds golden importAdditive, org-scoped seed from the canonical golden source DB into the bound stage without wiping it — the safe path for shared stages.
ds golden reanchorShifts a built stage's entire temporal dataset (dates, activity, timeboxes, …) by a uniform delta without rebuilding. Defaults to --to today.
ds golden statusRead-only health check: are the persona orgs present, is the dataset anchored at today, is it in sync with the canonical source. Mutates nothing.
ds golden refresh-stageOne-shot recovery path: additive importreanchor → verify. For a stage where golden was reset/disappeared.
ds golden aichatRe-seeds the golden AI-assistant chats in DynamoDB (run standalone if that leg was skipped/failed during build/push).
ds golden enrichAdditive in-place patch of an existing golden org (descriptions, activity, feature planning, admin governance, …) — idempotent, never truncates, no rebuild.
ds golden lifecycleWIP — not yet functional via the CLI. Its own source description says so directly: "Parallel lane walk... the CLI path needs the DynamoDB item 'state' read-model alive+populated locally (vitest tears its tables down after a build)."
ds golden resetDeletes the golden Acme org's rows in the bound DB. Scoped — not a whole-DB truncate.
ds golden cognitoSeeds Cognito logins (password Demo@123) for the golden persona users.
ds golden previewPure spec-to-text dump — no DB access at all.

Safety Model

  • Scoped by default. Every mutating verb (build, reset, enrich, reanchor, import, …) operates only on the Acme golden org's rows. It is never a whole-DB wipe — except push.
  • push is refused on both prod and dev. The CLI's stage guard (assertGoldenStageWritable) blocks push outright on production and dev stages. It's meant for fresh, disposable stages only.
  • import is the safe path for shared stages. For a populated stage like app.devstride.dev, ds golden import copies the persona org(s) from the canonical GOLDEN_DB_CONNECTION_STRING source additively, without wiping anything else on the stage.

Where to Learn More

This page is intentionally a pointer, not a duplicate. The real depth — build architecture, env flags (GOLDEN_SCALE), the assertion gate, stage-seeding recipes, and how to extend the dataset — lives in the main devstride repo and changes independently of this site. Duplicating it here would just go stale.

Next Steps