Spaces:
Build error
Build error
fix unstructured loader
Browse files- app.py +1 -1
- requirements.txt +1 -0
app.py
CHANGED
@@ -193,7 +193,7 @@ def respond(
|
|
193 |
def upload_documents(files):
|
194 |
for file in files:
|
195 |
loader = UnstructuredFileLoader(file.name)
|
196 |
-
documents = loader.
|
197 |
add_documents_to_chroma(chroma_client, chroma_collection, documents, embedding_function)
|
198 |
return "Documents uploaded and processed successfully!"
|
199 |
|
|
|
193 |
def upload_documents(files):
|
194 |
for file in files:
|
195 |
loader = UnstructuredFileLoader(file.name)
|
196 |
+
documents = loader.load()
|
197 |
add_documents_to_chroma(chroma_client, chroma_collection, documents, embedding_function)
|
198 |
return "Documents uploaded and processed successfully!"
|
199 |
|
requirements.txt
CHANGED
@@ -10,6 +10,7 @@ langchain-community
|
|
10 |
langchain-chroma
|
11 |
unstructured[all-docs]
|
12 |
libmagic
|
|
|
13 |
# poppler
|
14 |
# tesseract
|
15 |
# libxml2
|
|
|
10 |
langchain-chroma
|
11 |
unstructured[all-docs]
|
12 |
libmagic
|
13 |
+
gradio
|
14 |
# poppler
|
15 |
# tesseract
|
16 |
# libxml2
|