
System architecture flow diagram
Place
Overview
Email subscriptions cause massive inbox clutter. Gmail's native 'unsubscribe' requires individual clicks, making bulk management a manual chore. I built an AI-driven categorisation engine using Amazon Bedrock (Claude 3.5 Sonnet) to analyse subscriptions, assign 'trashiness scores,' and provide actionable insights for bulk cleanup.
๐ Project Impact
- Efficiency: Reduces inbox cleanup time from 30 minutes to 2 minutes
- Speed: Processes 30 emails in under 60 seconds
- Precision: Achieves 94% AI categorisation accuracy
- Optimisation: 40% cost savings using Bedrock vs. OpenAI
๐ฏ Key Learning Outcomes
๐ป Technical Skills Acquired
- Cloud Integration: Configured AWS IAM roles and enabled Amazon Bedrock model access
- AI Implementation: Integrated Claude 3.5 Sonnet; mastered prompt engineering for structured JSON outputs
- API Auth: Implemented OAuth 2.0 flow for Gmail API and managed token refresh cycles
- Full-Stack: Python backend development using boto3 and google-api-python-client
๐ Product Management Skills
- Trade-off Analysis: Conducted quantitative evaluation of Bedrock vs. OpenAI based on cost and compliance
- User-Centric Design: Identified core pain points via a survey of 7 peers
- MVP Scoping: Prioritised categorisation (Phase 1) over full automation to validate the core value prop
๐๏ธ System Architecture
Data Flow: Gmail API โ Python Backend โ Amazon Bedrock โ JSON Output
๐ Trade-offs: Bedrock vs. OpenAI
Final Decision: Amazon Bedrock โ
- Cost: $3/1M tokens (Bedrock) vs $5/1M tokens (OpenAI)
- Data Privacy: AWS-contained infrastructure vs External routing
- Rationale: 40% cost reduction scales to ~$730K annual savings at a 10k user scale. Data residency is essential for future GDPR/SOC2 compliance
๐ง Technical Challenges & Solutions
- OAuth Access Blocked: Resolved by adding test users in the Google Cloud Console
- JSON Parsing Error: Handled Claude's markdown fences by writing a Python cleaning utility
- 403 Forbidden Error: Enabled the Gmail API manually via the API Library
๐ Future Roadmap
- Phase 2: Implement programmatic unsubscribe via email headers
- Phase 3: Build a Streamlit interactive dashboard
- Phase 4: Deploy to AWS Lambda for production scaling
Last Updated: January 31, 2026