models:switch
rai models:switch [OPTIONS] <NAME>Switch the current model.
Validates that name is a provisioned model schema, then updates
deployment.schema in raiconfig (preserving comments/layout). This
is the schema rai models deploy and rai models branch use.
Validation dispatches on the configured oplog backend, so switch
is a first-class verb on every backend. It only rewrites raiconfig
(recording nothing), so unlike deploy/pull/merge it also works when
the oplog is disabled, like teardown:
jsonl: the model is provisioned iff its local oplog store has records (a parent carries Deploy/Create entries; a branch a leading BranchEntry). Validated purely from the oplog — no SQL connection.snowflake: keep theis_model_schemagate (theRAI_MODELobject tag set during real provisioning), unchanged.- oplog disabled: there is no oplog to consult, and a disabled-mode
deploy is a plain schema install that sets no
RAI_MODELtag — sois_model_schemawould wrongly reject it. Fall back toschema_exists(existence-only, no tag), the least-surprising gate that still catches a typo’d target.
Options
| Option | Type | Description |
|---|---|---|
--yes, -y | Boolean | Skip confirmation prompts (e.g. when modifying a raiconfig.yaml outside the current directory). Default: False. |