Roo Code
553ff2b88b
fix: add mergeToolResultText for Mistral/Devstral models on OpenRouter
...
Fixes the "Unexpected role user after role tool" and empty response errors
for mistralai/devstral-2512 on OpenRouter by:
1. Extending model detection to also match "devstral" in the model ID
2. Adding mergeToolResultText: true so text content after tool results
is merged into the last tool message instead of creating a separate
user message
Closes #10618
2026-02-20 19:04:14 +00:00
Daniel
6cfa82f571
Revert to pre-AI-SDK state (January 29, 2026) ( #11462 )
...
Revert to pre-AI-SDK state (commit 67e568f6b )
This commit reverts the codebase to the state before AI SDK migration work began.
Target commit: 67e568f6b - refactor: replace fetch_instructions with skill tool and built-in skills (#10913 )
Date: January 29, 2026
This removes approximately 152 commits of AI SDK migration work.
A follow-up PR will add back bug fixes and features that are unrelated to AI SDK.
Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-13 16:45:18 -05:00
Hannes Rudolph
b4d9f92b4d
Revert "Fix provider 400s: strip reasoning_details from messages, $ref from tool schemas" ( #11453 )
2026-02-12 19:51:21 -07:00
Hannes Rudolph
3965cd9743
fix: stabilize token/cache accounting across providers and routed Roo metadata ( #11448 )
2026-02-12 16:10:43 -07:00
0xMink
9e46d3e10c
Fix provider 400s: strip reasoning_details from messages, $ref from tool schemas ( #11431 )
...
Co-authored-by: daniel-lxs <ricciodaniel98@gmail.com>
2026-02-12 12:00:52 -05:00
Hannes Rudolph
897c372d2d
refactor: unify cache control with centralized breakpoints and universal provider options ( #11426 )
2026-02-12 00:21:25 -07:00
Daniel
e6f0e79c38
feat: implement ModelMessage storage layer with AI SDK response messages ( #11409 )
...
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-02-11 13:58:39 -05:00
Matt Rubens
dcb33c47ad
Revert "feat: wire RooMessage storage into Task.ts and all providers" ( #11394 )
2026-02-10 23:57:42 -05:00
Daniel
a7ba3b5af5
feat: wire RooMessage storage into Task.ts and all providers ( #11386 )
2026-02-10 21:25:48 -07:00
Daniel
5773af8ddd
feat: Refactor OpenRouter provider to use Vercel AI SDK ( #10778 )
...
Co-authored-by: Hannes Rudolph <hrudolph@gmail.com>
2026-02-09 20:50:33 -07:00
Hannes Rudolph
be0e8c2665
chore: clean up XML legacy code and native-only comments ( #10900 )
2026-01-22 15:56:11 -05:00
Hannes Rudolph
8de9337e63
chore: remove XML tool calling support ( #10841 )
...
Co-authored-by: daniel-lxs <ricciodaniel98@gmail.com>
Co-authored-by: Matt Rubens <mrubens@users.noreply.github.com>
2026-01-20 20:25:08 -05:00
Daniel
ddac338fdd
fix: Gemini thought signature validation errors ( #10694 )
...
Co-authored-by: Roo Code <roomote@roocode.com>
2026-01-15 23:25:42 -05:00
Daniel
f439496147
fix: correct Gemini 3 thought signature injection format via OpenRouter ( #10640 )
2026-01-12 17:05:00 -05:00
Chris Estreich
3171ffc809
Move more types to @roo-code/types (for the cli) ( #10583 )
2026-01-09 11:59:06 -08:00
Hannes Rudolph
6ba793137d
Revert "feat: enable mergeToolResultText for all OpenAI-compatible providers ( #10299 )" ( #10381 )
2025-12-29 16:07:24 -07:00
roomote[bot]
a07d28c7e6
feat: remove OpenRouter Transforms feature ( #10341 )
...
- Remove openRouterUseMiddleOutTransform checkbox from settings UI
- Remove openRouterUseMiddleOutTransform from TypeScript types
- Remove transforms parameter logic from OpenRouter handler
- Remove setting from EVALS_SETTINGS
- Remove translation keys from all locale files (18 locales)
Co-authored-by: Roo Code <roomote@roocode.com>
2025-12-25 09:53:48 -08:00
Hannes Rudolph
53e1ff0058
fix: preserve reasoning_details shape to prevent malformed responses ( #10313 )
2025-12-23 14:58:35 -07:00
Hannes Rudolph
ded6486a46
feat: enable mergeToolResultText for all OpenAI-compatible providers ( #10299 )
2025-12-23 14:19:33 -07:00
Daniel
3e0d9c65e8
feat: lock task tool protocol for consistent task resumption ( #10192 )
...
Co-authored-by: Roo Code <roomote@roocode.com>
2025-12-18 11:54:26 -08:00
Hannes Rudolph
06c5c7f980
feat: update OpenAI and Gemini tool preferences ( #10170 )
2025-12-17 19:46:33 -08:00
Daniel
a7b192adca
fix: normalize tool call IDs for cross-provider compatibility via OpenRouter ( #10102 )
2025-12-16 09:34:35 -08:00
John Richmond
a80a74aa02
Capture more of OpenRouter's provider specific error details ( #10073 )
...
* Capture more of OpenRouter's provider specific error details
* Actually match the openrouter structure
2025-12-14 13:28:32 -08:00
Hannes Rudolph
e4b9568dc9
feat(openrouter): add improvements to openrouter provider ( #10082 )
2025-12-14 12:29:34 -07:00
Daniel
23a214c519
fix: extract raw error message from OpenRouter metadata ( #10039 )
...
OpenRouter wraps upstream provider errors in a generic message but includes
the actual error in metadata.raw. This change:
- Adds OpenRouterErrorResponse interface for proper typing
- Creates handleStreamingError() helper for DRY error handling
- Extracts metadata.raw for actionable error messages in PostHog
- Includes nested error structure so getErrorMessage() can extract raw message
Before: PostHog receives '400 Provider returned error' (generic)
After: PostHog receives 'Model xyz not found' (actionable)
This enables proper error tracking and debugging via PostHog telemetry.
2025-12-12 10:42:36 -08:00
Daniel
fda020a418
fix: filter out 429 rate limit errors from API error telemetry ( #9987 )
...
Co-authored-by: Roo Code <roomote@roocode.com>
Co-authored-by: cte <cestreich@gmail.com>
2025-12-10 11:32:00 -08:00
Daniel
24eb6ae984
feat: add API error telemetry to OpenRouter provider ( #9953 )
...
Co-authored-by: Roo Code <roomote@roocode.com>
2025-12-09 16:30:29 -08:00
Daniel
88a0bed27f
fix: process finish_reason to emit tool_call_end events ( #9927 )
2025-12-08 13:27:55 -08:00
Matt Rubens
b9e2fd16b7
Revert "fix: sanitize reasoning_details IDs to remove invalid characters" ( #9846 )
2025-12-04 20:16:58 -05:00
Daniel
ae655c5d29
fix: sanitize reasoning_details IDs to remove invalid characters ( #9839 )
2025-12-04 15:53:10 -05:00
Matt Rubens
b31e755739
Fix openrouter tool calls ( #9642 )
2025-11-26 22:29:49 -05:00
Matt Rubens
339a869ea9
Add fine grained tool streaming for OpenRouter Anthropic ( #9629 )
2025-11-26 18:02:16 -05:00
Daniel
05f35735f0
feat: enable multiple native tool calls per turn with failure guardrails ( #9273 )
2025-11-25 20:21:13 -05:00
Matt Rubens
e4847ed8d9
Add support for images api ( #9587 )
2025-11-25 14:18:14 -05:00
Daniel
0327f12751
feat: implement streaming for native tool calls ( #9542 )
2025-11-24 23:12:39 -05:00
Matt Rubens
a8b366f3dd
Add Roo Code Cloud as an imagegen provider ( #9528 )
2025-11-24 15:11:35 -05:00
Daniel
b531075626
fix: support reasoning_details format for Gemini 3 models ( #9506 )
2025-11-24 00:47:25 -05:00
Daniel
a65e7807b1
fix: add fallback to yield tool calls regardless of finish_reason ( #9476 )
2025-11-21 16:04:38 -05:00
Daniel
5e6e601b0a
Add native tool call support ( #9159 )
...
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-11-13 12:48:35 -05:00
roomote[bot]
2abdad6d55
fix: respect custom OpenRouter URL for all API operations ( #8951 )
...
Co-authored-by: Roo Code <roomote@roocode.com>
2025-11-07 10:35:12 -05:00
roomote[bot]
65146b1b12
fix: add error transform to cryptic openAI SDK errors when API key is invalid ( #7586 )
...
Co-authored-by: Roo Code <roomote@roocode.com>
Co-authored-by: Daniel Riccio <ricciodaniel98@gmail.com>
2025-09-04 23:12:28 -04:00
roomote[bot]
b22a618ee2
feat: add optional input image parameter to image generation tool ( #7525 )
...
Co-authored-by: Roo Code <roomote@roocode.com>
Co-authored-by: Daniel Riccio <ricciodaniel98@gmail.com>
2025-08-29 11:08:21 -04:00
Daniel
2092fb1a50
feat: add image generation tool with OpenRouter integration ( #7474 )
...
Co-authored-by: Matt Rubens <mrubens@users.noreply.github.com>
Co-authored-by: cte <cestreich@gmail.com>
2025-08-28 01:57:48 -04:00
Christiaan Arnoldus
1a9aa13bd2
Use upstream_inference_cost for OpenRouter BYOK cost calculation and show cached token count ( #5145 )
...
Improve OpenRouter cache calculation and show cached tokens
2025-06-26 10:18:49 -04:00
Daniel
f18cf3d7ea
feat: add Gemini 2.5 models (Pro, Flash and Flash Lite) ( #4798 )
2025-06-17 16:36:37 -04:00
Christiaan Arnoldus
11668af83d
Fix OpenRouter cost calculation with BYOK ( #4543 )
...
Currently, when you use OpenRouter with your own key for the underlying service, the costs shown by Roo Code are way off what it actually costs.
With bring your own key, OpenRouter charges 5% of what it normally would (see https://openrouter.ai/docs/use-cases/byok )
so we have to multiply the reported cost by 20 to get an estimate of what it actually costs.
Co-authored-by: Johan Otten <drakonen@drakonen.com>
Co-authored-by: Eamon Nerbonne <eamon@nerbonne.org>
2025-06-11 23:19:24 -04:00
Daniel
3b45d86df7
Add gemini pro 06 05 ( #4386 )
...
* feat: add gemini-2.5-pro-preview-06-05 to Gemini and Vertex providers and UI, identical to 05-06
* feat: add thinking variant for gemini-2.5-pro-preview-06-05
* feat: add gemini-2.5-pro-preview-06-05 support to OpenRouter
* fix: update gemini-2.5-pro-preview model references in OpenRouter
* fix: tests
* feat: enhance reasoning handling in Gemini and Vertex handlers
* feat: add google/gemini-2.5-pro-preview to required reasoning budget models
* fix: refactor thinkingConfig assignment for consistency in Gemini and Vertex handlers
* Fix Gemini reasoning
* Fix tsc error
* Fix tsc error
* Hack to exclude thinking tokens by default
* feat: add global region to VERTEX_REGIONS
---------
Co-authored-by: Shariq Riaz <ishariqriaz@gmail.com>
Co-authored-by: cte <cestreich@gmail.com>
2025-06-05 17:49:12 -04:00
Chris Estreich
9e3b0fd870
Move provider data into @roo-code/types ( #4153 )
2025-05-30 14:54:48 -07:00
Chris Estreich
77a5b6c06d
Fix reasoning budget for Gemini 2.5 Flash on OpenRouter ( #3945 )
...
Co-authored-by: Matt Rubens <mrubens@users.noreply.github.com>
2025-05-24 19:46:42 -04:00
slytechnical
1791bb9053
Ability to refresh LiteLLM models list (take 2) ( #3852 )
...
* Litellm models can now be refreshed
* Fix no-case-declarations lint issue and put back missing autoCondenseContextPercent webviewMessageHandler case
* Add tests for litellm config changes
* replace hardcoded keys with constants
2025-05-23 16:19:40 -05:00