mirror of
https://github.com/1Panel-dev/MaxKB.git
synced 2025-12-26 01:33:05 +00:00
refactor: 修改依赖包的方法
This commit is contained in:
parent
251e4645b7
commit
3cee9bc495
|
|
@ -9,7 +9,7 @@
|
|||
from typing import List, Optional, Any, Iterator, Dict
|
||||
|
||||
from langchain_community.chat_models.sparkllm import \
|
||||
ChatSparkLLM, _convert_message_to_dict, _convert_delta_to_message_chunk
|
||||
ChatSparkLLM, convert_message_to_dict, _convert_delta_to_message_chunk
|
||||
from langchain_core.callbacks import CallbackManagerForLLMRun
|
||||
from langchain_core.messages import BaseMessage, AIMessageChunk
|
||||
from langchain_core.outputs import ChatGenerationChunk
|
||||
|
|
@ -56,7 +56,7 @@ class XFChatSparkLLM(MaxKBBaseModel, ChatSparkLLM):
|
|||
default_chunk_class = AIMessageChunk
|
||||
|
||||
self.client.arun(
|
||||
[_convert_message_to_dict(m) for m in messages],
|
||||
[convert_message_to_dict(m) for m in messages],
|
||||
self.spark_user_id,
|
||||
self.model_kwargs,
|
||||
True,
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ djangorestframework = "^3.15.2"
|
|||
drf-yasg = "1.21.7"
|
||||
django-filter = "23.2"
|
||||
langchain = "0.2.16"
|
||||
langchain_community = "0.2.4"
|
||||
langchain_community = "0.2.17"
|
||||
langchain-huggingface = "^0.0.3"
|
||||
psycopg2-binary = "2.9.7"
|
||||
jieba = "^0.42.1"
|
||||
|
|
|
|||
Loading…
Reference in New Issue