Learn/Digital FreedomOpen Source

Mercury: A Pure-Rust Whisper You Can Run Without Python

Mercury runs Whisper speech recognition in pure Rust on Candle, with no Python runtime and no whisper.cpp binding. How it compared at launch, and what stayed experimental.

Signed by M·
Vintage silver ribbon microphone on a boom stand on a dark walnut desk, next to a cassette tape, a blank spiral notebook, and over-ear headphones under a warm desk lamp
What is Mercury speech recognition?

Mercury is a pure-Rust Whisper you can run without Python and without a whisper.cpp binding. It runs on the Candle tensor framework with its own mel spectrogram, tokenizer and decoder, and some edges of the crate were still experimental at launch.

Whisper became the default open speech-to-text model the week OpenAI released it. Podcasters, journalists, caption tools and voice note apps all adopted it, because it was the first good transcription you did not have to send to someone else's server. In Rust, though, running it meant one of two compromises: bind whisper.cpp over FFI, or call the Python reference. Either way, a C++ or Python runtime sat in the middle of the app, right next to the microphone.

Mercury removes that compromise. It is a Whisper implementation written in Rust on the Candle tensor framework, with its own mel spectrogram, its own tokenizer, its own decoding and hand-written AVX2 kernels. There is no Python and no whisper-sys by default. This page covers the launch numbers, the limits, and when it is the right choice for a household that wants voice notes to stay home. The case for rebuilding these primitives at all is in rebuilding the foundation of the internet, and the full set of rebuilt crates is on remadewithrust.com.

Why a Rust Rebuild Beats One More Binding

A binding still runs the original code. whisper.cpp is excellent C++, and it still carries the memory bug classes that parsers and buffer handling attract. Python is wonderful for research and awkward to ship beside a wallet or a codec that is meant to stay memory-safe and compile to WASM. The NIST Secure Software Development Framework encourages memory-safe components for exactly this layer; wrapping the old runtime does not meet that bar, replacing it does.

Speech is also a privacy question. Cloud recognition means the voice memo left the house. A "local" tool that pulls in an interpreter, native wheels and a model download helper is local on paper and a supply chain in practice. The Electronic Frontier Foundation has documented how on-device promises erode when the stack phones home. Mercury's claim is smaller and checkable: inference is Rust, weights come from manifests with their licences shown, GPU support is behind feature flags, and CPU-only builds compile. The code is MIT or Apache-2.0; model weights keep their own licences, and the project says so.

How Mercury Measured Against whisper.cpp

These are the launch figures from August 2026. Treat them as a snapshot, since CPUs, workloads and model sizes all move the result.

Accuracy on Clean and Noisy Speech

On LibriSpeech, Mercury landed 0.19 percentage points behind whisper.cpp on clean speech and marginally ahead on noisy speech. Same league, different weather. Studio-quality audiobooks favoured the C++ engine; a kitchen table with a cheap microphone could flip it. What shipped was greedy decoding with the full logit-filter grammar. Beam search was experimental, so a fair comparison pins both engines to greedy decoding first.

Speed of the Pipeline and the Encoder

End to end, Mercury was roughly 1.12 times slower than whisper.cpp. In the same breath: its encoder ran 1.38 times faster than whisper.cpp's unfused encoder. The kernels were ahead and the surrounding pipeline was not finished. Quoting only one of those numbers misleads in either direction.

Inside FFAI, which wraps Mercury next to OCR and a vision-language model on one Candle backbone, early ASR-path benchmarks came in 15 percent faster than whisper.cpp with 7 percent better quality. That is a fused-pipeline figure, so say which surface you measured when you cite it. The later engine work is tracked in the Mercury memory traffic update.

What Stayed Experimental

At launch Mercury ran tiny.en and base.en. Larger models, streaming APIs and beam search were next. If you need multilingual large-v3 in production tomorrow, whisper.cpp is still the conservative pick. If you want a Rust dependency graph with no Python and can live with base English, Mercury fits. The FTC's consumer privacy guidance is about honest claims, and the honest claim here is a memory-safe implementation with measured gaps and a public repository.

Choosing Mercury for a Home Setup

Pick the engine by the constraint you will not bend.

Standalone Crate or the FFAI Bundle

If you only need transcription in a Rust service or a command line tool, depend on Mercury. If you need speech, OCR and vision behind one API, FFAI is the bundle and Mercury is its speech engine. The sibling engines are Carmenta for text in images and Diana for object detection. All of them live under github.com/Remade-With-Rust.

Voice Notes That Never Leave the House

The Freedom Guide is a list of local-first steps, and a transcription feature that quietly loads libpython contradicts every one of them. With Mercury, a family voice memo can be recorded, transcribed and searched on a machine in the house. The same test applies as for the rest of the stack: no C toolchain on the user's machine, and a WASM build that works. A *-sys crate that needs clang fails that test regardless of its accuracy.

What Not to Wait For

Use Mercury when you can pin tiny.en or base.en, accept greedy decoding, and prefer a Candle and Rust attack surface to ggml and Python. Keep whisper.cpp when you need the long tail of models or mature streaming. Follow the repository for beam search and larger checkpoints; the Eras of Digital Freedom roadmap shows where on-device speech fits. If an AI assistant is writing your app, the Mercury coding-assistant guide pins the crate before the agent reaches for Python, starting from safe vibe coding and the MATA Published Skills Drive. The older catalog page, the importance of the Remade crates, lists the rest.

FAQ

Short answers already in this article.

How close was Mercury to whisper.cpp on LibriSpeech at launch?

At launch Mercury landed 0.19 percentage points behind whisper.cpp on clean speech and marginally ahead on noisy speech. Studio-clean audiobooks favoured the C++ engine, while a kitchen and a cheap microphone could flip the gap.

Was Mercury slower than whisper.cpp from end to end?

Roughly 1.12 times slower end to end at launch, while its encoder ran 1.38 times faster than whisper.cpp's unfused encoder. The kernel work was real and the whole-pipeline work was not finished. GPU support is feature-flagged and CPU-only builds still compile.

Which English models could Mercury run at launch?

tiny.en and base.en. Larger models, streaming APIs and beam search were on the experimental list. For multilingual large-v3 in production, whisper.cpp remained the conservative choice.

Do I need the whole FFAI toolkit to use Mercury?

No. Mercury is published as a standalone crate for speech. FFAI is the bundle that adds OCR and a vision-language model on the same Candle backbone, and Mercury is the speech engine inside it.

What did the FFAI path measure when it wrapped Mercury?

Early FFAI ASR-path benchmarks landed 15 percent faster than whisper.cpp with 7 percent better quality. That is a fused-pipeline figure, not the standalone crate measured in isolation.