Pavan178 commited on
Commit
f8d8d78
·
verified ·
1 Parent(s): 889981c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -74,7 +74,7 @@ If the answer isn't directly available, explain why.""",
74
  input_variables=["context", "question"]
75
  )
76
 
77
- @timeout_decorator.timeout(60) # 1 minute timeout for PDF processing
78
  def load_and_process_pdf(self, pdf_path):
79
  loader = PyPDFLoader(pdf_path)
80
  documents = loader.load()
@@ -88,7 +88,7 @@ If the answer isn't directly available, explain why.""",
88
  combine_docs_chain_kwargs={"prompt": self.qa_prompt}
89
  )
90
 
91
- @timeout_decorator.timeout(30) # 30 seconds timeout for chat
92
  def chat(self, query):
93
  if not self.chain:
94
  return "Please upload a PDF first."
 
74
  input_variables=["context", "question"]
75
  )
76
 
77
+
78
  def load_and_process_pdf(self, pdf_path):
79
  loader = PyPDFLoader(pdf_path)
80
  documents = loader.load()
 
88
  combine_docs_chain_kwargs={"prompt": self.qa_prompt}
89
  )
90
 
91
+
92
  def chat(self, query):
93
  if not self.chain:
94
  return "Please upload a PDF first."