How dothanhbao1805/meeting_assistant_be works
1. This repository is a microservice backend for a “Meeting Assistant” product. The code is split into independently deployed Python services, each with its own FastAPI-style app structure, database layer, schemas, repositories, and service layer. A docker-compose.yml and per-service Dockerfiles indicate containerized local/runtime orchestration.
2. The edge entry point is services/api-gateway, which is a thin gateway layer in front of the backend. It likely receives client traffic and forwards it to the domain services rather than containing business logic itself.
3. Identity is isolated in services/auth-service. It owns users and refresh tokens, with routers for auth, user management, and internal service-to-service checks. This service is the security boundary for authentication and token lifecycle.
4. Core company and workspace data live in services/company-service. It manages companies, members, vocabulary, transcription corrections, Trello board settings, and Google Calendar settings. It also includes utility code for voice embeddings, which suggests member identification or speaker-related matching is part of the company domain.
5. Meeting metadata and file storage are handled by services/meeting-service. It stores meetings, meeting participants, and meeting files, and exposes both public and internal routers. This service is the canonical source for meeting records and uploaded assets before downstream transcription or analysis begins.
6. Speech-to-text processing is centered in services/transcription-service. It manages transcription jobs, transcripts, and utterances, and integrates with a Deepgram client plus webhook handling. It also has background workers and Redis support, indicating asynchronous job processing and webhook-driven state transitions. Utilities such as speaker matching and audio cropping show that this service does more than raw transcription; it also attempts diarization/alignment and post-processing.
7. Higher-level AI summarization and task extraction are in services/ai-analysis-service. It owns analysis jobs, meeting summaries, and extracted tasks, and depends on clients for meeting, participant, utterance, and speaker data. It also includes a Groq client, deadline parsing, assignee mapping, an event publisher, and a transcription subscriber, so this service consumes transcription output and turns it into structured meeting insights and action items.
8. services/ai-service is a separate AI utility service with upload and summarize routers, plus Whisper and Groq integrations. Compared with ai-analysis-service, it looks more like a narrower AI helper service for audio upload/transcription/summarization primitives rather than full meeting analytics.
9. Cross-system synchronization lives in services/integration-service. It stores calendar events, sync queues, and Trello sync logs, and includes workers plus Redis. It connects outward to Google Calendar and Trello and inward to company data via a company client, making it the integration boundary for external system sync and background reconciliation.
10. The system uses an event/worker pattern in several places. Transcription and analysis are not purely synchronous HTTP workflows; they involve Redis-backed processing, subscribers, and workers. That suggests a pipeline like: meeting/audio data enters the meeting and transcription services, transcription output is published/consumed, analysis produces summaries/tasks, and integration jobs sync those results to external tools.
11. Persistence is service-owned rather than shared. Most services have their own db/database.py, SQLAlchemy-style models, Alembic migrations, and repositories. This implies separate databases or at least separate schemas per service, with the repository layer acting as the main persistence boundary inside each service.
12. A useful architecture diagram should show the main domain boundaries as: identity, company/workspace, meetings/files, transcription, AI analysis, generic AI utilities, and external integrations. The external systems that materially affect behavior are Groq, Whisper, Deepgram, Google Calendar, Trello, Redis, and Cloudinary.
13. The repeated internal structure across services is intentional: routers expose HTTP APIs, services hold business logic, repositories isolate persistence, schemas define API payloads, and models map database entities. This makes the repo a federated set of backend services rather than a single monolith.
Main entry points: main.py API Gateway · sync.py Sync API · job.py Transcribe API · company.py Company API
Components 29
Edge/API
Client entry and request routing
- API Gateway · Thin front door for backend services
services/api-gateway/main.py
Identity
Authentication and user lifecycle
- Auth API · Authentication and user endpoints
services/auth-service/app/routers/auth.py - Auth Logic · Token and user orchestration
services/auth-service/app/services/auth_service.py - Users · Users and refresh tokens
services/auth-service/app/models/user.py
Company
Companies, members, and workspace settings
- Company API · Companies, members, and settings
services/company-service/app/routers/company.py - Member Voice · Voice embedding and speaker matching
services/company-service/app/services/member_voice_service.py - Company Data · Companies, members, vocabulary, and board settings
services/company-service/app/models/company.py
Meetings
Meeting records and uploaded files
- Meeting API · Meeting and file endpoints
services/meeting-service/app/routers/meeting.py - Meeting Files · Meeting file storage and handling
services/meeting-service/app/services/meeting_file_service.py - Meeting Data · Meetings, participants, and files
services/meeting-service/app/models/meeting.py
Transcription
Audio jobs, transcripts, and webhook processing
- Transcribe API · Jobs, transcripts, utterances, and webhooks
services/transcription-service/app/routers/job.py - Transcribe Worker · Background job and auto-resolve processing
services/transcription-service/app/workers/auto_resolve_worker.py - Deepgram · Speech-to-text provider integration
services/transcription-service/app/services/deepgram_client.py - Transcription Data · Jobs, transcripts, and utterances
services/transcription-service/app/models/transcription_job.py
AI Analysis
Meeting insights and task extraction
- Analysis API · Summaries, tasks, and analysis jobs
services/ai-analysis-service/app/routers/analysis.py - Transcription Sub · Consumes transcription output events
services/ai-analysis-service/app/subscribers/transcription_subscriber.py - Groq Analysis · LLM-backed summary and task generation
services/ai-analysis-service/app/services/groq_service.py - Analysis Data · Analysis jobs, summaries, and extracted tasks
services/ai-analysis-service/app/models/analysis_job.py
AI Utils
Narrow AI helper service
Integrations
Calendar and Trello synchronization
- Sync API · Calendar and Trello sync endpoints
services/integration-service/app/routers/sync.py - Integration Worker · Runs sync reconciliation jobs
services/integration-service/app/workers/integration_worker.py - Sync Data · Calendar events, sync queue, and sync logs
services/integration-service/app/models/sync_queue.py
External Systems
Third-party and infrastructure dependencies
- Redis · Shared async state and queues
- Google Calendar · Calendar sync target
- Trello · Task board sync target
- Cloudinary · File and asset storage
- Groq · Summarization and extraction model provider
- Whisper · Audio transcription helper
Connections 30
- API Gateway → Auth API: routes to · Gateway forwards auth traffic
- API Gateway → Company API: routes to · Gateway forwards workspace traffic
- API Gateway → Meeting API: routes to · Gateway forwards meeting traffic
- API Gateway → Transcribe API: routes to · Gateway forwards transcription traffic
- API Gateway → Analysis API: routes to · Gateway forwards analysis traffic
- Auth API → Auth Logic: uses · Auth routers call service logic
- Auth Logic → Users: persists · User and token persistence
- Company API → Member Voice: uses · Member endpoints rely on voice matching
- Member Voice → Company Data: persists · Workspace entities and settings
- Company API → Cloudinary: stores · Company assets and media storage
- Meeting API → Meeting Files: uses · Meeting file upload and retrieval
- Meeting Files → Meeting Data: persists · Meeting records and files
- Transcribe API → Deepgram: calls · Speech-to-text provider integration
- Transcribe API → Transcribe Worker: enqueues · Job processing continues asynchronously
- Transcribe Worker → Redis: uses · Background coordination and state
- Transcribe Worker → Transcription Data: updates · Job and transcript state changes
- Transcribe API → Transcription Data: persists · Transcription domain records
- Analysis API → Groq Analysis: uses · Generates summaries and tasks
- Analysis API → Transcription Sub: consumes · Receives transcription-driven events
- Transcription Sub → Groq: publishes to · Event-driven analysis execution
- Groq Analysis → Analysis Data: persists · Analysis jobs, summaries, and tasks
- AI API → AI Models: uses · Upload and summarize helper logic
- AI Models → Whisper: calls · Audio transcription helper
- AI Models → Groq: calls · Summarization helper
- Sync API → Integration Worker: queues · Sync tasks run asynchronously
- Integration Worker → Redis: uses · Queueing and coordination
- Sync API → Sync Data: persists · Sync queues, events, and logs
- Sync API → Google Calendar: syncs · Calendar synchronization boundary
- Sync API → Trello: syncs · Trello synchronization boundary
- Sync API → Company API: reads · Uses company data for sync decisions