#!/usr/bin/env bash
set -euo pipefail
# Run from either commit's installed checkout after T3CODE_DEV_SEED=0 vp run dev.
node apps/server/src/bin.ts project add "$PWD" --base-dir .t3 --title identity-demo
node apps/server/src/bin.ts thread start "$PWD" Start --base-dir .t3 --title 'Service worker identity' --provider devReplay --model multi-turn --wait --json
# Pair the web client using the startup pairing link, then open the returned thread.
