AWS Builder Center
Weekend Productivity Challenge: ZenTime

Weekend Productivity Challenge: ZenTime

ZenTime helps users reclaim screen time by transforming digital habits into balanced routines. It tracks mobile telemetry via an Android app and leverages a serverless AWS backend (API Gateway, Lambda, DynamoDB, EventBridge) with Amazon Bedrock (Nova Pro) to generate AI productivity insights. An admin console hosted on AWS Amplify completes the project, serving as an internal validation backdoor to mock payloads and audit system states in real time.

Vision & What the App Does

Social media has become an integral part of our daily lives, but it often comes at the cost of productivity. Many people install screen-time tracking applications, yet these apps typically stop at reporting statistics. They tell users how much time they spent on Instagram or YouTube but rarely provide personalized, actionable guidance on improving their habits.
To address this problem, I built ZenTime, an AI-powered Android application that helps users develop healthier social media habits using Amazon Bedrock.
The idea behind ZenTime is simple:
Instead of simply reporting yesterday's screen time, the application analyzes the user's behavior and generates personalized recommendations for the next day.
When a user first launches the app, they set a daily social media budget (for example, two hours). The application then collects usage statistics for supported social media applications such as YouTube, Instagram, and Snapchat using Android's UsageStatsManager API.
Every night, the collected data is securely sent to AWS, where Amazon Bedrock analyzes recent usage patterns. The AI identifies frequently used applications, peak usage periods, and overall behavior trends before generating a recommended distribution of the user's daily time budget for the following day.
When the user opens the app the next morning, they receive:
  • Daily usage statistics
  • Most-used applications
  • Peak usage periods
  • AI-generated recommendations
  • Suggested time allocation for each application
The goal is to transform passive analytics into proactive productivity coaching powered by AI.



How I Built It

I designed ZenTime as a serverless, event-driven application on AWS to keep the backend scalable, cost-effective, and easy to maintain.
The Android app collects daily social media usage metrics and sends them to an Amazon API Gateway REST endpoint. API Gateway invokes the  db_save_handler  AWS Lambda function, which validates the request and stores the data in a DynamoDB table ( metrics_db ). Using DynamoDB allows the application to efficiently store and retrieve time-series usage data without managing database infrastructure.
Instead of generating AI recommendations every time the user opens the app, I chose to decouple AI processing from user requests. An Amazon EventBridge Scheduler triggers the  invoke_handler  Lambda every day at 2:00 AM. This function retrieves recent usage metrics from  metrics_db , builds a structured prompt containing the user's daily budget and application usage history, and invokes Amazon Bedrock's Nova Pro model.
Nova Pro analyzes the user's behavior and generates personalized recommendations, including a usage summary, the most frequently used applications, and suggested screen-time allocations for the next day. These recommendations are stored in a separate DynamoDB table ( suggestions_db ), allowing AI-generated data to be cached and served efficiently.
When the user opens the app, it sends a GET request through API Gateway, which invokes the  db_get_handler  Lambda. This function retrieves the latest recommendations from  suggestions_db  and returns them to the client without requiring another Bedrock invocation. This approach reduces latency, minimizes AI inference costs, and provides a faster user experience.
One challenge was designing prompts that consistently produced structured responses instead of free-form text. By including historical usage metrics, app-specific screen time, and the user's configured daily budget, I was able to generate predictable JSON responses that could be directly displayed in the application.
Building ZenTime helped me gain practical experience designing serverless applications with AWS services and integrating Amazon Bedrock into a real-world workflow. The final architecture cleanly separates data collection, AI processing, and data retrieval, making each component independently scalable and easier to maintain.



AWS Services Used / Architecture Overview

ZenTime uses several AWS services working together in a serverless architecture.

Amazon API Gateway

Provides REST endpoints that allow the Android application to upload usage metrics and retrieve AI-generated recommendations

Amazon Lambda

Three Lambda functions power the backend:
  • Save user metrics
  • Retrieve stored data
  • Generate AI recommendations

Amazon DynamoDB

Stores:
  • Daily application usage metrics
  • AI-generated summaries
  • Personalized recommendations
  • User configuration

Amazon Bedrock (Amazon Nova Pro)

Amazon Nova Pro analyzes historical usage data and generates personalized recommendations for the user's next day.

Amazon EventBridge

Automatically triggers the recommendation generation workflow every day at 2:00 AM.

Amazon CloudWatch

Captures application logs and simplifies monitoring and debugging.
Amazon Amplify
While telemetry and application usage metrics are natively captured and pushed directly by the Android mobile application, this administrative portal provides an isolated control plane to cross-check the backend's integrity. It allows developers to mock payload ingestion, bypass the mobile client, and verify the suggestions made by Amazon Bedrock. This ensures that the generated Nova Pro productivity insights and DynamoDB states can be verified, debugged, and audited in real-time against raw user metrics without altering the mobile production environment.



Architecture Overview

Android App AWS Amplify (Web app for testing)
│ │
└──────────────────┬──────────────────┘
│
▼
Amazon API Gateway
│
▼
AWS Lambda
├── Save Metrics
├── Retrieve Data
└── AI Recommendation Generator
│
▼
Amazon Bedrock (Nova Pro)
│
▼
Amazon DynamoDB
▲
│
EventBridge (2 AM Daily)
This architecture is entirely serverless, allowing the application to scale automatically while minimizing operational overhead.



What I Learned

This challenge was an excellent opportunity to explore how generative AI can improve everyday productivity rather than simply acting as a chatbot.
Before building ZenTime, I had theoretical knowledge of Amazon Bedrock and serverless architectures. Through this project, I gained practical experience integrating Amazon Bedrock into a real application workflow and learned how to design prompts that consistently return structured responses suitable for mobile applications.
I also deepened my understanding of AWS Lambda, API Gateway, DynamoDB, and EventBridge while designing an end-to-end serverless backend.
On the Android side, implementing the application reinforced best practices around MVVM, Clean Architecture, dependency injection with Hilt, WorkManager scheduling, and Jetpack Compose.
One important lesson was recognizing that AI becomes significantly more valuable when paired with user context. Rather than asking a model generic questions, providing historical usage patterns and user-defined goals enables the model to generate meaningful, personalized recommendations.
If I continue developing ZenTime beyond this challenge, I would like to add weekly productivity reports, notification reminders, predictive trend analysis, and support for additional social media applications.



Link to App or Repository

GitHub Repository
Live Demo / Deployed Application


Thank you for reading! I hope ZenTime demonstrates how generative AI and serverless AWS services can work together to create practical productivity tools that encourage healthier digital habits.
Any opinions in this article are those of the individual author and may not reflect the opinions of AWS.
Enjoyed reading this content? Let the author know!

Your likes, comments, shares, and saves help creators reach more builders.

Loading recommendations

Loading article