Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updated bedrock.py to handle case of deploying it over Lambda functio…
…n with attached role access. Bedrock client access was working fine when used locally but it was not working when deployed the same solution over AWS Lambda function or EC2 Instance or ECS Task, when no access credentials being passed/set as environment variables. I have made changes in this to build bedrock-runtime client directly using boto3 which uses attached Role to managed AWS service. This is more secure way to running code over AWS. Tested it with AWS Lambda function and ECS container task.
- Loading branch information