usemoss/moss
Embedded hybrid retrieval that removes the query network hop for real-time RAG
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
Moss separates index management from query execution. Moss Cloud handles ingestion, document embedding, storage, and distribution. It packages documents and vectors into a single index artifact. An application initializes the SDK with a project ID and key, downloads the index over HTTPS, and keeps it in memory. Once the index is loaded, query embedding and retrieval run inside the application process. Document changes pass through Moss Cloud rather than a local database write path.
The primary integration surface is the SDK API: the Python quickstart uses create_index, load_index, and query, with camelCase equivalents for Node.js. The browser package, @moss-dev/moss-web, runs the query path in WebAssembly. SDK source and samples for JavaScript, Python, and Elixir sit under sdks/; database ingestion connectors sit under packages/moss-data-connector/. The root package is moss-samples-root and lists VitePress; that manifest does not describe the embedded engine's dependencies.
Key Capabilities & Differentiators
A single query can combine semantic and keyword retrieval, return a configurable top-k, and filter metadata with operators such as $eq, $and, $in, and $near. Built-in embeddings remove the need for an OpenAI key on that path, while Python and TypeScript examples show how to supply custom embeddings. moss-cli covers terminal-based index management and querying, and the integration examples range from LangChain retrieval to Pipecat and LiveKit voice pipelines.
The benchmark measures query embedding plus search on 100,000 documents, with 750 measured queries and top_k=5, on a MacBook Pro with an M4 Pro and 24 GB of memory. Moss measured 3.1 ms p50, 4.3 ms p95, and 5.4 ms p99. Those numbers characterize the loaded query path on that setup. They do not size startup or index refresh, establish browser or mobile latency, or quantify retrieval quality at larger corpus sizes.
Trade-offs & Limitations
Moving search into the process trades a network round trip for index transfer and resident memory wherever queries run. That is a strong fit for latency-sensitive workloads when the relevant index fits comfortably on each host or device. For fleets with many replicas or changing indexes, measure download bandwidth, aggregate memory, and how quickly updates become visible. For browser delivery, distribute only documents and vectors the client is allowed to receive; query filters do not make a downloaded index confidential.
The benchmark is useful as a comparison of deployment patterns, not as a controlled ranking of search engines: Pinecone, Qdrant, and ChromaDB use an external embedding service in the comparison, and Pinecone and Qdrant also use cloud search. If your priorities are centralized capacity, independently managed data, or a fully self-hosted ingestion and distribution path, evaluate those requirements directly. The repository is BSD-2-Clause, but that does not by itself establish Moss Cloud terms or a supported self-hosted control plane.
Hardware & Deployment Guide
For a backend, install moss on Python 3.10+ or @moss-js/moss on Node.js 20+, provision a Moss Cloud project, then create or load an index before serving queries. The sample repository's root Node constraint is narrower than the SDK quickstart baseline: ^20.19.0 || >=22.12.0. WebAssembly removes the need for a query server, not the need to obtain the index. The apps/pipecat-moss/ollama-local example uses Docker Compose for local LLM inference and retrieval; it does not supply a self-hosted replacement for Moss Cloud.
The iOS v0.17.0 release distributes Moss.xcframework.zip as a SwiftPM binary target. Android SDK v0.33.0 ships an arm64-v8a AAR with minSdk 24 and adds ClientOptions.keepModels, disabled by default. C SDK v0.33.0 ships precompiled binaries and adds client constructors that accept options. Before rollout, measure first-load time, memory per application instance, and update-to-visible latency on the actual target devices.
$eq, $and, $in, and $near.top_k=5.@moss-dev/moss-web for browser WASM, and release artifacts for iOS, Android, and C.moss-cli for index management and queries.Voice agents, interactive copilots, and client-side search where the active index fits in memory and Moss Cloud ingestion and distribution are acceptable.
The full ingestion and distribution pipeline must be self-hosted or air-gapped, clients cannot be trusted with the index contents, or copying indexes to each query instance exceeds your resource budget.
Quick Start & Installation
pip install mossComparison vs. Top RAG, Data & Memory Alternatives
Full comparison →| Repository | Stars | 7d Trend | Stack | License | Core Positioning |
|---|---|---|---|---|---|
| moss ★ | 1.2k | +176 | Python | BSD-2-Clause | Embedded hybrid retrieval that removes the query network hop for real-time RAG |
| PageIndex | 40.9k | +92 | Python | MIT | Tree-indexed RAG for evidence retrieval from long PDFs without a vector database |
| crawl4ai | 88.5k | +408 | Python | Apache-2.0 | Async browser crawler that turns web pages into Markdown and JSON for RAG |
| zvec | 16.3k | +29 | C++ | Apache-2.0 | In-process C++ vector database for local hybrid retrieval |
AI Context Briefing (for Claude / Cursor / Windsurf)
Standardized architecture summary & quickstart commands ready to paste into coding agents.
curl -sL https://repoforai.com/repo/usemoss/moss.md
Active README embeds unlock Hot-Tier 6h Telemetry Refresh automatically (zero pay-to-rank).
Frequently Asked Questions about moss
How do I keep retrieval off the network path in a voice agent?
Do I need a GPU, and how much memory should I budget?
Does the BSD license let us use Moss commercially and self-host the entire stack?
How should we benchmark Moss against a vector database?
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