Designing a private retrieval-augmented generation system

Design a private RAG system with source permissions, ingestion, retrieval, model boundaries, and evaluation.

On this page

Define source authority

A private RAG system combines source content, ingestion, embeddings, a vector store, retrieval filters, prompt construction, and a model endpoint. The source system remains authoritative for document and permission decisions.

Design ingestion and provenance

Record source, version, chunking method, embedding model, tenant or permission metadata, ingestion time, and deletion path. A source permission change must reach the index.

Enforce retrieval boundaries

Build filters from trusted identity data, not caller-supplied fields. Test allowed documents, cross-tenant requests, revoked documents, and ambiguous queries. Similarity ranking is not authorisation.

Evaluate answer and access quality

Use safe representative questions to inspect retrieved chunks, citations or references, exclusions, latency, and model routing. Measure failures before exposing sensitive business data.

RAG contract

Version the boundary.

LayerDecisionEvidence
SourceAuthority and permissionsOwner record.
IndexSchema and embeddingsWrite/query test.
RetrieverTrusted filtersCross-tenant denial.
ModelApproved endpointSafe prompt test.

Questions

Can a vector score grant access?

No; authorisation requires trusted filters.

What changes require reindexing?

Embedding, chunking, schema, or major permission corrections.

What proves safety?

Access, deletion, and endpoint-path tests.

Build stages

Inventory sources and permissions.

Checks

Keep operating evidence.

Source register

Owners and authority are known.

Access test

Cross-tenant retrieval is denied.

Delete test

Revoked content stops returning.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.