Skip to content

Repository files navigation

SlateCut

SlateCut is a local-first desktop video editor for creators who cut talking-head and interview-style footage. It edits video the way you'd edit a transcript: remove filler words and dead air automatically, let AI pick the best take when you recorded several, add zoom moments and captions, and render the result locally with hardware-accelerated ffmpeg — no footage ever leaves your machine unless you explicitly enable a cloud transcription or AI provider.

A video demo is on its way — the maintainer is recording one.

Project status

SlateCut is pre-release and under active development. Expect rough edges, missing polish, and breaking changes between commits.

  • macOS (Apple Silicon and Intel) is the only platform that has actually been built and run. The architecture is cross-platform by design — the default render backend is ffmpeg on every OS, an AVFoundation backend is an optional non-default feature, and local Whisper can run on CUDA/DirectML/CPU as well as Apple's MLX — but Windows and Linux are designed for, not yet tested. There is no CI yet. Treat Windows/Linux instructions in this document as best-effort, not verified.
  • There are no pre-built releases. Build from source (see below).

Architecture

React / TypeScript UI  <-->  Rust core (Tauri shell)  <-->  Python FastAPI sidecar
   (Tauri webview)             workspace crates            (transcription + media
                                                              intelligence)
  • UI — React + TypeScript, rendered inside the Tauri webview (ui/). It is a read-only projection of the Rust-owned project state; all mutation goes through Tauri commands.
  • Rust core — a Cargo workspace:
    • crates/lg-core — the render/EDL engine: project model, edit operations, ffmpeg render backend, encoder detection, HDR handling.
    • crates/lg-agent — the AI-brain broker: picks between a headless CLI subscription backend (claude -p / codex exec), an API-key backend (OpenAI/NVIDIA NIM/Gemini, OpenAI-compatible), and an optional MCP backend.
    • crates/lg-sidecar-bridge — typed Rust client for the Python sidecar's HTTP API.
    • src-tauri — the Tauri shell itself (binary/library name slatecut): command surface, sidecar process supervisor, keychain-backed credential storage, event emission.
  • Python sidecar — FastAPI service (sidecar/) wrapping transcription and media-intelligence logic (silence/filler/take/zoom detection, YouTube metadata generation, OTIO/FCPXML/Premiere/Resolve export). It is spawned and supervised by the Rust shell, binds 127.0.0.1 only, and every request (including GET /health) must carry a per-session secret the shell generates at launch and sends via the X-LG-Secret header.

Prerequisites

  • Rust (stable) via rustup, plus the Tauri CLI v2 — invoked here as cargo tauri (cargo install tauri-cli --version "^2", or use npx @tauri-apps/cli if you prefer not to install it globally).
  • Node.js 18+ (Vite 5 requires Node ^18 or 20+) and npm.
  • Python 3.10+ and uv for the sidecar.
  • ffmpeg and ffprobe on your PATH for dev mode. SlateCut deliberately does not bundle these in a source checkout — only packaged releases bundle real, capability-checked binaries (see src-tauri/resources/README.md). Your system ffmpeg should ideally support libass (caption burn-in) and, on macOS, h264_videotoolbox/hevc_videotoolbox; Homebrew ffmpeg builds have shipped without libass before, so verify with ffmpeg -filters | grep subtitles if captions misbehave.
  • macOS: Xcode Command Line Tools (xcode-select --install) for the Rust toolchain to link native dependencies.

Quick start (dev mode)

# 1. Clone and enter the repo
git clone https://github.com/Zambrini/slatecut.git
cd slatecut

# 2. Install UI dependencies
cd ui && npm install && cd ..

# 3. Install sidecar dependencies (light base install; add ML extras as needed)
cd sidecar
uv sync                        # light base: FastAPI + uvicorn + pydantic + numpy
# On Apple Silicon, add local Whisper support:
uv pip install -e '.[mlx]'
# On other platforms (CUDA/DirectML/CPU), use the torch extra instead:
# uv pip install -e '.[torch]'
cd ..

# 4. Launch the real desktop app in dev mode
cargo tauri dev

cargo tauri dev runs tauri.conf.json's beforeDevCommand (npm --prefix ui run dev, i.e. Vite) automatically and opens the actual Tauri desktop window — this is the real app.

Browser test-bridge (secondary, browser-only — not the app)

For quick UI iteration in an ordinary Chrome tab (no .app bundle, so accessibility/computer-use tooling can target it), run the HTTP+WebSocket bridge that mirrors every Tauri command over plain HTTP:

cd ui && npm run dev            # Vite dev server, if not already running
cargo run -p slatecut --example test_bridge   # in another terminal, from repo root

Then open http://localhost:1420 in a normal browser tab. ui/src/lib/tauri.ts detects the absence of window.__TAURI_INTERNALS__ and routes invoke/listen through this bridge instead of real Tauri IPC. This harness is useful for testing against a real sidecar without the native window, but it is not a substitute for running the actual app via cargo tauri dev.

Configuration

Cloud transcription and AI providers are optional and configured via environment variables. Copy .env.example to .env and fill in only the providers you want:

  • Transcription: ElevenLabs Scribe (ELEVENLABS_API_KEY), Deepgram (DEEPGRAM_API_KEY), NVIDIA Riva (RIVA_SERVER, gRPC, stubbed), or fully local Whisper/WhisperX (no key required).
  • AI brain (EDL editing decisions, YouTube metadata): a headless CLI subscription backend (claude or codex on PATH) is preferred; otherwise an API-key backend (OPENAI_API_KEY, NVIDIA_API_KEY, GEMINI_API_KEY). The desktop app also stores keys you paste into Settings in the OS keychain.

See docs/transcription-providers.md for a one-off local comparison of the transcription providers.

Building a release package

Packaged builds require real, capability-checked ffmpeg/ffprobe binaries and a frozen sidecar — none of these are checked into the repository. scripts/prepare-release-binaries.mjs (run automatically by Tauri's beforeBuildCommand, and safe to run standalone) stages them and enforces:

  • the binaries are real native executables, not scripts or placeholders;
  • ffmpeg has libx264 and the libass/subtitles filter;
  • ffmpeg has the platform hardware encoder family — h264_videotoolbox/ hevc_videotoolbox on macOS, *_nvenc/*_qsv/*_amf on Windows. Linux hardware-encoder support is not currently verified by this gate — the software libx264 fallback path is untested there.
  • on macOS, the ffmpeg binary isn't linked against Homebrew or other absolute third-party paths (use a relocatable/static build).
node scripts/build-sidecar.mjs
LG_SIDECAR_BIN=/abs/lg-sidecar \
LG_FFMPEG_BIN=/abs/ffmpeg \
LG_FFPROBE_BIN=/abs/ffprobe \
cargo tauri build

See src-tauri/resources/README.md for the full artifact requirements, target-triple overrides, and ffmpeg build flags.

Testing

# Rust workspace (core, agent, sidecar-bridge, Tauri shell)
cargo test --workspace

# UI typecheck + unit tests
cd ui && npm run build && npm test

# Sidecar (module invocation avoids a stale venv console-script shebang)
cd sidecar && uv sync --extra dev && uv run python -m pytest -q

# Release-binary staging gate (no API credentials needed)
node --test scripts/prepare-release-binaries.test.mjs

Contributing

See CONTRIBUTING.md.

License

MIT — see LICENSE.

About

Local-first desktop video editor: transcript-based editing, automatic filler/silence cuts, AI best-take selection, zoom moments, captions, and hardware-accelerated local rendering. Tauri + Rust + React/TypeScript + Python.

Topics

Resources

Contributing

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages