avsolatorio commited on
Commit
b48eaee
·
1 Parent(s): 37530e6

Improve render

Browse files

Signed-off-by: Aivin V. Solatorio <[email protected]>

Files changed (1) hide show
  1. mcp_remote_client.py +3 -3
mcp_remote_client.py CHANGED
@@ -84,7 +84,7 @@ class MCPClientWrapper:
84
  env={"PYTHONIOENCODING": "utf-8", "PYTHONUNBUFFERED": "1"},
85
  )
86
 
87
- # Launch MCP subprocess and bind streams on the *current* running loop
88
  stdio_transport = await self.exit_stack.enter_async_context(
89
  stdio_client(server_params)
90
  )
@@ -204,7 +204,7 @@ class MCPClientWrapper:
204
  "role": "assistant",
205
  "content": f"I'll use the {tool_name} tool to help answer your question.",
206
  "metadata": {
207
- "title": f"Using tool: {tool_name}",
208
  "log": f"Parameters: {json.dumps(tool_args, ensure_ascii=True)}",
209
  "status": "pending",
210
  "id": f"tool_call_{tool_name}",
@@ -241,7 +241,7 @@ class MCPClientWrapper:
241
  "role": "assistant",
242
  "content": "Here are the results from the tool:",
243
  "metadata": {
244
- "title": f"Tool Result for {tool_name}",
245
  "status": "done",
246
  "id": f"result_{tool_name}",
247
  },
 
84
  env={"PYTHONIOENCODING": "utf-8", "PYTHONUNBUFFERED": "1"},
85
  )
86
 
87
+ # Launch MCP subprocess and bind streams on the current running loop
88
  stdio_transport = await self.exit_stack.enter_async_context(
89
  stdio_client(server_params)
90
  )
 
204
  "role": "assistant",
205
  "content": f"I'll use the {tool_name} tool to help answer your question.",
206
  "metadata": {
207
+ "title": f"Using tool: {tool_name.replace('avsolatorio_test_data_mcp_server', '')}",
208
  "log": f"Parameters: {json.dumps(tool_args, ensure_ascii=True)}",
209
  "status": "pending",
210
  "id": f"tool_call_{tool_name}",
 
241
  "role": "assistant",
242
  "content": "Here are the results from the tool:",
243
  "metadata": {
244
+ "title": f"Tool Result for {tool_name.replace('avsolatorio_test_data_mcp_server', '')}",
245
  "status": "done",
246
  "id": f"result_{tool_name}",
247
  },