Pantograph is a local-first headless framework with an optional GUI desktop app that provides a unified local inference API, node based workflows, system resource aware runtime schedualing, real-time observability and diagnostic tracing of Ai pipelines. Functionality is provided via language bindings for Python, C#, Elixir, or the native Rust API surface.
- Clone the repository.
- Install dependencies:
npm install
- Run the desktop app:
npm run dev:desktop
- Node.js (for
npm) - Rust toolchain (
cargo,rustc) - Tauri system libraries for your OS
Install Rust:
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh source "$HOME/.cargo/env"
Install Tauri system dependencies:
# Debian/Ubuntu sudo apt install pkg-config libsoup2.4-dev libjavascriptcoregtk-4.0-dev # Fedora sudo dnf install pkgconf-pkg-config libsoup-devel javascriptcoregtk4.0-devel # Arch sudo pacman -S pkgconf libsoup2 webkit2gtk
Install project dependencies:
npm install
npm run dev:desktop
npm run dev
The Vite dev server binds to 127.0.0.1 by default. For an intentional LAN
preview, set PANTOGRAPH_VITE_HOST=0.0.0.0 when starting the server.
npm run build:desktop
./launcher.sh --help ./launcher.sh --test ./launcher.sh --release-smoke
- External OpenAI-compatible server (for example LM Studio)
- Bundled
llama.cppsidecar with local model files
- Node.js + npm matching
.node-versionandpackage.json - Rust toolchain matching
rust-toolchain.toml - Python matching
.python-versionfor Python-backed smoke paths - Tauri system dependencies (above)
Pinned toolchain ownership and update policy are documented in
docs/toolchain-policy.md.
# Lint (configured scope) npm run lint # Full lint scan npm run lint:full # Critical anti-pattern gate (src/ + packages/) npm run lint:critical # Focused Svelte accessibility gate npm run lint:a11y # No-new-debt gate for critical anti-patterns and decision traceability npm run lint:no-new # Rust formatting audit npm run format:check # Type check npm run typecheck # Tests npm test # Runtime separation guard (no compile-time Python linkage) npm run test:runtime-separation # Opt-in BEAM / Rustler host smoke npm run test:rustler-beam-smoke # Configured quality gates npm run check # Canonical local quality gate ./launcher.sh --test
Testing placement, cross-layer acceptance requirements, and release-smoke CI
strategy are documented in docs/testing-and-release-strategy.md.
Python-backed model execution is intentionally out-of-process and externally provisioned.
See docs/python-runtime-separation.md for configuration and migration details.
For a local diffusion worker smoke path, run:
./.venv/bin/python scripts/diffusion_cli_smoketest.py --model-path /path/to/tiny-sd-turbo
Pantograph exposes a Rust-first headless workflow API for host integrations
through crates/pantograph-workflow-service:
workflow_runworkflow_get_capabilitiesworkflow_get_ioworkflow_preflightcreate_workflow_sessionrun_workflow_sessionclose_workflow_sessionworkflow_get_session_statusworkflow_list_session_queueworkflow_cancel_session_queue_itemworkflow_reprioritize_session_queue_itemworkflow_set_session_keep_alive
Integration boundary:
- Headless hosts should integrate with the core API/service crate directly.
src-tauricommands are desktop app transport adapters, not the headless API.- HTTP binding exports are opt-in frontend adapters for modular standalone GUI
hosting (
frontend-httpin UniFFI and Rustler). - Recommended headless flow:
workflow_get_io->workflow_preflight->workflow_run.
| Path | Description |
|---|---|
src/ |
Frontend Svelte app, UI components, stores, and services |
src-tauri/src/ |
Tauri backend commands and runtime wiring |
crates/ |
Shared Rust crates (inference, node-engine, workflow-nodes, bindings) |
packages/svelte-graph/src/ |
Reusable graph editor package modules |
scripts/ |
Validation and tooling scripts |
docs/ |
Architecture and process documentation |
- Create a focused branch for one logical change.
- Follow coding, tooling, accessibility, and documentation standards.
- Run
./launcher.sh --testand relevant targeted checks before opening a PR. - Use Conventional Commits for all commits.
Workspace crates declare MIT OR Apache-2.0 in Cargo metadata. Review individual package metadata for any exceptions.