Feature: Date night suggestions from cadence data (#46 slice 7) #53

Closed
opened 2026-05-30 14:15:55 +00:00 by Mark · 1 comment
Owner

Goal

Add date night suggestions to the metrics engine — "You haven't had a date night in 3 weeks" — leveraging the existing cadence detection and suggestion system.

Scope

  • Add new suggestion type date_night_suggestion to metrics engine
  • Detect when a romantic partner hasn't had a date night within their typical cadence
  • Suggestion message: "You haven't had a date night with {name} in X days"
  • Uses isDateNight flag from #48 and romanceFields from #47
  • Integrates with existing generateSuggestions / generateAllSuggestions pipeline
  • Quality rating trend: "Your last 3 date nights averaged 4.2 stars — keep it up"

Acceptance Criteria

  • Date night overdue suggestion generated when past cadence
  • Suggestion includes days since last date night
  • Quality rating trend included when enough date night history exists
  • Suggestions only appear for romantic-type partners with date nights enabled
  • Unit tests for new suggestion logic
  • Typecheck passes

Dependencies

  • Requires #47 (romantic relationship type + romanceFields)
  • Requires #48 (date night data on interactions)
  • Builds on metrics engine (#31)

Decomposed from #46

## Goal Add date night suggestions to the metrics engine — "You haven't had a date night in 3 weeks" — leveraging the existing cadence detection and suggestion system. ## Scope - Add new suggestion type `date_night_suggestion` to metrics engine - Detect when a romantic partner hasn't had a date night within their typical cadence - Suggestion message: "You haven't had a date night with {name} in X days" - Uses `isDateNight` flag from #48 and `romanceFields` from #47 - Integrates with existing `generateSuggestions` / `generateAllSuggestions` pipeline - Quality rating trend: "Your last 3 date nights averaged 4.2 stars — keep it up" ## Acceptance Criteria - [ ] Date night overdue suggestion generated when past cadence - [ ] Suggestion includes days since last date night - [ ] Quality rating trend included when enough date night history exists - [ ] Suggestions only appear for romantic-type partners with date nights enabled - [ ] Unit tests for new suggestion logic - [ ] Typecheck passes ## Dependencies - Requires #47 (romantic relationship type + romanceFields) - Requires #48 (date night data on interactions) - Builds on metrics engine (#31) --- _Decomposed from #46_
Author
Owner

Implementation Summary

Added date night suggestions feature that analyzes interaction cadence data for romantic partners.

Changes

src/lib/metrics-engine.ts:

  • Added getDateNightMetrics() function to extract date night stats from interactions
  • Added generateDateNightSuggestions() function that creates suggestions based on:
    • Days since last date night
    • Average quality rating trend (when 3+ rated date nights exist)
  • Integrated into generateSuggestions() - only applies to Romantic, Partner, or Spouse relationship types

src/lib/metrics-engine.test.ts:

  • Added 4 new tests:
    1. Suggests date night for romantic partner without recent date night
    2. Does not suggest date night for non-romantic partner
    3. Suggests date night with high priority when overdue by 30+ days
    4. Includes quality trend when enough rated date nights exist

Test Results

  • Total tests: 724 (4 new)
  • All tests pass
  • TypeScript compiles successfully
  • Lint passes
## Implementation Summary Added date night suggestions feature that analyzes interaction cadence data for romantic partners. ### Changes **src/lib/metrics-engine.ts**: - Added `getDateNightMetrics()` function to extract date night stats from interactions - Added `generateDateNightSuggestions()` function that creates suggestions based on: - Days since last date night - Average quality rating trend (when 3+ rated date nights exist) - Integrated into `generateSuggestions()` - only applies to Romantic, Partner, or Spouse relationship types **src/lib/metrics-engine.test.ts**: - Added 4 new tests: 1. Suggests date night for romantic partner without recent date night 2. Does not suggest date night for non-romantic partner 3. Suggests date night with high priority when overdue by 30+ days 4. Includes quality trend when enough rated date nights exist ### Test Results - Total tests: 724 (4 new) - All tests pass - TypeScript compiles successfully - Lint passes
Mark closed this issue 2026-05-30 21:49:52 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Mark/kimi_agent_kin_app_sync#53
No description provided.