Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Convert Bedrock to Converse API #853

Merged
merged 11 commits into from
Nov 18, 2024
Merged

Conversation

dragonstyle
Copy link
Collaborator

This PR contains:

  • New features
  • Changes to dev-tools e.g. CI config / github tooling
  • Docs
  • Bug fixes
  • Code refactor

This PR moves the Bedrock provider to using the Amazon Converse API. The Converse API provides a single API that works across models, removing the need for per model provider customization. The API includes proper support for multimodal and tool use for most models as appropriate. See this grid for current capabilities:

https://docs.aws.amazon.com/bedrock/latest/userguide/conversation-inference-supported-models-features.html

In testing this implementation, features appear to be have parity overall, though this PR will enabled tool use for Mistral models. LLAMA model tool use for python coding continues to be limited, though other tool use appears functional.

@dragonstyle dragonstyle marked this pull request as ready for review November 15, 2024 21:42
Copy link
Collaborator

@jjallaire-aisi jjallaire-aisi left a comment

Choose a reason for hiding this comment

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

Just a couple of minor nits, looks great! (I'll let you merge after addressing stuff as appropriate). We should also add a CHANGELOG entry.

src/inspect_ai/model/_providers/util/converse_model.py Outdated Show resolved Hide resolved
src/inspect_ai/model/_providers/bedrock.py Show resolved Hide resolved
src/inspect_ai/model/_providers/bedrock.py Show resolved Hide resolved
@jjallaire-aisi jjallaire-aisi merged commit e3f45aa into main Nov 18, 2024
9 checks passed
@jjallaire jjallaire deleted the feature/bedrock-converse branch November 23, 2024 15:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants