Skip to content

Feat: Add settings page with integration and relationship configuration (Phase 2)#241

Closed
jhodapp wants to merge 7 commits intomainfrom
feature/146-ai-meeting-integration-phase2-settings
Closed

Feat: Add settings page with integration and relationship configuration (Phase 2)#241
jhodapp wants to merge 7 commits intomainfrom
feature/146-ai-meeting-integration-phase2-settings

Conversation

@jhodapp
Copy link
Copy Markdown
Member

@jhodapp jhodapp commented Dec 20, 2025

Description

Add settings infrastructure for coach integration configuration and per-relationship AI privacy settings. This is Phase 2 of the AI Meeting Integration feature, building on the backend foundation from Phase 1.

GitHub Issue: Relates to #146

Changes

Settings Page & Routing:

  • Add /settings route with standard app layout (sidebar, header)
  • Create SettingsContainer with tabs for Integrations and Relationships
  • Role-aware access: coaches see full settings, coachees see their privacy preferences
  • Link Settings in user-nav dropdown menu

Integration Settings (Coach-only):

  • Google Account connection status display with OAuth flow trigger
  • Recall.ai API key input with save and verify functionality
  • AssemblyAI API key input with save and verify functionality
  • Status badges showing connection/verification state
  • Password-style inputs with show/hide toggle for API keys
  • Auto-approve AI suggestions toggle

Relationship Settings (Coach-only):

  • Per-coachee Google Meet URL configuration
  • Per-relationship AI privacy level selection with visual radio-style buttons:
    • Full (Default): All AI features enabled
    • Transcribe Only: Text transcription without video/audio storage
    • None: No AI features for privacy-conscious clients
  • Save changes button appears only when settings are modified

Coachee Relationship Settings (New):

  • Coachees can set their own AI privacy level preference
  • Dual consent model: effective privacy level is the minimum of coach and coachee settings
  • Clear explanation of what each privacy level means

Type Definitions:

  • Add AiPrivacyLevel enum to coaching-relationship types
  • Add coach_ai_privacy_level, coachee_ai_privacy_level, and effective_ai_privacy_level to CoachingRelationship interface
  • Add UserIntegration types with auto_approve_ai_suggestions field
  • Add MeetingRecording, Transcription, TranscriptSegment types
  • Add AiSuggestedItem types for AI-suggested actions/agreements
  • Add utility functions for duration/timestamp formatting

API Updates:

  • Add user-integrations API module with SWR hooks and update methods
  • Implement coaching relationship update method for meeting_url and privacy levels
  • Add updateAutoApprove method for AI suggestion auto-approval setting

Recent Changes

  • Added coachee relationship settings component for dual-consent privacy model
  • Added auto-approve AI suggestions toggle to integration settings
  • Updated types for dual privacy level support (coach + coachee)

Testing Strategy

  • Run npm run lint - passes with only one pre-existing warning
  • Run npx tsc --noEmit - passes with no errors
  • Navigate to /settings when logged in as a coach to see the settings page
  • Navigate to /settings when logged in as a coachee to see privacy preferences
  • Verify Settings link in user-nav dropdown navigates correctly

Concerns

  • Backend Dependency: This PR adds frontend UI that depends on backend endpoints. Integration settings require the backend integration endpoints to be deployed.
  • Google OAuth: The Google OAuth flow requires backend /oauth/google/authorize endpoint.
  • Cross-Repository: This PR works with the backend PRs which add the database schema, entity definitions, and API endpoints.

…on (Phase 2)

Add settings infrastructure for coach integration configuration and
per-relationship AI privacy settings:

Settings Page:
- Add /settings route with layout matching existing app structure
- SettingsContainer with Integrations and Relationships tabs
- Coach-only access (coachees see informational message)

Integration Settings (coach-only):
- Google Account connection status and OAuth flow trigger
- Recall.ai API key input with save and verify functionality
- AssemblyAI API key input with save and verify functionality
- Status badges showing connection/verification state

Relationship Settings (coach-only):
- Per-coachee Google Meet URL configuration
- Per-relationship AI privacy level selection:
  - Full: All AI features (recording, transcript, suggestions)
  - Transcribe Only: Text transcription without video/audio storage
  - None: No AI features for privacy-conscious clients
- Visual privacy level selector with icons and descriptions

Type Definitions:
- Add AiPrivacyLevel enum to coaching-relationship types
- Add meeting_url and ai_privacy_level to CoachingRelationship
- Add UserIntegration types for API credentials status
- Add MeetingRecording, Transcription, TranscriptSegment types
- Add AiSuggestedItem types for AI-suggested actions/agreements

API Updates:
- Add user-integrations API module with hooks
- Implement coaching relationship update for meeting_url and ai_privacy_level
- Link Settings in user-nav dropdown

Relates to: #146
Add frontend components for the AI meeting recording and transcription feature:

API Modules:
- meeting-recordings.ts: Recording start/stop, transcript fetching with polling
- ai-suggestions.ts: Accept/dismiss AI-detected actions and agreements

Components:
- meeting-controls.tsx: Join Meet button + Start/Stop recording controls
- session-transcript.tsx: Displays transcript with segments and AI suggestions
- transcript-segment.tsx: Single utterance with speaker label and sentiment
- session-summary.tsx: AI-generated session summary with empty state
- ai-suggestions-panel.tsx: Groups AI-detected actions/agreements
- ai-suggestion-card.tsx: Accept/dismiss card for individual suggestions

Integrations:
- Added Summary tab to coaching-tabs-container (4th tab after Actions)
- Added Transcript tab to overarching-goal-container with green dot indicator
- Added MeetingControls to coaching session page header

Relates to #146
- Add polling to transcript hooks for automatic updates (5s interval)
- Fix empty POST body type (null → {} for TypeScript compatibility)
- Unify user integrations API to single endpoint
- Simplify meeting controls header layout
- Create HeaderSessionSelector component that only renders on coaching session pages
- Add session selector to site header (left of theme toggle and user nav)
- Remove duplicate session selector from coaching session page
- Add polling (5s interval) to useAiSuggestions hook for automatic updates
- Increase width to w-64/md:w-72/lg:w-80 for better content display
- Remove restrictive pr-2 padding that clipped dropdown arrow
- Increase chevron icon size from h-4 to h-5 for better visibility
- Add shrink-0 to prevent icon compression
- Add Extract Actions/Agreements menu items to meeting controls
- Add coachee relationship settings for privacy level consent
- Add auto-approve AI suggestions toggle to integration settings
- Display AI extraction results (actions/agreements) in session summary
- Update coaching relationship types for dual privacy levels
- Add API functions for manual LeMUR extraction endpoints
@jhodapp jhodapp marked this pull request as draft December 24, 2025 18:36
@jhodapp jhodapp self-assigned this Dec 24, 2025
@jhodapp jhodapp added the prototype Prototyping a major new feature. label Dec 24, 2025
@jhodapp
Copy link
Copy Markdown
Member Author

jhodapp commented Dec 24, 2025

Consolidated into #243 - AI Meeting Recording Integration Frontend

@jhodapp jhodapp closed this Dec 24, 2025
@jhodapp jhodapp deleted the feature/146-ai-meeting-integration-phase2-settings branch December 24, 2025 18:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

prototype Prototyping a major new feature.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant