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

Bedrock: Cross Region Inference capability #31570

Open
2 tasks
medha-hegde opened this issue Sep 26, 2024 · 2 comments
Open
2 tasks

Bedrock: Cross Region Inference capability #31570

medha-hegde opened this issue Sep 26, 2024 · 2 comments
Labels
@aws-cdk/aws-lambda Related to AWS Lambda effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. p2

Comments

@medha-hegde
Copy link

Describe the feature

The new cross-region inference profiles allow us to use the same Bedrock model in other regions by switching out the foundation model ARN with this inference profile ARN:
image

However, in the Amazon Bedrock Construct Library only allows for Foundation Models or Provisioned Models.

Can we incorprate this new cross-region inference profiles feature ASAP?

Use Case

I am invoking the Bedrock API via Step Functions tasks with this code currently:

claude_model_id = bedrock.FoundationModelIdentifier.ANTHROPIC_CLAUDE_V2_1
invoke_model = tasks.BedrockInvokeModel(
        scope,
        id + " (Invoke Model)",
        model=bedrock.FoundationModel.from_foundation_model_id(
            scope,
            "Model",
            claude_model_id,
        ),...

ideally I'd like to simply switch out the claude_model_id for the inference profile ARN.

Proposed Solution

Allow for custom ARNs instead of enforcing the bedrock.FoundationModelIdentifier class for the model IDs.

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

CDK version used

2.155.0

Environment details (OS name and version, etc.)

MacOS Ventura, M2 Chip

@medha-hegde medha-hegde added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Sep 26, 2024
@github-actions github-actions bot added the @aws-cdk/aws-lambda Related to AWS Lambda label Sep 26, 2024
@pahud
Copy link
Contributor

pahud commented Sep 26, 2024

Makes sense. We can consider to create a new static method for that. We welcome any PRs from the community.

@pahud pahud added p2 effort/medium Medium work item – several days of effort and removed needs-triage This issue or PR still needs to be triaged. labels Sep 26, 2024
@jdebuseamazon
Copy link
Contributor

#31958 adds some cross regional inference constructs that might be useful

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/aws-lambda Related to AWS Lambda effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. p2
Projects
None yet
Development

No branches or pull requests

3 participants