# Project Context ## Purpose Enterprise meeting knowledge management solution that automates meeting transcription and generates structured summaries. Solves the time-consuming problem of manual meeting notes by using edge AI for speech-to-text and LLM for intelligent summarization with action item tracking. ## Tech Stack - **Frontend**: Electron (edge computing for offline transcription) - **Backend**: Python FastAPI (middleware server) - **Database**: MySQL (shared instance at mysql.theaken.com:33306) - **AI/ML**: - faster-whisper (int8) for local speech-to-text - OpenCC for Traditional Chinese conversion - Dify LLM for summarization - **Key Libraries**: mysql-connector-python, fastapi, requests, openpyxl, PyInstaller ## Project Conventions ### Code Style - Database tables must use `meeting_` prefix - System IDs follow format: `C-YYYYMMDD-XX` (conclusions), `A-YYYYMMDD-XX` (action items) - API endpoints use `/api/` prefix - Environment variables for sensitive config (DB credentials, API keys) ### Architecture Patterns - **Three-tier architecture**: Electron Client → FastAPI Middleware → MySQL/Dify - **Security**: DB connections and API keys must NOT be in Electron client; all secrets stay in middleware - **Edge Computing**: Speech-to-text runs locally in Electron for offline capability - **Proxy Pattern**: Middleware proxies auth requests to external Auth API ### Testing Strategy - **Unit Tests**: DB connectivity, Dify proxy, admin role detection - **Integration Tests**: Auth flow with token refresh, full meeting cycle (create → record → summarize → save → export) - **Deployment Checklist**: Environment validation, table creation, package verification ### Git Workflow - Feature branches for new capabilities - OpenSpec change proposals for significant features ## Domain Context - **會議記錄 (Meeting Records)**: Core entity with metadata (subject, time, chairperson, location, recorder, attendees) - **逐字稿 (Transcript)**: Raw AI-generated speech-to-text output - **會議結論 (Conclusions)**: Summarized key decisions from meetings - **待辦事項 (Action Items)**: Tracked tasks with owner, due date, and status (Open/In Progress/Done/Delayed) - **Admin User**: ymirliu@panjit.com.tw has full access to all meetings and Excel template management ## Important Constraints - Target hardware: i5/8GB laptop must run faster-whisper int8 locally - Security: No DB credentials or API keys in client-side code - Language: Must support Traditional Chinese (繁體中文) output - Data Isolation: All tables prefixed with `meeting_` - Token Management: Client must implement auto-refresh for long meetings ## External Dependencies - **Auth API**: https://pj-auth-api.vercel.app/api/auth/login (company SSO) - **Dify LLM**: https://dify.theaken.com/v1 (AI summarization) - **MySQL**: mysql.theaken.com:33306, database `db_A060`