Mar 27, 2026 AI

When the Filter Fails: Why AI Tenant Isolation Cannot Be an Afterthought

All posts

I build AI systems for regulated businesses where making things up is not an option. My last two posts on temperature (controlling how random AI outputs are) and grounding (making sure the system only answers from real data) got a great response. This one keeps me up at night more than either of those.

The Most Natural Architecture Is Also the Most Dangerous

If you are building AI on top of client data, the most natural thing is to put everything in one place and use filters to keep clients apart. Client A queries their data. The filter ensures they only see their records. It is simple, efficient, and cost-effective.

It is also a ticking time bomb.

One bug, one misconfigured filter, or one edge case nobody tested, and Client A is looking at Client B's confidential information. The consequences depend on your industry:

This Is Not Hypothetical

Microsoft recently confirmed that Copilot had been reading emails marked as confidential for weeks, bypassing the data protection policies that were supposed to prevent exactly that. One code bug. Weeks of exposure. That is what logical separation looks like when it fails.

The pattern is always the same. The filters work in testing. They work in the demo. They work for the first six months. Then someone adds a new feature, refactors a query, or introduces a new data source, and the filter logic breaks in a way that nobody notices until it is too late.

The problem is not that filters are poorly built. It is that they are a single layer of defence against a catastrophic outcome. If the filter fails, there is nothing behind it. The data is all in the same place.

Physical Separation vs Logical Separation

The systems I build do not rely on filters for client isolation. Each client's data lives in its own separate database. There is no filter to misconfigure because the data simply is not in the same place.

The difference matters:

Physical separation costs more to run. More databases, more infrastructure, more operational overhead. But the risk profile is fundamentally different. You are not relying on every query, every API call, and every edge case correctly applying a filter. You are relying on the fact that the data is not there to leak in the first place.

Why AI Makes This Worse

Traditional applications query structured data in predictable ways. SQL queries with WHERE clauses. API calls with tenant IDs. These are well-understood patterns with decades of tooling around them.

AI systems are different. They use vector databases, semantic search, retrieval-augmented generation, and context windows. The query patterns are less predictable. The data flows are more complex. A prompt that works perfectly for one client might, through semantic similarity, pull in documents from another client's vector store if the data is co-located.

This is not a theoretical risk. It is an architectural consequence of how retrieval-augmented generation works. If two clients' documents are embedded in the same vector space, the similarity search does not respect business boundaries unless you explicitly enforce them. And enforcement means filters, which brings us back to the original problem.

What to Ask Your Vendor

If you are evaluating AI tools that handle sensitive client data, there is one question that cuts through the marketing:

Does each client get their own separate data environment, or is everyone's data in one place with filters keeping it apart?

If the answer is filters, ask the follow-up: what happens when one fails?

Listen carefully to the response. If they talk about how robust their filters are, how well-tested, how many layers of protection they have, that tells you the data is co-located and they are relying on software logic to keep it apart. That might be acceptable for low-sensitivity data. It is not acceptable for legal documents, financial records, or healthcare information.

The Trade-Off Is Real, But So Is the Risk

I am not suggesting that every application needs physical tenant isolation. For consumer products, collaboration tools, or low-sensitivity data, logical separation with well-tested filters is a reasonable trade-off.

But if you are handling data where a cross-tenant leak is a regulatory incident, a privilege violation, or a front-page story, the economics change. The additional cost of physical isolation is insurance against a category of failure that no amount of filter testing can fully eliminate.

I sleep a lot better knowing that a bug in my code cannot expose one client's data to another. Not because my filters are better than anyone else's. Because the data is not there to leak.

Read next The Steak Test: A Simple Way to Check If Your AI Is Making Things Up