Skip to main content
Yanked

This release has been yanked by its maintainers, and will be ignored by installers, except when explicitly specified.
Consider using release 0.6.90b448 instead.
Reason given by maintainers: not supported

lilbee

Beta — feedback and bug reports welcome. Open an issue.

PyPI Python 3.11+ CI Coverage Platforms License: MIT Downloads

Local knowledge base that handles both code and documents, with a git-like per-project model. Search, ask questions, or chat — standalone or as a retrieval backend for AI agents via MCP. Supports vision OCR for scanned PDFs. Everything stays on your machine, powered by Kreuzberg for text extraction, Ollama for embeddings, chat, and vision OCR, and LanceDB for vector storage.



Why lilbee

lilbee indexes documents and code into a searchable local knowledge base. Use it standalone — search, ask questions, chat — or plug it into AI coding agents as a retrieval backend via MCP.

Most tools like this only handle code. lilbee handles PDFs, Word docs, spreadsheets, images (OCR) — and code too, with AST-aware chunking.

  • Standalone knowledge base — add documents, search, ask questions, or chat interactively with model switching and slash commands
  • AI agent backend — MCP server and JSON CLI so coding agents can search your indexed docs as context
  • Per-project databases — lilbee init creates a .lilbee/ directory (like .git/) so each project gets its own isolated index
  • Documents and code alike — PDFs, Office docs, spreadsheets, images, ebooks, and 150+ code languages via tree-sitter
  • Open-source and fully offline — your documents never leave your machine. Runs with Ollama and LanceDB, no cloud APIs or Docker

Add files (lilbee add), then search or ask questions. Once indexed, search works without Ollama — agents use their own LLM to reason over the retrieved chunks.

Demos

Click the ▶ arrows below to expand each demo.

AI agent — lilbee search vs web search (detailed analysis)

opencode + minimax-m2.5-free, single prompt, no follow-ups. The Godot 4.4 XML class reference (917 files) is indexed in lilbee. The baseline uses Exa AI code search instead.

⚠️ Caution: minimax-m2.5-free is a cloud model — retrieved chunks are sent to an external API. Use a local model if your documents are private.

API hallucinations Lines
With lilbee (code · config) 0 261
Without lilbee (code · config) 4 (~22% error rate) 213
With lilbee — all Godot API calls match the class reference

With lilbee MCP

Without lilbee — 4 hallucinated APIs (details)

Without lilbee

If you spot issues with these benchmarks, please open an issue.

Vision OCR

Scanned PDF → searchable knowledge base

A scanned 1998 Star Wars: X-Wing Collector's Edition manual indexed with vision OCR (LightOnOCR-2), then queried in lilbee's interactive chat (qwen3-coder:30b, fully local). Three questions about dev team credits, energy management, and starfighter speeds — all answered from the OCR'd content.

Vision OCR demo

See benchmarks, test documents, and sample output for model comparisons.

One-shot question from OCR'd content

The scanned Star Wars: X-Wing Collector's Edition guide, queried with a single lilbee ask command — no interactive chat needed.

Top speed question

Standalone

Interactive local offline chat

[!NOTE] Entirely local on a 2021 M1 Pro with 32 GB RAM.

Model switching via tab completion, then a Q&A grounded in an indexed PDF.

Interactive local offline chat

Code index and search

Code search

Add a codebase and search with natural language. Tree-sitter provides AST-aware chunking.

JSON output

JSON output

Structured JSON output for agents and scripts.

Hardware requirements

lilbee runs entirely on your local machine — your hardware is the compute.

Resource Minimum Recommended
RAM 8 GB 16–32 GB
GPU / Accelerator — Apple Metal (M-series), NVIDIA GPU (6+ GB VRAM)
Disk 2 GB (models + data) 10+ GB if using multiple models
CPU Any modern x86_64 / ARM64 —

Ollama handles inference and uses Metal on macOS or CUDA on Linux/Windows. Without a GPU, models fall back to CPU — usable for embedding but slow for chat.

Install

