Files
momentry_studio/AGENTS.md

2.1 KiB

AGENTS.md

Stack

  • Frontend: Vue 3 + TypeScript + Vite (port 5173)
  • Desktop: Tauri 2 (Rust backend in src-tauri/)
  • Runtime: Node.js + npm + Rust/Cargo all required

Commands

npm run dev          # Vite dev server (port 5173)
npm run build        # vue-tsc --noEmit && vite build (typecheck + bundle)
npm run preview      # Preview production build
npm run tauri        # Alias for `cargo tauri`
cargo tauri dev      # Full Tauri desktop dev (builds frontend + opens native window)
cargo tauri build    # Full native app build (outputs to src-tauri/target/release/bundle/)

Architecture

  • All Core API calls go through Rust Tauri commands — frontend NEVER contacts localhost:3002 directly.
  • Rust proxies to external API: CORE_API = http://localhost:3002 (hardcoded in src-tauri/src/main.rs). This service must be running for the app to function.
  • API key: Hardcoded in src-tauri/src/main.rs only (API_KEY constant).
  • Rust entrypoint: src-tauri/src/main.rs — 15 Tauri commands:
    • search_llm_smart, get_files, get_people, get_faces, get_traces (data APIs)
    • get_thumbnail, get_identity_profile (return base64 image strings)
    • get_video_stream (returns file:// URL to temp MP4)
    • update_identity_name, delete_identity (identity management)
    • search_identities, get_face_candidates (search)
    • merge_identities, bind_face, unbind_face (identity ops)
  • Frontend routes: /search, /library, /people (redirect //search)
  • Frontend entry: src/main.tssrc/App.vuesrc/router/index.ts

Key Details

  • withGlobalTauri: true in tauri.conf.jsonwindow.__TAURI__ is available in the webview.
  • No linter, formatter, or tests configured — do not invent them unless asked.
  • TypeScript is non-strict (strict: false in tsconfig.json).
  • CI/CD: Shell scripts only (ci-cd.sh, local-ci-cd.sh, setup-gitea-ci.sh). No GitHub Actions.
  • Full native build order: npm installnpm run buildcargo tauri build
  • Rust deps: sqlx (postgres), reqwest, tokio, tauri-plugin-shell, base64