Skip to content

Commit 0cee25c

Browse files
authored
Merge pull request #75 from DefangLabs/linda-fix-deployment
2 parents 99f1a09 + 53b5974 commit 0cee25c

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

app/Dockerfile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,9 @@ COPY requirements.txt /app/
3333
# Install Python dependencies
3434
RUN pip install --no-cache-dir -r requirements.txt
3535

36+
# Preload the sentence transformer model to cache
37+
RUN python -c "from sentence_transformers import SentenceTransformer; SentenceTransformer('all-MiniLM-L6-v2')"
38+
3639
# Copy the application source code into the container
3740
COPY . /app
3841

app/app.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ def handle_webhook():
193193

194194
# Fetch the conversation and generate an LLM answer for the user
195195
logger.info(f"Detected a user reply in conversation {conversation_id}; fetching an answer from LLM...")
196-
answer_intercom_conversation(app.rag_system, conversation_id)
196+
answer_intercom_conversation(app.rag_system, conversation_id, topic)
197197

198198
else:
199199
logger.info(f"Received webhook for unsupported topic: {topic}; no action taken.")

0 commit comments

Comments
 (0)