FROM python:3.10-slim ENV TORCH_DISABLE_CUDA=1 ENV HF_HOME=/app/hf_cache ENV TRANSFORMERS_CACHE=/app/hf_cache WORKDIR /app COPY requirements.txt . RUN apt-get update && apt-get install -y git && \ pip install --no-cache-dir -r requirements.txt && \ rm -rf /var/lib/apt/lists/* COPY . . RUN mkdir -p /app/hf_cache && chmod -R 777 /app/hf_cache EXPOSE 7860 CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]