Why they ask
In a shared vector index, one missing filter means customer A's question retrieves customer B's documents, and the model happily quotes them. OWASP added "Vector and Embedding Weaknesses" (LLM08) to its 2025 list partly for this reason. It is a backend bug, not an AI bug, which is exactly why it slips through.
Know which model you use
| Isolation model | How it works | What reviewers probe |
|---|---|---|
| Separate index / namespace per tenant | Each customer's vectors live in their own namespace or collection | Is the namespace chosen from the session on the server, or from a request parameter? |
| Shared index + metadata filter | Every record has a tenant_id; every query adds a filter | Is the filter added on the server for every code path? What about records missing the field? |
| Postgres row-level security (pgvector) | The database only returns rows the current user may see | Does retrieval run with the user's identity, or with a service key that bypasses RLS? |
Sample answer
Every document chunk carries a tenant identifier, and retrieval adds a tenant filter on the server using the tenant from the authenticated session, never from the request. The same applies to caches and conversation history. We test isolation with two accounts in different tenants: each seeds a unique marker document, and we confirm the other tenant cannot retrieve or be shown it through search, chat or any API. The last test was in [month year]. When a customer deletes a document or leaves, its vectors are deleted and we verify they can no longer be retrieved.
The evidence that ends the thread
A short cross-tenant test record: two test tenants, a unique marker string seeded in each (for example CANARY-7f3a), the queries tried from the other tenant (direct question, paraphrase, "list all documents", injection asking to ignore filters), and the result. Add the same test for a deleted document. Reviewers rarely argue with a dated test like this.
Common gaps
- Records ingested before multi-tenancy existed, with no
tenant_id. A filter never matches them, and an unfiltered query returns them to everyone. - The tenant filter is built from a request body field the client can change.
- A semantic cache or shared conversation memory that ignores tenants.
- pgvector retrieval called with the Supabase service-role key, which bypasses row-level security. See the Supabase guide.