From 1ae8e0ac1fb28ae42d867761014caebbbd5818e7 Mon Sep 17 00:00:00 2001 From: commit111 Date: Thu, 17 Jul 2025 14:13:49 -0700 Subject: [PATCH] add cache var to dockerfile --- app/Dockerfile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/Dockerfile b/app/Dockerfile index 4d4ccb9..1c4a434 100644 --- a/app/Dockerfile +++ b/app/Dockerfile @@ -33,6 +33,9 @@ COPY requirements.txt /app/ # Install Python dependencies RUN pip install --no-cache-dir -r requirements.txt +# Set the environment variable for the sentence transformers model +ENV SENTENCE_TRANSFORMERS_HOME="/app/sentence-transformers" + # Preload the sentence transformer model to cache RUN python -c "from sentence_transformers import SentenceTransformer; SentenceTransformer('all-MiniLM-L6-v2')"