@echo off setlocal enabledelayedexpansion title Church Transcription — Installation echo. echo ============================================================ echo Church Live Transcription Display — One-time Setup echo ============================================================ echo. echo This will install all required software into a local echo virtual environment (.venv). It will NOT affect other echo Python programs on this computer. echo. echo Estimated time: 10-20 minutes (depends on internet speed). echo. pause :: ── Check Python ──────────────────────────────────────────────────────────── echo [1/6] Checking Python version... python --version >nul 2>&1 if errorlevel 1 ( echo. echo ERROR: Python is not installed or not in PATH. echo Please install Python 3.11 from https://python.org echo Make sure you tick "Add Python to PATH" during install. echo. pause exit /b 1 ) for /f "tokens=2 delims= " %%v in ('python --version 2^>^&1') do set PYVER=%%v echo Found Python %PYVER% :: ── Create virtual environment ─────────────────────────────────────────────── echo. echo [2/6] Creating virtual environment in .venv\ ... if exist .venv ( echo .venv already exists — skipping creation. ) else ( python -m venv .venv if errorlevel 1 ( echo ERROR: Failed to create virtual environment. pause exit /b 1 ) ) call .venv\Scripts\activate.bat :: ── Upgrade pip ────────────────────────────────────────────────────────────── echo. echo [3/6] Upgrading pip... python -m pip install --upgrade pip --quiet :: ── Install PyTorch with CUDA ───────────────────────────────────────────────── echo. echo [4/6] Installing PyTorch with CUDA support (~2.5 GB download)... echo This is the longest step. Please wait. echo. pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu124 if errorlevel 1 ( echo. echo ERROR: PyTorch installation failed. echo Check your internet connection and try again. pause exit /b 1 ) :: ── Install WhisperLiveKit ──────────────────────────────────────────────────── echo. echo [5/6] Installing WhisperLiveKit and dependencies... echo. pip install whisperlivekit pyannote.audio if errorlevel 1 ( echo. echo ERROR: WhisperLiveKit installation failed. pause exit /b 1 ) :: ── Install bridge dependencies ─────────────────────────────────────────────── echo. echo [6/6] Installing bridge script dependencies... pip install -r bridge\requirements.txt if errorlevel 1 ( echo. echo ERROR: Bridge dependencies failed to install. pause exit /b 1 ) :: ── Pre-download Whisper model ──────────────────────────────────────────────── echo. echo Downloading Whisper large-v3 model (~3 GB) — this only happens once. echo. python -c "from faster_whisper import WhisperModel; WhisperModel('large-v3', device='cuda', compute_type='float16')" if errorlevel 1 ( echo. echo WARNING: Model pre-download failed. It will download on first start instead. echo This is not critical — continuing. ) :: ── Done ───────────────────────────────────────────────────────────────────── echo. echo ============================================================ echo Installation complete. echo ============================================================ echo. echo Next steps: echo 1. Edit start.bat and add your HuggingFace token echo (see SETUP.md Part 7 for instructions) echo 2. Double-click start.bat to launch the system echo. pause