Update app.py
Browse files
app.py
CHANGED
@@ -195,11 +195,24 @@ def route_llm(context: str, query: str):
|
|
195 |
|
196 |
@outlines.prompt
|
197 |
def answer_with_context(context: str, query: str):
|
198 |
-
"""You are a world class AI model who answer
|
199 |
|
200 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
201 |
|
202 |
-
|
|
|
203 |
Answer:
|
204 |
"""
|
205 |
|
|
|
195 |
|
196 |
@outlines.prompt
|
197 |
def answer_with_context(context: str, query: str):
|
198 |
+
"""You are a world class AI model who answer Query by following the steps below :
|
199 |
|
200 |
+
1. Recursively break-down the Query into smaller questions/directives
|
201 |
+
|
202 |
+
2. For each atomic question/directive:
|
203 |
+
|
204 |
+
2a. Select the most relevant information from the Context
|
205 |
+
|
206 |
+
3. Generate a draft response using the selected information
|
207 |
+
|
208 |
+
4. Remove duplicate content from the draft response
|
209 |
+
|
210 |
+
5. Generate your final answer after adjusting it to increase accuracy and relevance
|
211 |
+
|
212 |
+
Context: {context}
|
213 |
|
214 |
+
Query: {query}
|
215 |
+
|
216 |
Answer:
|
217 |
"""
|
218 |
|