About LocalMode

LocalMode is an open-source TypeScript library for building AI-powered browser applications. Everything from embeddings and vector search to LLM chat and real-time hand tracking works offline after the initial model download. No servers, no API keys - data never leaves the device.

What LocalMode Does

LocalMode provides a unified API across multiple ML runtimes. A single LanguageModel interface works with WebLLM (WebGPU), Transformers.js (ONNX), wllama (llama.cpp WASM), and LiteRT (Google on-device). The same pattern applies to embeddings, classification, vision, audio, and every other ML task - write once, swap providers freely.

Key Facts

  • License: MIT - free for commercial and personal use
  • Language: TypeScript, zero dependencies in the core package
  • Models: 60+ curated models across 18 task categories, plus access to 180,000+ GGUF models via wllama
  • Providers: 6 provider packages (Transformers.js, WebLLM, wllama, LiteRT, MediaPipe, Chrome AI)
  • React: 56 hooks in @localmode/react for every core function
  • Privacy: Zero telemetry, zero network requests from the core package, all inference runs on-device

Links