@echo off REM Script to start Celery components on Windows REM Check if we're in the right directory if not exist "app.py" ( echo Please run this script from the backend directory pause exit /b 1 ) REM Function to start Celery worker :start_worker echo Starting Celery worker... start "Celery Worker" cmd /k "celery -A celery_app worker --loglevel=info" echo Celery worker started goto :eof REM Function to start Celery Beat scheduler :start_beat echo Starting Celery Beat scheduler... start "Celery Beat" cmd /k "celery -A celery_beat_config beat --loglevel=info" echo Celery Beat scheduler started goto :eof REM Main script logic if "%1"=="worker" ( call :start_worker ) else if "%1"=="beat" ( call :start_beat ) else if "%1"=="all" ( call :start_worker call :start_beat ) else ( echo Usage: %0 {worker^|beat^|all} echo worker - Start Celery worker echo beat - Start Celery Beat scheduler echo all - Start both worker and scheduler pause exit /b 1 )