Skip to content

feat: add Bedrock reasoning support#142

Merged
adesinah merged 3 commits into
genkit-ai:mainfrom
adesinah:feat/reasoning
Jun 19, 2026
Merged

feat: add Bedrock reasoning support#142
adesinah merged 3 commits into
genkit-ai:mainfrom
adesinah:feat/reasoning

Conversation

@adesinah

@adesinah adesinah commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

Description

This PR adds Bedrock reasoning support. This PR requires #140 to be merged first.

Closes point 3 in #136

Type of Change

  • New feature (non-breaking change which adds functionality)
  • Documentation update

Testing

Please describe the tests that you ran to verify your changes:

  • Unit tests pass (go test ./...)
  • Integration tests pass
  • Manual testing performed
  • Examples still work

Test Configuration

  • Go version:
  • AWS Bedrock models tested:
  • Operating system:

Code Quality

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings or errors
  • I have added tests that prove my fix is effective or that my feature works

Documentation

  • Updated README.md if needed
  • Updated code comments
  • Added examples if introducing new features
  • Updated API documentation

AWS Bedrock Specific

If this change affects AWS Bedrock functionality:

  • Tested with multiple Bedrock models
  • Verified AWS credential handling
  • Checked error handling for AWS API calls
  • Validated streaming functionality (if applicable)
  • Tested tool calling features (if applicable)

Checklist

  • I have read the CONTRIBUTING.md document
  • I have signed the CLA (if required)
  • My commits follow the conventional commit format
  • I have updated the version number (if applicable)

@adesinah adesinah requested a review from xavidop as a code owner June 18, 2026 23:45
@adesinah adesinah marked this pull request as draft June 18, 2026 23:45

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request introduces document reranking support via Cohere Rerank models and adds support for Bedrock reasoning ('thinking') content, enabling features like Claude's extended thinking. It also integrates request timeouts across various model invocations and adds comprehensive live and unit tests. A critical issue was identified in the live tests where an uninitialized Bedrock instance is used to define a model, which would result in a panic; reusing the initialized plugin instance is recommended.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread bedrock_live_test.go
@xavidop

xavidop commented Jun 19, 2026

Copy link
Copy Markdown
Collaborator

can you fix the linting issues in this pr too?

@adesinah

Copy link
Copy Markdown
Contributor Author

can you fix the linting issues in this pr too?

yes, i notice that too. It will be fixed in this PR. Thanks!

@adesinah adesinah marked this pull request as ready for review June 19, 2026 13:24
@adesinah

Copy link
Copy Markdown
Contributor Author

@xavidop it's good for a review when you get a chance. thank you!

@adesinah adesinah merged commit 8dc3b57 into genkit-ai:main Jun 19, 2026
9 checks passed
github-actions Bot pushed a commit that referenced this pull request Jun 19, 2026
## [1.16.0](v1.15.0...v1.16.0) (2026-06-19)

### 🚀 Features

* add Bedrock reasoning support ([#142](#142)) ([8dc3b57](8dc3b57))
@github-actions

Copy link
Copy Markdown

🎉 This PR is included in version 1.16.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants