AI / NLP
Self-Hosted LLM & RAG Stack
A privacy-first retrieval-augmented generation stack for querying proprietary documents with open-source models, embeddings, and vector search, so no data leaves the building.
Threat
Cloud LLM APIs are convenient until contracts, research data, or operational reports cannot leave your network. Teams still need semantic search and grounded answers over their own document corpus.
- LOCALInference
- PG+CHROMAVectors
- 12K+Chunks
- ON-PREMPrivacy
Inside the build
Approach & deliverables
How the system is put together, and what it hands the people who use it.
Approach
- Document ingestion pipeline: chunking, metadata extraction, and embedding with open models into pgvector or Chroma.
- Ollama and vLLM for local inference: chat, summarization, and structured extraction without third-party API calls.
- Hybrid retrieval combining semantic search and keyword filters, with source citation and query logging.
- LangChain orchestration for multi-step RAG workflows and tool-using agents wired into existing systems.
Delivers
- Grounded answers over proprietary documents with full data sovereignty.
- Queryable embedding index with measurable retrieval precision.
- Agent workflows for research triage and document summarization.
- Cost-controlled AI that scales without per-token billing surprises.
Related writing
Self-hosted AI when privacy matters
Cloud LLM APIs are convenient until your documents cannot leave the building. Open-source models on your own hardware are more viable than most teams assume.
When to use Chroma vs pgvector
Vector storage is a deployment choice, not a religion. Postgres with pgvector and dedicated Chroma each win in different contexts.