Skip to content

Development

Project Shape

text
vidbgm/
  Cargo.toml
  src/
    lib.rs
    main.rs
  desktop/
    package.json
    src/
    src-tauri/
  tools/
    eval_vision_prompts.py
  docs/

The root Rust crate owns the CLI and shared orchestration. The desktop app calls shared Rust functions through Tauri commands.

Rust Checks

bash
cargo test
bash
cargo build

Desktop Checks

bash
cd desktop
pnpm build
bash
cd desktop
pnpm tauri dev

Debug Tauri builds create local FFmpeg/FFprobe wrappers that forward to ffmpeg and ffprobe on PATH, so development and tests do not require committing media binaries. Release packaging requires real sidecar binaries:

bash
cd desktop
VIDBGM_FFMPEG=/path/to/ffmpeg \
VIDBGM_FFPROBE=/path/to/ffprobe \
pnpm prepare:ffmpeg-sidecars

Docs Checks

Install docs dependencies from the repo root:

bash
pnpm install

Run the docs site:

bash
pnpm docs:dev

Build the static docs:

bash
pnpm docs:build

Generated VitePress output stays out of git:

  • docs/.vitepress/dist/
  • docs/.vitepress/cache/

Vision Prompt Eval

Use the local QAT model to compare frame-analysis prompt variants:

bash
python3 tools/eval_vision_prompts.py \
  --video sample-video.mov \
  --model google/gemma-4-12b-qat \
  --max-frames 4 \
  --duration 240 \
  --out-dir output/vision-prompt-eval-v3

The eval writes results.csv, raw_results.json, and summary.json.

Rust CLI and Tauri desktop docs for adaptive video background music generation.