-
-
Notifications
You must be signed in to change notification settings - Fork 69.4k
[Bug]: Tool calls broken with kimi-k2.5 (anthropic-messages API) after upgrade to 2026.3.7 #39839
Description
Bug type
Regression (worked before, now fails)
Summary
After upgrading from 2026.3.2 to 2026.3.7, the agent no longer executes tool calls when using kimi-k2.5 via the anthropic-messages API. Instead, tool call commands appear as plain text in the assistant's response, causing the agent to loop indefinitely.
Environment
OpenClaw version (broken): 2026.3.7
OpenClaw version (working): 2026.3.2
Model: kimicode/kimi-k2.5
API format: anthropic-messages
Base URL: https://api.kimi.com/coding/v1
OS: OpenCloudOS (Linux)
Node.js: v22.22.0 (via nvm)
Channels: Feishu (WebSocket), Telegram
Steps to Reproduce
Configure OpenClaw with kimi-k2.5 via anthropic-messages API
Upgrade from 2026.3.2 to 2026.3.7
Send any message that requires tool use (e.g. "get this tweet", "read a file")
Observe the response
Expected Behavior
Agent executes tool calls (e.g. read, exec) and returns results. Session log shows entries with "type": "toolCall".
Working session (2026.3.2) — session log shows:
json{"type": "toolCall", "name": "read", ...}
{"type": "toolCall", "name": "exec", ...}
Actual Behavior
Tool calls are not executed. Instead, the tool call appears as raw text inside the assistant message, and the agent loops indefinitely retrying.
Broken session (2026.3.7) — session log shows only:
json{"type": "text", "text": "我来帮您获取这篇推文内容。read ~/.agents/skills/agent-reach/SKILL.md 我来帮您获取这篇推文内容。read ~/.agents/skills/agent-reach/SKILL.md ..."}
The tool name and arguments are embedded as plain text rather than being parsed as structured tool calls.
Session Log Comparison
2026.3.2 (working) — assistant content types:
type: toolCall name: read
type: toolCall name: exec
type: toolCall name: exec
...
2026.3.7 (broken) — assistant content types:
type: text (tool calls embedded as plain text, never executed)
Impact
Any tool-dependent task causes an infinite loop
The agent keeps retrying the same tool call in plain text
This affects all channels (Feishu, Telegram)
Workaround: downgrade to 2026.3.2
Additional Notes
Other models (e.g. claude-opus-4-6 via native Anthropic API) are not yet tested but may not be affected
The issue appeared immediately after upgrade with no config changes
kimi-k2.5 uses anthropic-messages API format (OpenAI-compatible wrapper)
The regression is reproducible and consistent across new sessions
Steps to reproduce
Repro: Install 2026.3.7 → set kimi-k2.5 (anthropic-messages) → send "Read ~/.agents/skills/agent-reach/SKILL.md" → tool appears as text, no execution, agent loops; 2026.3.2 same message runs tool and shows toolCall.
Expected behavior
Expected: The agent parses the model’s tool call, runs the tool (e.g. read / exec), returns the result to the model, and replies to the user without looping. Session log contains "type": "toolCall" entries. (Same as 2026.3.2 with kimi-k2.5 + anthropic-messages.)
Actual behavior
Actual: Tool calls are not executed. They appear as raw text in the assistant message (e.g. “read ~/.agents/skills/agent-reach/SKILL.md”), the agent loops repeating the same text, and the user never sees file content or command output. Session log has only "type": "text" and no "type": "toolCall". No user-visible error message or crash; the failure is the lack of tool execution and the infinite retry loop.
OpenClaw version
2026.3.7
Operating system
OS and version: OpenCloudOS 9.4 (Linux, platform:oc9)
Install method
No response
Logs, screenshots, and evidence
Impact and severity
No response
Additional information
No response