
CompassAI - AI-Powered AWS Architecture Decision Assistant
CompassAI helps developers design cloud architectures by analyzing application requirements and generating tailored AWS architecture recommendations powered by Amazon Nova Pro on Amazon Bedrock.
Vision and What It Does
CompassAI is an AI-powered AWS architecture decision assistant that helps developers navigate the complexity of cloud architecture design.
Architecture

Architecture Flow
- User opens the React SPA hosted on AWS Amplify
- Fills the Architecture Builder form and submits
- Frontend sends POST request to API Gateway (
/analyze)
- API Gateway invokes the Lambda function
- Lambda constructs a prompt and calls Amazon Bedrock (Nova Pro) via Converse API
- Nova Pro returns structured JSON with architecture recommendations
- Lambda validates/parses the response and returns it
- Frontend renders service cards, trade-off panels, and React Flow diagram
The Problem: Developers starting a new project face an overwhelming number of AWS services (200+) and architectural patterns. Choosing the right combination requires deep expertise that many developers don't have, especially for their first cloud-native application.
The Solution: CompassAI acts as a technical compass. Developers describe their application idea and requirements through a guided form, and the AI generates a complete architecture recommendation including:
- Specific AWS services with reasoning for each selection
- Trade-off comparisons between architectural alternatives
- An interactive visual architecture diagram
- Implementation considerations for each service
Who it's for: Developers building their first AWS application, teams evaluating architectural options, and anyone who wants a quick second opinion on their cloud architecture design.
Full Stack Breakdown
This project connects to the full stack series journey:
- Pitch: CompassAI's value proposition is clear turn application ideas into AWS architectures in seconds
- Prototype: Started with the core flow: form → AI → results. Validated that Amazon Nova Pro could produce structured JSON responses
- MVP: Shipped a working product with landing page, form, AI analysis, trade-offs, interactive diagram, and dark mode
- UX: Developer-focused design with clean typography, responsive layout, card-based UI, and polished error states
- Launch: Deployed end-to-end on AWS using CDK for backend and Amplify for frontend
How I Built It
Development Process
Used Kiro's spec-driven development workflow:
- Generated formal requirements (9 requirements with EARS-pattern acceptance criteria)
- Created a design document with architecture, interfaces, and 12 correctness properties
- Broke implementation into 37 tasks organized in 9 parallel execution waves
- Built incrementally with property-based testing at each stage
Key Decisions
Decision | Why |
|---|---|
Amazon Nova Pro over Claude | Faster response times, lower cost, native AWS integration |
Converse API over InvokeModel | Standardized API format, model-agnostic code |
React Flow for diagrams | Interactive drag/zoom/pan, category-colored nodes, detail panels |
No auth in MVP | Ship working product first, add Cognito later |
CDK over SAM | More expressive for complex stacks, better TypeScript support |
Vite over CRA/Next | Faster builds, simpler config for SPA, native ESM |
forceDockerBundling: false | Enabled local esbuild bundling without Docker dependency |
Challenges and Solutions
- Structured AI output: Amazon Nova Pro sometimes wraps responses in markdown code fences. Fixed by adding explicit "Return raw JSON only. No code fences." instructions to the system prompt.
- Diagram node positioning: Bedrock returns logical service connections but no x/y coordinates. Solved by integrating the dagre library for automatic top-to-bottom graph layout.
- Monorepo build on Amplify: The
@compassai/sharedtypes package needed to be built before the frontend. Fixed by addingnpm run build -w sharedto the Amplify preBuild phase.
- Docker unavailability for CDK:
NodejsFunctionrequires Docker by default for bundling. Fixed withforceDockerBundling: falseto use local esbuild instead.
- TypeScript strict mode in tests: Property-based tests had strict mode violations that blocked production builds. Fixed by removing
tscfrom the build script (Vite handles transpilation via esbuild internally).
AWS Services
Services Used
Service | Purpose | Why |
|---|---|---|
AWS Amplify | Frontend hosting | Automatic CI/CD from GitHub, SPA support, custom domains |
Amazon API Gateway | REST API | Managed API with CORS, 29s timeout for AI responses |
AWS Lambda | Compute | Serverless, pay-per-use, 60s timeout for Bedrock calls |
Amazon Bedrock | AI inference | Managed AI service, no model hosting required |
Amazon Nova Pro | LLM | Best balance of speed/quality/cost for architecture analysis |
AWS IAM | Security | Least-privilege roles scoped to specific model ARN |
AWS CDK | IaC | TypeScript infrastructure definitions, repeatable deployments |
What I Learned
- Amazon Nova Pro is impressively capable at structured JSON output with the right system prompt engineering
- Converse API is the way to go for Bedrock model-agnostic, cleaner interface than InvokeModel
- Property-based testing with fast-check catches edge cases that unit tests miss (discovered issues with the response parser handling of optional fields)
- Kiro's spec-driven workflow kept the project focused and deliverable within the 48-hour constraint by preventing scope creep
- CDK's NodejsFunction is powerful but has the Docker dependency gotcha
forceDockerBundling: falseis essential for environments without Docker
- Dark mode with Tailwind's
classstrategy and React Context is surprisingly straightforward when planned from the start
- React Flow with layout produces professional-looking architecture diagrams with minimal custom code
CompassAI landing page
CompassAI turns application requirements into practical AWS architecture recommendations, trade-offs, and visual designs.

CompassAI visualizes the recommended AWS services and their relationships in an interactive architecture diagram.

CompassAI compares AWS Lambda and Amazon EC2, highlighting the advantages, limitations, and recommended option.

The application compares Amazon S3 and Amazon EFS based on scalability, durability, cost, and use case.

CompassAI explains the purpose and rationale behind each AWS service selected for the proposed architecture.

An AI-generated summary explains how the selected AWS services work together to support the application.

CompassAI turns application requirements into practical AWS architecture recommendations, trade-offs, and visual designs.
Links
Built in 48 hours for The Full Stack Challenge using AWS Amplify, Lambda, API Gateway, Bedrock (Nova Pro), and CDK - developed with Kiro.
Thank you for taking the time to read my article! If you found it helpful, feel free to like, share, and drop your thoughts in the comments; I’d love to hear from you.
If you want to connect or dive deeper into cloud, AI and DevOps, feel free to follow me on my socials:
Enjoyed reading this content? Let the author know!
Your likes, comments, shares, and saves help creators reach more builders.
Loading recommendations
Loading article