paddlex运行报错:ModuleNotFoundError: No module named ‘langchain.docstore‘
需要修改源文件paddlex/inference/pipelines/components/retriever/base.py。
langchain为1.0.0版本
报错:
/paddlex/inference/pipelines/components/retriever/base.py", line 25, in
from langchain.docstore.document import Document
ModuleNotFoundError: No module named 'langchain.docstore'
需要修改源文件paddlex/inference/pipelines/components/retriever/base.py
if is_dep_available("langchain"):
from langchain.docstore.document import Document
from langchain.text_splitter import RecursiveCharacterTextSplitter
为
if is_dep_available("langchain"):
from langchain_core.documents import Document
from langchain_text_splitters.character import RecursiveCharacterTextSplitter
火山引擎开发者社区是火山引擎打造的AI技术生态平台,聚焦Agent与大模型开发,提供豆包系列模型(图像/视频/视觉)、智能分析与会话工具,并配套评测集、动手实验室及行业案例库。社区通过技术沙龙、挑战赛等活动促进开发者成长,新用户可领50万Tokens权益,助力构建智能应用。
更多推荐
所有评论(0)