Summary
On the Kimi For Coding plan (OpenAI-compatible Chat Completions, https://api.kimi.com/coding/v1), the K3-family models (k3, k3-256k) intermittently omit optional parameters from emitted tool calls — the assistant’s narration explicitly states the values, but the delivered arguments JSON lacks them. kimi-for-coding (K2.8) on the same endpoint never does this, and non-Kimi providers never do. On k3-256k the failure looks close to deterministic for the read tool’s offset/limit.
This is not the faux-text-tool-call issue reported elsewhere for K2.6/K3, and not the duplicate tool_use.id Anthropic-endpoint bug: the tool calls arrive well-formed and structured — they are simply missing optional fields.
Environment
- API: Kimi For Coding plan,
api.kimi.com/coding/v1(OpenAI-compatible) - Models affected:
k3(intermittent),k3-256k(near-deterministic forread) - Models unaffected:
kimi-for-coding(K2.8), same provider/endpoint - Client: OpenCode v2.0.26 (macOS arm64), October 2026 — but see “ruled out”: the client faithfully records and executes whatever arrives
Evidence (captured from the client’s session DB = what the API actually delivered)
- Five
readcalls onk3-256kwhere the assistant stated it was requesting e.g.offset: 100, limit: 50— recorded input every time:{"path": "..."}only. The tool then returned the whole file. - Same session, same model:
grep {"limit": 2, ...}andglob {"limit": 3, ...}— optional params survived. So the loss is intermittent/per-call, not a blanket strip. (Later use suggests other tools are affected intermittently too.) - Mixed-model session:
kimi-for-codingemitted 8readcalls withoffset/limit— all arrived correctly (one correctly errored “offset out of range”, proving the value was transported and validated). After switching the same session tok3, itsreadcalls suddenly included the params too — consistent with in-context imitation, i.e. the failure happens in cold contexts without examples. - Control experiment: identical requests re-sent with explicit
"strict": falseset on every tool definition → params still dropped. This rules out strict-mode schema normalization (cf. the opposite-direction sibling of this bug, where models turn optional fields into required ones).
Ruled out
- Client tool plumbing: other providers work on the same client build; K2.8 works on the same provider, same endpoint, same request shape.
- Schema generation: the client’s generated JSON Schemas are correct (verified against source; optional fields correctly absent from
required). - Strict-mode normalization: explicit
strict: falsechanges nothing. - Transport/adapter: identical adapter serves K2.8 fine.
Minimal reproduction
- Fresh session, model
k3-256k, client OpenCode v2.0.26 (macOS arm64) — the version this was reproduced on; any agentic client should show it. - Ask the agent to read lines 100–150 of a file (forces
offset/limit). - Observe the tool call as received/executed: contains only
path; the whole file is returned; no error. - Repeat with
kimi-for-coding(K2.8):offset/limitpresent and honored.
Impact
Any agentic workflow relying on optional tool arguments silently malfunctions: file pagination (read offset/limit) returns whole files instead of windows — worse, the model believes it paged correctly, so it proceeds on wrong data.
Workaround (observed, unofficial)
If a session’s first tool calls are made with a non-affected model (kimi-for-coding/K2.8) and the session then switches to k3, the K3 calls include the optional arguments — presumably because it imitates the in-context examples of correct tool calls. Starting a session on K2.8 and switching to K3 therefore has a good chance of avoiding the bug.
Questions
- Is this a known issue with K3-family tool calling?
- Is
api.kimi.com/coding/v1(Kimi For Coding plan) covered by this forum, or is there a dedicated channel for coding-plan API bugs? - Any documented workaround (a request parameter, a different endpoint, a model snapshot pin)?