Skip to content

Conversation

@hannesrudolph
Copy link
Collaborator

@hannesrudolph hannesrudolph commented Dec 14, 2025

Claude Code Provider Native Tool Calling

Implement Native Tool Calling in the Claude Code provider.

@dosubot dosubot bot added size:XXL This PR changes 1000+ lines, ignoring generated files. bug Something isn't working labels Dec 14, 2025
@hannesrudolph hannesrudolph added the Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. label Dec 14, 2025
@roomote
Copy link
Contributor

roomote bot commented Dec 14, 2025

Oroocle Clock   See task on Roo Cloud

Re-review completed for commit range 1e5ae81..095daee. No new issues in the latest commit; 1 previously-flagged item remains.

  • Fix normalizeClaudeCodeModelId() to avoid using the in operator for model validation (it can match inherited keys like toString).
  • When handling roocode://settings... docs links, pass values.section="providers" so the CTA lands on the right Settings section.
  • Avoid in operator when validating Claude Code model IDs in the handler (use an own-property check for claudeCodeModels).
  • Ensure Claude Code thinking_complete events persist the signature reliably for interleaved-thinking tool continuations (prefer emitting a thinking_complete stream chunk).
  • Use own-property check for model validation in completePrompt() too (avoid in operator).
  • Update filterNonAnthropicBlocks() docstring in streaming client to match current behavior (conversion removed).
Previous reviews

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

@JonasPammer
Copy link

It seems like an implementation of #4799.
To get this accepted despite the fear of the grey area, I'd suggest creating a new provider and leaving the existing Claude Code alone.

This way - if it breaks and if Anthopic never creates a client ID marketplace to fix it, at least there's still Claude Code Wrapper.
Also, the Claude Code CLI situation with the new Opus may be resolved with future PRs.

I know what you are referring to with the current PR title (Kilo-Org/kilocode#3747 (comment)), but since it rewrites or adds the entire thing, it is very misleading

@hannesrudolph
Copy link
Collaborator Author

It seems like an implementation of #4799.

To get this accepted despite the fear of the grey area, I'd suggest creating a new provider and leaving the existing Claude Code alone.

This way - if it breaks and if Anthopic never creates a client ID marketplace to fix it, at least there's still Claude Code Wrapper.

Also, the Claude Code CLI situation with the new Opus may be resolved with future PRs.

I know what you are referring to with the current PR title (Kilo-Org/kilocode#3747 (comment)), but since it rewrites or adds the entire thing, it is very misleading

I hear you but existing implementation is broken and does not support native tool calling. We are migrating to native tool calling, and the current implementation cannot be salvaged in its present state. The alternative is to remove the integration entirely.

@JonasPammer
Copy link

JonasPammer commented Dec 14, 2025

oh sorry, i now just realize that you are a Roo Administrator and the person that has responded to the Discord Community Chats about this (for others reference, "Claude Code Opus 4.5 Unexpected API Response", claude code provider with existing claude code mcp ). That's awesome. I was just in fear that this will not get merged.

The alternative is to remove the integration entirely.

Please do not remove Claude Code (or i.e. Claude Max Subscription Usability, in this perspective) Integration, it's the only cost-reasoning way to use make heavy use of Claude.

Edit: Also found your sneak peek :) https://www.reddit.com/r/RooCode/comments/1pm40ro/roo_built_a_new_claude_code_integration_for_roo/

@hannesrudolph
Copy link
Collaborator Author

:) this is going to increase the stability and feature. No regression.

@JonasPammer
Copy link

Well, yes it works (except the prompt enhancer, but that's a me problem i think). Clever find out of the system prompt needed so the API reuqest doesnt get blocked with "you must be Claude Code" or similiar.

Guess I'll be using this branch this week at work to dive into benefits of Roo again, may report back if major things didn't work.

local tests (yes i know it's just selfaware-introspecting questions which aren't helpful or trustful, but yeah):

image

roo_task_dec-14-2025_8-49-01-pm.md
roo_task_dec-14-2025_8-56-27-pm xml.md
roo_task_dec-14-2025_8-58-58-pm question about thinking tokens low effort 16k.md
roo_task_dec-14-2025_8-58-20-pm question about thinking tokens high effort 64k.md
roo_task_dec-14-2025_8-57-18-pm question about thinking tokens none no thoughts.md

i guess high reasoning is the same as typing "ultrathink" in the claude code cli (though i thought it made it 32k) :).

one mention: when this get merged, it should also have code to convert old selection values (with dates) into one of the new 3 real options.

@hannesrudolph
Copy link
Collaborator Author

hannesrudolph commented Dec 14, 2025

@JonasPammer Good catch on the prompt enhancement, likely applies to the context condensing as well! Will fix that now.

one mention: when this get merged, it should also have code to convert old selection values (with dates) into one of the new 3 real options.

Fixed!

@hannesrudolph hannesrudolph marked this pull request as draft December 15, 2025 23:37
@hannesrudolph hannesrudolph moved this from Triage to PR [Draft / In Progress] in Roo Code Roadmap Dec 15, 2025
@hannesrudolph hannesrudolph added PR - Draft / In Progress and removed Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. labels Dec 15, 2025
@JonasPammer
Copy link

today at work with my max ^20 account it worked without errors too. i even implemented mcpm.sh to centralize my mcp's and roo could still access all flawlessly, cmd and sse mode.

Except for when I ask it to use/access Roo's Codebase Indexing, Unknown API Error ^10. Could also be a me problem or thus unrelated as not dove deeper (using free auggie mcp beta instead).
image

@hannesrudolph
Copy link
Collaborator Author

hannesrudolph commented Dec 16, 2025

today at work with my max ^20 account it worked without errors too. i even implemented mcpm.sh to centralize my mcp's and roo could still access all flawlessly, cmd and sse mode.

Except for when I ask it to use/access Roo's Codebase Indexing, Unknown API Error ^10. Could also be a me problem or thus unrelated as not dove deeper (using free auggie mcp beta instead).

image

Someone else reported getting banned after using it all day.

The problem is not with the codebase indexing. If you want Roo to access it say "use the codebase_search tool with "red buttons" and it should search for buttons.

There is a fix coming for the MCP tool names. Should be merged.

What was the error detail when you hover over the api error and click the i icon?

@JonasPammer
Copy link

JonasPammer commented Dec 16, 2025

What was the error detail when you hover over the api error and click the i icon?

Oh, sorry, my fault - "Not authenticated with Claude Code. Please sign in using the Claude Code OAuth flow." (The Settings showed Sign In Button properly)
It's actually working x-x
image

Someone else reported getting banned after using it all day.

Still hope Roo doesn't completely ditch the CLI option. Or, at least, that if someone (even i'll try, even though never vscoded extension - good chance to get in) comes up with a proper rehaul/fix PR re-introducing that it would still be accepted.

@hannesrudolph
Copy link
Collaborator Author

What was the error detail when you hover over the api error and click the i icon?

Oh, sorry, my fault - "Not authenticated with Claude Code. Please sign in using the Claude Code OAuth flow." (The Settings showed Sign In Button properly)

It's actually working x-x

image

Someone else reported getting banned after using it all day.

Still hope Roo doesn't completely ditch the CLI option. Or, at least, that if someone (even i'll try, even though never vscoded extension - good chance to get in) comes up with a proper rehaul/fix PR re-introducing that it would still be accepted.

The CLI option is a subpar experience. It will not like be preserved as we are migrating to native tool calling.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working Enhancement New feature or request lgtm This PR has been approved by a maintainer PR - Needs Preliminary Review size:XXL This PR changes 1000+ lines, ignoring generated files.

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

6 participants