#!/usr/bin/env bash # ───────────────────────────────────────────────────────────────────────────── # scripts/start_agent.sh # # Starts the voice assistant. # Assumes the MCP server is already running (./scripts/start_server.sh). # # Usage: # chmod +x scripts/start_agent.sh # ./scripts/start_agent.sh # # Optional: point to a remote HF Spaces MCP server: # MCP_SERVER_URL=https://your-hf-space.hf.space/sse ./scripts/start_agent.sh # ───────────────────────────────────────────────────────────────────────────── set -euo pipefail ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)" cd "$ROOT_DIR" MCP_URL="${MCP_SERVER_URL:-}" if [ -n "$MCP_URL" ]; then echo "🔗 Using remote MCP server: $MCP_URL" uv run voice-agent --mcp-url "$MCP_URL" else echo "🔗 Using local MCP server (http://localhost:8000/sse)" uv run voice-agent fi