Skip to content
This repository was archived by the owner on May 15, 2026. It is now read-only.

fix: add preserveReasoning flag to Kimi and MiniMax reasoning models - #9907

Closed
ghost wants to merge 2 commits into
mainfrom
fix/bedrock-kimi-minimax-reasoning
Closed

fix: add preserveReasoning flag to Kimi and MiniMax reasoning models#9907
ghost wants to merge 2 commits into
mainfrom
fix/bedrock-kimi-minimax-reasoning

Conversation

@ghost

@ghost ghost commented Dec 8, 2025

Copy link
Copy Markdown

This PR attempts to address Issue #9902 by adding the preserveReasoning: true flag to the Kimi and MiniMax models.

Context

As reported by @jbearak, the Kimi and MiniMax models are reasoning models that output thinking traces. Without the preserveReasoning flag, Roo does not properly recognize task completion for these models.

Changes

  • Added preserveReasoning: true to moonshot.kimi-k2-thinking model configuration
  • Added preserveReasoning: true to minimax.minimax-m2 model configuration

This ensures that:

  1. Reasoning traces are preserved in the output
  2. Roo correctly recognizes task completion (shows "Task Completed" in green)
  3. Tool calls within reasoning traces are properly handled

Testing

  • ✅ Build successful (npm run build in packages/types)
  • ✅ All tests passing (npx vitest run in packages/types)
  • ✅ Linting checks passed
  • ✅ Type checks passed

Related Issues

Addresses feedback in #9902

Feedback and guidance are welcome!

- Add moonshot.kimi-k2-thinking with 32K max tokens and 256K context
- Add minimax.minimax-m2 with 16K max tokens and 230K context
- Add qwen.qwen3-next-80b-a3b with 8K max tokens and 262K context
- Add qwen.qwen3-coder-480b-a35b-v1:0 with 8K max tokens and 262K context

All models configured with native tool support and appropriate pricing.

Fixes #9902
@ghost

ghost commented Dec 8, 2025

Copy link
Copy Markdown
Author

Rooviewer Clock   See task on Roo Cloud

Review complete. No issues found. The changes correctly add the preserveReasoning: true flag to the Kimi K2 Thinking and MiniMax M2 models, which aligns with the existing codebase patterns and properly addresses issue #9902.

Mention @roomote in a comment to request specific changes to this pull request or fix all unresolved issues.

@hannesrudolph hannesrudolph added the Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. label Dec 8, 2025
@ghost

ghost commented Dec 8, 2025

Copy link
Copy Markdown
Author

Closing this PR as requested. The changes will be made to #9905 instead.

@ghost ghost closed this Dec 8, 2025
@github-project-automation github-project-automation Bot moved this from New to Done in Roo Code Roadmap Dec 8, 2025
@github-project-automation github-project-automation Bot moved this from Triage to Done in Roo Code Roadmap Dec 8, 2025
This pull request was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels.

Projects

No open projects
Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants