Skip to content

feat: Dossier Desktop — Tauri app with embedded Next.js UI#4

Open
ruvnet wants to merge 7 commits intorwliebs:mainfrom
ruvnet:wyr-rust-ruvector
Open

feat: Dossier Desktop — Tauri app with embedded Next.js UI#4
ruvnet wants to merge 7 commits intorwliebs:mainfrom
ruvnet:wyr-rust-ruvector

Conversation

@ruvnet
Copy link
Copy Markdown

@ruvnet ruvnet commented Mar 6, 2026

Summary

  • Adds a Rust/Tauri 2.x desktop application that wraps the real Dossier Next.js UI into a native window
  • Tauri binary spawns the Next.js standalone server on startup, waits for TCP readiness, then navigates the webview to http://127.0.0.1:{port}
  • Includes pure-Rust HNSW vector index (wyr-ruvector), WYR preference-learning game engine (wyr-core), and RVF binary format inspector
  • 17 Tauri IPC commands: 6 WYR game, 9 Dossier DB CRUD, 1 RVF inspector, 1 HNSW stats
  • Rust SQLite adapter (rusqlite bundled) compatible with Dossier's existing schema
  • 10 passing tests, 0 clippy warnings
  • Windows release binary: ~10MB, NSIS installer: ~2.5MB

Closes #3

Architecture

The Tauri shell acts as a lightweight native wrapper:

  1. Startup: Shows splash screen → finds node + .next/standalone/server.js → spawns server → polls port readiness
  2. Ready: Navigates webview to http://127.0.0.1:{port} — loads the full Dossier React UI with all components, API routes, and AI orchestration
  3. Shutdown: Kills the Node.js server process on window close
Tauri Binary (Rust)
├── wyr-ruvector  — HNSW vector index (cosine similarity, KNN search)
├── wyr-core      — WYR game engine (16 questions, 8 categories, EMA profiles)
└── wyr-app       — Tauri shell
    ├── Next.js server launcher (spawn, port discovery, TCP poll)
    ├── Dossier DB adapter (rusqlite, 7 tables, full CRUD)
    ├── RVF inspector (24 segment types, 64-byte aligned)
    └── 17 Tauri IPC commands

Platform Build Targets

Platform Binary Installer Status
Windows x64 wyr-app.exe (~10MB) NSIS .exe (~2.5MB) Tested
Windows ARM64 wyr-app.exe NSIS .exe Needs cross-compile
macOS x64 Dossier Desktop.app .dmg Needs macOS CI
macOS ARM64 Dossier Desktop.app .dmg Needs macOS CI
Linux x64 dossier-desktop .deb / .AppImage Needs Linux CI

Build Instructions

# Prerequisites: Rust stable, Node.js v18+, pnpm
# On Windows: RUSTUP_TOOLCHAIN=stable-x86_64-pc-windows-msvc

# 1. Build the Next.js standalone app
pnpm install && pnpm run build

# 2. Build & run the Tauri desktop app
cd wyr && cargo run --package wyr-app

# 3. Run tests (10 passing)
cd wyr && cargo test

# 4. Clippy (0 warnings)
cd wyr && cargo clippy

# 5. Release build with installer
cd wyr/wyr-app && cargo tauri build

Key Files

File Lines Description
wyr/wyr-app/src/lib.rs 270 Tauri setup: spawn Next.js, navigate webview
wyr/wyr-app/src/commands.rs 215 17 Tauri IPC commands
wyr/wyr-app/src/dossier_db.rs 328 Rust SQLite adapter (CRUD)
wyr/wyr-app/src/rvf_inspector.rs 177 RVF binary parser (24 segment types)
wyr/wyr-app/src/schema.sql 70 Dossier-compatible SQLite schema
wyr/wyr-ruvector/src/hnsw.rs 266 Full HNSW graph index
wyr/wyr-ruvector/src/vector.rs 79 Vector type + arithmetic
wyr/wyr-ruvector/src/similarity.rs 54 Cosine similarity, Euclidean distance
wyr/wyr-core/src/engine.rs 94 GameEngine (next_question, answer)
wyr/wyr-core/src/question.rs 120 16 seed questions, 8 categories
wyr/wyr-core/src/preference.rs 119 EMA profiles, HNSW answer history

Test Results

