Spaces:
Sleeping
Sleeping
add langchain_core.documents
Browse files- src/pipeline.py +5 -1
src/pipeline.py
CHANGED
|
@@ -10,7 +10,11 @@ try:
|
|
| 10 |
from langchain.docstore.document import Document
|
| 11 |
except ModuleNotFoundError as me:
|
| 12 |
print(me.__str__())
|
| 13 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 14 |
|
| 15 |
from .logging import log_error
|
| 16 |
|
|
|
|
| 10 |
from langchain.docstore.document import Document
|
| 11 |
except ModuleNotFoundError as me:
|
| 12 |
print(me.__str__())
|
| 13 |
+
try:
|
| 14 |
+
from langchain.schema import Document
|
| 15 |
+
except:
|
| 16 |
+
from langchain_core.documents import Document
|
| 17 |
+
print('only "from langchain_core.documents import Document" worked !')
|
| 18 |
|
| 19 |
from .logging import log_error
|
| 20 |
|