⬡ Hub
Skip to content

AWS GenAI Use Case 7: Enterprise Marketing Assistant

An end-to-end architecture using Amazon Q Business to build a secure, enterprise-grade chatbot customized for a Marketing Department. Amazon Q Business is distinct from Amazon Q Developer; it allows non-technical employees to ask GenAI questions about internal company documents (like marketing plans, branding guidelines, and campaign histories) safely.

Architecture Overview

This solution uses Terraform Modules to structure the Infrastructure as Code (IaC) according to industry best practices for reusability.

  1. Information Architecture (Amazon S3): A dedicated S3 bucket holds all the Marketing department's proprietary PDF/Docx files.
  2. Identity Provider (IAM Identity Center): Employees authenticate to the Amazon Q Business Application using their corporate Single Sign-On (SSO).
  3. The Brain (Amazon Q Business): Amazon Q crawls the S3 bucket, creates an internal search index, and provides a fully-managed web UI where employees can chat.
  4. Security: If User A is not authorized to see the "Q4 Salary Budgets", Amazon Q will mathematically block User A from generating any AI answers derived from that document.
  5. Infrastructure Automation (Terraform Modules): The IaC is split into reusable modules (e.g., setting up the S3 data lake vs setting up the Q application).

Component Breakdown

1. terraform/ (Advanced Modular IaC)

  • main.tf: The root module that calls the sub-modules.
  • modules/s3_data_source/: A reusable terraform module establishing the S3 bucket and necessary resource policies.
  • modules/q_business_app/: A module that provisions the actual Q Business Application index.

2. src/ (Configuration & Prompts)

Because Amazon Q Business provides its own internal web Chat UI, there is no Python app.py required! - system_prompts.md: The strict behavioral instructions assigned to the Amazon Q application to ensure it acts like a Marketing Manager.

3. .github/workflows/deploy.yml (CI/CD)

A pipeline that runs terraform apply across the modularized infrastructure.