pathwaycom/serviette
Self-hosted RAG with a separate indexer that keeps document answers current
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
Serviette is a Python application with separate write and read processes. The indexer uses Pathway to watch configured sources, then reuses Pathway's LLM xpack parsers, splitters and embedders to turn file changes into vector-store upserts and deletes. The stateless server embeds queries and reads from that store without calling the indexer. The documented collection schema is the integration contract, so another application can consume the same collection.
A server can keep answering from the last synced state while the indexer is down, and the indexer can continue writing if serving is interrupted. Indexer persistence supports resuming without re-embedding. With a shared external store, Pathway workers and query replicas can scale separately, though both still depend on database capacity. Embedded DuckDB gives up that deployment flexibility for a single local file and a single writer.
Key Capabilities & Differentiators
One YAML config can combine local files, Google Drive, S3/MinIO, SharePoint and PyFilesystem sources such as SFTP or WebDAV. The eight vector stores are DuckDB, pgvector, Qdrant, Milvus, ChromaDB, Weaviate, Pinecone and MongoDB Atlas Vector Search. Embeddings can use OpenAI, LiteLLM, SentenceTransformers, Gemini or Bedrock. Text, PDF and Office formats have built-in parsing; optional Docling adds layout and table extraction, PaddleOCR handles scanned images, and audio and video processing require the relevant OpenAI or TwelveLabs credentials.
The server exposes cited chat and POST /api/v1/retrieve. Retrieval starts with vector similarity; optional stages add BM25 rank fusion, cross-encoder or LLM reranking, MMR, query decomposition and adaptive context expansion. On the 824-question FRAMES evaluation, gold-article recall was 0.50 versus 0.21 for the reproduced BM25 baseline. The reported adaptive setup raised context-only answer accuracy from 41.3% to 52.8%; that result is specific to the benchmark setup, not a forecast for an internal corpus.
Trade-offs & Limitations
Compared with assembling a LangChain or LlamaIndex stack, Serviette packages ingestion, update propagation, cited chat and REST serving behind YAML rather than giving developers code-level control over each stage. DuckDB is the low-setup choice for a local trial; separate hosts or independently scaled replicas favor a shared external store. Cross-encoder reranking adds local inference, while LLM reranking, decomposition and adaptive retries can add model calls. An external answer model receives retrieved passages; an external embedder receives document text as well.
For capacity planning, the nominal 50 GB Qdrant run measured 6.0 hours of indexing, 14.65 GiB peak PSS and 84.45 GiB in Qdrant. That was a single published run for that size using plain text and local embeddings, not a sizing guarantee for PDFs or scans. The watcher retains per-file metadata, so file count matters alongside extracted text volume. Test freshness and query latency during bulk indexing against the chosen store instead of assuming separate processes eliminate contention.
Hardware & Deployment Guide
Use CPython 3.10 or newer and pip 23.1 or newer. Install with pip install serviette and set PATHWAY_LICENSE_KEY before running the CLI. serviette demo --embedder openai also needs OPENAI_API_KEY and opens the bundled-corpus chat at http://localhost:8989. For your own sources, generate YAML with serviette wizard, then use serviette up --config config.yaml to supervise the indexer and server together.
For distributed self-hosting, run serviette indexer and serviette server separately against a shared external store. An optional serviette frontend hosts chat on another host and proxies API requests server-side. DuckDB and local embeddings avoid a database service and an embedding API; omit the answer model to return quoted passages, but the Pathway key still applies. Release v0.1.8 marks the change from the llm-app template repository to the Serviette server; the previous templates remain in Pathway's examples/llm-app.
/ and a versioned REST API under /api/v1, including POST /api/v1/retrieve.serviette[docling] for layout-aware extraction or serviette[ocr] for scanned images.Teams that need cited Q&A and a retrieval API over frequently changing documents without building their own incremental indexing pipeline.
Your deployment cannot accept Pathway's license-key requirement, or you need code-level control over the orchestration rather than configuration of a packaged pipeline.
Quick Start & Installation
pip install serviette export PATHWAY_LICENSE_KEY=... # free: https://pathway.com/framework/get-license export OPENAI_API_KEY=sk-... serviette demo --embedder openai # → chat at http://localhost:8989
Comparison vs. Top RAG, Data & Memory Alternatives
Full comparison →| Repository | Stars | 7d Trend | Stack | License | Core Positioning |
|---|---|---|---|---|---|
| serviette ★ | 58.6k | +11 | Python | MIT | Self-hosted RAG with a separate indexer that keeps document answers current |
| ragflow | 95.1k | +297 | Go | Apache-2.0 | Go-based RAG platform for parsing complex documents and grounding answers in sou |
| private-gpt | 57.7k | +14 | Python | Apache-2.0 | Self-hosted API for cited document RAG and tool use on local models |
| WeKnora | 38.8k | +387 | Go | — | Self-hosted RAG, agents, and a Wiki on shared document knowledge bases |
AI Context Briefing (for Claude / Cursor / Windsurf)
Standardized architecture summary & quickstart commands ready to paste into coding agents.
curl -sL https://repoforai.com/repo/pathwaycom/serviette.md
Active README embeds unlock Hot-Tier 6h Telemetry Refresh automatically (zero pay-to-rank).
Frequently Asked Questions about serviette
How do I integrate Serviette with an existing vector store or application?
POST /api/v1/retrieve if they only need ranked passages.Do I need a GPU, and what should I size first?
Can I self-host Serviette commercially under the MIT license?
PATHWAY_LICENSE_KEY; review its terms for your deployment rather than assuming the MIT license covers the full stack. External services have their own terms and data-handling implications.When should I choose Serviette over building with LangChain or LlamaIndex?
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