Skip to content

Commit 7602765

Browse files
updated python version and updated README.md
1 parent 032d85a commit 7602765

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

apigw-lambda-bedrock-nova-terraform/README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# API Gateway Integration with AWS Lambda and Amazon Bedrock Nova Micro (Terraform)
1+
# Serverless Generative AI with Amazon Bedrock Nova Micro
22

33
## Overview
44

@@ -11,6 +11,7 @@ Important: this application uses various AWS services and there are costs associ
1111
## Requirements
1212

1313
* [Create an AWS account](https://portal.aws.amazon.com/gp/aws/developer/registration/index.html) if you do not already have one and log in. The IAM user that you use must have sufficient permissions to make necessary AWS service calls and manage AWS resources.
14+
* [Enable Access To Nova Models](https://docs.aws.amazon.com/nova/latest/userguide/getting-started-console.html) and follow item 2 under the Prerequisites to request access to Amazon Nova Micro model
1415
* [AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/install-cliv2.html) installed and configured
1516
* [Git Installed](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git)
1617
* [Terraform](https://learn.hashicorp.com/tutorials/terraform/install-cli?in=terraform/aws-get-started) installed

apigw-lambda-bedrock-nova-terraform/iam.tf

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,7 @@ resource "aws_iam_role_policy" "bedrock_policy" {
3232
{
3333
Effect = "Allow"
3434
Action = [
35-
"bedrock:InvokeModel",
36-
"bedrock:ListFoundationModels"
35+
"bedrock:InvokeModel"
3736
]
3837
Resource = "*"
3938
}

apigw-lambda-bedrock-nova-terraform/lambda.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
resource "aws_lambda_layer_version" "boto3_bedrock_layer" {
22
filename = "${path.module}/lambda-layer/boto3-bedrock-layer.zip"
33
layer_name = "boto3-bedrock-layer"
4-
compatible_runtimes = ["python3.9"]
4+
compatible_runtimes = ["python3.10"]
55
}
66

77
resource "aws_lambda_function" "content_generation" {
88
filename = "${path.module}/lambda_function.zip"
99
function_name = "ContentGenerationFunction"
1010
role = aws_iam_role.lambda_role.arn
1111
handler = "bedrock_integration.lambda_handler"
12-
runtime = "python3.9"
12+
runtime = "python3.10"
1313
architectures = ["arm64"]
1414

1515
layers = [aws_lambda_layer_version.boto3_bedrock_layer.arn]

0 commit comments

Comments
 (0)