How codexuf/meetscribeai works
1. Overall shape
- MeetScribe is a Next.js App Router application in TypeScript.
- It has two main surfaces: a public marketing/auth area and a protected dashboard/workspace for meeting management, transcription, and AI-assisted review.
2. Frontend route structure
- Public pages live under app/ such as landing (app/page.tsx), about, contact, help, FAQs, team, and auth sign-in/sign-up.
- The authenticated product UI lives under app/dashboard/*, including meetings, analytics, calendar, settings, new meeting, and transcription detail pages.
- app/layout.tsx, app/globals.css, Tailwind, and the components/ui library provide the shared app shell and design system.
3. Primary user workflow
- A user signs in, lands in the dashboard, creates or opens a meeting, records or uploads audio, generates transcription, reviews speaker-labeled segments, and then requests AI summaries or chat interactions.
- This workflow is reflected in the page hierarchy and the dedicated API routes for audio, transcription, meetings, AI chat, and summaries.
4. API layer as the backend boundary
- The backend is implemented as Next.js route handlers under app/api/*.
- These routes are grouped by domain: auth, users, meetings, audio, transcription, ai-summary, ai-chat, embeddings, stats, and send-email.
- The API layer is the main boundary between the browser UI and all persistence/AI/storage services.
5. Domain controllers
- Business logic is separated into controllers/* for auth, meetings, users, and AI chat/summary.
- This suggests a thin route-handler layer that delegates to domain controllers rather than embedding logic directly in each endpoint.
- For architecture diagrams, these controllers are the service layer between route handlers and data/integration libraries.
6. Data model and persistence
- MongoDB with Mongoose is the primary system of record, with models for User, Meeting, and AiChatSummary.
- Meeting records likely store transcript metadata, speaker mappings, media references, and generated AI artifacts.
- scripts/seed-database.js indicates a seeded demo dataset used for local exploration and onboarding.
7. AI and retrieval subsystem
- lib/gemini.ts, lib/embedding-service.ts, and app/api/embeddings/generate indicate AI-powered generation and vectorization.
- OpenAI is used for chat/summaries/embeddings according to the README, while Pinecone serves as the vector store for semantic retrieval.
- The AI chat flow appears meeting-scoped, with app/api/ai-chat/[meetingId] and a download endpoint for exporting results.
8. Audio and transcription pipeline
- Audio handling is split into start-recording, stop-recording, upload, and delete endpoints.
- Transcription has its own generation path plus export/copy/download routes, which implies a lifecycle of capture → upload/store → transcription generation → review/export.
- The README identifies AssemblyAI as the transcription service, so transcription is an external integration rather than an in-app model.
9. File/media and external services
- lib/cloudinary.ts shows Cloudinary is used for file storage, likely for audio assets and/or derived media.
- lib/mongodb.ts centralizes the database connection, while lib/pinecone.ts connects the retrieval layer to the vector database.
- app/api/send-email uses Resend for notifications/sharing, making email a separate outbound integration.
10. Authentication and access control
- Authentication is custom session-based, with routes for login, logout, and “me”.
- middleware.ts likely protects dashboard/API access and enforces authenticated navigation.
- context/UserContext.tsx suggests the client keeps current-user state in a shared context for UI personalization and authorization-aware rendering.
11. Dashboard subsystem
- components/dashboard/* contains the navigation shell, header, meeting cards, and stats widgets used across the authenticated area.
- app/dashboard/meetings, analytics, calendar, settings, and transcriptions are the main operational views, centered on meeting lifecycle management and insight display.
- components/modals/* handles common actions like upload, edit speaker, delete meeting, and transcription viewing.
12. Transcription review UX
- components/transcription/* provides the specialized transcript editor/player experience, including audio playback, speaker selection, and per-segment rendering.
- The route app/dashboard/transcriptions/[id] is the detailed review screen for a single meeting transcript.
- This is the main human-in-the-loop boundary where automated transcription and speaker identification are corrected or reviewed.
13. Analytics and stats
- app/api/stats/[userId] and the analytics dashboard indicate usage metrics are derived from persisted meeting/user data.
- components/dashboard/meeting-stats.tsx likely visualizes operational KPIs such as meeting counts, transcription usage, or generated summaries.
- Analytics appears to be an internal reporting subsystem rather than a separate service.
14. Implementation style and reusable UI
- The project uses a broad components/ui library based on shadcn/ui primitives, with Tailwind CSS driving styling.
- Shared helpers live in lib/utils.ts, lib/toast.ts, and client hooks under hooks/*.
- Overall, the architecture is a fairly standard Next.js monolith with clear separation between presentation, API routes, domain controllers, persistent models, and third-party AI/storage integrations.
Main entry points: page.tsx Dashboard shell · api Route handlers · authController.ts Controllers · layout.tsx App shell
Components 22
Frontend
Public site and authenticated dashboard UI
- App shell · Root layout, globals, and shared page framing
app/layout.tsx - Marketing site · Landing and informational pages for visitors
app/page.tsx - Auth pages · Public authentication entry points
app/auth/sign-in/page.tsx - Dashboard shell · Authenticated workspace and route group
app/dashboard/page.tsx - Meetings · Meeting list, creation, calendar, and settings
app/dashboard/meetings/page.tsx - Transcript review · Single transcript review and playback experience
app/dashboard/transcriptions/[id]/page.tsx - UI system · Reusable shadcn-style primitives and shared components
components/ui/button.tsx - Dashboard UI · Navigation, cards, stats, and dashboard chrome
components/dashboard/dashboard-header.tsx - Transcript UI · Audio player, speaker picker, and segment rendering
components/transcription/audio-player.tsx - User state · Client-side user context and shared UI hooks
context/UserContext.tsx
API layer
Next.js route handlers and request boundary
- Route handlers · HTTP boundary for auth, meetings, audio, AI, stats, and email
app/api - Auth API · Login, logout, and current-user session routes
app/api/auth/login/route.ts - Meeting API · CRUD and speaker management for meetings
app/api/meetings/route.ts - Audio pipeline API · Record, upload, delete, and transcription lifecycle routes
app/api/audio/upload/route.ts - AI API · Chat, summary, embeddings, and export routes
app/api/ai-chat/[meetingId]/route.ts - Stats & email API · Usage analytics and notification/sharing routes
app/api/stats/[userId]/route.ts
Domain services
Controllers, models, and shared app state
- Controllers · Business logic for auth, meetings, users, and AI workflows
controllers/authController.ts - Data models · User, meeting, and AI chat summary persistence
models/User.ts
Infra & integrations
Database, AI, storage, and external services
- App services · Audio, Gemini, embeddings, toast, and utility helpers
lib/gemini.ts - MongoDB · Mongoose-backed primary persistence layer
lib/mongodb.ts - Pinecone · Semantic retrieval store for embeddings
lib/pinecone.ts - AI & storage · OpenAI/Gemini, AssemblyAI, Cloudinary, and Resend integrations
lib/cloudinary.ts
Connections 25
- App shell → Marketing site: renders · Shared layout frames public pages
- App shell → Auth pages: renders · Shared layout frames auth pages
- App shell → Dashboard shell: renders · Shared layout frames authenticated workspace
- Dashboard shell → Meetings: navigates · Dashboard routes expose meeting operations
- Dashboard shell → Transcript review: navigates · Dashboard routes expose transcript review
- Dashboard shell → Dashboard UI: composes · Dashboard shell is built from shared chrome
- Transcript review → Transcript UI: uses · Transcript page uses specialized playback and segment UI
- Dashboard shell → UI system: uses · Workspace UI is assembled from shared primitives
- Marketing site → UI system: uses · Public pages use the same design system
- Route handlers → Auth API: contains · Auth routes are implemented as Next.js handlers
- Route handlers → Meeting API: contains · Meeting routes are implemented as Next.js handlers
- Route handlers → Audio pipeline API: contains · Media and transcript lifecycle routes live here
- Route handlers → AI API: contains · AI generation and export routes live here
- Route handlers → Stats & email API: contains · Reporting and outbound email routes live here
- Auth API → Controllers: delegates · Session handling delegates business logic to controllers
- Meeting API → Controllers: delegates · Meeting CRUD delegates business logic to controllers
- AI API → Controllers: delegates · Chat and summary routes delegate to AI controllers
- Controllers → Data models: persists · Controllers read and write domain records
- Controllers → MongoDB: connects · Controllers rely on MongoDB via Mongoose models
- App services → AI & storage: integrates · Shared libs wrap third-party AI, media, and email services
- App services → Pinecone: integrates · Embedding service connects to the vector database
- AI API → App services: uses · AI routes use Gemini, embeddings, and helper utilities
- Audio pipeline API → AI & storage: integrates · Audio and transcription workflows depend on external services
- Stats & email API → AI & storage: integrates · Email delivery and outbound notifications use external services
- User state → Dashboard shell: supports · Shared user state powers authenticated UI