Skip to content

Conversation

@roomote
Copy link
Contributor

@roomote roomote bot commented Dec 4, 2025

This PR attempts to address Issue #9802. Feedback and guidance are welcome!

Summary

Added support for Amazon Nova 2 Lite model in the Bedrock provider, as requested in issue #9802.

Changes

  • Added amazon.nova-lite-v2:0 model definition to packages/types/src/providers/bedrock.ts
  • Configured with 300k context window and image support (matching Nova Lite v1 capabilities)
  • Set pricing slightly higher than Nova Lite v1 but still competitive with Claude Haiku 4.5
  • Enabled prompt caching and native tools support

Testing

  • ✅ Type checking passes
  • ✅ All existing tests pass
  • ✅ Linting passes

Notes

The model configuration is based on the issue description mentioning that Nova 2 Lite is comparable to Claude Haiku 4.5. The exact pricing and capabilities may need adjustment once official AWS documentation is available.

Fixes #9802


Important

Add Amazon Nova 2 Lite model to Bedrock provider with specific configuration and pricing in bedrock.ts.

  • Behavior:
    • Added amazon.nova-2-lite-v1:0 model to bedrockModels in bedrock.ts.
    • Configured with 1,000,000 context window, image support, prompt caching, and native tools.
    • Set pricing higher than Nova Lite v1, competitive with Claude Haiku 4.5.
  • Testing:
    • Type checking, existing tests, and linting all pass.

This description was created by Ellipsis for 1f53359. You can customize this summary. It will automatically update as commits are pushed.

- Added amazon.nova-lite-v2:0 model definition
- Configured with 300k context window and image support
- Set pricing comparable to Claude Haiku 4.5 as mentioned in issue
- Supports prompt caching and native tools

Fixes #9802
@roomote
Copy link
Contributor Author

roomote bot commented Dec 4, 2025

Rooviewer Clock   See task on Roo Cloud

All issues resolved. The model has been correctly configured with the right model ID, pricing, context window, and maxTokens.

  • Move nova-lite-v2 definition to be placed immediately after nova-lite-v1 for better code organization
  • Update maxTokens to 65_535 (per reviewer suggestion)
Previous reviews

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

Comment on lines 85 to 99
"amazon.nova-lite-v2:0": {
maxTokens: 5000,
contextWindow: 300_000,
supportsImages: true,
supportsPromptCache: true,
supportsNativeTools: true,
inputPrice: 0.075,
outputPrice: 0.3,
cacheWritesPrice: 0.075, // per million tokens
cacheReadsPrice: 0.01875, // per million tokens
minTokensPerCachePoint: 1,
maxCachePoints: 1,
cachableFields: ["system"],
description: "Amazon Nova 2 Lite - Comparable to Claude Haiku 4.5",
},
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The nova-lite-v2 model should be placed immediately after nova-lite-v1 (line 70) rather than after nova-micro-v1 (line 84). This maintains the logical grouping of model versions together (Pro v1, Pro latency-optimized, Lite v1, Lite v2, Micro v1) which improves code readability and makes it easier to compare related models.

Fix it with Roo Code or mention @roomote and request a fix.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@roomote
Input Price = $0.33
OutputPrice = $2.75
Cache read input tokens will be 75% less than on-demand input token price
Context Window = 1M

Copy link
Contributor Author

@roomote roomote bot Dec 5, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixaroo Clock   See task on Roo Cloud

Fixed the reported issues. All local checks passed.

View commit | Revert commit

@hannesrudolph hannesrudolph added the Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. label Dec 4, 2025
@Smartsheet-JB-Brown
Copy link
Contributor

@roomote the json block for nova lite 2 should be the following, make the changs.

"amazon.nova-lite-v2:0": {
maxTokens: 5000,
contextWindow: 1_000_000,
supportsImages: true,
supportsPromptCache: true,
supportsNativeTools: true,
inputPrice: 0.30,
outputPrice: 2.5,
cacheWritesPrice: 0,
cacheReadsPrice: 0.075,
minTokensPerCachePoint: 1,
maxCachePoints: 1,
cachableFields: ["system"],
description: "Amazon Nova 2 Lite - Comparable to Claude Haiku 4.5",
}

@roomote
Copy link
Contributor Author

roomote bot commented Dec 5, 2025

Fixaroo Clock   See task on Roo Cloud

Fixed the reported issues. All local checks passed.

View commit | Revert commit

@Smartsheet-JB-Brown
Copy link
Contributor

@ronyblum looks right to me, double check and let @hannesrudolph know please

@ronyblum
Copy link
Contributor

ronyblum commented Dec 5, 2025

@hannesrudolph LGTM following the price update and last commit!
cc @Smartsheet-JB-Brown

@jbearak
Copy link

jbearak commented Dec 8, 2025

This seems to work. However, according to the official documentation, the model ID is us.amazon.nova-2-lite-v1:0

@ronyblum
Copy link
Contributor

ronyblum commented Dec 8, 2025

@roomote Change the model id to amazon.nova-2-lite-v1:0 in place of amazon.nova-lite-v2:0

@roomote
Copy link
Contributor Author

roomote bot commented Dec 8, 2025

Fixaroo Clock   See task on Roo Cloud

Updated the model ID from amazon.nova-lite-v2:0 to amazon.nova-2-lite-v1:0 as requested. All local checks passed.

View commit | Revert commit

@ronyblum
Copy link
Contributor

ronyblum commented Dec 8, 2025

This seems to work. However, according to the official documentation, the model ID is us.amazon.nova-2-lite-v1:0

Thanks - Updated.
us. prefix is added as part of the Geo Cross region checkbox

@ronyblum
Copy link
Contributor

@Smartsheet-JB-Brown @hannesrudolph
Tested and works as expected. Ready for merge

@mrubens mrubens marked this pull request as ready for review December 14, 2025 20:11
@mrubens mrubens requested review from cte and jr as code owners December 14, 2025 20:11
@dosubot dosubot bot added size:S This PR changes 10-29 lines, ignoring generated files. Enhancement New feature or request labels Dec 14, 2025
@roomote
Copy link
Contributor Author

roomote bot commented Dec 14, 2025

Rooviewer Clock   See task on Roo Cloud

All issues have been resolved. The PR is ready for merge.

  • Model positioning (after nova-lite-v1)
  • Pricing values updated ($0.33 input, $2.75 output)
  • Model ID corrected to amazon.nova-2-lite-v1:0
  • maxTokens updated to 65_535

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

@roomote roomote bot mentioned this pull request Dec 15, 2025
mini2s added a commit to zgsm-ai/costrict that referenced this pull request Dec 16, 2025
* refactor(core): clean up unused imports and improve file handling logic

* refactor: adjust file limits and multipliers

* ux: Improvements to the new, RCC Provider centric onboarding flow (RooCodeInc#9709)

Co-authored-by: roomote[bot] <219738659+roomote[bot]@users.noreply.github.com>

* ux: Toolbar cleanup and settings consolidation (RooCodeInc#9710)

Co-authored-by: Roo Code <[email protected]>

* Update a couple provider labels (RooCodeInc#9711)

Co-authored-by: Roo Code <[email protected]>

* Release: v1.88.0 (RooCodeInc#9713)

* Remove TabContent wrapper from Modes and MCP (RooCodeInc#9712)

* fix: preserve tool_use blocks in summary for parallel tool calls (RooCodeInc#9714)

Co-authored-by: huajiwuyan <[email protected]>

* feat(chutes): detect native tool support from API supported_features (RooCodeInc#9715)

Co-authored-by: Matt Rubens <[email protected]>

* Add NTC support for Cerebras (RooCodeInc#9692)

* Add native tools support to Unbound (RooCodeInc#9699)

Co-authored-by: Roo Code <[email protected]>

* Add native tool support for vercel ai gateway (RooCodeInc#9697)

Co-authored-by: Roo Code <[email protected]>

* Default grok code fast to native tools (RooCodeInc#9717)

* Bedrock native tool calling (RooCodeInc#9698)

* Support tool calling in native ollama provider (RooCodeInc#9696)

Co-authored-by: Roo Code <[email protected]>

* feat: add native tool support for LiteLLM provider (RooCodeInc#9719)

* fix: prevent navigation buttons from wrapping on smaller screens (RooCodeInc#9721)

Co-authored-by: Roo Code <[email protected]>

* chore: add changeset for v3.35.0 (RooCodeInc#9724)

* Changeset version bump (RooCodeInc#9725)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Matt Rubens <[email protected]>

* chore: bump version to v1.89.0 (RooCodeInc#9718)

* fix: flush pending tool results before task delegation (RooCodeInc#9726)

When tools are called in parallel (e.g., update_todo_list + new_task),
the tool results accumulate in userMessageContent but aren't saved to
API history until all tools complete. When new_task triggers delegation,
the parent is disposed before these pending results are saved, causing
400 errors when the parent resumes (missing tool_result for tool_use).

This fix:
- Adds flushPendingToolResultsToHistory() method in Task.ts that saves
  pending userMessageContent to API history
- Calls this method in delegateParentAndOpenChild() before disposing the
  parent task
- Safe for both native/XML protocols and sequential/parallel execution
  (returns early if there's nothing to flush)

* Better IPC error logging (RooCodeInc#9727)

* chore: add changeset for v3.35.1 (RooCodeInc#9728)

* Changeset version bump (RooCodeInc#9729)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Matt Rubens <[email protected]>

* Pass app version to provider (RooCodeInc#9730)

* Allow models to contain default temperature (RooCodeInc#9734)

* Look for a tag in the Roo provider to default the model to native tool calling (RooCodeInc#9735)

* Assume all LiteLLM models support native tools (RooCodeInc#9736)

* chore: add changeset for v3.35.2 (RooCodeInc#9737)

* Changeset version bump (RooCodeInc#9738)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Matt Rubens <[email protected]>

* Merge remote-tracking branch 'upstream/main' into roo-to-main

* Switch to new welcome view (RooCodeInc#9741)

* web: Homepage changes (RooCodeInc#9675)

Co-authored-by: roomote[bot] <219738659+roomote[bot]@users.noreply.github.com>
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>

* Add vendor confidentiality section to the system prompt for stealth models (RooCodeInc#9742)

Co-authored-by: roomote[bot] <219738659+roomote[bot]@users.noreply.github.com>

* chore: add changeset for v3.35.3 (RooCodeInc#9743)

* Changeset version bump (RooCodeInc#9745)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Matt Rubens <[email protected]>

* Refactor: Remove line_count parameter from write_to_file tool (RooCodeInc#9667)

* fix: remove reasoning toggles for GLM-4.5 and GLM-4.6 on z.ai provider (RooCodeInc#9752)

Co-authored-by: Roo Code <[email protected]>

* fix: handle malformed native tool calls to prevent hanging (RooCodeInc#9758)

Co-authored-by: Matt Rubens <[email protected]>

* chore: add changeset for v3.35.4 (RooCodeInc#9763)

* Changeset version bump (RooCodeInc#9764)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Matt Rubens <[email protected]>

* Convert the Roo provider tools for OpenAI (RooCodeInc#9769)

* Update the evals keygen command (RooCodeInc#9754)

* feat: Add provider routing selection for OpenRouter embeddings (