From 16a2e9b76367db38dcb6934c10fa45a6f332fb84 Mon Sep 17 00:00:00 2001 From: gjl <2802427218@qq.com> Date: Tue, 13 Aug 2024 16:48:29 +0800 Subject: [PATCH] =?UTF-8?q?fix:=E8=A7=A3=E5=86=B3agent=5Fenable=E4=B8=BAfa?= =?UTF-8?q?lse=E6=97=A0=E6=B3=95=E8=BE=93=E5=87=BA=E7=9A=84bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/mindpilot/app/chat/chat.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mindpilot/app/chat/chat.py b/src/mindpilot/app/chat/chat.py index da8baf4..6da9fe8 100644 --- a/src/mindpilot/app/chat/chat.py +++ b/src/mindpilot/app/chat/chat.py @@ -63,7 +63,8 @@ def create_models_chains( [i.to_msg_template() for i in history] ) else: - chat_prompt = ChatPromptTemplate.from_messages([]) + # TODO 完善 + chat_prompt = ChatPromptTemplate.from_messages([("system", "您好,我是智能Agent桌面助手MindPilot,请问有什么可以帮您?")]) llm = models llm.callbacks = callbacks @@ -142,7 +143,6 @@ async def chat( tools = [tool for tool in all_tools if tool.name in tool_configs] tools = [t.copy(update={"callbacks": callbacks}) for t in tools] - print(prompt) full_chain = create_models_chains( prompts=prompt, models=model,