aws-samples / amazon-bedrock-samples

This repository contains examples for customers to get started using the Amazon Bedrock Service. This contains examples for all available foundational models
https://aws.amazon.com/bedrock/
MIT No Attribution
358 stars 183 forks source link

Customer support Streamlit application with Guardrails #211

Open mccartni-aws opened 1 week ago

mccartni-aws commented 1 week ago

Issue #, if available:

210

Description of changes:

Features:

CloudFormation Template:
    Defines a guardrail for the customer support chatbot.
    Filters out harmful content and protects sensitive information.
    Configures Content Policy, Sensitive Information Policy, Topic Policy, and Word Policy.

Python Scripts:
    deploy_guardrails_infra.sh: Bash script to deploy the CloudFormation stack and retrieve the guardrail identifier.
    streamlit_guardrails_app.py: Streamlit app to interact with the chatbot, using the guardrails set up in the CloudFormation stack.

Requirements:
    Added requirements.txt to install necessary Python packages, including Streamlit.

Documentation:
    Detailed README with step-by-step instructions to set up the environment, deploy the CloudFormation stack, and run the Streamlit app.
    Included links to relevant resources and documentation for further reference.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.