lekkalar commited on
Commit
0aae5ba
·
1 Parent(s): 1cfe121

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -49,7 +49,7 @@ def load_pdf_and_generate_embeddings(pdf_doc, open_ai_key, relevant_pages):
49
  {context}
50
 
51
  Question: {question}
52
- Return the answer. Where applicable, break the answer into bullet points. When the sentences are long, try and break them into sub sections and include all the information and do not skip any information. If there is an exception to the answer, please do include it in a 'Note:' section. Include a 'For additional details refer to' section as needed. If the document has a Preface or 'Table of Contents' section, extract the chapter# and a short description and include the info under the 'For additional details refer to' section. List only the chapters that contain information or skip this section altogether. Do not use page numbers as chapter numbers as they are different. If additional information is found in multiple pages within the same chapter, list the chapter only once. If chapter information cannot be extracted, include any other information that will help the user to navigate to the relevant sections of the document. """
53
 
54
  PROMPT = PromptTemplate(template=prompt_template, input_variables=["context", "question"])
55
 
 
49
  {context}
50
 
51
  Question: {question}
52
+ Return the answer. Where applicable, break the answer into bullet points. When the sentences are long, try and break them into sub sections and include all the information and do not skip any information. If there is an exception to the answer, please do include it in a 'Note:' section. Include a 'For additional details refer to' section when the document has more information to offer on the topic being questioned. If the document has a Preface or 'Table of Contents' section, extract the chapter# and a short description and include the info under the 'For additional details refer to' section. List only the chapters that contain information or skip this section altogether. Do not use page numbers as chapter numbers as they are different. If additional information is found in multiple pages within the same chapter, list the chapter only once. If chapter information cannot be extracted, include any other information that will help the user navigate to the relevant sections of the document. If the document does not contain a Preface or 'Table of Contents' section, do not call that out in the response."""
53
 
54
  PROMPT = PromptTemplate(template=prompt_template, input_variables=["context", "question"])
55