MENU

Fun & Interesting

AWS Project: Build an AI-Powered Chatbot with Amazon Lex, Bedrock, S3 and RAG | AWS Tutorials

Tiny Technical Tutorials 22,763 5 months ago
Video Not Working? Fix It Now

Generative AI and chatbots are all the rage these days—whether it’s ChatGPT, Copilot, or Gemini. But you can also build your own with AWS services, and even drive it from your own data with retrieval augmented generation (RAG). Using Amazon Lex for the chatbot, Amazon Bedrock for the AI, and S3 for document storage, you get a super-smart chatbot that lets you have conversations about your data. In this hands-on tutorial, we’ll start by requesting access to two different Amazon Bedrocks models. Then we’ll set up an S3 bucket to house travel policy documents (or whatever documents you’d like). Then we set up a knowledge base in Amazon Bedrock that points to the S3 bucket. Finally, we’ll build a Lex bot to leverage all of that goodness, letting us have a conversation about travel policies (to Mars, no less!). Also be sure to stick around to the end where I’ll show you how to delete all the resources we created. 🌟***WHAT YOU NEED TO FOLLOW ALONG***🌟 • An AWS account • Access to Amazon Titan Embeddings G1 – Text Model on Bedrock • Anthropic Claude v2 Model on Bedrock • The four PDFs used in this video are zipped up and available for download here: https://drive.google.com/file/d/1kyewU4eCFnaYS3wQ7Fyv22G3ycthbfJb/view?usp=sharing • If you want to use a proper web UI for your bot, check out the instructions in this GitHub repo: https://github.com/aws-samples/aws-lex-web-ui 🌟***OTHER VIDEOS YOU MIGHT ENJOY***🌟 • Getting started with Amazon Bedrock: https://youtu.be/32D7NJK9QIk • S3 for Beginners: https://youtu.be/mDRoyPFJvlU 🌟***MY AWS COURSES***🌟 If you’re interested in getting AWS certifications, check out these full courses. They include lots of hands-on demos, quizzes and full practice exams. Use FRIENDS10 for a 10% discount! - AWS Certified Cloud Practitioner: https://academy.zerotomastery.io/a/aff_n20ghyn4/external?affcode=441520_lm7gzk-d - AWS Certified Solutions Architect Associate: https://academy.zerotomastery.io/a/aff_464yrtnn/external?affcode=441520_lm7gzk-d 🌟***TIMESTAMPS***🌟 00:00 – Demo-ing the completed Lex and Bedrock chatbot 00:44 – Retrieval augmented generation (RAG) with Amazon Bedrock 01:01 – What you’ll need to follow along 01:28 – How much will this cost? 03:37 – Requesting access to the Amazon Bedrock models (Titan Embeddings and Claude) 06:07 – Reviewing the travel policy documents that we’ll use for RAG with Bedrock 06:46 – Creating an S3 bucket for a document store, which will drive the Bedrock knowledge base 07:27 – Creating a knowledge base in Amazon Bedrock that hooks into S3 09:18 – What is the embeddings model in Amazon Bedrock? 10:39 – What is a vector database in Amazon Bedrock? 11:27 – Syncing the data sources in an Amazon Bedrock knowledge base 11:48 – Creating an Amazon Lex bot that uses Bedrock 13:23 – Building out an intent in Amazon Lex 15:23 – Building the Amazon Lex bot and testing our intent 16:31 – Adding the QnAIntent to get generative AI capabilities in our Amazon Lex chatbot 18:26 – Building and testing genAI the QnAIntent in our Amazon Lex chatbot 20:00 – Adding a custom web UI to the Amazon Lex bot 20:30 – IMPORTANT! Deleting the Bedrock knowledge base, OpenSearch vector database, Lex bot and S3 bucket

Comment