Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
@@ -25,8 +25,9 @@ def pdf_to_document_store(pdf_files):
|
|
25 |
for pdf in pdf_files:
|
26 |
doc = converter.convert(file_path=pdf.name, meta=None)[0]
|
27 |
preprocessed_doc=preprocessor.process([doc])
|
28 |
-
|
29 |
-
|
|
|
30 |
st.write('Document count: ', document_store.get_document_count())
|
31 |
|
32 |
|
|
|
25 |
for pdf in pdf_files:
|
26 |
doc = converter.convert(file_path=pdf.name, meta=None)[0]
|
27 |
preprocessed_doc=preprocessor.process([doc])
|
28 |
+
st.write(preprocessed_doc[0]['content']
|
29 |
+
documents.append(preprocessed_doc)
|
30 |
+
document_store.write_documents(documents)
|
31 |
st.write('Document count: ', document_store.get_document_count())
|
32 |
|
33 |
|