# aieradev/clypra architecture

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

- Interactive diagram: https://gitdiagram.com/aieradev/clypra
- Repository: https://github.com/aieradev/clypra

## Overview

Clypra is a cross-platform video editor with a React/TypeScript frontend and a Rust/Tauri native backend. The principal workflow is to open a project, arrange media and edits on a multi-track timeline, preview playback through the rendering stack, and export a finished video. The graph also preserves documented audio, compositing, AI, thumbnail, and telemetry capabilities. Edges are limited to README statements and SOURCE INDEX references; links between unsampled subsystems are omitted or marked unverified.

Main entry points: [`src/components/screens/EditorScreen.tsx`](https://github.com/aieradev/clypra/blob/master/src/components/screens/EditorScreen.tsx) (Editor workspace), [`src/components/editor/preview/PreviewPanel.tsx`](https://github.com/aieradev/clypra/blob/master/src/components/editor/preview/PreviewPanel.tsx) (Preview interface), [`src-tauri/src/commands/mod.rs`](https://github.com/aieradev/clypra/blob/master/src-tauri/src/commands/mod.rs) (Native commands), [`src-tauri/src/engine/mod.rs`](https://github.com/aieradev/clypra/blob/master/src-tauri/src/engine/mod.rs) (Native engine)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_editing["Editing and projects"]
  node_app["Application shell<br/>[App.tsx]"]
  node_editor["Editor workspace<br/>[EditorScreen.tsx]"]
  node_timeline["Timeline editing<br/>[timelineStore.ts]"]
  node_projects["Project persistence<br/>[projectStore.ts]"]
  node_session["Project runtime<br/>[ProjectSession.ts]"]
end

subgraph group_preview["Playback and preview"]
  node_preview_ui["Preview interface<br/>[PreviewPanel.tsx]"]
  node_playback["Playback clock<br/>[PlaybackClock.ts]"]
  node_render_engine["Render engine<br/>[renderEngine.ts]"]
end

subgraph group_media["Media and export"]
  node_ipc["Tauri IPC<br/>[tauri.ts]"]
  node_commands["Native commands<br/>[mod.rs]"]
  node_engine["Native engine<br/>[mod.rs]"]
  node_decoder["Media decoding<br/>[decoder.rs]"]
  node_compositor["GPU compositor<br/>[wgpu_compositor.rs]"]
  node_export["Video export<br/>[export.rs]"]
end

subgraph group_capabilities["Creative capabilities"]
  node_audio["Audio engine<br/>[AudioEngine.ts]"]
  node_ai["AI media tools<br/>[mod.rs]"]
  node_thumbnails["Thumbnail engine"]
end

subgraph group_operations["Runtime services"]
  node_telemetry["Performance telemetry"]
  node_perf_logs["Performance logs<br/>[perfLogService.ts]"]
end

node_user(("Editor"))

node_user -->|"opens"| node_app
node_app -->|"routes to"| node_editor
node_editor -.->|"edits timeline"| node_timeline
node_editor -.->|"manages projects"| node_projects
node_timeline -->|"updates"| node_session
node_projects -.->|"opens project"| node_session
node_editor -.->|"presents preview"| node_preview_ui
node_session -->|"creates"| node_render_engine
node_preview_ui -.->|"controls playback"| node_playback
node_preview_ui -.->|"requests native preview"| node_ipc
node_ipc -->|"invokes"| node_commands
node_commands -.->|"dispatches to"| node_engine
node_engine -.->|"decodes media"| node_decoder
node_engine -.->|"renders frames"| node_compositor
node_commands -.->|"exports media"| node_export
node_editor -.->|"edits audio"| node_audio
node_editor -.->|"uses AI tools"| node_ai
node_editor -.->|"creates thumbnails"| node_thumbnails
node_telemetry -->|"routes events"| node_perf_logs

click node_app "https://github.com/aieradev/clypra/blob/master/src/App.tsx"
click node_editor "https://github.com/aieradev/clypra/blob/master/src/components/screens/EditorScreen.tsx"
click node_timeline "https://github.com/aieradev/clypra/blob/master/src/store/timelineStore.ts"
click node_projects "https://github.com/aieradev/clypra/blob/master/src/store/projectStore.ts"
click node_session "https://github.com/aieradev/clypra/blob/master/src/core/runtime/ProjectSession.ts"
click node_preview_ui "https://github.com/aieradev/clypra/blob/master/src/components/editor/preview/PreviewPanel.tsx"
click node_playback "https://github.com/aieradev/clypra/blob/master/src/core/playback/PlaybackClock.ts"
click node_render_engine "https://github.com/aieradev/clypra/blob/master/src/lib/renderEngine/renderEngine.ts"
click node_ipc "https://github.com/aieradev/clypra/blob/master/src/lib/platform/tauri.ts"
click node_commands "https://github.com/aieradev/clypra/blob/master/src-tauri/src/commands/mod.rs"
click node_engine "https://github.com/aieradev/clypra/blob/master/src-tauri/src/engine/mod.rs"
click node_decoder "https://github.com/aieradev/clypra/blob/master/src-tauri/src/engine/decoder.rs"
click node_compositor "https://github.com/aieradev/clypra/blob/master/src-tauri/src/wgpu_compositor.rs"
click node_export "https://github.com/aieradev/clypra/blob/master/src-tauri/src/commands/export.rs"
click node_audio "https://github.com/aieradev/clypra/blob/master/src/core/audio/AudioEngine.ts"
click node_ai "https://github.com/aieradev/clypra/blob/master/src-tauri/src/ai/mod.rs"
click node_thumbnails "https://github.com/aieradev/clypra/blob/master/src-tauri/src/thumbnail_engine.rs"
click node_telemetry "https://github.com/aieradev/clypra/blob/master/src/services/telemetryCollector.ts"
click node_perf_logs "https://github.com/aieradev/clypra/blob/master/src/services/perfLogService.ts"

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_editor,node_timeline,node_projects,node_session toneBlue
class node_preview_ui,node_playback,node_render_engine toneAmber
class node_ipc,node_commands,node_engine,node_decoder,node_compositor,node_export toneMint
class node_audio,node_ai,node_thumbnails toneRose
class node_telemetry,node_perf_logs,node_user toneIndigo
```

## Components

### Editing and projects

- [Application shell](https://github.com/aieradev/clypra/blob/master/src/App.tsx): `src/App.tsx`
- [Editor workspace](https://github.com/aieradev/clypra/blob/master/src/components/screens/EditorScreen.tsx): `src/components/screens/EditorScreen.tsx`
- [Timeline editing](https://github.com/aieradev/clypra/blob/master/src/store/timelineStore.ts): `src/store/timelineStore.ts`
- [Project persistence](https://github.com/aieradev/clypra/blob/master/src/store/projectStore.ts): `src/store/projectStore.ts`
- [Project runtime](https://github.com/aieradev/clypra/blob/master/src/core/runtime/ProjectSession.ts): `src/core/runtime/ProjectSession.ts`

### Playback and preview

- [Preview interface](https://github.com/aieradev/clypra/blob/master/src/components/editor/preview/PreviewPanel.tsx): `src/components/editor/preview/PreviewPanel.tsx`
- [Playback clock](https://github.com/aieradev/clypra/blob/master/src/core/playback/PlaybackClock.ts): `src/core/playback/PlaybackClock.ts`
- [Render engine](https://github.com/aieradev/clypra/blob/master/src/lib/renderEngine/renderEngine.ts): `src/lib/renderEngine/renderEngine.ts`

### Media and export

- [Tauri IPC](https://github.com/aieradev/clypra/blob/master/src/lib/platform/tauri.ts): `src/lib/platform/tauri.ts`
- [Native commands](https://github.com/aieradev/clypra/blob/master/src-tauri/src/commands/mod.rs): `src-tauri/src/commands/mod.rs`
- [Native engine](https://github.com/aieradev/clypra/blob/master/src-tauri/src/engine/mod.rs): `src-tauri/src/engine/mod.rs`
- [Media decoding](https://github.com/aieradev/clypra/blob/master/src-tauri/src/engine/decoder.rs): `src-tauri/src/engine/decoder.rs`
- [GPU compositor](https://github.com/aieradev/clypra/blob/master/src-tauri/src/wgpu_compositor.rs): `src-tauri/src/wgpu_compositor.rs`
- [Video export](https://github.com/aieradev/clypra/blob/master/src-tauri/src/commands/export.rs): `src-tauri/src/commands/export.rs`

### Creative capabilities

- [Audio engine](https://github.com/aieradev/clypra/blob/master/src/core/audio/AudioEngine.ts): `src/core/audio/AudioEngine.ts`
- [AI media tools](https://github.com/aieradev/clypra/blob/master/src-tauri/src/ai/mod.rs): `src-tauri/src/ai/mod.rs`
- [Thumbnail engine](https://github.com/aieradev/clypra/blob/master/src-tauri/src/thumbnail_engine.rs): `src-tauri/src/thumbnail_engine.rs`

### Runtime services

- [Performance telemetry](https://github.com/aieradev/clypra/blob/master/src/services/telemetryCollector.ts): `src/services/telemetryCollector.ts`
- [Performance logs](https://github.com/aieradev/clypra/blob/master/src/services/perfLogService.ts): `src/services/perfLogService.ts`

### Other components

- **Editor**

## Connections

- Editor → Application shell: opens (evidence: `README.md`)
- Application shell → Editor workspace: routes to (evidence: `src/App.tsx`)
- Editor workspace → Timeline editing: edits timeline
- Editor workspace → Project persistence: manages projects
- Timeline editing → Project runtime: updates (evidence: `src/store/timelineStore.ts`)
- Project persistence → Project runtime: opens project (evidence: `src/store/projectStore.ts`)
- Editor workspace → Preview interface: presents preview
- Project runtime → Render engine: creates (evidence: `src/core/runtime/ProjectSession.ts`)
- Preview interface → Playback clock: controls playback
- Preview interface → Tauri IPC: requests native preview
- Tauri IPC → Native commands: invokes (evidence: `src/lib/platform/tauri.ts`)
- Native commands → Native engine: dispatches to
- Native engine → Media decoding: decodes media
- Native engine → GPU compositor: renders frames
- Native commands → Video export: exports media
- Editor workspace → Audio engine: edits audio
- Editor workspace → AI media tools: uses AI tools
- Editor workspace → Thumbnail engine: creates thumbnails
- Performance telemetry → Performance logs: routes events (evidence: `src/services/telemetryCollector.ts`)
