FROM python:3.10-slim WORKDIR /app ENV TRANSFORMERS_CACHE=/tmp/hf_cache RUN mkdir -p /tmp/hf_cache RUN apt-get update && apt-get install -y git && \ pip install --no-cache-dir wheel && \ pip install "huggingface_hub<0.17" && \ pip install --no-cache-dir sentence-transformers==2.2.2 transformers==4.30.2 uvicorn fastapi COPY . /app CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]