Skip to content

Installation

Basic install

The base install gives you the Python library, CLI, and semantic search. No Docker required.

bash
pip install locallens

This includes:

  • LocalLens Python API
  • locallens CLI
  • Qdrant Edge (embedded vector database)
  • Sentence-transformers embeddings (all-MiniLM-L6-v2)
  • Extractors for PDF, DOCX, code, text, spreadsheets

With LLM support (RAG Q&A)

The ask command requires Ollama running locally. Install Ollama separately, then pull a model:

bash
# Install Ollama from https://ollama.com
ollama pull qwen2.5:3b
ollama serve

No extra Python packages needed — LocalLens talks to Ollama over HTTP.

With voice

Adds speech-to-text (Moonshine) and text-to-speech (Piper) for the voice interface:

bash
pip install "locallens[voice]"

With MCP server

Exposes LocalLens as tools for Claude Code, Claude Desktop, Cursor, and other MCP clients:

bash
pip install "locallens[mcp]"

With web dashboard

Full React web UI with FastAPI backend:

bash
pip install "locallens[server]"

With Rust acceleration

Installs locallens-core, the optional Rust extension package for 5-10x faster BM25, chunking, and file walking on large corpora:

bash
pip install "locallens[fast]"

Without this, LocalLens uses pure Python for everything. Same results, just slower on 10k+ file corpora.

Everything

Install all optional dependencies at once (includes Rust extensions):

bash
pip install "locallens[all]"

From source

bash
git clone https://github.com/mahimairaja/locallens.git
cd locallens
pip install -e ".[all]"

System requirements

RequirementMinimumRecommended
Python3.11+3.12+
RAM2 GB4 GB
OSmacOS, Linux, WindowsmacOS (Apple Silicon)
DockerNot requiredFor web dashboard only
OllamaNot requiredFor ask / RAG feature

Released under the MIT License.