Overview — Rust plays, Julia learns, a model file sits between them
samples / recordings
│
▼
Julia training/ ──export──▶ models/<instrument>/<version>/
model.safetensors · manifest.toml · golden.safetensors
▲ │
│ ccall (optional parity test) ▼
└────────────────────── Rust crates/dsp (inference, allocation-free)
│
▼
crates/<instrument> (clack: CLAP; VST3/AU later via clap-wrapper)
│
▼
host / DAWRepository layout
| Path | What | Language |
|---|---|---|
crates/dsp/ (instruments-dsp) | Framework-free DSP and model inference: the Processor trait, no allocation in event/render. Today: PianoEngine (stage 1, format v1; T-008) and the placeholder SineVoices | Rust |
crates/model-format/ (instruments-model-format, T-015) | Reads and validates model files (safetensors + manifest + golden vectors); the piano’s format v3 as PianoModelV3 (Piano model file) | Rust |
crates/piano/ (instruments-piano) | The piano’s CLAP plugin on clack: ports, params, state, egui GUI in the host window; plays PianoEngine with the committed salamander-c5 model compiled in (T-009); tests with an in-process host | Rust |
crates/demos/ (instruments-demos, T-040) | Offline demo renders: reads MIDI files (midly), plays them through PianoEngine with the plugin’s model in 64-sample blocks, writes WAV; compose writes the pieces that are the project’s own | Rust |
crates/gui/ (planned) | Shared egui widgets (knobs, meters, keyboard) behind an Editor trait (ADR-0006) | Rust |
crates/params/ (instruments-params, T-025) | Framework-free parameter descriptions, atomic value and gesture exchange, text conversion and state for the piano plugin and editor | Rust |
crates/tuning/ (instruments-tuning, T-049) | Microtuning shared by all instruments: Scala .scl/.kbm parsing and mapping, and the MTS-ESP client (a Rust port of ODDSound’s loader, libMTS loaded at run time; the workspace’s only FFI) | Rust |
crates/standalone, web/ (planned, M6) | Standalone instrument for PC/Raspberry Pi with a Dioxus web remote (Standalone and remote) | Rust |
crates/xtask/ | cargo xtask bundle piano [--release] → target/bundled/Instruments Piano.clap (later clap-wrapper’s VST3/AU); cargo xtask render-demos → target/demos/ | Rust |
scripts/ | nix-develop-git.sh (dev shell in cloud sessions), gui-smoke-test.sh (X11 editor test on Xvfb), publish-demos.sh (demo renders to the listening branch) | shell |
training/ (T-004) | Julia project (Project.toml + Manifest.toml): data loading, model, training, export | Julia |
models/<instrument>/<version>/ | Exported model files and golden vectors (Git LFS if large): neural models and fitted physical parameters alike | data |
demos/ (T-040) | The demo set’s MIDI files, their sources and licences (README.md), and CHANGES.md (one line per refresh of the renders, which live on the listening branch) | MIDI / Markdown |
docs/ | This vault | Markdown |
site/ | Builds the vault with Quartz | shell / TS |
Two seams keep the parts replaceable: the DSP core knows nothing about plugin formats (ADR-0002), and Rust and Julia share only the model file (ADR-0003).