Translation_app_ / scripts /start_demo.bat
Athena1621's picture
feat: Implement Multi-Lingual Product Catalog Translator frontend with Streamlit
67f25fb
@echo off
echo ========================================
echo Multi-Lingual Catalog Translator
echo Quick Demo Deployment
echo ========================================
echo.
echo πŸ”§ Checking prerequisites...
where python >nul 2>nul
if %errorlevel% neq 0 (
echo ❌ Python not found! Please install Python 3.11+
pause
exit /b 1
)
echo βœ… Python found
echo.
echo πŸš€ Starting Backend Server...
echo Opening new window for backend...
start "Translator Backend" cmd /k "cd /d %~dp0backend && echo Starting Backend API on port 8001... && uvicorn main:app --host 0.0.0.0 --port 8001"
echo.
echo ⏳ Waiting for backend to initialize (15 seconds)...
timeout /t 15 /nobreak >nul
echo.
echo 🎨 Starting Frontend Server...
echo Opening new window for frontend...
start "Translator Frontend" cmd /k "cd /d %~dp0frontend && echo Starting Streamlit Frontend on port 8501... && streamlit run app.py --server.port 8501"
echo.
echo βœ… Deployment Complete!
echo.
echo πŸ“± Access your application:
echo πŸ”— Frontend UI: http://localhost:8501
echo πŸ”— Backend API: http://localhost:8001
echo πŸ”— API Docs: http://localhost:8001/docs
echo.
echo πŸ’‘ Tips:
echo - Wait 30-60 seconds for models to load
echo - Check the backend window for loading progress
echo - Both windows will stay open for monitoring
echo.
echo πŸ›‘ To stop all services:
echo Run: stop_services.bat
echo Or close both command windows
echo.
echo Press any key to open the frontend in your browser...
pause >nul
start http://localhost:8501
echo.
echo πŸŽ‰ Application is now running!
echo Check the opened browser window.