# therealmoeid/orphivo architecture

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

- Interactive diagram: https://gitdiagram.com/therealmoeid/orphivo
- Repository: https://github.com/therealmoeid/orphivo

## Overview

Orphivo’s established workflow starts at the Tkinter entry point: the user records audio, the app transcribes it locally in Persian, presents editable text, and can save or revisit transcripts. The UI also manages preferences, themes, and transcript actions. The README describes a separate PySide6 migration, but its source files are absent from this tree, so it is not mapped. Connections reflect the sampled Tkinter code and README; external microphone and model details are limited to documented or excerpted evidence.

Main entry points: [`src/ui.py`](https://github.com/therealmoeid/orphivo/blob/main/src/ui.py) (Tkinter application), [`src/recorder.py`](https://github.com/therealmoeid/orphivo/blob/main/src/recorder.py) (Audio recorder), [`app.py`](https://github.com/therealmoeid/orphivo/blob/main/app.py) (App launcher), [`src/settings.py`](https://github.com/therealmoeid/orphivo/blob/main/src/settings.py) (Settings)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["Application entry"]
  node_app["App launcher<br/>[app.py]"]
end

subgraph group_desktop["Desktop experience"]
  node_ui["Tkinter application<br/>[ui.py]"]
  node_preferences["Settings<br/>[settings.py]"]
  node_theme["Theme palettes<br/>[theme.py]"]
end

subgraph group_speech["Speech processing"]
  node_recorder["Audio recorder<br/>[recorder.py]"]
  node_audiofile["Temporary WAV audio<br/>[recorder.py]"]
  node_transcriber["Persian transcriber<br/>[transcriber.py]"]
end

subgraph group_data["Local data"]
  node_history["Transcript history<br/>[history.py]"]
  node_transcripts[("Transcript text files<br/>[history.py]")]
  node_settingsfile[("Settings JSON<br/>[settings.py]")]
end

node_user(("Desktop user"))
node_microphone(("Microphone"))
node_model["Local Whisper model"]

node_user -->|"starts"| node_app
node_app -->|"launches"| node_ui
node_user -->|"uses"| node_ui
node_ui -->|"loads and saves"| node_preferences
node_preferences -->|"reads and writes"| node_settingsfile
node_ui -->|"applies palette"| node_theme
node_ui -->|"starts and stops"| node_recorder
node_microphone -->|"provides audio"| node_recorder
node_recorder -->|"writes WAV"| node_audiofile
node_ui -->|"passes audio path"| node_audiofile
node_ui -->|"requests transcription"| node_transcriber
node_transcriber -->|"loads and transcribes"| node_model
node_ui -->|"lists, reads, saves"| node_history
node_history -->|"reads and writes"| node_transcripts

click node_app "https://github.com/therealmoeid/orphivo/blob/main/app.py"
click node_ui "https://github.com/therealmoeid/orphivo/blob/main/src/ui.py"
click node_preferences "https://github.com/therealmoeid/orphivo/blob/main/src/settings.py"
click node_theme "https://github.com/therealmoeid/orphivo/blob/main/src/theme.py"
click node_recorder "https://github.com/therealmoeid/orphivo/blob/main/src/recorder.py"
click node_audiofile "https://github.com/therealmoeid/orphivo/blob/main/src/recorder.py"
click node_transcriber "https://github.com/therealmoeid/orphivo/blob/main/src/transcriber.py"
click node_history "https://github.com/therealmoeid/orphivo/blob/main/src/history.py"
click node_transcripts "https://github.com/therealmoeid/orphivo/blob/main/src/history.py"
click node_settingsfile "https://github.com/therealmoeid/orphivo/blob/main/src/settings.py"

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_user toneBlue
class node_ui,node_preferences,node_theme toneAmber
class node_recorder,node_audiofile,node_transcriber toneMint
class node_history,node_transcripts,node_settingsfile toneRose
class node_microphone,node_model toneIndigo
```

## Components

### Application entry

- [App launcher](https://github.com/therealmoeid/orphivo/blob/main/app.py): `app.py`

### Desktop experience

- [Tkinter application](https://github.com/therealmoeid/orphivo/blob/main/src/ui.py): `src/ui.py`
- [Settings](https://github.com/therealmoeid/orphivo/blob/main/src/settings.py): `src/settings.py`
- [Theme palettes](https://github.com/therealmoeid/orphivo/blob/main/src/theme.py): `src/theme.py`

### Speech processing

- [Audio recorder](https://github.com/therealmoeid/orphivo/blob/main/src/recorder.py): `src/recorder.py`
- [Temporary WAV audio](https://github.com/therealmoeid/orphivo/blob/main/src/recorder.py): `src/recorder.py`
- [Persian transcriber](https://github.com/therealmoeid/orphivo/blob/main/src/transcriber.py): `src/transcriber.py`

### Local data

- [Transcript history](https://github.com/therealmoeid/orphivo/blob/main/src/history.py): `src/history.py`
- [Transcript text files](https://github.com/therealmoeid/orphivo/blob/main/src/history.py): `src/history.py`
- [Settings JSON](https://github.com/therealmoeid/orphivo/blob/main/src/settings.py): `src/settings.py`

### Other components

- **Desktop user**
- **Microphone**
- **Local Whisper model**

## Connections

- Desktop user → App launcher: starts (evidence: `README.md`)
- App launcher → Tkinter application: launches (evidence: `app.py`)
- Desktop user → Tkinter application: uses (evidence: `README.md`)
- Tkinter application → Settings: loads and saves (evidence: `src/ui.py`)
- Settings → Settings JSON: reads and writes (evidence: `src/settings.py`)
- Tkinter application → Theme palettes: applies palette (evidence: `src/ui.py`)
- Tkinter application → Audio recorder: starts and stops (evidence: `src/ui.py`)
- Microphone → Audio recorder: provides audio (evidence: `src/recorder.py`)
- Audio recorder → Temporary WAV audio: writes WAV (evidence: `src/recorder.py`)
- Tkinter application → Temporary WAV audio: passes audio path (evidence: `src/ui.py`)
- Tkinter application → Persian transcriber: requests transcription (evidence: `src/ui.py`)
- Persian transcriber → Local Whisper model: loads and transcribes (evidence: `src/transcriber.py`)
- Tkinter application → Transcript history: lists, reads, saves (evidence: `src/ui.py`)
- Transcript history → Transcript text files: reads and writes (evidence: `src/history.py`)
