# Use a slim Python image FROM python:3.9-slim # Set working directory WORKDIR /app # Install dependencies COPY requirements.txt . RUN pip install --no-cache-dir -r requirements.txt # Copy app code and models COPY . . # Expose the default port (Hugging Face uses 7860, but can be any port) EXPOSE 7860 # Start uvicorn CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]