Cortex · Guides
Start a local session
Obtain Cortex through your team's distribution process; see installation and access. The executable wrappers require Node.js 22.6.0 or later.
Before starting, choose a session directory, a model catalog and routing policy, and an API token. The daemon loads local .env and normally loads host channel credentials; it may refresh host OAuth credentials. For an isolated session, disable host-secret loading, Slack autostart and automatic tunnels. Review .env too: disabling host configuration does not disable that file.
Prepare models.toml using your available model identifiers and route. Credentials alone do not select a model, and the example names in the catalog procedure are placeholders. With no catalog entries or discovered models, a seat can remain unrouted.
From an environment with Cortex installed and that catalog prepared:
export PI_DURABLE_DISABLE_HOST_CONFIG=1
export PI_DURABLE_AUTO_TUNNEL=0
export CORTEX_MODEL_CATALOG="$PWD/models.toml"
export PI_DURABLE_SESSION_DIR="$PWD/session-state"
# Supply PI_DURABLE_API_TOKEN through your secret manager.
# Set THALAMUS_URL if the catalog uses Thalamus routing.
cortexd --host 127.0.0.1 --port 4319 --no-slack
Run the daemon under your process supervisor for ongoing use. Do not use cortexd --help to inspect its options: it has no help dispatch and can start the daemon. The daemon reference lists its options.
In another terminal with the same URL, session-directory and token environment:
cortex doctor --json
cortex seats
cortex models
cortex status --seat sandbox@local --conv 1
Read the readiness report and model list before sending work. doctor checks configuration and routes, not live inference. Startup preloads the sandbox unless --no-sandbox is set and writes daemon.json for CLI discovery. If the CLI reaches another daemon, inspect explicit URL/port environment and that discovery file.
Open the daemon's /ui interface to work in a browser. Keep the listener local unless you have deliberately configured authentication and protected network access. Channel signatures do not protect every HTTP route.