# mjawadi2002/omnimotion architecture

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

- Interactive diagram: https://gitdiagram.com/mjawadi2002/omnimotion
- Repository: https://github.com/mjawadi2002/omnimotion

## Overview

OmniMotion is a desktop editor for turning talking-head footage—or, in motion mode, an idea—into short-form video. Users create a project, attach media, transcribe and cut speech, plan and refine a word-anchored edit, preview it, then render. The app also supports reference analysis and recreation, custom looks, project memory, and free-model routing. The graph follows documented capabilities; unsampled screen and runtime wiring is represented only where the README or excerpts support it.

Main entry points: [`cutline-app/electron/main.mjs`](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/main.mjs) (IPC handlers), [`cutline-app/src/lib/api.ts`](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/lib/api.ts) (Desktop API), [`cutline-app/src/screens/Workspace.tsx`](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/Workspace.tsx) (Project workspace), [`cutline-app/electron/ai.mjs`](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/ai.mjs) (AI planning)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_desktop["Desktop workflow"]
  node_app["App shell<br/>[App.tsx]"]
  node_projects["Projects<br/>[Projects.tsx]"]
  node_workspace["Project workspace<br/>[Workspace.tsx]"]
  node_media_ui["Media setup<br/>[MediaTab.tsx]"]
  node_api["Desktop API<br/>[api.ts]"]
  node_main["IPC handlers<br/>[main.mjs]"]
end

subgraph group_editing["Edit and render"]
  node_story["Transcribe and cut<br/>[StoryTab.tsx]"]
  node_plan["Word-anchored plan<br/>[PlanTab.tsx]"]
  node_edit["Plan editing<br/>[EditTab.tsx]"]
  node_timeline["Timeline control<br/>[Timeline.tsx]"]
  node_render["Render and preview<br/>[RenderTab.tsx]"]
  node_media["Media handling<br/>[media.mjs]"]
  node_engine["Edit engine runner<br/>[engine.mjs]"]
end

subgraph group_creative["AI and creative modes"]
  node_motion_ui["Motion graphics mode<br/>[MotionMode.tsx]"]
  node_motion["Motion generation<br/>[motion.mjs]"]
  node_agent["Reference recreation<br/>[agentbuild.mjs]"]
  node_analysis["Reference analysis<br/>[refanalyze.mjs]"]
  node_looks["Looks<br/>[looks.mjs]"]
  node_ai["AI planning<br/>[ai.mjs]"]
  node_analyze_ui["Analyze reel<br/>[Analyze.tsx]"]
  node_library["Reference library<br/>[library.mjs]"]
end

subgraph group_services["Persistence and services"]
  node_memory[("Project memory<br/>[memory.mjs]")]
  node_store[("Settings and projects<br/>[store.mjs]")]
  node_free["Free model routing<br/>[freellm.mjs]"]
  node_gateway["FreeLLM gateway<br/>[gateway.mjs]"]
end

node_user(("Editor"))
node_claude{{"Claude"}}
node_eleven{{"ElevenLabs"}}
node_remotion["Remotion renderer<br/>[Composition.tsx]"]

node_user -->|"uses"| node_app
node_app -->|"routes to"| node_projects
node_app -->|"routes to"| node_workspace
node_app -->|"routes to"| node_analyze_ui
node_projects -.->|"opens project"| node_workspace
node_workspace -.->|"shows stage"| node_media_ui
node_workspace -.->|"shows stage"| node_story
node_workspace -.->|"shows stage"| node_plan
node_workspace -.->|"shows stage"| node_edit
node_workspace -.->|"shows stage"| node_render
node_media_ui -.->|"requests media operations"| node_api
node_story -.->|"requests preparation"| node_api
node_plan -.->|"requests planning"| node_api
node_edit -.->|"submits changes"| node_api
node_render -.->|"requests render"| node_api
node_api -.->|"bridges requests"| node_main
node_main -.->|"attaches media"| node_media
node_main -->|"starts engine runs"| node_engine
node_engine -->|"resolves look"| node_looks
node_engine -->|"renders composition"| node_remotion
node_motion_ui -->|"requests motion workflow"| node_api
node_main -->|"uses recording"| node_motion
node_motion -->|"generates motion script"| node_ai
node_motion -->|"requests voice"| node_eleven
node_motion -->|"builds animation"| node_remotion
node_main -.->|"runs reference build"| node_agent
node_agent -->|"analyzes reference"| node_analysis
node_agent -->|"asks Claude to build"| node_ai
node_analyze_ui -->|"requests analysis"| node_api
node_main -->|"describes reference"| node_library
node_analyze_ui -.->|"creates look from analysis"| node_looks
node_main -->|"runs AI edit"| node_ai
node_ai -->|"plans edit"| node_claude
node_ai -->|"uses free fallback"| node_free
node_free -->|"gets backend"| node_gateway
node_gateway -.->|"routes model requests"| node_claude
node_ai -->|"loads project context"| node_memory
node_main -->|"records spelling fixes"| node_memory
node_main -->|"saves settings and plans"| node_store
node_media -->|"uses cache"| node_store
node_library -.->|"uses project storage"| node_store

