# mkeses/ai_meeting_note_tool architecture

> Architecture diagram of the GitHub repository mkeses/ai_meeting_note_tool, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-25). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/mkeses/ai_meeting_note_tool
- Repository: https://github.com/mkeses/ai_meeting_note_tool

## Overview

AI Meeting Note Tool captures or accepts meeting content, produces editable live transcripts and cleaned, structured notes, then saves and searches meeting workspaces. The React application coordinates capture, review, authentication, and workspace operations with a FastAPI backend; storage can be local SQLite or owner-scoped PostgreSQL. Electron supports a desktop runtime and local model setup. README capabilities guide the major workflow branches; sampled excerpts are partial, so uncertain internal call paths are not expanded.

Main entry points: [`backend/app.py`](https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/app.py) (FastAPI endpoints), [`frontend/src/App.tsx`](https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/App.tsx) (Workspace UI), [`backend/storage.py`](https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/storage.py) (Storage selection), [`frontend/src/hooks/useAuth.ts`](https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/hooks/useAuth.ts) (Authentication state)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["Meeting workspace"]
  node_app["Workspace UI<br/>[App.tsx]"]
  node_authui["Sign-in screen<br/>[AuthScreen.tsx]"]
  node_authhook["Authentication state<br/>[useAuth.ts]"]
  node_capture["Audio capture<br/>[useAudioCapture.ts]"]
  node_live["Live transcript state"]
  node_sessions["Meeting workspace data"]
  node_pdf["Report export"]
  node_api["HTTP and API URLs<br/>[api.ts]"]
  node_serviceworker["Offline app shell<br/>[service-worker.js]"]
end

subgraph group_backend["API and processing"]
  node_backend["FastAPI endpoints<br/>[app.py]"]
  node_transcription["Speech transcription<br/>[transcription.py]"]
  node_llm["Cleanup and notes<br/>[llm.py]"]
  node_storage["Storage selection<br/>[storage.py]"]
  node_authbackend["Authentication and sessions<br/>[auth.py]"]
end

subgraph group_persistence["Meeting persistence"]
  node_sqlite[("SQLite meetings<br/>[database.py]")]
  node_postgres[("PostgreSQL meetings")]
end

subgraph group_desktop["Desktop runtime"]
  node_electron["Electron controller<br/>[main.mjs]"]
  node_ollama["Local model runtime<br/>[ollama-runtime.mjs]"]
  node_ollamalifecycle["Model lifecycle"]
end

node_person(("Meeting user"))

node_person -->|"uses"| node_app
node_person -->|"signs in"| node_authui
node_authui -->|"submits credentials"| node_authhook
node_app -->|"checks session"| node_authhook
node_authhook -->|"requests auth"| node_api
node_app -->|"starts recording"| node_capture
node_capture -->|"streams audio"| node_backend
node_backend -->|"transcribes audio"| node_transcription
node_transcription -->|"sends transcript"| node_live
node_app -->|"edits transcript"| node_live
node_app -->|"uploads audio"| node_backend
node_backend -->|"cleans and structures"| node_llm
node_app -->|"manages meetings"| node_sessions
node_sessions -->|"requests CRUD and search"| node_api
node_api -->|"calls REST API"| node_backend
node_backend -->|"selects store"| node_storage
node_storage -->|"creates SQLite store"| node_sqlite
node_storage -->|"creates PostgreSQL store"| node_postgres
node_backend -->|"authenticates requests"| node_authbackend
node_authbackend -->|"uses auth store"| node_storage
node_app -->|"exports report"| node_pdf
node_person -.->|"loads app shell"| node_serviceworker
node_electron -->|"manages setup"| node_ollamalifecycle
node_ollamalifecycle -->|"starts runtime"| node_ollama
node_electron -->|"starts backend"| node_backend

