You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
base_prompt="""Use the following pieces of context to answer the question at the end. First identify which of the contexts are relevant to the question.
185
-
If you don't know the answer, just say that you don't know, don't try to make up an answer.
186
-
Use five sentences maximum and keep the answer as concise as possible.
187
+
base_prompt="""Use the following list of documents to answer user's question.
188
+
Use the following steps:
189
+
190
+
1. Identify if the user input is really a question.
191
+
2. If the user input is not related to the topic then respond that it is not related to the topic.
192
+
3. If the user input is related to the topic then first identify relevant documents from the list of documents.
193
+
4. Ignore all the documents that are not relevant to the question.
194
+
5. If the documents that you found relevant have information to completely and accurately answers the question then respond with the answer.
195
+
6. If the documents that you found relevant have code snippets then respond with the code snippets.
196
+
7. Most importantly, don't make up code snippets that are not present in the documents.
197
+
198
+
####
199
+
Documents
187
200
####
188
201
{context}
189
202
###
190
-
Question: {question}
203
+
User: {question}
191
204
###
192
-
Include a {response_programming_language} code snippet verbatim in the answer wherever possible. You speak like {persona} in {language}. If the context is empty, ask for more information.
205
+
206
+
If the user input is generic then respond with a generic answer. For example: If the user says "Hello" then respond with "Hello". If the user says "Thank you" then respond with "You are welcome".
207
+
You speak like {persona} in {language}.
208
+
209
+
Most importantly, If you don't find any document to answer the question say I don't know! DON'T MAKE UP AN ANSWER! It is very important that you don't make up an answer!
0 commit comments