rabiyulfahim commited on
Commit
60cc5d3
·
verified ·
1 Parent(s): 3c2845b

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -2
Dockerfile CHANGED
@@ -15,11 +15,15 @@ RUN pip install --no-cache-dir -r requirements.txt
15
  COPY . .
16
 
17
  # ✅ Hugging Face cache directory (use /tmp, writable in Spaces)
18
- ENV HF_HOME=/tmp
 
 
 
19
 
20
  # Pre-download model into /tmp to avoid cold start
21
  RUN python -c "from transformers import AutoTokenizer, AutoModelForCausalLM; \
22
- model_id='rabiyulfahim/qa_python_gpt2'; \
 
23
  AutoTokenizer.from_pretrained(model_id, cache_dir='/tmp'); \
24
  AutoModelForCausalLM.from_pretrained(model_id, cache_dir='/tmp')"
25
 
 
15
  COPY . .
16
 
17
  # ✅ Hugging Face cache directory (use /tmp, writable in Spaces)
18
+ # ENV HF_HOME=/tmp
19
+ # ✅ Hugging Face cache directory (writable path)
20
+ ENV HF_HOME=/app/.cache/huggingface
21
+ RUN mkdir -p /app/.cache/huggingface
22
 
23
  # Pre-download model into /tmp to avoid cold start
24
  RUN python -c "from transformers import AutoTokenizer, AutoModelForCausalLM; \
25
+ # model_id='rabiyulfahim/qa_python_gpt2'; \
26
+ model_id='deepseek-ai/DeepSeek-R1'; \
27
  AutoTokenizer.from_pretrained(model_id, cache_dir='/tmp'); \
28
  AutoModelForCausalLM.from_pretrained(model_id, cache_dir='/tmp')"
29