--- license: apache-2.0 language: - en library_name: kokoro-onnx pipeline_tag: text-to-speech base_model: hexgrad/Kokoro-82M tags: - text-to-speech - kokoro - onnx - cpu - local-first - jarvis - british-english - butler --- # Jarvis LVM **A complete, CPU-first British-butler voice model that runs on your machine.** No API key. No cloud TTS. No network request during synthesis. Jarvis LVM packages the Apache-2.0 Kokoro-82M INT8 model, the full Kokoro voice bundle, three purpose-built style vectors, a delivery planner, and a small Python CLI into one self-contained download. It is designed for the OpenJarvis desktop assistant and for any product that needs a low, measured, English-butler delivery on ordinary CPU hardware. Two things carry the character. The **style vector** sets the timbre: a blend of three British male voices whose median pitch sits around 105–114 Hz instead of the stock voice's 137 Hz. The **delivery planner** sets the cadence: it splits a reply at sentence and clause boundaries, inserts a measured pause, and slows the terminal clause, which is what makes the result read as deliberate rather than merely deep. > **What "JARVIS-inspired" means here:** the cadence, pitch, and diction are > tuned toward a polished British male assistant. This is **not** a Paul Bettany > voice clone, was **not** trained on Marvel film audio, and cannot reproduce his > exact likeness. A literal celebrity clone requires a licensed reference voice > model and the actor's permission. This package deliberately contains neither. ## Hear it | Preset | Sample | |---|---| | `jarvis-prime` (default) | [Greeting](samples/jarvis-prime-greeting.wav) · [Briefing](samples/jarvis-prime-briefing.wav) · [Status](samples/jarvis-prime-status.wav) | | `jarvis-classic` | [Greeting](samples/jarvis-classic-greeting.wav) · [Briefing](samples/jarvis-classic-briefing.wav) · [Status](samples/jarvis-classic-status.wav) | | `jarvis-deep` | [Greeting](samples/jarvis-deep-greeting.wav) · [Briefing](samples/jarvis-deep-briefing.wav) · [Status](samples/jarvis-deep-status.wav) | Sample text: *"I have reviewed the overnight telemetry, and the results are encouraging. Your calendar is clear for the next two hours."* ## Quick start ### 1. Download ```bash # Hugging Face CLI (recommended; fetches LFS files) hf download broduer/Jarvis --repo-type model --local-dir jarvis-lvm cd jarvis-lvm ``` Or clone with Git LFS: ```bash git lfs install git clone https://huggingface.co/broduer/Jarvis jarvis-lvm cd jarvis-lvm ``` ### 2. Install Python 3.10–3.12 is supported. CPU only; no CUDA required. ```bash python -m venv .venv # Windows: .venv\Scripts\activate # macOS / Linux: # source .venv/bin/activate pip install -r requirements.txt ``` ### 3. Speak ```bash python -m jarvis_lvm \ --text "Good evening, sir. All systems are functioning within normal parameters." \ --voice jarvis-prime \ --out greeting.wav ``` Output is 24 kHz, mono, 16-bit PCM WAV: ``` wrote greeting.wav voice=jarvis-prime rate=24000Hz duration=5.54s style=jarvis segments=3 threads=6 ``` Install the console command if you prefer: ```bash pip install -e . jarvis-lvm --text "Welcome home, sir." --out welcome.wav ``` Useful options: ```text --voice jarvis-prime|jarvis-classic|jarvis-deep|... select a preset --speed 0.95 default; lower is slower --style jarvis|off measured delivery (default) or plain --lang en-gb Kokoro language code --text-file briefing.txt read a UTF-8 script --raw skip Markdown/acronym cleanup --model-dir PATH assets elsewhere --intra-threads N pin ONNX CPU threads --list-voices show every available voice ``` ## Python API ```python from pathlib import Path from jarvis_lvm import JarvisLVM model = JarvisLVM() # package root, or set JARVIS_LVM_ROOT result = model.synthesize( "Good evening, sir. All systems are functioning within normal parameters.", voice="jarvis-prime", speed=0.95, style="jarvis", ) Path("greeting.wav").write_bytes(result.wav) print(result.seconds, result.sample_rate) ``` `JarvisLVM` loads the ONNX session once. Reuse the instance for every request; it serializes synthesis internally and is safe to call from a worker thread. If the package is installed somewhere other than the asset directory: ```python model = JarvisLVM(root=r"C:\path\to\jarvis-lvm") # or: set JARVIS_LVM_ROOT=C:\path\to\jarvis-lvm ``` ## Use with OpenJarvis Copy the default vector into the app's voice directory, then select `jarvis-original` in the voice picker: ```powershell # Windows copy voices\jarvis-prime.npy "$env:USERPROFILE\.openjarvis\voices\jarvis-original.npy" ``` ```bash # macOS / Linux mkdir -p ~/.openjarvis/voices cp voices/jarvis-prime.npy ~/.openjarvis/voices/jarvis-original.npy ``` For a brighter read, copy `voices/jarvis-classic.npy` instead; `jarvis-deep.npy` is the heaviest. Restart the app after replacing the file. The existing Kokoro model and `voices-v1.0.bin` are already provisioned by OpenJarvis; this package duplicates them so standalone users and companies get a complete, reproducible bundle. For the intended JARVIS-like cadence, set the speed to `0.95` in the same `[speech]` section of `~/.openjarvis/config.toml`: ```toml [speech] voice_id = "jarvis-original" voice_speed = 0.95 voice_style = "jarvis" voice_enabled = true tts_backend = "jarvis_local" ``` At speed `1.0` the preset still sounds lower than stock `bm_george`, but it is about 5% faster and slightly brighter. ## Deploying in a product Companies can vendor this folder as-is. The runtime is CPU-only, makes no outbound requests during synthesis, and needs no API key, account, or license server. A typical deployment: 1. Download a tagged commit and verify `SHA256SUMS`. 2. Install the four Python dependencies into an isolated environment. 3. Start one `JarvisLVM` instance per worker process, reuse it across requests, and cap concurrent calls at one per instance. 4. Set `JARVIS_LVM_ROOT` if the assets live outside the checkout. 5. Disclose that the voice is synthetic in user-facing products. The measured 0.44× real-time factor leaves headroom for a small API service on ordinary CPU hosts. For lower latency, synthesize at sentence boundaries rather than sending 5,000-character prompts in one call. ## Why it sounds closer to JARVIS The stock `bm_george` voice is a clean British male, but it is brighter and higher than the film character's calm, low register. Jarvis LVM derives a new Kokoro style vector by blending three British male voices: | Preset | Recipe | Median F0 | Character | |---|---|---|---| | `jarvis-prime` | 55% `bm_lewis` + 30% `bm_daniel` + 15% `bm_george` | **105 Hz** | default; lowest register with crisp consonants | | `jarvis-classic` | 25% `bm_george` + 35% `bm_daniel` + 40% `bm_lewis` | **114 Hz** | brighter, precise, unforced | | `jarvis-deep` | 50% `bm_lewis` + 50% `bm_daniel` | **105 Hz** | heaviest; slower-feeling | | stock `bm_george` | reference | 137 Hz | brighter, more generic | Measurements are median values across the included greeting sample at speed `0.95`. The presets lower median pitch by 23–32 Hz, which reads as a darker, more enclosed "butler" timbre without sacrificing intelligibility. `jarvis-deep` reaches the same pitch as `jarvis-prime` but with the two source voices weighted equally; `jarvis-prime` keeps a 15% `bm_george` share for a crisper consonant edge, which is why it is the default from v1.1. ### Delivery Timbre alone does not sound like the character. The planner (`jarvis_lvm/delivery.py`) shapes pacing: - normalise the reply (strip Markdown, expand `API` → `A.P.I.`, `24 kHz` → `24 kilohertz`, `%` → `percent`); - split at sentence and clause boundaries, never inside a decimal or an abbreviation such as `Dr.`; - insert 130 ms after a clause and 240 ms after a sentence; - speak the opening clause at 0.99×, the middle at 1.0×, and the terminal clause at 0.96× of the requested speed. Measured on the reference machine, the same 20-word line takes 6.50 s plain and 7.63 s with `style="jarvis"` at speed `0.95` — about **157 words per minute**, against roughly 185 wpm plain. That is the difference between a voice that is deep and a voice that is *measured*. Set `style="off"` (or `--style off`) to disable it; the timbre is unchanged. At the default speed the delivery is about **150–160 words per minute** — brisk enough for assistant replies, slow enough to sound deliberate. The included briefing samples transcribe exactly with Faster-Whisper `base` (zero word errors), so the darker timbre has not cost clarity. The recipes are reproducible with [`scripts/build_styles.py`](scripts/build_styles.py): ```bash python scripts/build_styles.py --voices voices/voices-v1.0.bin --out voices python scripts/make_samples.py python scripts/build_manifest.py --version 1.1.0 ``` ## Package contents | File | Size | SHA-256 | |---|---:|---| | `models/kokoro-v1.0.int8.onnx` | 92,361,271 B | `6e742170d309016e5891a994e1ce1559c702a2ccd0075e67ef7157974f6406cb` | | `voices/voices-v1.0.bin` | 28,214,398 B | `bca610b8308e8d99f32e6fe4197e7ec01679264efed0cac9140fe9c29f1fbf7d` | | `voices/jarvis-classic.npy` | 522,368 B | `3dfb704fed377720ae0c75c8f3122330a3973181ed7cfb5494d7fbe69a2bff50` | | `voices/jarvis-deep.npy` | 522,368 B | `13b1e8f3c82d1ed28c59ad0490ccf509c2d41ada576f8fef70f49cb64d0f7050` | | `voices/jarvis-prime.npy` | 522,368 B | `02cb0c7f09527a3e6f6fc8d1fdbce4dd8b51c0cb309e536d2247a7cd36bed0bd` | ``` jarvis-lvm/ ├── jarvis_lvm/ # engine, delivery planner, text, CLI ├── models/ # Kokoro INT8 ONNX model ├── voices/ # Kokoro voice bundle + three Jarvis presets ├── samples/ # nine rendered WAV demos ├── scripts/ # blend recipe, sample render, manifest build ├── manifest.json # machine-readable package metadata ├── SHA256SUMS # integrity check ├── LICENSE # Apache-2.0 └── NOTICE # Kokoro and voice attribution ``` Verify the download: ```bash sha256sum -c SHA256SUMS ``` ## Performance Measured on Windows 11, 6 physical CPU cores, ONNX Runtime 1.32, INT8 model: | Metric | Result | |---|---| | Model load | 0.77 s | | Synthesis, 6.5 s of audio | 3.28 s | | Real-time factor | **0.50×** (about twice as fast as playback) | | Process RSS after load | ~574 MiB | | Sample rate | 24 kHz mono | A 10-second reply is generated in roughly 5 seconds on this class of CPU. The delivery planner costs about 15% more audio, not more synthesis time per second of audio: the measured RTF is 0.50–0.51 with delivery on, 0.50 with it off. Performance scales with physical cores: the engine defaults to one ONNX thread per physical core and uses `--intra-threads` for explicit control. ## Licensing - **This package and the two Jarvis style vectors:** Apache License 2.0. - **Kokoro-82M model:** Apache License 2.0, © 2025 hexgrad. - **Kokoro v1.0 ONNX export and `voices-v1.0.bin`:** distributed by the MIT-licensed [kokoro-onnx](https://github.com/thewh1teagle/kokoro-onnx) project; the underlying Kokoro weights remain Apache-2.0. - See [`NOTICE`](NOTICE) for the full attribution. You may use the voice in commercial products, modify the style vectors, and redistribute the bundle under Apache-2.0. You are responsible for your local laws and for disclosing that the voice is synthetic where required. ## Limitations and responsible use - This is a **style**, not a person. It is not Paul Bettany, Tony Stark, or any real individual. Do not market it as an actor clone or use it to imply endorsement. - The model is English-only and optimized for `en-gb`. Other Kokoro languages are available through `--lang`, but the Jarvis presets were tuned in English. - Kokoro can mispronounce unusual names, and long text is synthesized in one pass. For production prompts, normalize names/units first or split at sentence boundaries. - Do not use the voice for impersonation, fraud, harassment, or to fabricate statements by a real person. Synthetic speech should be disclosed. - "JARVIS" is a trademark of Marvel/Disney. This project uses the term only to describe a voice style and is not affiliated with or endorsed by them. ## Provenance Built by Broduer / AAI for the OpenJarvis project. The style vectors are deterministic linear blends of Kokoro's permissively licensed `bm_george`, `bm_daniel`, and `bm_lewis` voice embeddings. No film audio, YouTube rips, or actor recordings were used. Every sample in this repository was generated by the code and weights shipped here. Published at [broduer/Jarvis](https://huggingface.co/broduer/Jarvis).