Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -101,13 +101,14 @@ def get_url_text(url_link):
|
|
101 |
|
102 |
with st.sidebar:
|
103 |
st.title("Add a file for CRETA memory:")
|
104 |
-
|
105 |
-
uploaded_url = st.text_area("
|
|
|
106 |
if st.button("Submit & Process"):
|
107 |
if uploaded_files or uploaded_url:
|
108 |
with st.spinner("Processing..."):
|
109 |
if uploaded_files:
|
110 |
-
pdf_text = get_pdf_text(
|
111 |
st.session_state["docs"] = (st.session_state.get("docs", "") + pdf_text).strip()
|
112 |
|
113 |
if uploaded_url:
|
|
|
101 |
|
102 |
with st.sidebar:
|
103 |
st.title("Add a file for CRETA memory:")
|
104 |
+
uploaded_files = st.file_uploader("Upload your PDF Files and Click on the Submit & Process Button", accept_multiple_files=True)
|
105 |
+
uploaded_url = st.text_area("Please upload a URL:")
|
106 |
+
|
107 |
if st.button("Submit & Process"):
|
108 |
if uploaded_files or uploaded_url:
|
109 |
with st.spinner("Processing..."):
|
110 |
if uploaded_files:
|
111 |
+
pdf_text = get_pdf_text(uploaded_files)
|
112 |
st.session_state["docs"] = (st.session_state.get("docs", "") + pdf_text).strip()
|
113 |
|
114 |
if uploaded_url:
|