A structured conversation platform for emotionally difficult dialogues. Originally designed for families, now production-ready for enterprise teams β HR departments, managers, and workplace conflict resolution.
B2C (Free): A safe space for family conversations β structured turn-taking, trigger detection, and trauma-informed design.
B2B (Enterprise): Professional tools for HR teams, 1-on-1 check-ins, and conflict resolution β observer modes, compliance logging, and team health analytics.
v0 Release (Jan 2025): Production-ready for organizations with full analytics, transcription, and enterprise landing page.
| Feature | Status | Last Updated |
|---|---|---|
| Core Conversation | ||
| Turn-taking with configurable duration (60/90/120s) | β Working | Jan 2025 |
| Session creation/joining (6-char codes) | β Working | Dec 2024 |
| Real-time sync via Socket.io | β Working | Dec 2024 |
| Volume monitoring with auto-pause | β Working | Dec 2024 |
| Breathing exercise (synced, skippable) | β Working | Jan 2025 |
| Round control (unlimited/3/5) | β Working | Jan 2025 |
| End conversation button | β Working | Jan 2025 |
| Security & Reliability | ||
| Redis session persistence | β Working | Dec 2024 |
| Session reconnection | β Working | Dec 2024 |
| Zod input validation | β Working | Dec 2024 |
| Rate limiting (join: 10/min, create: 5/min) | β Working | Dec 2024 |
| Secure session codes (crypto) | β Working | Dec 2024 |
| Privacy consent flow | β Working | Jan 2025 |
| Microphone permission flow | β Working | Jan 2025 |
| Error boundaries | β Working | Jan 2025 |
| B2B Features | ||
| Observer mode | β Working | Jan 2025 |
| Admin dashboard | β Working | Jan 2025 |
| Check-in templates (10 workplace scenarios) | β Working | Jan 2025 |
| Speaking time tracking | β Working | Jan 2025 |
| PDF export | β Working | Jan 2025 |
| Audit logging | β Working | Jan 2025 |
| v0 Features | ||
| Real-time transcription (Deepgram) | β Ready | Jan 2025 |
| Speaker diarization | β Ready | Jan 2025 |
| Conversation health analytics | β Ready | Jan 2025 |
| User analytics dashboard | β Ready | Jan 2025 |
| Enterprise landing page | β Ready | Jan 2025 |
- Frontend: Next.js 16, React 19, TypeScript, Tailwind CSS, Framer Motion
- Backend: Socket.io, Redis (optional fallback to in-memory)
- AI: Claude API (Anthropic) with local fallbacks
- Transcription: Deepgram API (Nova-2 with diarization)
- State: Zustand
- Validation: Zod schemas
- Security: Node.js crypto module, rate limiting
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β CLIENT LAYER β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β Next.js App Web Audio API β
β βββββββββββββββββββ βββββββββββββββββββ β
β β React Componentsβ β Volume Monitor β β
β β Zustand Store β β Audio Streaming β β
β β Socket.io Clientβ ββββββββββ¬βββββββββ β
β ββββββββββ¬βββββββββ β β
β β β β
ββββββββββββββΌββββββββββββββββββββββββββββββββββΌββββββββββββββ
β β
βΌ βΌ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β SERVER LAYER β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β Socket.io Server Next.js API Deepgram β
β βββββββββββββββββββ βββββββββββββββββ ββββββββββ β
β β Session Mgmt β β /ai/trigger β β Nova-2 β β
β β Turn Control β β /ai/summarize β β WSS β β
β β Audit Logging β β /ai/prompt β ββββββββββ β
β β Rate Limiting β β /transcriptionβ β
β ββββββββββ¬βββββββββ βββββββββββββββββ β
β β β
ββββββββββββββΌββββββββββββββββββββββββββββββββββββββββββββββββ
β
βΌ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β DATA LAYER β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β Redis (Sessions) PostgreSQL (Analytics) β
β βββββββββββββββββββ βββββββββββββββββββ β
β β TTL: 24 hours β β Metrics β β
β β Session State β β Audit Logs β β
β β Participant Dataβ β Team Health β β
β βββββββββββββββββββ βββββββββββββββββββ β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
- Structured Turn-Taking: Configurable timers (60/90/120s) with visual cues
- Real-Time Volume Monitoring: Gentle alerts when voices rise
- Trigger Detection: AI-powered detection of blame language and escalation
- Reflection Prompts: Thoughtful prompts for perspective-taking
- Breathing Exercises: 4-7-8 breathing with sync (can be skipped)
- Conversation Summaries: Neutral, AI-generated summaries with private notes
- Observer Mode: HR/coaches can observe with participant consent
- Check-in Templates: 10 pre-built workplace scenarios (1-on-1s, conflict resolution, performance)
- Speaking Time Analytics: Visual % split with balance tracking
- PDF Export: Compliance-ready documentation
- Admin Dashboard: Session management and team oversight
- Audit Logging: Complete activity trail for compliance
- Conversation Health Scoring: Balance, regulation, engagement, safety metrics
- Real-Time Transcription: Deepgram Nova-2 with speaker diarization
- Trend Analysis: Track improvement over time
- Coaching Insights: AI-generated personalized recommendations
- Role-Based Access: Individuals see their data, managers see aggregates
- Redis Session Persistence: 24-hour TTL with secure fallback
- Cryptographic Security:
crypto.randomBytesfor all tokens - Input Validation: Zod schemas on all socket events
- Rate Limiting: Brute-force protection
- Privacy Consent Flow: GDPR-aligned opt-in
- Audit Trail: Immutable logging for compliance
- Node.js 18+
- npm or yarn
- Redis (optional)
git clone <repo>
cd mediator
npm install
cp .env.local.example .env.local# Required
NEXT_PUBLIC_SOCKET_URL=http://localhost:3001
SOCKET_PORT=3001
# AI Features (optional but recommended)
ANTHROPIC_API_KEY=your_anthropic_key
# Transcription (optional)
DEEPGRAM_API_KEY=your_deepgram_key
# Session Storage (optional, falls back to in-memory)
REDIS_URL=redis://localhost:6379
# Production
NEXT_PUBLIC_APP_URL=https://mediator.app
NODE_ENV=production# Run both servers (recommended)
npm run dev:all
# Or separately:
npm run dev # Next.js on :3000
npm run dev:socket # Socket.io on :3001| Route | Purpose |
|---|---|
/ |
Enterprise marketing landing page |
/demo |
Full conversation app (code-protected: MEDIATOR2025) |
/admin |
Admin dashboard |
/observer |
Observer join page |
src/
βββ app/ # Next.js app directory
β βββ api/
β β βββ ai/ # Claude AI endpoints
β β βββ transcription/ # Deepgram token endpoint
β βββ admin/ # Admin dashboard page
β βββ demo/ # Code-protected conversation app
β βββ observer/ # Observer join page
β βββ page.tsx # Enterprise landing page
βββ components/
β βββ admin/ # Admin dashboard components
β βββ analytics/ # Health scores, trends, insights
β βββ breathing/ # Breathing exercise
β βββ conversation/ # Main screens
β βββ observer/ # Observer mode components
β βββ onboarding/ # Privacy, mic permissions
β βββ templates/ # Check-in template selector
β βββ transcription/ # Real-time transcript UI
β βββ ui/ # Reusable components
βββ hooks/
β βββ useSocket.ts # Socket.io management
β βββ useVolumeMonitor.ts # Microphone volume
β βββ useTranscription.ts # Deepgram transcription
βββ lib/
β βββ ai.ts # AI helpers with fallbacks
β βββ analytics.ts # Metrics calculations
β βββ deepgram.ts # Transcription client
β βββ checkInTemplates.ts # B2B templates
β βββ pdfExport.ts # PDF generation
βββ store/
β βββ session.ts # Zustand state
βββ types/
βββ index.ts # TypeScript definitions
server.js # Socket.io server
V0-IMPLEMENTATION-PLAN.md # Detailed v0 specs
ROADMAP.md # Feature roadmap
| Use Case | Template | Target Buyer |
|---|---|---|
| Weekly 1-on-1s | weekly-1on1 |
Managers, HR |
| Conflict Resolution | conflict-resolution |
HR, Employee Relations |
| Performance Check-ins | performance-review |
Managers, HR |
| Stay Interviews | stay-interview |
HR, Retention Teams |
| Project Retrospectives | project-retro |
Engineering Managers |
| Feedback Exchange | feedback-exchange |
Teams, Peers |
| Career Development | career-development |
Managers, L&D |
| Onboarding Check-ins | onboarding-checkin |
Managers, HR |
| Return from Leave | return-from-leave |
HR, Managers |
| Difficult Conversations | difficult-conversation |
HR, Managers |
| Metric | Weight | Description |
|---|---|---|
| Communication Balance | 25% | Equal speaking time distribution |
| Emotional Regulation | 30% | Pause usage, trigger response |
| Engagement Depth | 20% | Turn duration, reflection engagement |
| Safety Indicator | 25% | Completion rate, trigger patterns |
| Role | Can See |
|---|---|
| Individual | Own metrics, own transcripts, personal trends |
| Manager | Team aggregates, anonymized patterns |
| HR Admin | Org-wide health, department comparisons |
- Soft colors, no harsh reds
- Invitational language ("Would you like to...")
- Always-visible exit options
- Reduced motion support
- Non-punitive framing
- Audio processed in real-time, never stored (unless transcription enabled)
- Private notes never synced to partner
- Individual metrics private by default
- Aggregation before sharing up the chain
- Workplace-appropriate language
- Consent-based observation
- Compliance-ready logging
- Growth-oriented analytics (not surveillance)
- SSL/TLS certificates configured
- CORS restricted to production domains
- Rate limiting tuned
- Redis instance configured
- Environment variables set
- Error tracking (Sentry) configured
- Load testing completed
- Accessibility audit passed
- Privacy policy published
- Terms of service published
- Cookie consent implemented
See ROADMAP.md for detailed task breakdowns and V0-IMPLEMENTATION-PLAN.md for v0 specifications.
MIT