Commit 28a8820b authored by 何家明's avatar 何家明

移除无意义代码

parent 93e23eba
......@@ -188,12 +188,6 @@ class McpClient:
final_text.append(chat_completion_message.content) if chat_completion_message.content else None
return "\n".join(final_text)
async def handle_query(self, param: QueryParam):
try:
return await self.process_query(param)
except Exception as e:
logger.exception(e)
async def cleanup(self):
"""Clean up resources."""
await self.exit_stack.aclose()
......@@ -207,7 +201,7 @@ async def user_query(param: QueryParam):
if not client.connected:
await client.connect_to_server()
await client.read_mcp()
result = await client.handle_query(param)
result = await client.process_query(param)
logger.info(f"Final return: {result}")
return result
except Exception as e:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment