File size: 843 Bytes
0a32234
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/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