← Back to projects

Personal Project Case Study

Cadence

Cadence is a reflective wellbeing and behavioral-tracking web app that helps users log mood, habits, planning, journaling, and life context, then turns that data into more trustworthy personal insights.

Cadence
Cadence secondary view

Product focus

Reflective wellbeing, habit formation, planning, journaling, and context-aware personal analytics.

Architecture

Next.js App Router, typed server modules, Prisma models, Auth.js, Zod, and a robust mock-backed demo path.

Build priority

Trustworthy insight framing over gamification, novelty, or exaggerated confidence.

Next.jsTypeScriptReactPrismaPostgreSQLAuth.jsTailwind CSSZodResponsive build

Full Project Overview

Cadence is a personal analytics and reflection product built for people who want to better understand how their routines, emotions, and life circumstances interact over time.

Instead of treating mood, habits, journaling, and planning as separate tools, Cadence brings them together into one product loop.

The product is intentionally designed to feel reflective and supportive rather than clinical, gamified, or hyper-optimized. A major focus of the build was trust: insights should be evidence-aware, uncertainty should be visible, and the interface should avoid overstating what the data means.

  • log mood and daily context
  • track habits and planned activities
  • capture journal reflections
  • record meaningful life events
  • surface higher-confidence patterns and summaries

Problem It Solves

Most self-tracking tools split mood, habits, journaling, and planning into disconnected experiences. That makes it hard to see the actual relationships between emotional state, daily behavior, and life context.

Cadence solves that by creating a unified system where the data stays connected and the resulting summaries are framed with appropriate evidence.

  • mood logs can include contextual variables like sleep quality, work stress, and social quality
  • habits and planner activity can be compared against mood trends
  • journal entries can be grouped into story windows and themes
  • life events can be modeled as ongoing context rather than one-off notes
  • insights can show both stronger patterns and more exploratory signals with clear evidence framing

Core Features

Mood Tracking And Reflection

  • Quick mood capture directly from the dashboard
  • Full end-of-day reflection flow
  • Structured contextual inputs such as sleep quality, work stress, and social quality
  • Intraday mood periods with overlap protection so the day model stays consistent

Habit Tracking

  • Positive and limiting habits tracked separately
  • Daily logging with weekly consistency and streak-style feedback
  • Habit data feeds into broader reflection and insight surfaces

Planner And Activity Tracking

  • Planned and retrospective activity logging
  • Recurring activity support
  • Suggested planner experiments based on recent review patterns
  • Activity completion can be tied back to mood context

Journaling And Storytelling

  • Prompt-aware journaling instead of static note capture
  • Story windows that group related journal entries across a date range
  • Theme archive and drilldowns for repeated topics like stress, focus, or movement
  • Overlay comparisons between journal stories and dashboard or mood summaries

Life Event Context

  • Dedicated life-events surface instead of hiding context in other pages
  • Recurring life-event support
  • Ongoing and historical event modeling
  • Contextual weighting that can inform insight confidence

Insight Engine

  • Evidence-aware relationship analysis instead of simplistic pattern claims
  • Exploratory vs higher-confidence pattern framing
  • Lag-window analysis rather than only same-day comparisons
  • Context-adjusted insight presentation when confounding factors are present

Public Launch Safeguards

  • Credentials auth with demo fallback for mock-mode preview
  • Lightweight rate limiting on sign-in attempts
  • Public privacy page
  • Health endpoint for uptime monitoring

Product Philosophy

Cadence was built around a few explicit product principles.

  • Trust is more important than novelty.
  • Reflection is more important than streak pressure.
  • Insights should sound probabilistic, not diagnostic.
  • Users should be able to see uncertainty and sparse-data limits.
  • Life context should be treated as meaningful signal, not noise.

Technical Overview

Cadence is a full-stack TypeScript application built with a server-first architecture.

The app uses Next.js App Router for routing and rendering, Prisma with PostgreSQL for persistence, Auth.js for authentication, and typed server actions and query modules to keep the business logic close to the data layer.

The frontend is built with React and Tailwind CSS, using reusable UI primitives and a feature-based folder structure. Validation is handled with Zod, and focused test coverage is already in place for important logic-heavy modules.

Architecture Summary

Frontend

  • Next.js App Router
  • React 19
  • TypeScript
  • Tailwind CSS
  • Reusable UI components under components/ui
  • Feature-based workspace components under features/**

Backend And Data Layer

  • Fully typed Next.js server-action and query module architecture
  • Prisma used for robust TypeScript model generation and schema definitions
  • Configured for PostgreSQL, but intentionally bypassed via a robust mock-adapter for the public portfolio to guarantee zero-latency and zero-downtime demonstration
  • Validation with Zod before logic execution

Authentication

  • Auth.js / NextAuth v5 beta
  • Credentials-based authentication
  • Fully configurable with @auth/prisma-adapter for live persistence, but defaulting to a hardcoded demo-user fallback to ensure instantaneous sandbox access
  • Lightweight JWT session strategy

Data Model

The schema models several connected entities and is designed to support both daily logging and more advanced cross-feature analysis.

  • users
  • activities and activity templates
  • habits and habit logs
  • mood entries and mood periods
  • journal entries
  • life events and recurring life-event series
  • life-event day exposures
  • persisted insights

Tech Stack

Core Framework

  • Next.js 16.2.5
  • React 19.2.4
  • TypeScript 5

Styling And UI

  • Tailwind CSS 4
  • shadcn/ui
  • Base UI
  • Lucide React
  • Framer Motion
  • next-themes
  • class-variance-authority
  • clsx
  • tailwind-merge
  • tw-animate-css

Forms And Validation

  • React Hook Form
  • Zod
  • @hookform/resolvers

Backend, Auth, And Data Schema

  • Prisma 7 for explicit TypeScript model generation
  • @prisma/client
  • Auth.js / NextAuth v5 beta
  • Zod for form processing

Data And Visualization

  • Recharts
  • date-fns

Tooling

  • ESLint 9
  • tsx for tests and TypeScript execution

Notable Engineering Decisions

Server-First Feature Design

Most product data is fetched on the server through page-specific query modules and passed into feature workspaces. That keeps business logic close to the data layer and reduces unnecessary client state complexity.

Context-Aware Insight Framing

Rather than presenting raw correlation-style output as truth, the insight engine distinguishes between stronger signals and exploratory patterns and adjusts messaging when contextual confounding is present.

Unified Reflection Loop

The dashboard, mood, planner, habits, journal, and insights surfaces are intentionally connected so the app behaves like one product rather than a bundle of separate tools.

Zero-Downtime Public Demo Architecture

To ensure the portfolio piece is always fast, reliable, and immune to database timeouts, the app operates entirely on a statically defined mock data layer. The original DB queries were decoupled, and the application now successfully hydrates the entire unified reflection loop directly from memory. This guarantees an optimal user experience when reviewing the interface concepts.

What I Built

I designed and built Cadence as a frontend product engineering showcase, covering product strategy, data modeling schemas, frontend UX, robust client and server boundary validation, typed stateless authentication, and public-launch safeguards.

I decoupled the live database overhead in favor of a rock-solid mock implementation so users can purely evaluate how the UI handles context, data representation, and reflection logic without friction.

Key Challenges Solved

Modeling Context In A Useful Way

It is easy to collect life context badly. Cadence needed structured context that improved insight quality without forcing heavy manual entry. The solution was to keep the inputs small, high-signal, and tied directly to later analysis.

Preventing Misleading Insights

A major challenge was avoiding shallow or overconfident pattern claims. The insight system was shaped to surface evidence levels, exploratory framing, lag windows, and context-aware adjustments instead of pretending the product could make strong causal claims.

Connecting Multiple Product Surfaces Cleanly

Cadence combines mood, habits, planner activity, journaling, and life events. One of the main implementation challenges was building those as connected workflows rather than isolated feature pages.

Preparing A Real Public Demo

The project needed to be portfolio-ready, not just locally impressive. That meant adding rate limiting, privacy notes, a health endpoint, testing plans, and a practical deployment checklist alongside the main features.

Quality And Reliability

The implementation already includes focused hardening work in the logic-heavy parts of the product and a testing strategy shaped around public launch quality.

  • unit-style tests for logic-heavy modules
  • repository-wide linting
  • successful production build validation
  • input validation with Zod across core flows
  • public-launch safeguards such as auth throttling and health checks
  • a staged testing plan covering unit, integration, acceptance, validation, and smoke testing

Deployment And Operations

Cadence is set up for a lightweight public portfolio deployment and already has the operational groundwork needed for a reliable demo.

The project was prepared for public launch with lightweight operational safeguards, including auth protection, privacy notes, health monitoring infrastructure, and a documented deployment workflow.

  • privacy page
  • health endpoint at /api/health
  • credentials auth throttling
  • deployment checklist
  • monitoring setup guide

What I Would Build Next

  • Richer insight explainability views that show the evidence trail behind each surfaced pattern
  • More guided weekly and monthly review loops that turn reflection history into concrete experiments
  • A gradual transition from the mock-backed public demo into a live alpha environment for authenticated testers
  • Exportable reports and summaries that make reflection history easier to revisit over longer time ranges