Skip to content

Level 101 experiments with AWS Bedrock on top of Lambda Functions.

License

Notifications You must be signed in to change notification settings

san99tiago/aws-cdk-bedrock-lambda-poc

Repository files navigation

🎨 AWS-CDK-BEDROCK-LAMBDA-POC 🎨

AWS FastAPI CDK deployment with sample Bedrock-based AI solution.

Summary/Overview 📝

  • Deployed on AWS with Infrastructure as Code on CDK-Python.
  • API developed with FastAPI.
  • AI Models on top of AWS Bedrock.
  • Unit and Integration Tests for the source code with PyTest.

AWS Architecture Diagram 🏆

The AWS infrastructure solution is deployed with CDK-Python with the resources defined on the cdk folder:


Folders Explained 📜

This repository consists of multiple folders/files, which are explained as follows:

Demo Responses 🔮


Usage ✅

Follow these steps to configure the project locally:

Enable AWS Bedrock Models

Go to AWS Console, and request access to the Bedrock models that will be used.

Clone the repository

First, clone the repository:

git clone https://github.com/san99tiago/aws-cdk-bedrock-lambda-poc
cd aws-cdk-bedrock-lambda-poc

Configure CDK

Review the step by step commands for configuring the CDK at:

Note: python dependencies for this project are managed by Poetry. Review ./pyproject.toml for details.

Note: for deploying or destroying the solution, see ("part 3") inside ./important_commands.sh.

Dependencies 💯

Software

  • Visual Studio Code
    Visual Studio Code is my main code editor for high-level programming. This is not absolutely necessary, but from my experience, it gives us a great performance and we can link it with Git and GitHub easily.

  • Python
    Python is a dynamic programming language that let us work fast, with easy and powerful integration of different software solutions.

Tools

  • CDK CLI (Toolkit)
    To work with the CDK, it is important to install the main toolkit as a NodeJs global dependency. Please refer to the official AWS Getting started with the AWS CDK

  • AWS CLI
    The AWS Command Line Interface (AWS CLI) is a unified tool to manage your AWS services. We will use it for connecting to our AWS account from the terminal (authentication and authorization towards AWS).

Special thanks 🍻

  • I am grateful to the talented individuals who have dedicated their time and effort to develop the exceptional open-source projects that have been used in the creation of this solution.

Author 🎹

Santiago Garcia Arango

As a curious DevOps Engineer, I am deeply passionate about implementing cutting-edge cloud-based solutions on AWS.
I firmly believe that today's greatest challenges must be solved by the expertise of individuals who are truly passionate about their work.

LICENSE

Copyright 2023 Santiago Garcia Arango