okami.mom/strata
git clone https://git.nkp.pet/okami.mom/strata
4f0f93394
main
Terminal quick start
This page is for people who already have a model and want to read a running server, rerun it from a saved profile, or measure it.
To set up and serve a new model, use strata launch.
The commands use the strata command from the Terminal install, which carries its own Python.
In a source checkout, type python strata.py in place of strata, from the repository root. These commands read, prepare
and rerun a model you already have; they do not download one. All options, permissions and limits are in TERMINAL.md.
Read a running server
With Strata already serving locally, get one machine-readable snapshot:
strata status--url http://127.0.0.1:8080--json
The interactive monitor comes with the installed Terminal. Open the one-screen Overview:
strata monitor--url http://127.0.0.1:8080
The Overview puts serving state, prompt and answer speed, batch/queue pressure, four selected GPU rows, requests and activity on one screen. Press 1–7 for the views (7 is Connect), Space to freeze the display, r to refresh, and q to detach. Detach leaves the server running. On a machine without a terminal, use status --json or monitor --once --json.
For a remote server, use HTTPS or a local SSH tunnel. A saved connection stores only the credential environment variable's name:
strata connection create work--url https://example.invalid--credential-env STRATA_TELEMETRY_KEYstrata monitor--connection work
Set STRATA_TELEMETRY_KEY in the environment before connecting. Replace example.invalid with your own server root. The monitor client never needs a management credential.
Prepare and rerun a local model
Use the run config written by setup. Start by reviewing its components and effective launch; neither command starts an engine:
strata doctor--profile /absolute/path/to/strata-model.json--components --output jsonstrata serve--profile /absolute/path/to/strata-model.json--plan --output json
For repeatable local management, create a named profile from that config. Review changes before saving them:
strata profile create four-gpu--from-config /absolute/path/to/strata-model.jsonstrata profile set four-gpu parallel=8 batch_groups=auto max_queue=32 queue_timeout=15 batch_telemetry=true--plan strata profile set four-gpu parallel=8 batch_groups=auto max_queue=32 queue_timeout=15 batch_telemetry=truestrata profile show four-gpu--effective --output jsonstrata runtime start--profile four-gpu--plan --output jsonstrata runtime start--profile four-gpustrata runtime verify--profile four-gpu--output json
Choose slot and queue settings for the actual model and card memory. A requested parallel=8 does not prove the engine loaded eight effective slots. Check the reported values after start. To change a running profile, save the edit, review the restart, then execute it:
strata profile set four-gpu parallel=4--plan strata profile set four-gpu parallel=4strata runtime restart--profile four-gpu--plan --output jsonstrata runtime restart--profile four-gpu
The restart is an explicit operation. profile set alone does not restart or retune a running model. runtime stop --profile four-gpu stops only the owned instance; q in Monitor does not. The desktop app starts its models through the same runtime host on every system.
Check cards, calibrate and benchmark
Read installed components without launching the engine. The --live forms also probe host GPUs:
strata components verify--profile four-gpu--output jsonstrata doctor--profile four-gpu--live --output json
Calibration is separate from serving. Review the plan and measure a decode sweep only when the selected devices are available for exclusive use. Measuring writes a report but does not apply settings:
strata engine calibrate--profile four-gpu--plan --output jsonstrata engine calibrate--profile four-gpu--measure --exclusive --out /absolute/path/to/calibration.jsonstrata engine calibrate--profile four-gpu--review-result /absolute/path/to/calibration.json--output json
After reviewing the report, applying and rolling back remain separate explicit actions. Both require exclusive device access:
strata engine calibrate--profile four-gpu--apply-result /absolute/path/to/calibration.json--exclusive strata engine calibrate--profile four-gpu--review-rollback /absolute/path/to/calibration.json--output jsonstrata engine calibrate--profile four-gpu--rollback-result /absolute/path/to/calibration.json--exclusive
Check the candidate report and owner state before either action. The full preconditions and rollback behavior are in TERMINAL.md.
After the model is loaded, save an explicit serving benchmark report:
strata bench run--profile four-gpu--suite serving-smoke--concurrency 4--out /absolute/path/to/new-bench-report
The benchmark writes into a new output directory and does not publish its result. Synthetic screenshots and local fake-engine tests do not establish performance on a four-card host. Capture the exact GPU generation, model, driver and workload before comparing real runs.
1# Terminal quick start 2 3This page is for people who already have a model and want to read a running server, rerun it from a saved profile, or measure it. 4To set up and serve a new model, use [`strata launch`](TERMINAL_LAUNCH.md). 5 6The commands use the `strata` command from the [Terminal install](INSTALL.md#the-terminal), which carries its own Python. 7In a source checkout, type `python strata.py` in place of `strata`, from the repository root. These commands read, prepare 8and rerun a model you already have; they do not download one. All options, permissions and limits are in [TERMINAL.md](TERMINAL.md). 9 10## Read a running server 11 12With Strata already serving locally, get one machine-readable snapshot: 13 14``` sh 15strata status --url http://127.0.0.1:8080 --json 16``` 17 18The interactive monitor comes with the installed Terminal. Open the one-screen Overview: 19 20``` sh 21strata monitor --url http://127.0.0.1:8080 22``` 23 24The Overview puts serving state, prompt and answer speed, batch/queue pressure, four selected GPU rows, requests and activity on one screen. Press `1`–`7` for the views (`7` is Connect), `Space` to freeze the display, `r` to refresh, and `q` to detach. Detach leaves the server running. On a machine without a terminal, use `status --json` or `monitor --once --json`. 25 26For a remote server, use HTTPS or a local SSH tunnel. A saved connection stores only the credential environment variable's **name**: 27 28``` sh 29strata connection create work --url https://example.invalid --credential-env STRATA_TELEMETRY_KEY 30strata monitor --connection work 31``` 32 33Set `STRATA_TELEMETRY_KEY` in the environment before connecting. Replace `example.invalid` with your own server root. The monitor client never needs a management credential. 34 35## Prepare and rerun a local model 36 37Use the run config written by setup. Start by reviewing its components and effective launch; neither command starts an engine: 38 39``` sh 40strata doctor --profile /absolute/path/to/strata-model.json --components --output json 41strata serve --profile /absolute/path/to/strata-model.json --plan --output json 42``` 43 44For repeatable local management, create a named profile from that config. Review changes before saving them: 45 46``` sh 47strata profile create four-gpu --from-config /absolute/path/to/strata-model.json 48strata profile set four-gpu parallel=8 batch_groups=auto max_queue=32 queue_timeout=15 batch_telemetry=true --plan 49strata profile set four-gpu parallel=8 batch_groups=auto max_queue=32 queue_timeout=15 batch_telemetry=true 50strata profile show four-gpu --effective --output json 51strata runtime start --profile four-gpu --plan --output json 52strata runtime start --profile four-gpu 53strata runtime verify --profile four-gpu --output json 54``` 55 56Choose slot and queue settings for the actual model and card memory. A requested `parallel=8` does not prove the engine loaded eight effective slots. Check the reported values after start. To change a running profile, save the edit, review the restart, then execute it: 57 58``` sh 59strata profile set four-gpu parallel=4 --plan 60strata profile set four-gpu parallel=4 61strata runtime restart --profile four-gpu --plan --output json 62strata runtime restart --profile four-gpu 63``` 64 65The restart is an explicit operation. `profile set` alone does not restart or retune a running model. `runtime stop --profile four-gpu` stops only the owned instance; `q` in Monitor does not. The desktop app starts its models through the same runtime host on every system. 66 67## Check cards, calibrate and benchmark 68 69Read installed components without launching the engine. The `--live` forms also probe host GPUs: 70 71``` sh 72strata components verify --profile four-gpu --output json 73strata doctor --profile four-gpu --live --output json 74``` 75 76Calibration is separate from serving. Review the plan and measure a decode sweep only when the selected devices are available for exclusive use. Measuring writes a report but does not apply settings: 77 78``` sh 79strata engine calibrate --profile four-gpu --plan --output json 80strata engine calibrate --profile four-gpu --measure --exclusive --out /absolute/path/to/calibration.json 81strata engine calibrate --profile four-gpu --review-result /absolute/path/to/calibration.json --output json 82``` 83 84After reviewing the report, applying and rolling back remain separate explicit actions. Both require exclusive device access: 85 86``` sh 87strata engine calibrate --profile four-gpu --apply-result /absolute/path/to/calibration.json --exclusive 88strata engine calibrate --profile four-gpu --review-rollback /absolute/path/to/calibration.json --output json 89strata engine calibrate --profile four-gpu --rollback-result /absolute/path/to/calibration.json --exclusive 90``` 91 92Check the candidate report and owner state before either action. The full preconditions and rollback behavior are in [TERMINAL.md](TERMINAL.md). 93 94After the model is loaded, save an explicit serving benchmark report: 95 96``` sh 97strata bench run --profile four-gpu --suite serving-smoke --concurrency 4 --out /absolute/path/to/new-bench-report 98``` 99 100The benchmark writes into a new output directory and does not publish its result. Synthetic screenshots and local fake-engine tests do not establish performance on a four-card host. Capture the exact GPU generation, model, driver and workload before comparing real runs.