trabb / start.sh
fokan's picture
Initial commit
0a32234
raw
history blame contribute delete
843 Bytes
#!/bin/bash
# Document Translator - Development Startup Script
echo "πŸš€ Starting Document Translator..."
# Check if virtual environment exists
if [ ! -d "venv" ]; then
echo "πŸ“¦ Creating virtual environment..."
python3 -m venv venv
fi
# Activate virtual environment
echo "πŸ”§ Activating virtual environment..."
source venv/bin/activate
# Install dependencies
echo "πŸ“š Installing dependencies..."
pip install -r requirements.txt
# Check if OpenRouter API key is set
if [ -z "$OPENROUTER_API_KEY" ]; then
echo "⚠️ Warning: OPENROUTER_API_KEY environment variable not set"
echo "Please set it with: export OPENROUTER_API_KEY='your_key_here'"
fi
# Run tests
echo "πŸ§ͺ Running setup tests..."
python test_setup.py
# Start the application
echo "🌐 Starting FastAPI server on http://localhost:7860"
python app.py