// types/Profile.ts export interface ScoredValue { value: T; confidence: number; // 0 to 1 } export interface Profile { profile_id: string; tenant_id: string; // unique identifier for the tenant status: "processing" | "summarizing" | "ready"; core_info?: { name?: ScoredValue; age?: ScoredValue; gender?: ScoredValue; location?: ScoredValue; language?: ScoredValue; }; interests?: { hobbies?: ScoredValue[]; music?: ScoredValue[]; food?: ScoredValue[]; books?: ScoredValue[]; movies?: ScoredValue[]; sports?: ScoredValue[]; travel?: ScoredValue[]; technology?: ScoredValue[]; art?: ScoredValue[]; gaming?: ScoredValue[]; fashion?: ScoredValue[]; fitness?: ScoredValue[]; pets?: ScoredValue[]; other?: ScoredValue[]; }; personality?: { traits?: ScoredValue[]; mood_trends?: { default?: ScoredValue; recent?: ScoredValue; }; }; memories?: { event: string; date?: string; importance?: "low" | "medium" | "high"; confidence?: number; }[]; preferences?: { conversation_style?: ScoredValue; topics_to_avoid?: ScoredValue[]; }; field_timestamps?: { [section: string]: string; // ISO timestamp }; update_log?: { extracted_on: string; changes: Partial; }[]; last_updated: Date; created_at: Date; // ISO timestamp summary?: string; // optional summary of the profile }