Huzaifa367 commited on
Commit
d0c901f
·
verified ·
1 Parent(s): f4ce74d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -2
app.py CHANGED
@@ -84,9 +84,11 @@ def main():
84
  st.header("Chat with DOCS")
85
  st.markdown("<h1 style='font-size:20px;'>ChatBot by Muhammad Huzaifa</h1>", unsafe_allow_html=True)
86
  api_key = st.secrets["inference_api_key"]
87
-
 
88
  with st.sidebar:
89
- st.title("Menu:")
 
90
  pdf_docs = st.file_uploader("Upload your PDF Files and Click on the Submit Button", accept_multiple_files=True, type=["pdf"])
91
  if st.button("Submit"):
92
  with st.spinner("Processing..."):
@@ -95,6 +97,9 @@ def main():
95
  get_vector_store(text_chunks, api_key)
96
  st.success("Done")
97
 
 
 
 
98
  # Check if any document is uploaded
99
  if pdf_docs:
100
  user_question = st.text_input("Ask a question from the Docs")
 
84
  st.header("Chat with DOCS")
85
  st.markdown("<h1 style='font-size:20px;'>ChatBot by Muhammad Huzaifa</h1>", unsafe_allow_html=True)
86
  api_key = st.secrets["inference_api_key"]
87
+
88
+
89
  with st.sidebar:
90
+ st.header("Chat with PDF")
91
+ # st.title("Menu:")
92
  pdf_docs = st.file_uploader("Upload your PDF Files and Click on the Submit Button", accept_multiple_files=True, type=["pdf"])
93
  if st.button("Submit"):
94
  with st.spinner("Processing..."):
 
97
  get_vector_store(text_chunks, api_key)
98
  st.success("Done")
99
 
100
+ if st.button("Summerize Chat"):
101
+ st.switch_page('summarizer.py')
102
+
103
  # Check if any document is uploaded
104
  if pdf_docs:
105
  user_question = st.text_input("Ask a question from the Docs")