# amit0119/ai-infographic-video architecture

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

- Interactive diagram: https://gitdiagram.com/amit0119/ai-infographic-video
- Repository: https://github.com/amit0119/ai-infographic-video

## Overview

This is an AI-driven infographic video engine. Users upload corporate data, review and revise an AI-generated storyboard, set branding, then approve a video rendered with scene narration and music. The README documents the backend capabilities and user flow; the source excerpts show the Remotion composition dispatching scenes and attaching audio and B-roll. Backend internals beyond the named files were not excerpted, so those relationships are based on the README rather than inspected implementation details.

Main entry points: [`backend/main.py`](https://github.com/amit0119/ai-infographic-video/blob/main/backend/main.py) (Storyboard API), [`src/Root.tsx`](https://github.com/amit0119/ai-infographic-video/blob/main/src/Root.tsx) (Scene composition), [`backend/static/index.html`](https://github.com/amit0119/ai-infographic-video/blob/main/backend/static/index.html) (Control panel), [`public`](https://github.com/amit0119/ai-infographic-video/tree/main/public) (Media assets)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_authoring["Storyboard authoring"]
  node_panel["Control panel<br/>[index.html]"]
  node_api["Storyboard API<br/>[main.py]"]
  node_gemini{{"Gemini API"}}
  node_storyboard["Storyboard data<br/>[storyboard.json]"]
end

subgraph group_media["Audio and media"]
  node_audio["Voiceover generation"]
  node_tts{{"Edge-TTS"}}
  node_broll["B-roll preparation"]
  node_assets[("Media assets")]
end

subgraph group_rendering["Video rendering"]
  node_composition["Scene composition<br/>[Root.tsx]"]
  node_scenevisuals["Scene visualizations"]
  node_dashboard["Dashboard scene<br/>[DashboardUI.tsx]"]
  node_captions["Caption overlay<br/>[Captions.tsx]"]
  node_brollview["B-roll background"]
  node_glass["Glass card<br/>[GlassCard.tsx]"]
  node_entry["Remotion entry<br/>[index.ts]"]
end

subgraph group_contracts["Scene contracts"]
  node_types["Scene definitions<br/>[types.ts]"]
end

node_user(("Video author"))

node_user -->|"uploads data"| node_panel
node_panel -->|"submits data"| node_api
node_api -->|"generates storyboard"| node_gemini
node_gemini -->|"returns storyboard"| node_api
node_api -.->|"provides storyboard"| node_storyboard
node_user -->|"requests revisions"| node_panel
node_panel -->|"sends revision prompt"| node_api
node_user -->|"sets branding"| node_panel
node_panel -->|"approves render"| node_api
node_api -->|"generates narration"| node_audio
node_audio -->|"synthesizes speech"| node_tts
node_audio -.->|"writes audio"| node_assets
node_api -.->|"prepares B-roll"| node_broll
node_broll -.->|"fetches footage"| node_assets
node_entry -->|"registers composition"| node_composition
node_composition -->|"renders scene types"| node_scenevisuals
node_composition -->|"renders dashboard scene"| node_dashboard
node_composition -->|"renders captions"| node_captions
node_composition -->|"renders background"| node_brollview
node_composition -->|"loads audio assets"| node_assets
node_brollview -.->|"loads footage"| node_assets
node_scenevisuals -->|"uses card"| node_glass
node_composition -.->|"uses scene data"| node_types
node_dashboard -->|"uses scene props"| node_types

click node_panel "https://github.com/amit0119/ai-infographic-video/blob/main/backend/static/index.html"
click node_api "https://github.com/amit0119/ai-infographic-video/blob/main/backend/main.py"
click node_storyboard "https://github.com/amit0119/ai-infographic-video/blob/main/src/data/storyboard.json"
click node_audio "https://github.com/amit0119/ai-infographic-video/blob/main/backend/generate_all_audio.py"
click node_broll "https://github.com/amit0119/ai-infographic-video/blob/main/backend/predownload_broll.py"
click node_assets "https://github.com/amit0119/ai-infographic-video/tree/main/public"
click node_composition "https://github.com/amit0119/ai-infographic-video/blob/main/src/Root.tsx"
click node_scenevisuals "https://github.com/amit0119/ai-infographic-video/tree/main/src/components"
click node_dashboard "https://github.com/amit0119/ai-infographic-video/blob/main/src/components/DashboardUI.tsx"
click node_captions "https://github.com/amit0119/ai-infographic-video/blob/main/src/components/Captions.tsx"
click node_brollview "https://github.com/amit0119/ai-infographic-video/blob/main/src/components/BRollBackground.tsx"
click node_glass "https://github.com/amit0119/ai-infographic-video/blob/main/src/components/GlassCard.tsx"
click node_types "https://github.com/amit0119/ai-infographic-video/blob/main/src/types.ts"
click node_entry "https://github.com/amit0119/ai-infographic-video/blob/main/src/index.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_panel,node_api,node_gemini,node_storyboard toneBlue
class node_audio,node_tts,node_broll,node_assets toneAmber
class node_composition,node_scenevisuals,node_dashboard,node_captions,node_brollview,node_glass,node_entry toneMint
class node_types toneRose
class node_user toneIndigo
```

## Components

### Storyboard authoring

- [Control panel](https://github.com/amit0119/ai-infographic-video/blob/main/backend/static/index.html): `backend/static/index.html`
- [Storyboard API](https://github.com/amit0119/ai-infographic-video/blob/main/backend/main.py): `backend/main.py`
- **Gemini API**
- [Storyboard data](https://github.com/amit0119/ai-infographic-video/blob/main/src/data/storyboard.json): `src/data/storyboard.json`

### Audio and media

- [Voiceover generation](https://github.com/amit0119/ai-infographic-video/blob/main/backend/generate_all_audio.py): `backend/generate_all_audio.py`
- **Edge-TTS**
- [B-roll preparation](https://github.com/amit0119/ai-infographic-video/blob/main/backend/predownload_broll.py): `backend/predownload_broll.py`
- [Media assets](https://github.com/amit0119/ai-infographic-video/tree/main/public): `public`

### Video rendering

- [Scene composition](https://github.com/amit0119/ai-infographic-video/blob/main/src/Root.tsx): `src/Root.tsx`
- [Scene visualizations](https://github.com/amit0119/ai-infographic-video/tree/main/src/components): `src/components`
- [Dashboard scene](https://github.com/amit0119/ai-infographic-video/blob/main/src/components/DashboardUI.tsx): `src/components/DashboardUI.tsx`
- [Caption overlay](https://github.com/amit0119/ai-infographic-video/blob/main/src/components/Captions.tsx): `src/components/Captions.tsx`
- [B-roll background](https://github.com/amit0119/ai-infographic-video/blob/main/src/components/BRollBackground.tsx): `src/components/BRollBackground.tsx`
- [Glass card](https://github.com/amit0119/ai-infographic-video/blob/main/src/components/GlassCard.tsx): `src/components/GlassCard.tsx`
- [Remotion entry](https://github.com/amit0119/ai-infographic-video/blob/main/src/index.ts): `src/index.ts`

### Scene contracts

- [Scene definitions](https://github.com/amit0119/ai-infographic-video/blob/main/src/types.ts): `src/types.ts`

### Other components

- **Video author**

## Connections

- Video author → Control panel: uploads data (evidence: `README.md`)
- Control panel → Storyboard API: submits data (evidence: `README.md`)
- Storyboard API → Gemini API: generates storyboard (evidence: `README.md`)
- Gemini API → Storyboard API: returns storyboard (evidence: `README.md`)
- Storyboard API → Storyboard data: provides storyboard
- Video author → Control panel: requests revisions (evidence: `README.md`)
- Control panel → Storyboard API: sends revision prompt (evidence: `README.md`)
- Video author → Control panel: sets branding (evidence: `README.md`)
- Control panel → Storyboard API: approves render (evidence: `README.md`)
- Storyboard API → Voiceover generation: generates narration (evidence: `README.md`)
- Voiceover generation → Edge-TTS: synthesizes speech (evidence: `README.md`)
- Voiceover generation → Media assets: writes audio
- Storyboard API → B-roll preparation: prepares B-roll
- B-roll preparation → Media assets: fetches footage
- Remotion entry → Scene composition: registers composition (evidence: `src/index.ts`)
- Scene composition → Scene visualizations: renders scene types (evidence: `src/Root.tsx`)
- Scene composition → Dashboard scene: renders dashboard scene (evidence: `src/Root.tsx`)
- Scene composition → Caption overlay: renders captions (evidence: `src/Root.tsx`)
- Scene composition → B-roll background: renders background (evidence: `src/Root.tsx`)
- Scene composition → Media assets: loads audio assets (evidence: `src/Root.tsx`)
- B-roll background → Media assets: loads footage
- Scene visualizations → Glass card: uses card (evidence: `src/components/BarChart.tsx`)
- Scene composition → Scene definitions: uses scene data (evidence: `src/Root.tsx`)
- Dashboard scene → Scene definitions: uses scene props (evidence: `src/components/DashboardUI.tsx`)
