Oriol Ganduxé Pregona commited on
Commit
f96e73c
·
1 Parent(s): 1f9e56a

Adding pre-prompt to get better results.

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -233,7 +233,9 @@ def get_result_qa_chain():
233
  return_source_documents=True
234
  )
235
 
236
- result = qa({"query": input_question.value})
 
 
237
  return result
238
 
239
  def result_box(_):
 
233
  return_source_documents=True
234
  )
235
 
236
+ final_prompt = f"You are a coder 'Bot' that helps the 'User' reading, understanding and writing code, being proactive and as verbose as necessary. Propose code and refactor sources when needed. User: {input_question.value} Bot:"
237
+ result = qa({"query": final_prompt})
238
+
239
  return result
240
 
241
  def result_box(_):