Home

Awesome

Sample Apps for AWS Generative AI CDK Constructs

This repo provides samples to demonstrate how to build your own Generative AI solutions using AWS Generative AI CDK Constructs.

Getting started

Use CaseDescriptionTypeLanguage
Document ExplorerThis sample provides an end-to-end experience that allows a user to ingest documents into a knowledge base, then summarize and ask questions against those documents.Backend + FrontendTypeScript for Backend, Python for Frontend (Streamlit)
Content GenerationThis sample provides an end-to-end experience that allows a user to generate images from text using Amazon titan-image-generator-v1 or stability stable-diffusion-xl model.Backend + FrontendTypeScript for Backend, Python for Frontend (Streamlit)
Image DescriptionThis sample provides an end-to-end experience that allows a user to generate descriptive text for uploaded images.Backend + FrontendTypeScript for Backend, Python for Frontend (Streamlit)
SageMaker JumpStart modelThis sample provides a sample application which deploys a SageMaker real-time endpoint hosting a Llama 2 foundation model developed by Meta from Amazon JumpStart, and an AWS Lambda function to run inference requests against that endpoint.BackendTypeScript
SageMaker Hugging Face modelThis sample provides a sample application which deploys a SageMaker real-time endpoint hosting a model (Mistral 7B) from Hugging Face, and an AWS Lambda function to run inference requests against that endpoint.BackendTypeScript
SageMaker Hugging Face model on AWS Inferentia2This sample provides a sample application which deploys a SageMaker real-time endpoint hosting a model (Zephyr 7B) from Hugging Face, and an AWS Lambda function to run inference requests against that endpoint. This sample uses Inferentia 2 as the hardware accelerator.BackendTypeScript
SageMaker custom endpointThis sample provides a sample application which deploys a SageMaker real-time endpoint hosting a model with artifacts stored in an Amazon Simple Storage Service (S3) bucket, and an AWS Lambda function to run inference requests against that endpoint. This sample uses Inferentia2 as the hardware accelerator.BackendTypeScript
SageMaker multimodal custom endpointThis sample provides a sample application which deploys a SageMaker real-time endpoint hosting llava-1.5-7b, with artifacts stored in an Amazon Simple Storage Service (S3) bucket, a custom inference script, and an AWS Lambda function to run inference requests against that endpoint.BackendTypeScript
SageMaker image to video endpointThis sample provides a sample application which deploys a SageMaker async endpoint hosting stable-video-diffusion-img2vid-xt-1-1, with artifacts stored in an Amazon Simple Storage Service (S3) bucket, a custom inference script, and an AWS Lambda function to run inference requests against that endpoint.BackendTypeScript
LLM on SageMaker in GovCloud PDTThis sample provides a sample application which deploys a SageMaker real-time endpoint hosting Falcon-40b on GovCloud PDT.BackendTypeScript
Amazon Bedrock AgentsThis sample provides a sample application which deploys an Amazon Bedrock Agent and Knowledge Base backed by an OpenSearch Serverless Collection and documents in S3. It demonstrates how to use the Amazon Bedrock CDK construct.BackendTypeScript
Amazon Bedrock Agent with Web CrawlerThis sample provides a sample application which deploys an Amazon Bedrock Agent and an Action Group using the Web Crawler construct to give internet access to the agent.BackendTypeScript
Python SamplesThis project showcases the utilization of the 'generative-ai-cdk-constructs' package from the Python Package Index (PyPI).BackendPython
.NET SamplesThis project showcases the utilization of the 'Cdklabs.GenerativeAiCdkConstructs' package from nuget library.Backend.NET
Contract Compliance AnalysisThis project automates the analysis of contracts by splitting them into clauses, determining clause types, evaluating compliance against a customer's legal guidelines, and assessing overall contract risk based on the number of compliant clauses. This is achieved through a workflow that leverages Large Language Models via Amazon Bedrock.Backend + FrontendPython for Backend, TypeScript (React) for Frontend
Text To SQLThe "Text To SQL" generative AI sample application solution enables users to interact with databases through natural language queries, eliminating the need for extensive SQL knowledge. This application leverages the powerful Anthropic Claude 3 model, hosted on Amazon Bedrock, to translate natural language queries into executable SQL statements seamlessly.Backend + FrontendPython for Backend, TypeScript (React) for Frontend
LlamaIndex Basic DataLoaderThe "LlamaIndex Basic Data Loader" generative AI sample application solution demonstrates the LlamaIndexDataLoader from the Generative AI CDK Constructs package. The default implementation uses the S3 File or Directory Loader, and can be extended for other LlamaHub Readers. The solution expects LlamaIndex Documents into an output S3 ready for downstream consumer generative AI solutions.BackendPython

Contributing

Please refer to the CONTRIBUTING document for further details on contributing to this repository.