#!/usr/bin/env bash
# Run from either checkout after vp i and starting a fresh dev server with
# T3CODE_DEV_SEED=0 and GOOGLE_GEMINI_BASE_URL configured for the available API.
# Configure Antigravity in the app: Gemini API key, a nonempty key, Connect.
# Arguments: fresh synthetic workspace path, T3 base directory.
set -eu
workspace=$1
base_dir=$2
mkdir -p "$workspace"
node apps/server/src/bin.ts project add --base-dir "$base_dir" --title 'Swarm proof' "$workspace"
node apps/server/src/bin.ts thread start --base-dir "$base_dir" --title 'Scout reactivation' --provider antigravity --model gemini-4-hydrogen "$workspace" "/swarm Add exactly one swarm worker named scout. Brief: create notes1.txt containing 'round one', post a board update 'scout: round one done', then swarm_wait to park. Coordinator: end your turn after the board update and do not kill the worker."
# Open the printed thread in the web app. Wait for the board update and parking.
# Start a recording, expand Previous agents, then run the following with its id:
# node apps/server/src/bin.ts thread send --base-dir "$base_dir" "$thread_id" "Use post_message to wake the existing worker @scout (do NOT add a new worker). Tell it: create notes2.txt 'round two', then notes3.txt 'round three', post a board update, then swarm_wait again."
# Observe Lineage while running, open @scout, and expand Worked / Used tools.
# Both runs used light theme and a 1280x800 CSS viewport. Sidebar was collapsed.
# The Workspace section was hidden for capture privacy; the head video also
# masks that section's rectangle. No transcript or Lineage state was changed.
