Sapari¶
Internal documentation for the Sapari AI-powered video editing platform.
What This Is¶
Sapari automates the tedious parts of video editing — silence removal, false start detection, asset overlays, and rendering. Users upload videos or paste YouTube URLs, we analyze them with Whisper and LLMs, then render the final cut with FFmpeg.
The system is built on FastAPI with TaskIQ workers for background processing, Cloudflare R2 for storage, and Redis for task queues and pub/sub events.
Quick Links¶
| Section | What You'll Find |
|---|---|
| Quickstart | Run the stack locally |
| Architecture | How the pieces fit together |
| Backend | API routes, models, render pipeline |
| Frontend | React architecture, state, SSE |
| Development | Patterns for modules, services, routes |
| AI & Workers | Pipelines, steps, LLM integration |
| Operations | Deployment, migrations, monitoring |
| QA | Manual testing checklists (desktop, mobile, billing) |
| Brand | Writing guidelines and brand voice |
Key Directories¶
backend/
├── src/
│ ├── infrastructure/ # Storage, auth, stripe, taskiq, events, config
│ ├── interfaces/ # API routes
│ ├── modules/ # Business logic (project, clip, edit, credits, payment, entitlement, etc.)
│ └── workers/ # Analysis, render, download, asset_edit
└── tests/
frontend/
├── App.tsx # Entry point with providers
├── shell/ # App orchestration (Dashboard, Sidebar)
├── features/ # Self-contained feature modules
│ ├── projects/ # Project CRUD, SSE events
│ ├── clips/ # Clip management
│ ├── edits/ # Edit operations
│ ├── assets/ # Asset management (overlays, audio, intros)
│ ├── exports/ # Export panel
│ ├── mobile/ # Mobile UI (SwipeReview, FocusMode)
│ └── ... # analysis, auth, captions, video-player, etc.
├── shared/ # Cross-cutting concerns
│ ├── api/ # API client, React Query
│ ├── ui/ # UI components, icons
│ └── lib/ # SSE, logger, storage
└── types.ts # Frontend UI types
landing/ # Astro static marketing site
├── src/
└── package.json
docs/ # Documentation (served with uvx zensical serve)