llmware-ai/llmware
Local-first Python RAG SDK for document retrieval and small-model inference.
Automated SPDX check for reference only — not legal advice. Disclaimer
GitHub Star History
Full-history star trajectory from GitHub official history. Switch ranges or hover any point for exact counts.
Evidence-Backed Technical Brief
AI Deep ReviewArchitecture & Core Mechanics
llmware is a Python SDK that connects document ingestion, retrieval, and inference through four main interfaces. Library routes files by extension, parses and chunks them, and indexes the text. A library can carry multiple embedding indexes, each configured with an embedding model and a vector backend. Query searches a library independently of generation, while Prompt attaches retrieved passages or batches document sources to fit the model's context window.
ModelCatalog provides a common lookup and loading interface over runtimes including llama.cpp for GGUF, OpenVINO, ONNX Runtime and its Qualcomm QNN path, Windows Local Foundry, and PyTorch. Applications can also add custom models. The main integration seam is the Python API: applications choose the model, collection database, and vector backend without tying document ingestion to an inference provider.
Key Capabilities & Differentiators
Retrieval covers text, semantic, and hybrid search, with exact text matching and document or metadata filters where appropriate. Prompt can attach existing query results or run a new search against a library. It exposes prompt history and a post-generation source check, while HumanInTheLoop exports the prompt, response, model, and evidence to CSV for review. These are useful audit inputs, not a guarantee that an answer is correct.
The catalog covers 300+ models, including 50+ llmware fine-tunes from families such as SLIM, Bling, Dragon, and Industry-Bert. It includes 1–7B RAG-oriented models and integrations with OpenAI, Anthropic, and Google. Beyond question answering, LLMfx exposes task-specific calls such as field extraction, sentiment, topic tagging, and Boolean judgments, then aggregates their outputs into a report.
Trade-offs & Limitations
Compared with assembling a parser, vector store, retriever, and model client independently, llmware reduces integration work when its library and prompt abstractions fit the application. Compared with a managed RAG service, it gives operators a local path for documents and inference, but they must provision and maintain runtimes, indexes, and storage. An application with an existing search platform or model gateway may benefit more from adding a targeted component than from adopting the full SDK.
The common model API does not make backends interchangeable in practice: model artifacts, drivers, context budgets, and output quality still need validation on the target platform. Additional embedding indexes also consume build time and storage; changing embedding models requires re-embedding the affected corpus. Test parsing on representative documents and evaluate retrieval and answer grounding separately before standardizing on a small model. The SDK's Apache-2.0 license does not automatically cover model weights or third-party services.
Hardware & Deployment Guide
Start with a Python environment, SQLite for collections, a local vector store such as ChromaDB, and a quantized GGUF model. A laptop with 16 GB of system RAM is a reasonable trial platform for a small quantized model, not a production sizing target. For offline operation, stage the weights and dependencies before disconnecting and verify that both embedding and generation stay local. A self-hosted deployment can use PostgreSQL with pgvector for both storage roles, or operate separate services such as MongoDB and Milvus using the available Docker Compose examples.
The v0.4.7 wheel adds preconfigured llama.cpp binaries for DGX Spark, AMD GPU, Windows CUDA (4090+), and Linux CUDA (8.9+), alongside standard builds for Windows x86 and ARM64, Mac, and Linux x86. Match the build and runtime to the target hardware and drivers rather than assuming acceleration from the wheel alone. Size RAM and VRAM with the selected weights, context length, offload settings, and concurrency.
Library.add_files() routes files by extension for parsing, chunking, and text indexing.Query supports text, semantic, and hybrid search, plus document and metadata filters.Prompt can attach retrieved sources, check responses against those sources, and expose prompt history; HumanInTheLoop can export an interaction to CSV.Python teams building private document search, evidence-backed Q&A, or repeatable extraction workflows with local small models and a choice of storage backends.
You need a turnkey managed service with operations handled for you, or already have a working RAG stack and only need to replace one component.
Quick Start & Installation
curl -o docker-compose.yaml https://raw.githubusercontent.com/llmware-ai/llmware/main/docker-compose.yaml docker compose up -d
Comparison vs. Top RAG, Data & Memory Alternatives
Full comparison →| Repository | Stars | 7d Trend | Stack | License | Core Positioning |
|---|---|---|---|---|---|
| llmware ★ | 14.8k | +8 | Python | Apache-2.0 | Local-first Python RAG SDK for document retrieval and small-model inference. |
| haystack | 27.2k | +53 | Python | Apache-2.0 | Component-based Python orchestration for RAG pipelines and tool-using agents |
| auto-ontology | 19.1k | +3.7k | Python | Apache-2.0 | An ontology framework that grounds agent-generated SQL in reviewed business defi |
| llama_index | 53.1k | +104 | Python | MIT | A modular Python SDK for document ingestion, indexing, and RAG |
AI Context Briefing (for Claude / Cursor / Windsurf)
Standardized architecture summary & quickstart commands ready to paste into coding agents.
curl -sL https://repoforai.com/repo/llmware-ai/llmware.md
Active README embeds unlock Hot-Tier 6h Telemetry Refresh automatically (zero pay-to-rank).
Frequently Asked Questions about llmware
Can I adopt the retrieval layer separately from generation?
Library, retrieve passages with Query, then attach the results to Prompt with add_source_query_results(). You can start with text search and add an embedding and vector backend later. If a library has multiple embeddings, select the intended model and backend when creating Query.Can I start on a 16 GB laptop without a discrete GPU?
Can we use it commercially and keep sensitive documents on-premises?
When is llmware a better fit than a modular RAG stack?
Upstream README & Documentation
This profile focuses on independent engineering analysis and live telemetry. Read the full upstream README, changelog, and examples directly on GitHub.
Top 10 Breakout Open-Source AI Repos, Every Thursday
Signal-only digest of fast-growing AI repos, SPDX license alerts, and architecture picks. Zero spam.
Zero spam · 1-click unsubscribe · Privacy Policy