Missing support tool calls in thinking tokens for Kimi K2 Thinking #3327

Closed
opened 2026-02-16 17:39:40 -05:00 by yindo · 1 comment
Owner

Originally created by @Adictya on GitHub (Dec 5, 2025).

Description

Can't use Kimi K2 Thinking from opencode zen as it tries to make tool calls in its thinking tokens which the opencode harness doesn't parse

OpenCode version

1.0.132

Steps to reproduce

  1. Switch model to Kimi K2 Thinking
  2. Make a request that results in tool calls
  3. Find the harness stuck

Screenshot and/or share link

Image

Operating System

macOS 26.1

Terminal

Ghostty

Originally created by @Adictya on GitHub (Dec 5, 2025). ### Description Can't use Kimi K2 Thinking from opencode zen as it tries to make tool calls in its thinking tokens which the opencode harness doesn't parse ### OpenCode version 1.0.132 ### Steps to reproduce 1. Switch model to Kimi K2 Thinking 2. Make a request that results in tool calls 3. Find the harness stuck ### Screenshot and/or share link <img width="2540" height="774" alt="Image" src="https://github.com/user-attachments/assets/e3cfcb3b-2dec-454d-9f6d-0d206a65fd34" /> ### Operating System macOS 26.1 ### Terminal Ghostty
yindo added the opentuibug labels 2026-02-16 17:39:40 -05:00
yindo closed this issue 2026-02-16 17:39:40 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Dec 5, 2025):

This issue might be a duplicate of existing issues. Please check:

  • #3561: opencode zen models tool calls are not parsed correctly mid conversation
  • #3596: SSE Stream Bug: Out-of-Order thinking_delta via LiteLLM → AWS Bedrock (thinking token streaming/parsing issues)
  • #4255: OpenCode v1.0.25 Hangs Indefinitely with LM Studio + Qwen Models Due to Empty tool_calls Array (similar hanging behavior with tool calls)
  • #992: AI_APICallError: "stream=true" with structured outputs is currently not supported for reasoning models

Feel free to ignore if none of these address your specific case.

@github-actions[bot] commented on GitHub (Dec 5, 2025): This issue might be a duplicate of existing issues. Please check: - #3561: opencode zen models tool calls are not parsed correctly mid conversation - #3596: SSE Stream Bug: Out-of-Order thinking_delta via LiteLLM → AWS Bedrock (thinking token streaming/parsing issues) - #4255: OpenCode v1.0.25 Hangs Indefinitely with LM Studio + Qwen Models Due to Empty tool_calls Array (similar hanging behavior with tool calls) - #992: AI_APICallError: "stream=true" with structured outputs is currently not supported for reasoning models Feel free to ignore if none of these address your specific case.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#3327