Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -74,7 +74,7 @@ def get_vectorstore():
|
|
74 |
|
75 |
def main():
|
76 |
load_dotenv()
|
77 |
-
user_question = "
|
78 |
folder_path = './PDFs'
|
79 |
pdf_text = get_pdf_text(folder_path)
|
80 |
text_chunks = get_text_chunks(pdf_text)
|
@@ -82,9 +82,10 @@ def main():
|
|
82 |
|
83 |
retriever=get_vectorstore().as_retriever()
|
84 |
retrieved_docs=retriever.invoke(
|
85 |
-
|
86 |
)
|
87 |
-
|
|
|
88 |
# bei incoming pdf
|
89 |
|
90 |
#vectorstore_DB=get_vectorstore() # bei Abfrage durch Chatbot
|
|
|
74 |
|
75 |
def main():
|
76 |
load_dotenv()
|
77 |
+
user_question = st.text_area("Eingabe:")
|
78 |
folder_path = './PDFs'
|
79 |
pdf_text = get_pdf_text(folder_path)
|
80 |
text_chunks = get_text_chunks(pdf_text)
|
|
|
82 |
|
83 |
retriever=get_vectorstore().as_retriever()
|
84 |
retrieved_docs=retriever.invoke(
|
85 |
+
user_question
|
86 |
)
|
87 |
+
if text:
|
88 |
+
st.text(retrieved_docs[0].page_content)
|
89 |
# bei incoming pdf
|
90 |
|
91 |
#vectorstore_DB=get_vectorstore() # bei Abfrage durch Chatbot
|