Inspiration

Living in apartments and rental properties, we've all experienced the frustration of not being able to install traditional smart doorbells due to wiring requirements, landlord restrictions, or older building infrastructure. I wanted to create a solution that brings smart doorbell functionality to anyone, anywhere, with no installation required. The rise of QR codes has showed us how simple scanning can bridge physical and digital experiences.

What it does

TitaniumDoorman transforms any door into an intelligent doorbell using TiDB, Amazon Web Services, and just a QR code. Visitors scan the code, interact with an AI-powered virtual doorman, and residents receive instant email notifications with visit context. The system recognizes returning visitors, learns from historical patterns stored in TiDB, and provides personalized responses. Perfect for apartments, condos, rental properties, and older homes where traditional doorbell installation isn't possible.

Architecture Diagram

How we built it

We built a sophisticated multi-step AI agent workflow powered by TiDB Serverless as our core database and AWS Bedrock for AI capabilities:

  1. S3 Static Website hosts the visitor interface and QR code generation
  2. API Gateway + Lambda handle session management and orchestrate the AI agent workflow
  3. TiDB Serverless stores all visitor sessions, messages, and historical visit data with MySQL compatibility
  4. AWS Bedrock (Titan Text Express) performs dual AI tasks: visitor intent classification and personalized response generation
  5. SNS delivers contextual email notifications to residents
  6. Secrets Manager securely stores TiDB credentials

The AI agent workflow demonstrates true agentic behavior by querying TiDB for historical visitor data, using that context to inform Bedrock AI decisions, then triggering external actions via SNS, all orchestrated through Lambda functions.

Leveraging user-friendly cloud services means that you can deploy this whole project with a single click! The deploy button below will deploy your own Titanium Doorman! All you need to do is provide your MySQL connection string from your free TiDB Cloud account and you can print our your QR code and interact with your AI doorman in minutes.

Deploy to AWS

Challenges we ran into

  • TiDB SSL Requirements: TiDB Serverless requires encrypted connections, which took debugging to implement proper SSL context in PyMySQL
  • Bedrock Model Access: AWS requires explicit model access requests for foundation models, and model IDs don't always match console names
  • AI Prompt Engineering: Getting the AI to respond as a doorman TO visitors (not about them) required careful prompt crafting
  • CloudFormation formatting: Regex patterns in CloudFormation templates required proper escape character handling, among other challenges. I added a linter action to my GitHub repository to make debugging easier.

Accomplishments that we're proud of

  • True Multi-Step AI Agent: Built a genuine agentic workflow where AI decisions trigger database queries, external API calls, and notifications
  • TiDB Integration Excellence: Leveraged TiDB's MySQL compatibility for seamless session management and historical visitor tracking
  • One-Click Deployment: Entire infrastructure deploys via CloudFormation in under 3 minutes with zero manual configuration
  • Hardware-Free Innovation: Solved a real problem for renters and older homes without requiring any physical installation
  • Intelligent Personalization: The system understands visitor intent and customizes responses accordingly. It also categorizes the visit types for you automatically in your TiDB table!
  • Production-Ready Architecture: Built with proper security (SSL, Secrets Manager), error handling, and fallback mechanisms

What we learned

  • TiDB's Power: TiDB Serverless provides incredible MySQL compatibility while offering cloud-native scalability - perfect for agentic AI workflows that need reliable data persistence
  • Agentic AI Design: Building true AI agents requires careful orchestration between data retrieval, AI inference, and external actions
  • CloudFormation Complexity: Infrastructure-as-code enables powerful one-click deployments but requires attention to detail in resource dependencies and configurations
  • AI Prompt Engineering: Small changes in prompts dramatically affect AI behavior - precision in language is crucial
  • AWS Service Integration: Modern cloud applications shine when services work together seamlessly (Lambda + Bedrock + TiDB + SNS)

What's next for Titanium Doorman - Hardware-less AI Doorbell

  • SMS Integration: Implement proper SMS notifications with AWS origination numbers for instant mobile alerts
  • Amazon Alexa Integration: "Alexa, who's at the door?" - voice integration for hands-free visitor management
  • Advanced TiDB Features: Leverage TiDB's vector search capabilities for semantic visitor message analysis and pattern recognition
  • Voice Messages: Allow visitors to leave voice messages processed through AWS Transcribe and stored in TiDB

Built With

Share this project:

Updates