click node_app "https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/App.tsx"
click node_authui "https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/components/AuthScreen.tsx"
click node_authhook "https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/hooks/useAuth.ts"
click node_capture "https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/hooks/useAudioCapture.ts"
click node_live "https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/hooks/useLiveTranscript.ts"
click node_sessions "https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/hooks/useMeetingSessions.ts"
click node_pdf "https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/lib/meetingReportPdf.ts"
click node_api "https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/api.ts"
click node_backend "https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/app.py"
click node_transcription "https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/transcription.py"
click node_llm "https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/llm.py"
click node_storage "https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/storage.py"
click node_sqlite "https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/database.py"
click node_postgres "https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/postgres_database.py"
click node_authbackend "https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/auth.py"
click node_serviceworker "https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/public/service-worker.js"
click node_electron "https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/electron/main.mjs"
click node_ollama "https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/electron/ollama-runtime.mjs"
click node_ollamalifecycle "https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/electron/ollama-lifecycle.mjs"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_app,node_authui,node_authhook,node_capture,node_live,node_sessions,node_pdf,node_api,node_serviceworker,node_person toneBlue
class node_backend,node_transcription,node_llm,node_storage,node_authbackend toneAmber
class node_sqlite,node_postgres toneMint
class node_electron,node_ollama,node_ollamalifecycle toneRose
```

## Components

### Meeting workspace

- [Workspace UI](https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/App.tsx): `frontend/src/App.tsx`
- [Sign-in screen](https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/components/AuthScreen.tsx): `frontend/src/components/AuthScreen.tsx`
- [Authentication state](https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/hooks/useAuth.ts): `frontend/src/hooks/useAuth.ts`
- [Audio capture](https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/hooks/useAudioCapture.ts): `frontend/src/hooks/useAudioCapture.ts`
- [Live transcript state](https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/hooks/useLiveTranscript.ts): `frontend/src/hooks/useLiveTranscript.ts`
- [Meeting workspace data](https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/hooks/useMeetingSessions.ts): `frontend/src/hooks/useMeetingSessions.ts`
- [Report export](https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/lib/meetingReportPdf.ts): `frontend/src/lib/meetingReportPdf.ts`
- [HTTP and API URLs](https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/src/api.ts): `frontend/src/api.ts`
- [Offline app shell](https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/public/service-worker.js): `frontend/public/service-worker.js`

### API and processing

- [FastAPI endpoints](https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/app.py): `backend/app.py`
- [Speech transcription](https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/transcription.py): `backend/transcription.py`
- [Cleanup and notes](https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/llm.py): `backend/llm.py`
- [Storage selection](https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/storage.py): `backend/storage.py`
- [Authentication and sessions](https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/auth.py): `backend/auth.py`

### Meeting persistence

- [SQLite meetings](https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/database.py): `backend/database.py`
- [PostgreSQL meetings](https://github.com/mkeses/ai_meeting_note_tool/blob/main/backend/postgres_database.py): `backend/postgres_database.py`

### Desktop runtime

- [Electron controller](https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/electron/main.mjs): `frontend/electron/main.mjs`
- [Local model runtime](https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/electron/ollama-runtime.mjs): `frontend/electron/ollama-runtime.mjs`
- [Model lifecycle](https://github.com/mkeses/ai_meeting_note_tool/blob/main/frontend/electron/ollama-lifecycle.mjs): `frontend/electron/ollama-lifecycle.mjs`

### Other components

- **Meeting user**

## Connections

- Meeting user → Workspace UI: uses
- Meeting user → Sign-in screen: signs in
- Sign-in screen → Authentication state: submits credentials
- Workspace UI → Authentication state: checks session
- Authentication state → HTTP and API URLs: requests auth
- Workspace UI → Audio capture: starts recording
- Audio capture → FastAPI endpoints: streams audio
- FastAPI endpoints → Speech transcription: transcribes audio
- Speech transcription → Live transcript state: sends transcript
- Workspace UI → Live transcript state: edits transcript
- Workspace UI → FastAPI endpoints: uploads audio
- FastAPI endpoints → Cleanup and notes: cleans and structures
- Workspace UI → Meeting workspace data: manages meetings
- Meeting workspace data → HTTP and API URLs: requests CRUD and search
- HTTP and API URLs → FastAPI endpoints: calls REST API
- FastAPI endpoints → Storage selection: selects store
- Storage selection → SQLite meetings: creates SQLite store
- Storage selection → PostgreSQL meetings: creates PostgreSQL store
- FastAPI endpoints → Authentication and sessions: authenticates requests
- Authentication and sessions → Storage selection: uses auth store
- Workspace UI → Report export: exports report
- Meeting user → Offline app shell: loads app shell
- Electron controller → Model lifecycle: manages setup
- Model lifecycle → Local model runtime: starts runtime
- Electron controller → FastAPI endpoints: starts backend
