FROM python:3.10-slim WORKDIR /app # Install system dependencies RUN apt-get update && apt-get install -y git \ && rm -rf /var/lib/apt/lists/* # Install Python libs # hf_transfer enables faster downloads (Rust-based) to avoid timeouts RUN pip install --no-cache-dir \ torch \ transformers \ accelerate \ gradio \ protobuf \ sentencepiece \ hf_transfer # Enable HF Transfer ENV HF_HUB_ENABLE_HF_TRANSFER=1 # Copy app COPY . . # Run CMD ["python", "app.py"]