Prerequisites

  • Python 3.11+
  • Ollama — the embedding model (nomic-embed-text) is auto-pulled on first sync. If no chat model is installed, lilbee prompts you to pick and download one.
  • Optional (for scanned PDF/image OCR): Tesseract (brew install tesseract / apt install tesseract-ocr) or an Ollama vision model (recommended for better quality — see vision OCR)

First-time download: If you're new to Ollama, expect the first run to take a while — models are large files that need to be downloaded once. For example, qwen3:8b is ~5 GB and the embedding model nomic-embed-text is ~274 MB. After the initial download, models are cached locally and load in seconds. You can check what you have installed with ollama list.

Install

pip install lilbee        # or: uv tool install lilbee

Development (run from source)

git clone https://github.com/tobocop2/lilbee && cd lilbee
uv sync
uv run lilbee

Quick start

See the usage guide.

Agent integration

lilbee can serve as a local retrieval backend for AI coding agents via MCP or JSON CLI. See docs/agent-integration.md for setup and usage.

Interactive chat

Running lilbee or lilbee chat enters an interactive REPL with conversation history, streaming responses, and slash commands:

Command Description
/status Show indexed documents and config
/add [path] Add a file or directory (tab-completes paths)
/model [name] Switch chat model — no args opens an interactive picker; with a name, switches directly (tab-completes installed models)
/vision [name|off] Switch vision OCR model — no args opens a picker, off disables (tab-completes catalog models)
/version Show lilbee version
/reset Delete all documents and data (asks for confirmation)
/help Show available commands
/quit Exit chat

Slash commands and paths tab-complete. A spinner shows while waiting for the first token from the LLM.

Supported formats

Text extraction powered by Kreuzberg, code chunking by tree-sitter. Structured formats (XML, JSON, CSV) get embedding-friendly preprocessing. This list is not exhaustive — Kreuzberg supports additional formats beyond what's listed here.

Format Extensions Requires
PDF .pdf —
Scanned PDF .pdf (no extractable text) Tesseract (auto, plain text) or Ollama vision model (recommended — preserves tables, headings, and layout as markdown)
Office .docx, .xlsx, .pptx —
eBook .epub —
Images (OCR) .png, .jpg, .jpeg, .tiff, .bmp, .webp Tesseract
Data .csv, .tsv —
Structured .xml, .json, .jsonl, .yaml, .yml —
Text .md, .txt, .html, .rst —
Code .py, .js, .ts, .go, .rs, .java and 150+ more via tree-sitter (AST-aware chunking) —

See the usage guide for OCR setup and model benchmarks.

License

MIT

Metadata

Release files for lilbee 0.4.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for lilbee 0.4.5
File Size Uploaded
lilbee-0.4.5.tar.gz 14.5 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for lilbee 0.4.5
File Interpreter ABI Platform
lilbee-0.4.5-py3-none-any.whl Python 3 none any Details

Total release size: 14.5 MB

Release files / lilbee-0.4.5.tar.gz

Download URL lilbee-0.4.5.tar.gz
Size 14.5 MB
Tags Source
SHA-256 checksum
How to use checksums
981b2c73d22b4924d04ab3848853d8a9b45f3e5ad3189c3ec40af43839eb2419
BLAKE2b-256 checksum
How to use checksums
6b0a746b56cb175ffdfa72d10ea1821a32980a02d55f5dcb3b82129ba05e7238
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Mar 13, 2026.

Transparency log

Release files / lilbee-0.4.5-py3-none-any.whl

Download URL lilbee-0.4.5-py3-none-any.whl
Size 46.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a92f83f0cbd5f0e31153db8b9800533ccfa4c9433bc2aad0ee3782a4922c1b3e
BLAKE2b-256 checksum
How to use checksums
6860d7f2af494fbccd302fedbcfae66d56b57d8ac62be500b1275202c70a1ca4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Mar 13, 2026.

Transparency log

Release history Release notifications | RSS feed

0.5.4

2 release files

0.5.3

2 release files

0.5.2

2 release files

0.5.1

2 release files

0.5.0

2 release files

0.4.6

2 release files

This release

0.4.5 This release

2 release files

0.4.4

2 release files

0.4.3

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.10

2 release files

0.3.9

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page