Custom Model Configurations
AWS Bedrock

AWS Bedrock Integration with Bwat

This guide provides step-by-step instructions for configuring AWS Bedrock with the Bwat VS Code extension using secure credential authentication. Learn how to set up your AWS environment, verify regional access, and establish a secure connection.

Key Components

  • AWS Bedrock: A managed service providing access to leading AI models (Claude, Titan, etc.) through AWS infrastructure.

  • AWS Bedrock Documentation: AWS Bedrock Docs (opens in a new tab)

  • Bwat: A VS Code extension that enhances developer productivity through AI-powered code generation and analysis.

  • Enterprise Security Focus: Designed for organizations using IAM roles, AWS SSO, and other enterprise security measures.

Step 1: Configure AWS Environment

1.1 Set Up IAM Access

Access AWS Console:

  1. Login to your AWS Management Console (opens in a new tab)
  2. Navigate to IAM:

1.2 Apply Security Policies

Attach Bedrock Policy:

Refine Permissions:

  • Include bedrock:InvokeModel and related permissions
  • For enterprises: Use Service Control Policies (SCPs) for granular access control

Step 2: Verify Bedrock Access

2.1 Select AWS Region

Choose Deployment Region:

Check Model Availability:

  • Confirm required models show "Access granted" in Bedrock console
  • Note: Some models may require Inference Profiles

2.2 Manage Marketplace Subscriptions

Subscribe to Models:

  • Access Bedrock console's model subscription section
  • Accept terms for third-party models (e.g., Anthropic)

Enterprise Consideration:

  • Coordinate with cloud team for centralized model subscriptions

Step 3: Configure Bwat Extension

3.1 Install Bwat

Get VS Code:

Add Bwat Extension:

  1. Open Extensions view (Ctrl+Shift+X)
  2. Search for Bwat and install

3.2 Set Up AWS Integration

Access Bwat Settings:

  1. Open settings (⚙️ icon)
  2. Select API Provider

Configure AWS Bedrock:

  1. Choose AWS Bedrock as provider
  2. Enter AWS credentials (Access/Secret keys)
  3. Specify AWS region (e.g., us-east-1)
  4. Select model (e.g., Claude 3 Sonnet)

Test Connection:

  1. Save settings
  2. Verify with test prompt (e.g., "Write Python code for prime number check")

Step 4: Security & Operations

Access Management:

  • Prefer temporary credentials via AWS SSO
  • Follow IAM best practices

Network Protection:

  • Consider AWS PrivateLink for secure connectivity

Monitoring:

  • Enable CloudTrail for API logging
  • Set up CloudWatch metrics/alerts

Cost Control:

  • Monitor usage via AWS Cost Explorer
  • Implement billing alerts

Implementation Summary

  1. AWS Setup: Configure IAM roles with appropriate Bedrock permissions
  2. Access Verification: Confirm regional model availability
  3. Bwat Configuration: Install extension and connect to Bedrock
  4. Security Operations: Implement monitoring and cost controls

For ongoing updates, refer to AWS Bedrock docs (opens in a new tab) and coordinate with your cloud team.