-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
Summary
Add support for AWS Bedrock as an alternative authentication method for Anthropic Claude models. This enables users who have Claude access through AWS Bedrock to use Ash without needing a separate Anthropic API key.
Motivation
- Users with AWS Bedrock access can leverage their existing AWS credentials
- Organizations that provision Claude through AWS can use Ash without separate API key management
- Aligns with how other tools (like Claude Code) support Bedrock authentication
Proposed Configuration
[anthropic]
auth_method = "bedrock" # "api_key" (default) or "bedrock"
bedrock_region = "us-west-2" # Required when using Bedrock
[models.default]
provider = "anthropic"
model = "claude-sonnet-4-20250514" # Standard model names workImplementation Details
- New optional dependency:
anthropic[bedrock]for Bedrock client support - Config changes: Add
auth_methodandbedrock_regiontoProviderConfig - Model translation: Map standard Anthropic model names to Bedrock inference profile IDs (e.g.,
claude-sonnet-4-20250514→us.anthropic.claude-sonnet-4-20250514-v1:0) - Authentication flow: When
auth_method = "bedrock", useAsyncAnthropicBedrockclient with AWS credentials from environment
Installation
pip install 'ash[bedrock]'Users would configure AWS credentials via standard methods (env vars, ~/.aws/credentials, IAM roles).
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels