Initial commit: Kalei app — docs, mockups, logo, pitch deck

Complete project files including:
- 73 polished HTML mockup screens (onboarding, turn, mirror, lens, gallery, you, ritual, spectrum, modals, guide)
- Design system CSS with Inter font, jewel-tone palette, device frame scaling
- Canonical 6-blade kaleidoscope logo (soft-elegance-final)
- SVG asset library (fragments, icons, patterns, evidence wall, spectrum viz)
- Product docs, brand guidelines, technical architecture, build phases
- Pitch deck and cost projections
- Logo mockup iterations and finalists

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-22 14:55:22 +01:00
commit 38021c4633
168 changed files with 46724 additions and 0 deletions

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,792 @@
# Kalei — Complete User Journey Map
> Version 2.0 — February 2026
> Updated to include Ritual, Rehearsal, Evidence Wall, and full cross-feature integration
---
## Overview
This document maps every user-facing flow in Kalei from first launch to long-term mastery. It serves as the single source of truth for what the user experiences, when, and why — covering all 7 features across the 5-tab architecture.
**Navigation Architecture:** Turn ◇ | Mirror ✦ | Lens ◎ | Gallery ▦ | You ●
**Core Features (4 Pillars):**
- The Turn (Kaleidoscope) — Perspective shifting via cognitive reframing
- The Mirror — Awareness through freeform journaling with AI fragment detection
- The Lens — Direction through goal setting, visualization, and action planning
- Gallery — Pattern collection and history
**Connector Features (4 Bridges):**
- The Ritual — Context-anchored daily habit sequences chaining Mirror → Turn → Lens
- The Rehearsal — Guided multi-sensory visualization (Lens sub-feature)
- The Evidence Wall — Mastery tracking mosaic (You tab sub-feature)
- The Guide — Active coaching layer connecting all features with proactive check-ins, cross-feature bridges, attention prompts, evidence interventions, and weekly pulse
**Intelligence Layer:**
- The Spectrum — AI-powered self-knowledge dashboard
---
## Journey Stage 1: First Launch & Onboarding
### Screen 1: Splash
- Breathing logo animation (soft-elegance iris, slow rotation, core pulse)
- Background: Void (#050508) with subtle breathing aura
- Duration: 2 seconds, auto-advance
### Screen 2: Welcome — "Same pieces. New angle."
- Hero kaleidoscope pattern (6-blade prismatic, screen blend mode)
- Tagline in Space Grotesk display font
- Single CTA: "See how it works" (Amethyst shimmer button)
### Screen 3: The Metaphor — Fragment Introduction
- Visual: A single thought fragment (◇) appears, glowing Amber
- Copy: "Your thoughts are like pieces of glass in a kaleidoscope."
- Interaction: User taps the fragment → it pulses with detected-state animation
- Copy continues: "Sometimes you see sharp edges. Sometimes beautiful patterns."
### Screen 4: The Turn Demo — Live Reframe
- Pre-populated negative thought: "I always mess everything up"
- Auto-animated Turn sequence (1.5s): collapse → multiply → crystallize → settle
- Three reframed perspectives appear as jewel-toned cards (Amethyst, Sapphire, Emerald)
- Copy: "Same pieces. New angle. That's a Turn."
### Screen 5: Choose Your Style
- 4 coaching style cards with fragment icons:
- Stoic Sage (Sapphire ◇) — "Clear-eyed perspective"
- Compassionate Friend (Rose ◇) — "Gentle understanding"
- Pragmatic Coach (Emerald ◇) — "Practical next steps"
- Growth Catalyst (Amber ◇) — "Opportunity in everything"
- User selects default (can change later)
### Screen 6: Notification Permission
- Copy: "When would you like a gentle nudge to check in?"
- Time picker with morning/evening presets
- Skip option available
### Screen 7: Account Creation
- Email + password OR Apple/Google SSO
- Minimal fields — name optional at this stage
- Privacy assurance: "Your thoughts stay yours. Always encrypted."
### Screen 8: First Real Turn
- Empty Turn input with prompt: "What's weighing on you right now?"
- User types their first real negative thought
- Full Turn animation plays
- 3 reframed perspectives appear
- User can save favorites (→ Gallery) or dismiss
- Success burst animation on save
### Screen 9: Welcome Complete
- Copy: "Welcome to Kalei. Your kaleidoscope is ready."
- Mini kaleidoscope pattern generated from their first Turn (deterministic, seeded from input)
- CTA: "Start exploring" → Tab bar appears, Turn tab active
---
## Journey Stage 2: Daily Core Loop
### 2A: The Turn (Tab 1 — Amethyst ◇)
**Entry:** User opens app → Turn tab is default home
**Empty State:**
- Breathing logo at center, subtle floating shards in background
- Rotating prompts: "What thought keeps circling?", "What would you like to see differently?", "What feels heavy right now?"
- Single large text input area
**Active Flow:**
1. User types or speaks a negative thought
2. Tap "Turn it" button (Amethyst shimmer)
3. Turn animation plays (1.5s kaleidoscope rotation)
4. 3 reframed perspectives appear as cards:
- Each card has a coaching style label, the reframe text, and a fragment icon
- Cards use jewel tone gradients matching their style
5. Below perspectives: "If-Then Micro-Action" card
- Format: "If [situation], then I will [specific action]"
- Emerald accent, action-oriented
6. User actions:
- Save any perspective → goes to Gallery as a Keepsake
- Save micro-action → goes to Lens as a suggested action
- Share → generates Pattern Card (kaleidoscope pattern + reframe text)
- Dismiss → confirmation, thought is discarded
**Turn History:**
- Scrollable list below input showing today's Turns
- Each entry: timestamp, first line of thought, fragment count badge, pattern thumbnail
**Rate Limiting (Free tier):**
- 3 Turns per day
- After limit: "You've used your 3 Turns today. Upgrade to Kalei Prism for unlimited Turns."
- Gentle, never punishing
### 2B: The Mirror (Tab 2 — Amber ✦)
**Entry:** Mirror tab → New session or continue existing
**Empty State:**
- Soft amber glow background
- Copy: "What's on your mind? Write freely — no judgment, no rules."
- Suggested prompts rotate: "How are you feeling right now?", "What happened today?", "What's been on repeat in your head?"
**Active Session Flow:**
1. User writes freely in chat-like interface (user messages appear as dark bubbles)
2. After each message, AI processes silently (AI thinking animation: 3 oscillating fragments)
3. AI responds with warm, reflective prompts (light bubbles with subtle amber border)
4. Simultaneously, AI detects cognitive distortions in user's text
5. Detected fragments appear as inline highlights:
- Amber glow underline beneath the distorted phrase
- Small ◇ icon at start of highlight
- Highlight appears post-message (never while typing)
6. User taps a highlight → Half-sheet modal:
- Distortion type name + icon (from icons-distortions.svg)
- Brief explanation: "Catastrophizing: Assuming the worst possible outcome"
- 1-2 quick reframes
- "Take to Turn" button → opens Turn with this thought pre-filled
- Dismiss to continue writing
**Session Close:**
- User taps "End Session" or navigates away
- AI generates Reflection:
- Themes detected
- Fragment count and types
- One-line insight
- Unique kaleidoscope pattern (seeded from session content)
- Reflection saved to Gallery
**Nudge System:**
- If user ignores 5+ highlighted fragments, ONE gentle offer:
- "I noticed a few patterns in what you wrote. Want to look at them together?"
- Max once per session
- Dismissible
**Rate Limiting (Free):** 2 sessions per week, 3 distortion types detected (Catastrophizing, Black-and-White, Should Statements). Prism: unlimited sessions, all 10 types.
### 2C: The Lens (Tab 3 — Emerald ◎)
**Entry:** Lens tab → Goal dashboard
**Dashboard View:**
- Active goals displayed as cards with progress rings
- Each goal card shows: title, progress percentage, next action, streak indicator
- "Add Goal" floating action button (Emerald gradient)
**Goal Creation Flow (6 Steps):**
**Step 1: Decide — Set a SMART Goal**
- AI-guided conversation to refine a vague desire into a specific goal
- Template: "I want to [specific outcome] by [date] measured by [metric]"
- AI suggests refinements if goal is vague
**Step 2: See It — The View (Vision Board)**
- AI generates a visualization description based on goal
- User can add personal images or AI-generated imagery
- "The View" appears as a full-screen card they can revisit
**Step 3: Believe — Capability Building**
- Evidence Wall integration: surfaces past achievements relevant to this goal
- AI generates affirmations based on goal + user's history
- Daily affirmation card appears at Lens tab top
**Step 4: Notice — Attention Training**
- AI prompts awareness exercises: "Today, notice one moment where you [goal-related behavior]"
- Prompts delivered via notification at user-chosen time
- User logs noticed moments → feeds Evidence Wall
**Step 5: Act — If-Then Micro-Actions**
- AI generates situation-specific implementation intentions
- Format: "If [context], then [specific action]"
- User can mark actions complete → feeds Evidence Wall
- Action completion streak tracking
**Step 6: Compound — Habit Tracking**
- Visual habit tracker (fragment-shaped step indicators)
- Streak counter with flame icon
- Weekly review of consistency
**The Rehearsal (Lens Sub-Feature):**
- Accessed from goal detail screen → "Rehearse" button
- Timer ring appears (default: 10 minutes)
- AI generates personalized visualization script:
- First-person perspective
- Multi-sensory (see, hear, feel, smell)
- Process-oriented (not just outcome)
- Includes obstacle rehearsal ("When X happens, I will Y")
- Script plays as text cards with breathing animation pacing
- Progress ring counts down
- Completion → Success burst → logged to Evidence Wall
- Free: 1 Rehearsal per week. Prism: unlimited.
### 2D: Gallery (Tab 4 — Sapphire ▦)
**Entry:** Gallery tab → Collection view
**Views:**
- **All Patterns** (default): Reverse-chronological grid of kaleidoscope pattern thumbnails
- **Keepsakes**: Saved reframes, reflections, and insights
- **By Feature**: Filter by Turn / Mirror / Lens source
- **By Distortion**: Filter by cognitive distortion type
**Pattern Card Detail:**
- Full kaleidoscope pattern (hero variant, animated)
- Source content (the reframe or reflection that generated it)
- Date, feature source, distortion types tagged
- Share button → exports as Pattern Card image
- Delete with confirmation
**Search:**
- Text search across all saved content
- Filter chips: date range, feature, distortion type, favorites
### 2E: You (Tab 5 — Soft Light ●)
**Entry:** You tab → Profile dashboard
**Sections:**
- **Profile**: Name, avatar, member since
- **Stats Overview**: Total Turns, Mirror sessions, Goals active, Streak count
- **Evidence Wall** (prominent card → opens full view)
- **Settings**: Coaching style, notification times, theme (dark only for now), data export
- **Subscription**: Current plan, upgrade CTA (if free)
- **Support**: FAQ, contact, crisis resources
**The Evidence Wall (You Sub-Feature):**
- Accessed from You tab → "Your Evidence Wall" card
- Opens full-screen mosaic view
**Evidence Wall States:**
*Empty State (0-2 items):*
- Ghost tile outlines (dashed borders) showing where tiles will appear
- Central fragment icon with breathing animation
- Copy: "Start collecting evidence. Each Turn adds a tile to your wall."
*Early State (3-7 items):*
- Small cluster of tiles, connections forming
- Tiles are mixed shapes (diamond, hex, rectangle, pentagon, triangle)
- Each tile represents one proof point:
- Completed action (Emerald border)
- Saved keepsake (Sapphire border)
- Self-correction in Mirror (Amber border)
- Streak milestone (Amethyst border)
- Goal completion (Emerald border, larger tile)
- Reframe echo (Indigo border) — when user's later writing echoes a saved reframe
*Mid State (8-20 items):*
- Mosaic takes shape, dashed connection lines between related tiles
- Tiles glow softly when tapped → detail half-sheet
*Full State (20+ items):*
- Dense mosaic with visible connection web
- Zoom/pan enabled
- Most impactful tiles glow brighter
**Contextual Surfacing:**
- During low self-efficacy moments (detected in Mirror or Turn), the Evidence Wall surfaces 1-2 relevant tiles
- Example: User writes "I can never stick to anything" → Evidence Wall suggests: "You completed 12 actions in the last month and maintained a 7-day streak"
- Presented as a gentle card, not a correction
---
## Journey Stage 3: The Ritual (Connector Feature)
The Ritual chains Mirror → Turn → Lens into a single context-anchored daily flow.
**Access:** Dedicated "Start Ritual" button at top of Turn tab, or via notification
**Template Selection:**
*Morning Ritual (15-20 min):*
1. Mirror check-in: "How are you waking up today?" (3 min writing)
2. Turn: AI identifies strongest fragment from Mirror → offers reframe (2 min)
3. Lens: Today's priority action from active goal (1 min review)
4. Affirmation: Daily affirmation card
5. Set intention: One sentence for the day
*Evening Ritual (10-15 min):*
1. Mirror reflection: "What stood out about today?" (3 min writing)
2. Turn: Process any unresolved thought from the day (2 min)
3. Lens review: Mark completed actions, log noticed moments
4. Gratitude: One thing from today (saved to Gallery)
*Quick Ritual (5 min):*
1. One-line check-in
2. Fastest Turn (single perspective)
3. One action reminder
**Ritual Flow UI:**
- Step indicators using fragment-shaped progress bar (from progress-indicators.svg)
- Each step has a timer (visible but not pressuring)
- Smooth transitions between steps (fragment scatter/converge animation)
- Completion → Success burst → streak updated
**Ritual Tracking:**
- Streak calendar (7-day week view, Amber jewel tone)
- Context consistency tracking (Wood et al.): same time, same place → stronger habit
- Ritual completion logged to Evidence Wall
**Rate Limiting (Free):** Quick Ritual only. Prism: all 3 templates.
---
## Journey Stage 3B: The Guide (Active Coaching Layer)
The Guide is not a tab or a destination — it's an intelligence layer that surfaces across all features through five interaction patterns. These screens show how each pattern manifests in the UI.
### Guide Pattern 1: Goal Check-In (Lens)
**Access:** "Check in" button on goal detail screen, or via notification at user's chosen check-in time
**Screen 65: Goal Check-In Conversation**
A chat-like interface within the goal detail screen. The Guide has full context from the user's Lens activity, Mirror sessions, and Turn history.
**Flow:**
1. Guide opens with a recognition of recent progress (evidence-first)
2. Guide asks about specific milestones or actions since last check-in
3. User responds conversationally
4. Guide reviews relevant if-then plans — did the situations arise? Did the plans work?
5. If plans need adjustment, Guide proposes modifications collaboratively
6. Guide closes with a concrete Evidence Wall proof point
**UI Elements:**
- Chat interface within goal detail (not a separate screen — slides up from goal card)
- Guide messages use prismatic gradient border (distinguishing from Mirror's amber)
- User messages in dark bubbles (consistent with Mirror style)
- At bottom: typing area with send button
- Check-in history accessible via "Past check-ins" link
**Screen 66: Check-In Summary**
After the conversation ends, a summary card appears:
- What was reviewed
- Plan adjustments made (if any)
- Evidence highlighted
- Next check-in date
- "Added to your coaching history" confirmation
**Rate Limiting (Free):** 1 check-in per month per goal. Prism: weekly per goal + on-demand.
---
### Guide Pattern 2: Cross-Feature Bridge Cards
**Access:** Appear automatically at the top of Turn, Mirror, or Lens tabs when the Guide detects a cross-feature pattern
**Screen 67: Discovery Bridge**
Appears when 3+ Mirror sessions or Turns share a theme that doesn't map to any existing Lens goal.
**Layout:**
- Half-height card at top of screen (below nav header, above feature content)
- Prismatic gradient border (thin, cycling amethyst → sapphire → emerald → amber)
- Header: "◇ Something keeps coming up" (or "A pattern is forming")
- Body: 1-2 sentences referencing the theme, with quoted user text in italics
- CTAs: Primary action (e.g., "Open Lens" / "Start a goal") + Dismiss ("Just noticing")
- Dismissible with swipe or tap
**Screen 68: Reinforcement Bridge**
Appears when Mirror/Turn content directly relates to an existing Lens goal.
**Layout:** Same card format as discovery bridge.
- Header: "◇ This connects to something you're building"
- Body: References the specific goal and how the current processing connects to it
- CTAs: "Start Rehearsal" / "Check in on goal" + Dismiss
**Screen 69: Integration Bridge**
Appears when current Mirror/Turn writing contradicts a previously saved keepsake.
**Layout:** Same card format, but includes a quoted keepsake.
- Header: "◇ You've seen this differently before"
- Body: Shows the saved keepsake text, then the current contradicting sentiment
- CTAs: "See your Evidence Wall" / "Full Turn" + "Continue writing"
**Rules:** Maximum one bridge per day. Never appears mid-Mirror session. Always dismissible.
---
### Guide Pattern 3: Attention Prompts (Lens)
**Access:** Daily notification → opens in Lens tab. Also accessible from Lens dashboard as a card.
**Screen 70: Daily Attention Prompt**
**Layout:**
- Card in Lens tab (below goals, above rehearsals)
- Emerald accent border (Lens color family)
- Header: "Today's Focus: [Prompt Type]" (Notice / Reflect / Act / Envision)
- Body: The specific prompt, 1-2 sentences, tied to the active goal
- Goal reference: "For your goal: [goal title]"
- CTA: "Got it" (acknowledges) + "Log a moment" (appears later in the day)
- Prompt type rotates based on which step of the manifestation chain the user is in
**Screen 71: Moment Log**
When user taps "Log a moment" (later in the day or from notification):
**Layout:**
- Simple text input: "What did you notice?"
- Below: context reminder of today's prompt
- Submit → confirmation: "That's evidence. Added to your Evidence Wall."
- The logged moment appears as a new Evidence Wall tile
**Rate Limiting (Free):** 3 attention prompts per week. Prism: daily.
---
### Guide Pattern 4: Evidence Intervention
**Access:** Surfaces automatically during Mirror sessions or after Turns when low self-efficacy is detected
**Screen 72: Evidence Intervention Card (Mirror)**
Appears after a Mirror session ends (never mid-session) when the session contained significant self-efficacy dip language.
**Layout:**
- Card at bottom of Mirror reflection screen
- Prismatic border
- Header: "◇ Here's what I've seen"
- Body: 2-3 specific, numbered proof points from Evidence Wall that directly counter the expressed doubt
- Each proof point includes a specific number, date, or action
- CTA: "See your full Evidence Wall" + Dismiss
- Tone: Presenting evidence, not cheerleading. "You said X. Your data shows Y."
**Screen 73: Evidence Intervention Card (Turn)**
Appears below Turn results when the original thought contained capability doubt on a topic where the user has evidence.
**Layout:**
- Same card format as Mirror intervention
- Positioned below the 3 reframe cards, above the action buttons
- Contextually references the Turn's topic
**Rules:** Maximum one intervention per session. Only surfaces when meaningful evidence exists. Never fabricates or exaggerates.
**Rate Limiting (Free):** Not available. Prism: full evidence interventions.
---
### Guide Pattern 5: Weekly Pulse
**Access:** Weekly notification on user's chosen day (default: Sunday evening) → opens dedicated Pulse flow
**Screen 74: Pulse — Self-Report**
Step 1 of 3 in the Weekly Pulse flow.
**Layout:**
- Full-screen flow (no tab bar — immersive like Ritual)
- Header: "Your Weekly Pulse"
- Subheader: "How did this week feel?"
- 5-point fragment scale (SVG diamonds at increasing glow/facet levels):
- ◇ dim, cracked — "Rough"
- ◇ muted — "Harder than usual"
- ◇ neutral — "Steady"
- ◇ glowing — "Good momentum"
- ◇ brilliant, faceted — "Breakthrough week"
- Below scale: optional one-sentence write-in
- Progress indicator: Step 1 of 3
**Screen 75: Pulse — AI Read**
Step 2 of 3.
**Layout:**
- Header: "Here's what I noticed this week"
- 3-5 bullet observations from the AI, each with a jewel-tone accent dot:
- Turn count and theme
- Mirror session emotional trajectory
- Lens goal progress
- Distortion pattern changes
- Streak/consistency data
- If self-report diverges from data: a highlighted callout — "You said this was a rough week, but your data shows progress on two fronts. Sometimes the feeling lags behind the evidence."
- Progress indicator: Step 2 of 3
**Screen 76: Pulse — Next Week Focus**
Step 3 of 3.
**Layout:**
- Header: "For next week"
- 2-3 suggested focus areas as cards:
- Each card: one-sentence suggestion + the feature it relates to (Lens, Mirror, Rehearsal, etc.)
- Examples: "Do a Rehearsal for your 5K — you haven't done one in 10 days" / "Your Mirror streak is at 14 days — keep it going"
- CTAs: "Sounds good" (accepts) / "Adjust" (opens edit)
- Completion: "Pulse complete. See you next week."
- Pulse data saved → feeds Spectrum
**Rate Limiting (Free):** Self-report step only (no AI read, no next-week focus). Prism: full 3-step Pulse.
---
### Guide — Enhanced Turn Results (Updated Screen 13)
The existing Turn Results screen (13) is enhanced with two new elements:
**Addition 1: If-Then Micro-Action Card**
Positioned between the reframe cards and the action buttons:
- Emerald accent border
- Format: "If [situation from the thought], then I will [specific action]"
- CTA: "Save to Lens" → creates an action item on the most relevant active goal
- If no active goal exists: "Start a Lens goal around this"
**Addition 2: Goal Connection (when relevant)**
If the Turn's topic maps to an active Lens goal:
- Small card below the micro-action: "This connects to your goal: [goal title]"
- CTA: "Check in on this goal" / Dismiss
---
### Guide — Enhanced Mirror Reflection (Updated Screen 19)
The existing Mirror Session Reflection screen (19) is enhanced:
**Addition: "The Guide noticed..." section**
Below the existing reflection content (themes, fragment count, patterns, insight):
- Prismatic-bordered card
- Header: "The Guide noticed..."
- 1-2 cross-feature observations:
- Theme connections to Lens goals
- Pattern changes compared to recent sessions
- Integration bridge opportunities (if a saved keepsake was contradicted)
- CTAs appropriate to the observation (e.g., "Open Lens" / "See your Evidence Wall" / Dismiss)
---
## Journey Stage 4: Spectrum (Intelligence Layer)
**Unlock:** After 2 weeks of active use (minimum 5 Turns, 2 Mirror sessions)
**Teaser Period:**
- Notification: "Something is forming... Your Spectrum is almost ready."
- Small locked card on You tab with shimmer animation
**Launch Reveal:**
- Full-screen animation: fragments converge into prismatic kaleidoscope
- User's first Spectrum dashboard appears
**Dashboard Components:**
**The River (Emotional Flow):**
- Flowing prismatic gradient band showing emotional valence over time
- Data points as fragment icons at key moments
- X-axis: days/weeks, Y-axis: emotional valence
- Hover/tap any point → detail card with source Turn/Mirror session
**Your Glass (Distortion Distribution):**
- Radar/spider chart showing which of the 10 distortion types appear most
- Amber jewel tone data shape on hex grid
- Vertices as fragment icons
- Evolves weekly as patterns shift
**Turn Impact (Before/After):**
- Bar chart pairs showing emotional metrics before and after Turns
- Metrics: Distress level, Clarity, Hope
- Ruby bars (before) vs Emerald bars (after)
- Rolling 30-day average
**Rhythm Detection (Your Cycles):**
- Time-of-day engagement pattern
- Bubble sizes represent intensity
- Peak labels with fragment accents
- Helps user identify best times for practice
**Growth Trajectory (The Long View):**
- Line chart with fragment data points
- Y-axis: Resilience Score (composite of fragment density, self-correction rate, reframe adoption, distortion diversity, Turn-to-insight ratio)
- Milestone markers (10th Turn, 30-day streak, etc.)
- Monthly trend with prismatic gradient fill under curve
**Cadence:**
- Weekly summary: Sunday evening notification with 1 key insight
- Monthly deep dive: First of month with month-over-month comparison
- In-context nudges: Insights surface within Mirror/Turn/Lens at natural moments
**Rate Limiting (Free):** Simplified weekly summary (1 insight, no visuals, basic fragment counts). Prism: full dashboard, all 5 components, weekly/monthly deep dives, growth trajectory, export.
---
## Journey Stage 5: Engagement Deepening & Retention
### Streak System
- Daily streak counter (consecutive days with at least 1 Turn or Ritual)
- Visual: flame icon with Amber gradient, pulse animation
- Milestones: 3, 7, 14, 30, 60, 90, 180, 365 days
- Each milestone → special pattern generated, saved to Gallery
- Streak freeze: 1 free per week (Prism: 3 per week)
### Push Notifications
- Daily check-in at user's chosen time
- Streak maintenance reminders (if about to break)
- Milestone celebrations
- Weekly Spectrum insights (Prism)
- Ritual reminders at consistent time/place
- Never more than 2 per day
### Empty States
- Every screen has a warm, encouraging empty state
- Uses breathing logo animation or floating shard clusters
- Copy examples:
- Turn: "What would you like to see differently today?"
- Mirror: "Ready to write? There's no wrong way to start."
- Lens: "What are you working toward? Let's build a path."
- Gallery: "Your first pattern is waiting to be created."
- Evidence Wall: "Every small step is evidence. Start collecting."
### Upgrade Moments (Free → Prism)
- After hitting 3 Turn limit: "You're on a roll. Unlock unlimited Turns."
- After 2nd Mirror session: "Want to explore all 10 distortion types?"
- After first Rehearsal: "That felt good, right? Get unlimited Rehearsals."
- After Evidence Wall shows 10+ tiles: "Your evidence is growing. See the full picture with Spectrum."
- Never blocks current action — always shows after completion
---
## Journey Stage 6: System States
### Loading States
- Initial load: Breathing logo animation
- Feature transitions: Fragment scatter/converge
- AI processing: 3-fragment oscillation (AI thinking bubble)
- Data loading: Skeleton shimmer (text lines + card shapes)
- Long operations: Iris spinner with progress text
### Error States
- Network error: "Lost connection. Your data is safe — we'll sync when you're back."
- AI error: "Our thinking engine needs a moment. Try again in a few seconds."
- Rate limit: Feature-specific messaging (see each feature above)
- Generic: Ruby-accent toast with retry option
### Success States
- Turn saved: Emerald toast "Turn saved" with fragment icon
- Goal completed: Success burst animation (expanding rings + particle fragments)
- Streak milestone: Special celebration with pattern generation
- Ritual complete: Prismatic ring completion animation
### Offline Mode
- Turn input cached locally, syncs when online
- Mirror sessions continue with local fragment detection (basic)
- Gallery browsable offline
- Clear indicator: "Offline — your work will sync automatically"
---
## Monetization Tiers
### Kalei (Free)
| Feature | Limit |
|---------|-------|
| Turn | 3 per day |
| Mirror | 2 sessions per week, 3 distortion types |
| Lens | 1 active goal, basic actions |
| Rehearsal | 1 per week |
| Ritual | Quick template only |
| Evidence Wall | 30-day window |
| Guide | Discovery bridges only, 1 check-in/month/goal, 3 attention prompts/week, self-report Pulse only |
| Gallery | Full access |
| Spectrum | Simplified weekly summary (text only) |
### Kalei Prism ($7.99/month)
| Feature | Access |
|---------|--------|
| Turn | Unlimited + if-then micro-action cards |
| Mirror | Unlimited sessions, all 10 distortion types, unlimited inline reframes + evidence interventions |
| Lens | Unlimited goals, AI-refined actions + weekly check-ins + daily attention prompts |
| Rehearsal | Unlimited |
| Ritual | All 3 templates |
| Evidence Wall | Full history, no time window + contextual AI surfacing |
| Guide | All 5 patterns: full check-ins, all bridge types, daily prompts, evidence interventions, full Pulse |
| Gallery | Full access + export |
| Spectrum | Full dashboard, all 5 components, weekly/monthly insights, growth trajectory |
---
## Appendix: Screen Inventory
| # | Screen | Tab | Feature |
|---|--------|-----|---------|
| 1 | Splash | — | System |
| 2 | Welcome | — | Onboarding |
| 3 | Fragment Intro | — | Onboarding |
| 4 | Turn Demo | — | Onboarding |
| 5 | Style Selection | — | Onboarding |
| 6 | Notification Permission | — | Onboarding |
| 7 | Account Creation | — | Onboarding |
| 8 | First Turn | — | Onboarding |
| 9 | Welcome Complete | — | Onboarding |
| 10 | Turn Home (empty) | Turn | Turn |
| 11 | Turn Input Active | Turn | Turn |
| 12 | Turn Animation | Turn | Turn |
| 13 | Turn Results | Turn | Turn |
| 14 | Turn History | Turn | Turn |
| 15 | Mirror Home (empty) | Mirror | Mirror |
| 16 | Mirror Session Active | Mirror | Mirror |
| 17 | Mirror Fragment Highlight | Mirror | Mirror |
| 18 | Mirror Fragment Detail (half-sheet) | Mirror | Mirror |
| 19 | Mirror Session Reflection | Mirror | Mirror |
| 20 | Lens Dashboard | Lens | Lens |
| 21 | Lens Goal Creation Step 1 | Lens | Lens |
| 22 | Lens Goal Creation Step 2 | Lens | Lens |
| 23 | Lens Goal Creation Step 3 | Lens | Lens |
| 24 | Lens Goal Creation Step 4 | Lens | Lens |
| 25 | Lens Goal Creation Step 5 | Lens | Lens |
| 26 | Lens Goal Creation Step 6 | Lens | Lens |
| 27 | Lens Goal Detail | Lens | Lens |
| 28 | Lens Daily Affirmation | Lens | Lens |
| 29 | Rehearsal Session | Lens | Rehearsal |
| 30 | Rehearsal Complete | Lens | Rehearsal |
| 31 | Gallery All Patterns | Gallery | Gallery |
| 32 | Gallery Keepsakes | Gallery | Gallery |
| 33 | Gallery Pattern Detail | Gallery | Gallery |
| 34 | Gallery Search/Filter | Gallery | Gallery |
| 35 | You Profile | You | You |
| 36 | You Stats | You | You |
| 37 | You Settings | You | Settings |
| 38 | You Subscription | You | Billing |
| 39 | Evidence Wall (empty) | You | Evidence Wall |
| 40 | Evidence Wall (early) | You | Evidence Wall |
| 41 | Evidence Wall (mid) | You | Evidence Wall |
| 42 | Evidence Wall (full) | You | Evidence Wall |
| 43 | Evidence Wall Tile Detail | You | Evidence Wall |
| 44 | Ritual Template Selection | Turn | Ritual |
| 45 | Ritual Morning Flow | Turn | Ritual |
| 46 | Ritual Evening Flow | Turn | Ritual |
| 47 | Ritual Quick Flow | Turn | Ritual |
| 48 | Ritual Complete | Turn | Ritual |
| 49 | Ritual Streak View | Turn | Ritual |
| 50 | Spectrum Dashboard | You | Spectrum |
| 51 | Spectrum The River | You | Spectrum |
| 52 | Spectrum Your Glass | You | Spectrum |
| 53 | Spectrum Turn Impact | You | Spectrum |
| 54 | Spectrum Rhythm | You | Spectrum |
| 55 | Spectrum Growth | You | Spectrum |
| 56 | Spectrum Weekly Summary | You | Spectrum |
| 57 | Spectrum Monthly Deep Dive | You | Spectrum |
| 58 | Upgrade Modal | — | Billing |
| 59 | Rate Limit Notice | — | System |
| 60 | Crisis Response | — | Safety |
| 61 | Pattern Card Share | — | Social |
| 62 | Notification Settings | You | Settings |
| 63 | Data Export | You | Settings |
| 64 | Account Deletion Confirm | You | Settings |
| 65 | Goal Check-In Conversation | Lens | Guide |
| 66 | Check-In Summary | Lens | Guide |
| 67 | Discovery Bridge Card | Turn/Mirror/Lens | Guide |
| 68 | Reinforcement Bridge Card | Turn/Mirror/Lens | Guide |
| 69 | Integration Bridge Card | Mirror | Guide |
| 70 | Daily Attention Prompt | Lens | Guide |
| 71 | Moment Log | Lens | Guide |
| 72 | Evidence Intervention (Mirror) | Mirror | Guide |
| 73 | Evidence Intervention (Turn) | Turn | Guide |
| 74 | Pulse — Self-Report | — | Guide |
| 75 | Pulse — AI Read | — | Guide |
| 76 | Pulse — Next Week Focus | — | Guide |
| 13* | Turn Results (Enhanced) | Turn | Guide + Turn |
| 19* | Mirror Reflection (Enhanced) | Mirror | Guide + Mirror |

View File

@@ -0,0 +1,374 @@
# The Mirror — Kalei's Notebook Feature
## Scientific Foundation
The Mirror is Kalei's most direct application of attention and neuroscience research.
**Selective Attention as the Core Mechanism:** Yantis (2008) showed that selective attention operates through modulatory signals that amplify relevant information and suppress irrelevant inputs. The Mirror externalizes this process — Kalei's AI acts as an attentional amplifier, highlighting cognitive patterns the user's own system has habituated to and stopped noticing. The highlighted fragments aren't new information; they're existing patterns made visible through redirected attention.
**Attention Is Trainable:** Stevens & Bavelier (2012) demonstrated that attentional control improves with practice and transfers across domains. Regular Mirror use trains the user to notice their own cognitive distortions — first with AI assistance, eventually independently. The Spectrum's "self-correction rate" metric (Phase 2) directly measures this training effect.
**Attention vs. Consciousness:** Koch & Tsuchiya's distinction between attention and consciousness is operationally important. The Mirror works at the attention level: it doesn't require the user to be consciously aware of their patterns (consciousness) — it simply redirects attention toward them. The conscious recognition follows naturally.
**Habit Formation Through Consistent Practice:** Wood & Neal (2007) showed that habits form through context-response associations. Regular Mirror sessions — anchored to consistent contexts (time of day, emotional state) — train the habit of reflective self-examination until it becomes automatic.
---
---
## The Concept
The Kaleidoscope (Turn) is structured: one fragment in, patterns out. It works when you **know** what's bothering you.
But most of the time, people don't. They're carrying a vague heaviness — a bad day, an argument replaying in their head, a worry they can't articulate. They don't need a tool yet. They need a space to **think out loud** first.
**The Mirror** is that space.
It's a freeform notebook with a chat-like interface where you write whatever's on your mind — stream of consciousness, venting, processing. As you write, Kalei's AI reads along quietly and does two things:
1. **Highlights fragments** — gently underlines or marks phrases that carry negative cognitive patterns (catastrophizing, black-and-white thinking, personalization, fortune-telling, etc.)
2. **Offers to Turn them** — tapping a highlighted fragment opens a mini-reframe inline, without leaving the flow of writing
You're not journaling into a void. You're writing into a mirror that reflects back what you can't see yourself.
---
## Why "The Mirror"
A kaleidoscope is built from mirrors. The mirrors are what create the symmetry — what take a random fragment and reveal the pattern. Without the mirrors, it's just broken glass.
The Mirror feature is the reflective surface of Kalei. The Kaleidoscope (Turn) is the active tool. The Mirror is the quiet awareness that makes the tool work.
**Metaphor alignment:**
- You write freely → you're pouring fragments onto the table
- Kalei highlights patterns → the mirror reflects back what you couldn't see
- You tap to reframe → you choose which fragments to Turn
- The session becomes a Reflection → saved to your Gallery with its own pattern
---
## How It Works — User Flow
### Entry Point
The Mirror lives as the **fifth element** in the app's navigation, or as a secondary action within the Turn tab. Two options:
**Option A — Dedicated tab (recommended):**
| Icon | Label | Function |
|------|-------|----------|
| ◇ | **Turn** | Quick structured reframe |
| ✦ | **Mirror** | Freeform notebook with AI awareness |
| ◎ | **Lens** | Manifestation Engine |
| ▦ | **Gallery** | History of patterns and reflections |
| ● | **You** | Profile and settings |
**Option B — Nested under Turn:**
Turn tab has two modes: "Quick Turn" (current structured input) and "Open Mirror" (freeform). Toggle at top.
**Recommendation:** Option A. The Mirror is different enough in intent and behavior that it deserves its own space. Users will develop separate habits — quick Turns for specific thoughts, Mirror sessions for processing.
### The Writing Experience
**Visual:** Chat-style interface. The user's messages appear as bubbles or blocks on one side. Clean, minimal, dark background consistent with Kalei's aesthetic. No AI responses appear unprompted — the AI is **listening**, not talking.
**Prompt on empty state:**
> "Start writing. Say whatever's on your mind. I'll listen."
> *Kalei will gently highlight patterns it notices. You decide what to do with them.*
**User writes freely.** They can send multiple messages in sequence, like texting a friend or writing in a stream. No character limits. No structure required. Just write.
### The Highlighting — "Fragment Detection"
As the user writes (or after each message is sent), Kalei's AI analyzes the text for **cognitive distortion patterns** — the same patterns that cognitive behavioral therapy identifies as drivers of negative thinking:
| Distortion | Example | What Kalei detects |
|---|---|---|
| Catastrophizing | "This is going to ruin everything" | Absolutist prediction language |
| Black-and-white thinking | "I always fail at this" | Always/never, all-or-nothing |
| Mind reading | "They probably think I'm an idiot" | Assuming others' thoughts |
| Fortune telling | "This will never get better" | Predicting negative outcomes |
| Personalization | "It's all my fault" | Taking undue responsibility |
| Discounting positives | "That win was just luck" | Minimizing good things |
| Emotional reasoning | "I feel like a failure so I must be one" | Feelings presented as facts |
| Should statements | "I should be further along by now" | Rigid self-imposed rules |
| Labeling | "I'm such a loser" | Identity-level negative labels |
| Overgeneralization | "Nothing ever works out for me" | One event → universal pattern |
**How highlighting appears:**
- Detected phrases get a **subtle underline or soft glow** in a warm amber/gold color — the color of light catching a fragment
- The highlight is gentle, not aggressive. It shouldn't feel like a red pen correcting homework. It should feel like sunlight falling on a piece of glass — drawing attention naturally
- A small **◇ icon** (fragment symbol) appears at the end of the highlighted phrase, indicating this fragment can be Turned
- Highlights appear **after the user finishes a message** (not while typing — that would be intrusive and anxiety-inducing)
**Critical UX principle:** The highlighting must feel like **noticing**, not **judging**. The AI is a mirror, not a critic. The user should feel seen, not corrected. This distinction is scientifically grounded — Bandura (1977) showed that perceived criticism undermines self-efficacy, while neutral observation preserves it. The Mirror builds capability awareness, not self-judgment.
### Tapping a Fragment — Inline Reframing
When the user taps a highlighted fragment:
1. A **mini-card slides up** from below (half-sheet modal, not full screen — user can still see their writing above)
2. The card shows:
- The original fragment, quoted
- The cognitive pattern name in plain language (e.g., "This sounds like catastrophizing — predicting the worst outcome")
- **12 reframed alternatives** — shorter and lighter than a full Turn, designed for quick insight
- A "Full Turn" button if they want to take this fragment into the Kaleidoscope for deeper exploration
- A "Dismiss" option — user can say "I see it, moving on" without reframing
**Example interaction:**
> **User writes:** "Had a terrible meeting today. My manager barely acknowledged my presentation. She probably thinks I'm not cut out for this role. I should just start looking for another job."
> **Kalei highlights:** "She probably thinks I'm not cut out for this role"
> **User taps the highlight. Card appears:**
> **◇ Fragment detected**
> *"She probably thinks I'm not cut out for this role"*
>
> This looks like **mind reading** — assuming someone else's thoughts without evidence.
>
> **A different angle:**
> There are many reasons a manager might seem distracted that have nothing to do with your performance. What you observed was her behavior. What she thinks is something you don't have access to yet — but you could ask.
>
> **[Full Turn ◇]** · **[Dismiss]**
### The AI's Role — Passive, Not Conversational
**This is critical.** The Mirror is NOT a chatbot. The AI does not:
- Respond to every message
- Ask follow-up questions unprompted
- Inject unsolicited advice
- Break the user's flow with interjections
The AI **only** does three things:
1. Highlights fragments (passively, after each message)
2. Provides reframes when the user taps a highlight (on demand)
3. Generates a session summary when the user ends the session (see below)
**Why not make it a chatbot?** Because the whole point is that the user is thinking out loud. Inserting AI responses between every message turns it into a conversation with a bot, which changes the psychology entirely. The user stops introspecting and starts performing. The Mirror should feel like writing in a journal that occasionally catches the light — not like talking to a therapist.
**Exception — The Nudge:** If the user has written 5+ messages with zero taps on any highlights and significant negative patterns are accumulating, Kalei can offer ONE gentle nudge at the end of the stream:
> "I noticed a few fragments in what you wrote. Want to look at them together?"
> **[Show me]** · **[Not now]**
This is the only time the AI initiates. Once per session maximum.
---
## Session Wrap-Up — The Reflection
When the user signals they're done writing (closes the Mirror, presses a "Done" button, or after a period of inactivity), Kalei generates a **Reflection** — a brief session summary.
**The Reflection includes:**
1. **The Mosaic** — a high-level summary of what the user wrote about (themes, not specifics)
> "Today's Mirror covered: work frustration, self-doubt about career, and a conflict with your manager."
2. **Fragments Found** — count of cognitive patterns detected
> "4 fragments noticed. You explored 2 of them."
3. **Patterns Revealed** — the reframes the user chose to engage with
> "You looked at mind reading and catastrophizing from new angles."
4. **A Generated Pattern** — a unique kaleidoscope visual for this session, saved to the Gallery alongside their Turn patterns. Mirror sessions get their own visual style — perhaps slightly different geometry (softer, more organic) to distinguish them from structured Turns
5. **An optional one-line insight** — the AI's single most important observation from the session
> "You were hardest on yourself about things you haven't confirmed are true."
**The Reflection is saved to the Gallery** as a distinct type: a Mirror Reflection. Users can revisit their sessions, re-read what they wrote, see which fragments they explored, and track how their patterns evolve over time.
---
## Where the Mirror Fits in the User's Journey
The three core features now form a **progression**:
```
THE MIRROR THE KALEIDOSCOPE THE LENS
(Awareness) → (Perspective) → (Direction)
"What am I "How else can I "What am I
feeling?" see this?" building toward?"
Freeform Structured Goal-focused
writing reframing manifestation
Fragments Fragments → Patterns Patterns → Focus
detected revealed applied
```
**The natural user flow:**
1. **Mirror** — User dumps their raw thoughts. AI highlights the fragments they can't see themselves
2. **Turn** — User takes the most charged fragment and gives it a full Turn in the Kaleidoscope, getting deep, multi-angle reframes
3. **Lens** — The insights from reframing inform the user's goals. What they thought was a setback becomes fuel for what they're building toward
Not every session follows this sequence. Some days you just need a quick Turn. Some days you just need to write in the Mirror. Some days you go straight to the Lens. But when a user does flow through all three, that's the **Kalei experience** at its deepest.
---
## Engagement & Retention Mechanics
### Mirror Streaks
Track separately from Turn streaks:
- "You've written in the Mirror 5 days in a row"
- Mirror sessions tend to be longer and more personal → higher engagement signal
**Science note:** Wood et al. (2021) found that context stability is the single biggest predictor of habit formation. Mirror streaks should track not just frequency but context consistency — "You've written in the Mirror at roughly the same time for 14 days" is a stronger habit signal than "14 sessions total across random times."
### Fragment Tracking Over Time
The Gallery can show **fragment patterns over time**:
- "This month, your most common fragment type was **should statements**"
- "You've reduced catastrophizing by 40% compared to last month"
- A visual "spectrum" chart showing which cognitive distortions appear most frequently
This turns the Mirror from a journal into a **self-awareness engine**. Users can literally see their thinking patterns change over time.
**Science note:** This longitudinal tracking implements Stevens & Bavelier's (2012) finding that attention training transfers and compounds. The fragment density decline over time is a measurable proxy for improved attentional self-awareness — the user is literally catching patterns earlier and more often because their attentional system has been retrained.
### Mirror Prompts
For days when the user opens the Mirror but doesn't know what to write:
- "What happened today that you're still thinking about?"
- "What would you say to a friend if they were feeling what you're feeling?"
- "What's one thing you're avoiding thinking about?"
- "Describe your mood in a sentence. Then ask yourself why."
These are optional, dismissible, and only shown on empty-state.
---
## Monetization Placement
| Feature | Free (Kalei) | Premium (Kalei Prism) |
|---|---|---|
| Mirror access | 2 sessions/week | Unlimited |
| Fragment highlighting | Basic (3 distortion types) | Full spectrum (all 10 types) |
| Inline reframes | 1 per session | Unlimited |
| Session Reflections | Summary only | Full Reflection with insight |
| Fragment tracking over time | ✗ | ✓ |
| Export Mirror sessions | ✗ | ✓ |
The free tier gives enough Mirror access to experience the value. The paywall hits at the point where the user wants **depth and consistency** — which is exactly when they're most likely to convert.
---
## Technical Implementation Notes
### AI Processing Pipeline
Each message the user sends in the Mirror triggers a lightweight AI analysis:
```
User message → Claude API call → Returns:
{
"fragments": [
{
"text": "She probably thinks I'm not cut out for this role",
"start_index": 89,
"end_index": 143,
"distortion_type": "mind_reading",
"distortion_label": "Mind reading",
"distortion_description": "Assuming someone else's thoughts without evidence",
"confidence": 0.87
}
]
}
```
**Confidence threshold:** Only highlight fragments with confidence > 0.75 to avoid false positives. A false positive (highlighting something that isn't actually distorted thinking) would erode trust quickly.
**Latency:** Analysis should complete within 12 seconds after message sent. Highlights appear with a subtle fade-in animation — fragments "catching the light."
### Reframe Generation (On Tap)
When user taps a highlighted fragment, a second API call generates the inline reframe:
```
Input: fragment text + surrounding context + distortion type
Output: {
"distortion_explanation": "Plain language explanation",
"reframe": "1-2 sentence alternative perspective",
"full_turn_prompt": "Pre-filled prompt for Kaleidoscope if user wants deeper exploration"
}
```
### Data Storage
Mirror sessions stored in Supabase:
```sql
-- Mirror sessions table
CREATE TABLE mirror_sessions (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
user_id UUID REFERENCES users(id),
started_at TIMESTAMPTZ DEFAULT NOW(),
ended_at TIMESTAMPTZ,
reflection_summary TEXT,
reflection_insight TEXT,
pattern_seed TEXT, -- for generating the visual pattern
created_at TIMESTAMPTZ DEFAULT NOW()
);
-- Mirror messages table
CREATE TABLE mirror_messages (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
session_id UUID REFERENCES mirror_sessions(id),
content TEXT NOT NULL,
sequence_order INTEGER,
created_at TIMESTAMPTZ DEFAULT NOW()
);
-- Detected fragments within messages
CREATE TABLE mirror_fragments (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
message_id UUID REFERENCES mirror_messages(id),
fragment_text TEXT NOT NULL,
start_index INTEGER,
end_index INTEGER,
distortion_type VARCHAR(50),
confidence FLOAT,
was_tapped BOOLEAN DEFAULT FALSE,
was_reframed BOOLEAN DEFAULT FALSE,
reframe_text TEXT,
created_at TIMESTAMPTZ DEFAULT NOW()
);
```
### Privacy & Sensitivity
Mirror content is the most personal data in the app. Requirements:
- **End-to-end encryption** for all Mirror content at rest
- **No Mirror content used for model training** — explicit policy
- **Local-first option** (future): Allow users to keep Mirror data on-device only
- **Easy deletion**: User can delete any session or all Mirror data
- **Content safety**: If AI detects crisis language (self-harm, suicidal ideation), surface crisis resources immediately — not as a highlight/reframe, but as a dedicated intervention with hotline numbers and a warm handoff message
---
## Updated App Structure
With the Mirror, Kalei now has three pillars that map to a complete mental model:
| Pillar | Feature | Metaphor | User need | Interaction style |
|--------|---------|----------|-----------|-------------------|
| **Awareness** | The Mirror | Reflective surface that shows you your fragments | "I need to process" | Freeform writing, passive AI |
| **Perspective** | The Kaleidoscope | The turn that reveals patterns in fragments | "I need to see this differently" | Structured input → output |
| **Direction** | The Lens | Focused vision toward what you're building | "I need to move forward" | Goal setting, affirmations, tracking |
**Together:** You become aware of your patterns (Mirror), you learn to see them differently (Kaleidoscope), and you channel that clarity into what you're building (Lens).
**Tagline still holds:** *Same pieces. New angle.*
**Elevator pitch (updated):**
> "Kalei is a kaleidoscope for your mind. Write freely in the Mirror and Kalei gently highlights the negative thinking patterns you can't see yourself. Take any thought into the Kaleidoscope and see it from entirely new angles. Then focus your clarity through the Lens toward the goals that matter to you. Same pieces. New angle. That's Kalei."
---
*The mirror doesn't tell you what to see. It shows you what's already there.*

View File

@@ -0,0 +1,427 @@
# The Spectrum — Kalei v1
## Scientific Foundation
The Spectrum is where multiple research pillars converge into a single intelligence layer.
**Expectation Effects (Stetler 2014, Pardo-Cabello et al. 2022):** The Turn Impact component ("Before & After") is a deliberate evidence engine. Stetler demonstrated that consistent adherence to a process reinforces positive expectations, which in turn improve outcomes — a documented feedback loop. By showing users concrete proof that reframing measurably shifts their subsequent emotional state, the Spectrum accelerates this cycle. The transparency doesn't weaken the effect; it strengthens it.
**Habit Formation (Wood & Neal 2007, Wood et al. 2021):** Rhythm Detection and streak mechanics implement Wood's finding that ~43% of daily behavior is habitual and that context stability predicts habit formation. The Spectrum tracks context patterns (time-of-day rhythms, weekly cycles) to help users understand and leverage their own behavioral patterns.
**Selective Attention (Yantis 2008, Stevens & Bavelier 2012):** Fragment Pattern tracking ("Your Glass") operates the Mirror's attentional principle at a longitudinal scale. Instead of highlighting individual distortions in real-time, it reveals macro-patterns: which cognitive biases dominate, how they shift over time, and which respond most to reframing. This is attentional self-knowledge — seeing your own perceptual filters from the outside.
**Self-Efficacy (Bandura 1977):** The Growth Trajectory ("The Long View") directly implements Bandura's most potent self-efficacy source: mastery experiences. By tracking fragment density decline, self-correction rate, and reframe adoption, the Spectrum provides concrete evidence of growing capability — "You are getting better at this" backed by data, not platitudes.
---
## Emotional Intelligence, Not Mood Tracking
Every wellness app asks you to rate your mood on a scale. Tap a smiley face. Drag a slider. It's self-reported, inaccurate, and most people stop doing it after two weeks because it feels like homework.
Kalei doesn't need to ask how you feel. **It already knows.**
Over time, users accumulate weeks or months of Mirror sessions, Turns, and Lens activity. Every word they've written, every fragment detected, every pattern revealed, every reframe they saved or dismissed — it's all data. Rich, personal, longitudinal emotional data that the user generated naturally while using features they already love.
The Spectrum turns that data into **self-knowledge**.
---
## Why "The Spectrum"
Light enters a prism and exits as a spectrum — the full range of colors that were always present but invisible to the naked eye. The Spectrum takes the raw light of your daily Kalei usage and separates it into its component colors so you can see what's really going on inside.
It also completes the optical metaphor system:
| Feature | Optical element | What it does |
|---------|----------------|--------------|
| The Mirror | Mirror | Reflects your thoughts back to you |
| The Kaleidoscope | Kaleidoscope | Rearranges fragments into patterns |
| The Lens | Lens | Focuses your vision on what's ahead |
| The Spectrum | Prism | Reveals the full range of what you're feeling |
---
## What The Spectrum Shows
### 1. The Emotional Landscape
A visual representation of your emotional state over time — not from self-reporting, but from **AI analysis of your Mirror sessions, Turns, and Lens check-ins.**
**How it works:**
Every Mirror message and Turn input is analyzed for emotional signatures across multiple dimensions:
- **Valence:** Positive ↔ Negative
- **Arousal:** Calm ↔ Activated
- **Certainty:** Confident ↔ Uncertain
- **Agency:** In control ↔ Helpless
- **Social orientation:** Connected ↔ Isolated
- **Temporal focus:** Past-dwelling ↔ Present ↔ Future-focused
These dimensions are plotted over time as a **flowing gradient visualization** — not a line chart, but a river of color that shifts and blends. Warm colors for activated states, cool for calm, dark for negative, bright for positive. The result looks like light passing through a prism: your emotional spectrum, laid out across days and weeks.
**The user sees:**
- The overall color/tone of their week at a glance
- Shifts and transitions (Tuesday was dark and activated → Wednesday calmed down after a Turn)
- Long-term trends (past month trending brighter, or a slow slide they hadn't noticed)
**What they don't see:** Numbers, scores, or ratings. The Spectrum is visual and intuitive, not clinical. You look at it and *feel* whether things are moving in the right direction.
### 2. Fragment Patterns — "Your Glass"
A breakdown of which cognitive distortion types appear most frequently in the user's writing.
**Visualization:** A faceted gem or crystal with different faces representing different distortion types. The larger the face, the more frequently that pattern appears. The gem evolves over time as patterns shift.
**Insights delivered in plain language:**
> "This month, **should statements** made up 34% of your fragments — up from 22% last month. You're putting more pressure on yourself than usual."
> "**Mind reading** dropped significantly since you started Turning those fragments. You assumed others' thoughts 8 times in January, only twice in February."
> "Your top 3 fragment types this month: catastrophizing, discounting positives, and black-and-white thinking."
**Why this matters:** Most people have 2-3 dominant cognitive distortions they don't know about. Seeing them named and tracked over time is genuinely transformative — it's the kind of insight you'd normally get after months of therapy.
### 3. Turn Impact — "Before & After"
Tracks the measurable effect of reframing on subsequent emotional state.
**How it works:**
The AI compares the emotional tone of Mirror sessions **before and after** a Turn:
- User writes in Mirror (frustrated, catastrophizing)
- User takes a fragment to the Kaleidoscope
- User writes in Mirror again later that day or the next day
- The Spectrum measures the shift
**What the user sees:**
> "After Turning a fragment, your next Mirror session is 62% more likely to show increased agency and reduced catastrophizing."
> "Your most impactful Turn this month was on Feb 3 — the shift in your writing afterward was significant."
> "Turns on work-related fragments have the strongest positive effect for you. Relationship fragments take 2-3 Turns before the shift shows up."
This is the **evidence engine** for Kalei's core thesis: that changing the angle actually changes how you feel. Users can see the proof in their own data.
**Science note:** This directly implements Stetler's (2014) adherence-expectation model. When users see measurable shifts in their own emotional data after Turns, it reinforces the expectation that reframing works — which increases future engagement and actual benefit. Pardo-Cabello et al. (2022) confirmed that the quality of the therapeutic relationship (or in Kalei's case, the app-user relationship) is the strongest predictor of whether expectation effects materialize. The Spectrum builds that trust through evidence.
### 4. Rhythm Detection — "Your Cycles"
Identifies recurring emotional patterns tied to time.
**Weekly rhythms:**
> "Your Mirror sessions on Mondays contain 3x more should statements than any other day."
> "Fridays tend to be your most positive writing days."
**Monthly rhythms:**
> "The last week of each month shows elevated anxiety patterns — possibly tied to deadlines or financial cycles."
**Event correlation (Lens integration):**
> "When you check in with your Lens goals in the morning, your afternoon Mirror sessions show 40% fewer negative fragments."
**Contextual patterns:**
> "After writing about [work] topics, catastrophizing spikes. After writing about [relationships], personalization is more common."
The user starts to see their emotional life as a **landscape with terrain** rather than random weather. Some hills are always there. Some valleys are seasonal. That awareness alone is a superpower.
**Science note:** Rhythm Detection operationalizes Wood et al.'s (2021) finding that habits are triggered by context cues. By revealing temporal patterns ("Mondays are heavy on should-statements"), the Spectrum helps users anticipate and prepare for predictable emotional terrain — turning reactive coping into proactive awareness.
### 5. Growth Trajectory — "The Long View"
The headline metric: **how is this person's relationship with their own thinking changing over time?**
**Tracked indicators:**
- Fragment density: How many distortions per 100 words in Mirror sessions (trending down = growth)
- Self-correction rate: How often the user identifies their own fragments before Kalei highlights them (measured by editing/deleting mid-message)
- Reframe adoption: How often saved patterns from Turns echo in subsequent Mirror writing (user naturally using new perspectives)
- Distortion diversity: Whether the user is getting stuck on one pattern or successfully addressing multiple types
- Turn-to-insight ratio: How many Turns result in a saved keepsake vs. dismissed patterns
**Visualization:** A single, evolving kaleidoscope pattern that represents your overall growth. The more you use Kalei, the more complex, colorful, and beautiful the pattern becomes. At month 1, it might be simple and muted. At month 6, it's intricate and vivid.
This becomes the **centerpiece of the Spectrum dashboard** — your personal growth, visualized as a living kaleidoscope pattern.
**Science note:** Every tracked indicator maps to Bandura's (1977) self-efficacy sources. Fragment density decline and self-correction rate are mastery experiences (the strongest efficacy source). Reframe adoption shows vicarious learning internalized. The evolving pattern visualization provides a visceral, non-numerical representation of growing capability — "I am getting better at this" made visible.
**Milestone moments:**
> "Your fragment density has dropped 30% since you started. You're catching your own patterns now."
> "This week, you naturally reframed a catastrophizing thought in your Mirror session without needing a Turn. That's new."
> "You've explored all 10 fragment types. You're seeing the full spectrum."
---
## The Spectrum Dashboard — Layout
### Top Section: The River
Your emotional landscape as a flowing color gradient. Swipe horizontally to scroll through time. Tap any point to see the Mirror session or Turn from that day.
### Middle Section: Your Glass
The faceted gem visualization showing fragment type distribution. Toggle between "This week," "This month," "All time." Tap any facet for the distortion deep-dive.
### Bottom Section: Insights Feed
A scrollable feed of AI-generated insights, refreshed weekly. Each insight is a card with:
- A one-line observation
- Supporting data (subtle, not overwhelming)
- An action suggestion when relevant
### Floating Element: Your Pattern
Your evolving kaleidoscope pattern, accessible from the top corner. Tap to expand full-screen. Shareable as a "growth snapshot."
---
## When Insights Are Delivered
The Spectrum doesn't bombard users with data. Insights surface at natural moments:
### Weekly Reflection (Push Notification)
Every Sunday evening (or user-configured day):
> "Your Spectrum updated. See what this week's light revealed. 🔮"
Opens to a **Weekly Spectrum Summary:**
- Dominant emotional color this week
- Top fragment type
- Most impactful Turn
- One insight
- The week's addition to your evolving pattern
### Monthly Deep Dive
First of each month:
> "January's Spectrum is ready. See how your light shifted."
A richer summary with month-over-month comparisons, rhythm detection insights, and growth trajectory updates.
### In-Context Nudges
Subtle, non-intrusive insights surfaced within other features:
- In the Mirror: "You've used the phrase 'I should' 4 times this session. That's a pattern worth noticing."
- After a Turn: "This is the 3rd time you've Turned a work-related fragment this week. The Spectrum can show you more about this pattern."
- In the Lens: "Your Lens focus on [career growth] aligns with the fragments you've been processing. You're working on the right things."
---
## Monetization
The Spectrum is a **Kalei Prism exclusive feature**. It's the single strongest reason to upgrade.
**Free tier gets:**
- A simplified weekly emotional summary (1 insight, no visualizations)
- Fragment type counts (basic numbers only)
- A teaser of what the full Spectrum shows: "Upgrade to see your full Spectrum"
**Prism tier gets:**
- Full Spectrum dashboard with all 5 sections
- Weekly and monthly deep dives
- Growth trajectory and evolving pattern
- Rhythm detection
- Turn impact analysis
- Export and sharing of Spectrum snapshots
**Upgrade CTA:**
> "You've written 47 Mirror sessions and completed 23 Turns. There's a story in that data. See your full Spectrum."
This is a natural paywall because the Spectrum **requires usage history to be valuable.** By the time a user has enough data for the Spectrum to be meaningful, they've already experienced Kalei's value through the free tier and are primed to convert.
---
## Privacy Architecture
The Spectrum analyzes deeply personal data. Trust is non-negotiable.
### Principles
1. **All analysis happens on aggregated patterns, never exposed raw content.** The Spectrum shows "your catastrophizing increased this week" — it never shows "you wrote 'my life is falling apart' on Tuesday"
2. **No Spectrum data leaves the user's account.** Not for model training, not for anonymized research, not for anything
3. **Users control the window.** They can exclude any Mirror session or Turn from Spectrum analysis. They can set the Spectrum to only analyze the last 30/60/90 days
4. **Full deletion.** "Reset my Spectrum" erases all analyzed data and starts fresh
5. **Transparency.** A "How this works" section explains exactly what the AI analyzes and what it doesn't
### Data Processing
Spectrum analysis runs as a **background job**, not in real-time:
- After each Mirror session ends, emotional dimensions are computed and stored as numerical vectors — not raw text
- Fragment types are already captured during Mirror sessions
- Weekly aggregation job runs to compute trends, rhythms, and insights
- The Spectrum dashboard reads from aggregated data only
```sql
-- Emotional analysis per Mirror session
CREATE TABLE spectrum_session_analysis (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
user_id UUID REFERENCES users(id),
session_id UUID REFERENCES mirror_sessions(id),
session_date DATE NOT NULL,
valence FLOAT, -- -1 (negative) to 1 (positive)
arousal FLOAT, -- -1 (calm) to 1 (activated)
certainty FLOAT, -- -1 (uncertain) to 1 (confident)
agency FLOAT, -- -1 (helpless) to 1 (in control)
social_orientation FLOAT, -- -1 (isolated) to 1 (connected)
temporal_focus FLOAT, -- -1 (past) to 0 (present) to 1 (future)
fragment_count INTEGER,
word_count INTEGER,
dominant_distortion VARCHAR(50),
created_at TIMESTAMPTZ DEFAULT NOW()
);
-- Emotional analysis per Turn
CREATE TABLE spectrum_turn_analysis (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
user_id UUID REFERENCES users(id),
turn_id UUID REFERENCES turns(id),
turn_date DATE NOT NULL,
pre_valence FLOAT, -- emotional state of input
post_valence FLOAT, -- emotional state after reframe engagement
distortion_type VARCHAR(50),
reframe_saved BOOLEAN,
topic_cluster VARCHAR(100),
created_at TIMESTAMPTZ DEFAULT NOW()
);
-- Weekly aggregated insights
CREATE TABLE spectrum_weekly (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
user_id UUID REFERENCES users(id),
week_start DATE NOT NULL,
avg_valence FLOAT,
avg_arousal FLOAT,
avg_agency FLOAT,
total_fragments INTEGER,
total_turns INTEGER,
total_mirror_sessions INTEGER,
dominant_distortion VARCHAR(50),
distortion_distribution JSONB, -- {"catastrophizing": 5, "mind_reading": 3, ...}
fragment_density FLOAT, -- fragments per 100 words
turn_impact_score FLOAT, -- measured shift after turns
insight_text TEXT, -- AI-generated weekly insight
created_at TIMESTAMPTZ DEFAULT NOW(),
UNIQUE(user_id, week_start)
);
-- Monthly deep dive
CREATE TABLE spectrum_monthly (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
user_id UUID REFERENCES users(id),
month_start DATE NOT NULL,
growth_score FLOAT, -- composite improvement metric
rhythm_insights JSONB, -- detected patterns tied to time
month_over_month_delta JSONB, -- comparison with previous month
top_fragment_types JSONB, -- ranked list
most_impactful_turn UUID, -- references turn with biggest shift
pattern_complexity_score FLOAT, -- drives evolving visual pattern
narrative_summary TEXT, -- AI-generated monthly narrative
created_at TIMESTAMPTZ DEFAULT NOW(),
UNIQUE(user_id, month_start)
);
```
---
## Notification Copy — Spectrum Voice
The Spectrum speaks with slightly more authority than other Kalei features — it has data behind it. But still warm, still poetic.
### Weekly
- "Your Spectrum shifted this week. Come see the colors."
- "7 days of fragments and patterns. Here's what the light reveals."
- "This week had a rhythm. The Spectrum caught it."
### Monthly
- "A month of Turns. Your Spectrum has a story to tell."
- "January's light, separated into its colors. Your monthly Spectrum is ready."
### Milestone Insights
- "First month of Spectrum data. Your baseline is set — now watch it evolve."
- "Your fragment density dropped below 5 per 100 words for the first time. You're catching yourself."
- "3 consecutive weeks of increasing agency in your writing. Something shifted."
- "You haven't catastrophized in 12 days. That's your longest streak."
### Growth Pattern Evolution
- "Your pattern grew a new layer this month. Tap to see it."
- "Remember your first pattern? Compare it to today's. Look how far you've come."
---
## The Spectrum as Retention Engine
The Spectrum solves the biggest problem in wellness apps: **the drop-off after the initial novelty fades.**
**Week 1-2:** Users are engaged with the Mirror and Kaleidoscope. Everything is new.
**Week 3-4:** Novelty fades. This is where most wellness apps lose people.
**With the Spectrum (timed with early user data accumulation):**
- "Your first Spectrum is ready" re-engages users with a new reason to open the app
- The evolving pattern creates **collection psychology** — users want to see it grow
- Weekly insights create a **recurring appointment** with the app
- Growth trajectory shows **concrete progress** — "this is working" evidence
- Fragment tracking creates **self-competition** — users try to beat their own patterns
- Monthly deep dives become **anticipated events** — not notifications to dismiss
The Spectrum turns Kalei from a tool you use when you feel bad into a **dashboard you check because you're curious about yourself.** That's the difference between reactive usage (declining) and proactive usage (compounding).
**Science note:** This retention mechanic is grounded in both habit formation and expectation effects. Wood et al. (2021) showed that shifting behavior from goal-directed (conscious, effortful) to habitual (automatic, context-triggered) is what sustains long-term change. Stetler (2014) showed that consistent engagement reinforces positive expectations. The Spectrum provides the evidence that keeps both loops spinning.
---
## Spectrum Rollout Sequence
### Pre-Launch (2 weeks before)
Notification to existing users:
> "You've completed [X] Turns and [Y] Mirror sessions. Something new is coming that turns all of that into self-knowledge. Stay tuned."
### Launch Day
> "The Spectrum is here. Every Turn you've taken, every fragment you've noticed — it all means something. See your full emotional landscape for the first time."
Open to a dramatic reveal of their personal Spectrum for the first time — the river visualization populating with their historical data, the gem forming its facets, the evolving pattern appearing.
This should be a **wow moment.** The user's own emotional history, visualized beautifully for the first time. Data they generated without thinking about it, now reflecting back as genuine self-knowledge.
### Post-Launch (ongoing)
Weekly and monthly cadence takes over. The Spectrum becomes a background engine that surfaces insights at the right moments and gives users a reason to maintain their Mirror and Turn habits.
---
## Updated Feature Map — Full Kalei Ecosystem
```
PHASE 1 PHASE 2
───────────────────────────────── ──────────────────────
THE MIRROR (Awareness) ──→ feeds data to ──→ THE SPECTRUM
Write freely (Intelligence)
AI highlights fragments See your patterns
Inline reframes Track growth
Discover rhythms
THE KALEIDOSCOPE (Perspective) ──→ feeds data to ──→ Measure impact
Structured reframing Evolving visual
Fragment → Patterns
Save keepsakes
THE LENS (Direction) ──→ informed by ──→
Goal setting
Daily affirmations
Vision tracking
◇ ◇
Kalei Free Kalei Prism
3 Turns/day Unlimited everything
2 Mirror/week + Full Spectrum
Basic Lens + Weekly/monthly insights
+ Growth trajectory
+ Fragment analytics
```
---
*White light looks simple. The Spectrum shows you everything it's made of.*