← all repositories
zzmp/juliusjs

Speech recognition that never phones home

A C speech engine compiled to JavaScript so your voice data stays in the browser.

2.6k stars JavaScript Image · Video · Audio
juliusjs
Velocity · 7d
+0.6
★ / day
Trend
steady
star history

What it does

JuliusJS ports the Julius speech recognition engine to JavaScript via Emscripten. It captures microphone input through Web Audio, runs recognition in a Web Worker, and fires an onrecognition callback with the transcribed sentence. No server round-trips, no external API keys.

The interesting bit

The project replaces Julius’s native looping C code with an event-driven model to fake multithreading inside a Worker. It also ships pre-compiled binaries in dist/ so you don’t need Emscripten just to try it—though you’ll need it (plus Perl’s mkdfa.pl) to build custom grammars.

Key highlights

  • 100% in-browser: recognition happens locally via Web Worker
  • Event-style API: julius.onrecognition = (sentence, score) => ...
  • Custom grammars supported via Julius’s .voca/.grammar/.dfa format
  • Configurable engine options (zero-crossing threshold, silence stripping, etc.)
  • Live demo available at zzmp.github.io/juliusjs

Caveats

  • Default grammar is basic; out-of-the-box accuracy is noted as a future improvement
  • Examples section is entirely “Coming soon…” as of the README
  • Tests are not yet implemented (npm test is aspirational)
  • Building custom grammars requires Perl tooling and Emscripten setup on non-Mac systems

Verdict

Worth a look if you need offline, privacy-first voice commands in a web app and can tolerate constrained grammars. Skip it if you need open-domain dictation or a polished, batteries-included developer experience.

heatdrop uses Google Analytics to see which pages get read — nothing else. Your call. How we handle data.