click node_app "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/App.tsx"
click node_projects "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/Projects.tsx"
click node_workspace "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/Workspace.tsx"
click node_media_ui "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/MediaTab.tsx"
click node_story "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/StoryTab.tsx"
click node_plan "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/PlanTab.tsx"
click node_edit "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/EditTab.tsx"
click node_timeline "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/Timeline.tsx"
click node_render "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/RenderTab.tsx"
click node_api "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/lib/api.ts"
click node_main "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/main.mjs"
click node_media "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/media.mjs"
click node_engine "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/engine.mjs"
click node_motion_ui "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/MotionMode.tsx"
click node_motion "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/motion.mjs"
click node_agent "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/agentbuild.mjs"
click node_analysis "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/refanalyze.mjs"
click node_looks "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/looks.mjs"
click node_ai "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/ai.mjs"
click node_memory "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/memory.mjs"
click node_store "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/store.mjs"
click node_free "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/freellm.mjs"
click node_gateway "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/gateway.mjs"
click node_remotion "https://github.com/mjawadi2002/omnimotion/blob/main/video-studio/src/Composition.tsx"
click node_analyze_ui "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/Analyze.tsx"
click node_library "https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/library.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_projects,node_workspace,node_media_ui,node_api,node_main toneBlue
class node_story,node_plan,node_edit,node_timeline,node_render,node_media,node_engine toneAmber
class node_motion_ui,node_motion,node_agent,node_analysis,node_looks,node_ai,node_analyze_ui,node_library toneMint
class node_memory,node_store,node_free,node_gateway toneRose
class node_user,node_claude,node_eleven toneIndigo
class node_remotion toneTeal
```

## Components

### Desktop workflow

- [App shell](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/App.tsx): `cutline-app/src/App.tsx`
- [Projects](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/Projects.tsx): `cutline-app/src/screens/Projects.tsx`
- [Project workspace](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/Workspace.tsx): `cutline-app/src/screens/Workspace.tsx`
- [Media setup](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/MediaTab.tsx): `cutline-app/src/screens/MediaTab.tsx`
- [Desktop API](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/lib/api.ts): `cutline-app/src/lib/api.ts`
- [IPC handlers](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/main.mjs): `cutline-app/electron/main.mjs`

### Edit and render

- [Transcribe and cut](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/StoryTab.tsx): `cutline-app/src/screens/StoryTab.tsx`
- [Word-anchored plan](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/PlanTab.tsx): `cutline-app/src/screens/PlanTab.tsx`
- [Plan editing](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/EditTab.tsx): `cutline-app/src/screens/EditTab.tsx`
- [Timeline control](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/Timeline.tsx): `cutline-app/src/screens/Timeline.tsx`
- [Render and preview](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/RenderTab.tsx): `cutline-app/src/screens/RenderTab.tsx`
- [Media handling](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/media.mjs): `cutline-app/electron/media.mjs`
- [Edit engine runner](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/engine.mjs): `cutline-app/electron/engine.mjs`

### AI and creative modes

- [Motion graphics mode](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/MotionMode.tsx): `cutline-app/src/screens/MotionMode.tsx`
- [Motion generation](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/motion.mjs): `cutline-app/electron/motion.mjs`
- [Reference recreation](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/agentbuild.mjs): `cutline-app/electron/agentbuild.mjs`
- [Reference analysis](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/refanalyze.mjs): `cutline-app/electron/refanalyze.mjs`
- [Looks](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/looks.mjs): `cutline-app/electron/looks.mjs`
- [AI planning](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/ai.mjs): `cutline-app/electron/ai.mjs`
- [Analyze reel](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/src/screens/Analyze.tsx): `cutline-app/src/screens/Analyze.tsx`
- [Reference library](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/library.mjs): `cutline-app/electron/library.mjs`

### Persistence and services

- [Project memory](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/memory.mjs): `cutline-app/electron/memory.mjs`
- [Settings and projects](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/store.mjs): `cutline-app/electron/store.mjs`
- [Free model routing](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/freellm.mjs): `cutline-app/electron/freellm.mjs`
- [FreeLLM gateway](https://github.com/mjawadi2002/omnimotion/blob/main/cutline-app/electron/gateway.mjs): `cutline-app/electron/gateway.mjs`

### Other components

- **Editor**
- **Claude**
- **ElevenLabs**
- [Remotion renderer](https://github.com/mjawadi2002/omnimotion/blob/main/video-studio/src/Composition.tsx): `video-studio/src/Composition.tsx`

## Connections

- Editor → App shell: uses (evidence: `README.md`)
- App shell → Projects: routes to (evidence: `cutline-app/src/App.tsx`)
- App shell → Project workspace: routes to (evidence: `cutline-app/src/App.tsx`)
- App shell → Analyze reel: routes to (evidence: `cutline-app/src/App.tsx`)
- Projects → Project workspace: opens project
- Project workspace → Media setup: shows stage
- Project workspace → Transcribe and cut: shows stage
- Project workspace → Word-anchored plan: shows stage
- Project workspace → Plan editing: shows stage
- Project workspace → Render and preview: shows stage
- Media setup → Desktop API: requests media operations
- Transcribe and cut → Desktop API: requests preparation
- Word-anchored plan → Desktop API: requests planning
- Plan editing → Desktop API: submits changes
- Render and preview → Desktop API: requests render
- Desktop API → IPC handlers: bridges requests
- IPC handlers → Media handling: attaches media (evidence: `cutline-app/electron/main.mjs`)
- IPC handlers → Edit engine runner: starts engine runs (evidence: `cutline-app/electron/main.mjs`)
- Edit engine runner → Looks: resolves look (evidence: `cutline-app/electron/engine.mjs`)
- Edit engine runner → Remotion renderer: renders composition (evidence: `README.md`)
- Motion graphics mode → Desktop API: requests motion workflow (evidence: `cutline-app/src/lib/api.ts`)
- IPC handlers → Motion generation: uses recording (evidence: `cutline-app/electron/main.mjs`)
- Motion generation → AI planning: generates motion script (evidence: `cutline-app/electron/motion.mjs`)
- Motion generation → ElevenLabs: requests voice (evidence: `README.md`)
- Motion generation → Remotion renderer: builds animation (evidence: `README.md`)
- IPC handlers → Reference recreation: runs reference build (evidence: `cutline-app/electron/main.mjs`)
- Reference recreation → Reference analysis: analyzes reference (evidence: `cutline-app/electron/agentbuild.mjs`)
- Reference recreation → AI planning: asks Claude to build (evidence: `cutline-app/electron/agentbuild.mjs`)
- Analyze reel → Desktop API: requests analysis (evidence: `cutline-app/src/screens/Analyze.tsx`)
- IPC handlers → Reference library: describes reference (evidence: `cutline-app/electron/main.mjs`)
- Analyze reel → Looks: creates look from analysis
- IPC handlers → AI planning: runs AI edit (evidence: `cutline-app/electron/main.mjs`)
- AI planning → Claude: plans edit (evidence: `README.md`)
- AI planning → Free model routing: uses free fallback (evidence: `cutline-app/electron/ai.mjs`)
- Free model routing → FreeLLM gateway: gets backend (evidence: `cutline-app/electron/freellm.mjs`)
- FreeLLM gateway → Claude: routes model requests
- AI planning → Project memory: loads project context (evidence: `cutline-app/electron/ai.mjs`)
- IPC handlers → Project memory: records spelling fixes (evidence: `cutline-app/electron/main.mjs`)
- IPC handlers → Settings and projects: saves settings and plans (evidence: `cutline-app/electron/main.mjs`)
- Media handling → Settings and projects: uses cache (evidence: `cutline-app/electron/media.mjs`)
- Reference library → Settings and projects: uses project storage (evidence: `cutline-app/electron/library.mjs`)