running 10 tests
test wyr_ruvector::vector::tests::test_vector_new ............. ok
test wyr_ruvector::vector::tests::test_vector_normalize ....... ok
test wyr_ruvector::vector::tests::test_vector_add_scale ....... ok
test wyr_ruvector::similarity::tests::test_cosine_identical ... ok
test wyr_ruvector::similarity::tests::test_cosine_orthogonal .. ok
test wyr_ruvector::similarity::tests::test_cosine_opposite .... ok
test wyr_ruvector::similarity::tests::test_euclidean .......... ok
test wyr_ruvector::hnsw::tests::test_insert_and_len .......... ok
test wyr_ruvector::hnsw::tests::test_search .................. ok
test wyr_ruvector::hnsw::tests::test_get_vector .............. ok

test result: ok. 10 passed; 0 failed; 0 ignored
cargo clippy: 0 warnings

Test plan

  • cargo test — 10 tests pass (vector, similarity, HNSW, game engine)
  • cargo clippy — 0 warnings
  • cargo build --release — builds successfully on Windows x64
  • App launches, splash screen shows, Next.js server starts on port 3000
  • Webview navigates to Dossier UI after server readiness
  • Next.js standalone server responds with HTTP 307 (redirect to default project)
  • macOS build (requires macOS CI runner)
  • Linux build (requires Linux CI runner)
  • Windows ARM64 cross-compile
  • Tauri bundle installer (cargo tauri build)

🤖 Generated with claude-flow

Introduces a Rust/Tauri desktop application that wraps the actual Dossier
Next.js product planning UI into a native desktop window. On startup the
Tauri binary spawns the Next.js standalone server, waits for readiness,
then navigates the webview to the local server.

Key components:
- wyr-ruvector: pure-Rust HNSW vector index + cosine similarity (10 tests)
- wyr-core: WYR preference-learning game engine (seed questions, EMA profiles)
- wyr-app: Tauri 2.x shell that launches Next.js standalone + exposes
  Dossier DB, WYR game, and RVF inspector as Tauri commands
- RVF inspector: parses all 24 RuVector Format segment types
- Dossier DB adapter: Rust/SQLite layer compatible with Dossier schema

Architecture: Tauri spawns node .next/standalone/server.js, polls TCP
readiness, then calls webview.navigate() to load the full Dossier UI
including all React components, API routes, and AI orchestration features.

Co-Authored-By: claude-flow <ruv@ruv.net>
@vercel
Copy link
Copy Markdown
Contributor

vercel bot commented Mar 6, 2026

@rwliebs is attempting to deploy a commit to the richardliebrecht-gmailcom's projects Team on Vercel.

A member of the Team first needs to authorize it.

rwliebs and others added 6 commits March 6, 2026 15:57
Adds a clear "Desktop app" section above the existing quickstart with
download links to the Releases page, platform table (Windows .exe,
macOS .dmg), and plain-language usage instructions. Renames the
existing quickstart to "Run in the browser" so both options are visible.

Co-Authored-By: claude-flow <ruv@ruv.net>
- docs/adr/0011-rvf-agent-packages.md: ADR for RVF agent package format
- docs/domains/rvf-*.md: kernel, openclaw, package, runtime, security refs
- .mcp.json: MCP server configuration
- CLAUDE.md: Claude Code project configuration
- wyr/wyr-app/capabilities/default.json: Tauri capability manifest
- pnpm-lock.yaml: updated after pnpm install

Co-Authored-By: claude-flow <ruv@ruv.net>
Points README download table to actual release binaries on GitHub
with file sizes and direct download URLs for the Windows NSIS, MSI,
and portable exe installers.

Co-Authored-By: claude-flow <ruv@ruv.net>
Builds Tauri desktop app on 4 platforms via matrix:
- Windows x64 (NSIS .exe + MSI)
- macOS ARM64 (Apple Silicon .dmg)
- macOS x64 (Intel .dmg)
- Linux x64 (.deb + .AppImage)

Triggers on desktop-v* tags or manual workflow_dispatch.
Uploads artifacts and creates a GitHub release with all binaries.

Co-Authored-By: claude-flow <ruv@ruv.net>
macos-13 runner is not available; macos-latest (ARM64) can cross-compile
to x86_64-apple-darwin via the Rust target flag.

Co-Authored-By: claude-flow <ruv@ruv.net>
- README: add direct download links for macOS ARM64 and Intel .dmg files
- CI: fix Windows postbuild (use bash shell, mkdir before cp)
- CI: remove RUSTFLAGS that broke Linux GTK linking
- CI: release job runs even if some matrix jobs fail

Co-Authored-By: claude-flow <ruv@ruv.net>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: Dossier Desktop — native Tauri app with embedded Next.js UI

2 participants