chore: tighten malformed tool-call guard wording

This commit is contained in:
Xubin Ren
2026-06-28 19:46:59 +08:00
parent 8248d075db
commit 7dc45ff94e
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -952,7 +952,7 @@ class AgentRunner:
retry_messages = list(messages)
note = (
"The previous model response attempted to call tools, but every tool call "
"was malformed: the tool_use blocks had missing/non-string name, id, or input. "
"was malformed: the tool_use blocks had missing or non-string tool names. "
"Do not answer with a promise to use tools. Either call the required tools again "
"using valid tool names from the provided tool list and JSON object inputs, or give "
"a final answer only if no tool is required."
+1 -1
View File
@@ -1,7 +1,7 @@
"""Tests for tool hint formatting (nanobot.utils.tool_hints)."""
from nanobot.utils.tool_hints import format_tool_hints
from nanobot.providers.base import ToolCallRequest
from nanobot.utils.tool_hints import format_tool_hints
def _tc(name: str, args) -> ToolCallRequest: