mirror of
https://github.com/xinnan-tech/xiaozhi-esp32-server.git
synced 2026-07-28 01:53:53 +08:00
调整缩进
This commit is contained in:
@@ -1083,7 +1083,8 @@ class ConnectionHandler:
|
|||||||
|
|
||||||
# 构建工具调用的显示文本,格式如: get_weather({"location": "北京"})
|
# 构建工具调用的显示文本,格式如: get_weather({"location": "北京"})
|
||||||
tool_input = json.loads(tool_call_data.get("arguments") or "{}")
|
tool_input = json.loads(tool_call_data.get("arguments") or "{}")
|
||||||
tool_text = json.dumps([
|
tool_text = json.dumps(
|
||||||
|
[
|
||||||
{
|
{
|
||||||
"type": "tool",
|
"type": "tool",
|
||||||
"text": f"{tool_call_data['name']}({json.dumps(tool_input, ensure_ascii=False)})",
|
"text": f"{tool_call_data['name']}({json.dumps(tool_input, ensure_ascii=False)})",
|
||||||
|
|||||||
Reference in New Issue
Block a user