Update document_qa_engine.py
Browse files- document_qa_engine.py +2 -2
document_qa_engine.py
CHANGED
@@ -118,7 +118,7 @@ class DocumentQAEngine:
|
|
118 |
|
119 |
def inference(self, query, input_messages: List[dict]):
|
120 |
system_message = ChatMessage.from_system(
|
121 |
-
"You are a
|
122 |
messages = [system_message]
|
123 |
for message in input_messages:
|
124 |
if message["role"] == "user":
|
@@ -127,7 +127,7 @@ class DocumentQAEngine:
|
|
127 |
messages.append(
|
128 |
ChatMessage.from_user(message["content"]))
|
129 |
messages.append(ChatMessage.from_user("""
|
130 |
-
Relevant information from the uploaded
|
131 |
{% for doc in documents %}
|
132 |
{{ doc.content }}
|
133 |
{% endfor %}
|
|
|
118 |
|
119 |
def inference(self, query, input_messages: List[dict]):
|
120 |
system_message = ChatMessage.from_system(
|
121 |
+
"You are a consultant answering questions about potential AI use cases based on the uploaded document. Please provide accurate, concise answers in 1-2 sentences, referencing the document content.")
|
122 |
messages = [system_message]
|
123 |
for message in input_messages:
|
124 |
if message["role"] == "user":
|
|
|
127 |
messages.append(
|
128 |
ChatMessage.from_user(message["content"]))
|
129 |
messages.append(ChatMessage.from_user("""
|
130 |
+
Relevant information from the uploaded documents:
|
131 |
{% for doc in documents %}
|
132 |
{{ doc.content }}
|
133 |
{% endfor %}
|