# For Hugging Face Spaces with Python 3.11 FROM python:3.11-slim WORKDIR /app # Install build dependencies RUN apt-get update && apt-get install -y --no-install-recommends \ build-essential \ curl \ && rm -rf /var/lib/apt/lists/* # Upgrade pip RUN pip install --upgrade pip # Install requirements COPY requirements.txt . RUN pip install --no-cache-dir -r requirements.txt # Copy app COPY app.py . # Environment ENV PYTHONUNBUFFERED=1 # Expose port for Gradio EXPOSE 7860 CMD ["python", "app.py"]