Learnerbegginer commited on
Commit
24b8a66
·
verified ·
1 Parent(s): b93b23f

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -1
Dockerfile CHANGED
@@ -17,7 +17,12 @@ RUN pip install --no-cache-dir -r requirements.txt
17
  # Create cache directory and set permissions
18
  RUN mkdir -p /app/cache && chown -R appuser /app/cache
19
 
20
- # Copy all files and set ownership
 
 
 
 
 
21
  COPY . .
22
  RUN chown -R appuser /app
23
 
 
17
  # Create cache directory and set permissions
18
  RUN mkdir -p /app/cache && chown -R appuser /app/cache
19
 
20
+ # Pre-download the model during build time
21
+ RUN python3 -c "from transformers import AutoTokenizer, AutoModelForSeq2SeqLM; \
22
+ AutoTokenizer.from_pretrained('ai4bharat/IndicBART', use_fast=False); \
23
+ AutoModelForSeq2SeqLM.from_pretrained('ai4bharat/IndicBART')"
24
+
25
+ # Copy all project files and set ownership
26
  COPY . .
27
  RUN chown -R appuser /app
28