Skip to content
Deployment Architecture

When Much of Your Codebase Is AI-Generated and It Lives Behind a Firewall

When much of your codebase is AI-generated and your enclave can't reach cloud testing tools, validation has to run where the data lives. A POV for healthcare CTOs.

Deployment behind your firewall is not generally available.

Zof Reliability Team · Engineering & product

March 5, 2026 · 7 min read · Updated March 5, 2026

Share
01

Two trends a healthcare CTO should hold together

AI assistants and agents now write a meaningful share of new code. Separately, research on AI coding tools keeps finding that a meaningful share of generated changes introduce flaws or security issues. Read those together and the direction is unforgiving: a growing share of your change volume comes from a source that ships defects at a real rate, and it does so faster than any human review cadence was designed to absorb.

In most industries that produces technical debt and the occasional incident. In healthcare it produces something sharper. The systems generating the most AI-assisted code, the EHR integrations, the eligibility and claims logic, the device data pipelines, are frequently the systems that handle protected health information and sit inside segmented, firewalled networks by design. The blast radius of a bad change is not a degraded user experience. It is a reportable privacy breach, a corrupted clinical record, or an interface engine silently dropping messages between systems that clinicians trust.

Estimates of what poor software quality costs the economy each year run very large. You do not need to accept any particular figure to accept the direction it points. The volume of change is up, the defect rate per change is not going down, and in regulated environments the cost per defect is among the highest there is.

02

The firewall is doing its job, and that is the problem

Here is the uncomfortable structural fact. The validation tooling that has matured fastest over the last few years assumes your code, your fixtures, and your runtime telemetry can leave the building. Cloud-hosted test runners, SaaS observability, AI code scanners that phone home to an external model: all of them assume egress.

Your most sensitive enclave is engineered to deny exactly that. No outbound calls to an external model. No raw logs shipped to someone else's tenant. No inbound listening port for an external orchestrator to reach in and drive a test. The segmentation that satisfies your auditors is the same segmentation that locks modern validation tooling out.

So teams improvise. They test the AI-generated code in a lower environment that does not actually mirror the enclave, then promote it across the boundary on faith. Or they carve a temporary exception in the firewall to let a scanner run, and quietly forget to close it. Or they accept that the highest-risk systems get the lightest automated validation, because the good tools cannot operate where the risk lives. Each of these is a rational local decision that adds up to an indefensible global posture.

The requirement, stated plainly, is this: governed validation that runs *inside* the customer boundary, produces evidence an auditor will accept, and does not force sensitive data or inbound access out of the segment to do it. Anything that requires egress is, for your regulated estate, not a solution.

03

Why "review harder" and "more AI" both fail here

Two reflexes show up when a CTO confronts this shift. Neither survives contact with the firewall.

The first is to lean harder on human review. But review is the resource that does not scale with generation. If a tool can emit a thousand lines in a minute and a senior engineer can meaningfully review a few hundred lines an hour, the queue only grows. Worse, industry surveys keep finding that developers bypass policy and guardrails when those controls slow them down. Adding review steps to a process people already route around does not increase safety. It increases the gap between your documented controls and your actual ones.

The second reflex is to buy more AI: another model, another autonomous agent that promises to fix the code it just wrote. For a regulated estate this is reckless. Unsupervised autonomous fixing inside an enclave that holds PHI is not a productivity feature, it is an unbounded liability with no audit trail. A serious healthcare enterprise does not want more AI acting on its core systems. It wants control over what acts, when, and on whose authorization.

That is the real category. Not better generation. A control layer that sits between intent and production and validates every change before it lands, with the validation running where your data already lives.

04

What in-enclave reliability actually requires

Making this concrete means naming the mechanisms, not the marketing. A control plane that can only operate where your data is least sensitive is not a control plane. Extending governance into the enclave without weakening the enclave takes a few things working together. Some of them are live in Zof today; the in-enclave parts are a design we are pursuing and are not generally available.

  • A live model of the system. A System Graph that maps services, dependencies, and repos makes validation change-aware. A one-line config edit and a refactor of the ADT message handler are not equal risk, and a control layer that knows the difference can be proportionate instead of punishing. That same context is what makes reachability-based prioritization possible, so your scarce review attention lands on what is genuinely reachable rather than on noise. The System Graph is live in Zof today.
  • Validation that tracks the system as it moves. Static test scripts rot the moment the system changes, and a rotting gate gets disabled under load. The pattern that holds up is validation chosen from what changed and what depends on it, so coverage follows reality instead of decaying into the kind of noise engineers learn to ignore. Zof's Verification records test runs and ties them to the change today. Zof does not generate tests.
  • Execution that stays inside the boundary. This is the non-negotiable for healthcare. In the design we are pursuing, a signed runner deployed by the customer would run validation locally, capture evidence, apply redaction, and produce reports inside the protected network. Planning would happen outside, where the larger models run; execution would happen inside, where the PHI is. The boundary would stay one-directional, with no inbound access carved for an external orchestrator, and the part that touches your data would make no external model calls at runtime. This in-enclave execution is not generally available today; we scope it with each team.
  • Governance as the actual product. The governing principle is that agents propose and humans authorize. When an AI-generated change falls outside policy, the control layer should neither silently let it through nor silently fix it. It should surface the evidence and route the decision to a person with the authority to make it, with separation of duties and named approvers on emergency paths. Zof's Control makes that release decision against policy today, and the mobile approval app puts the sign-off in a named approver's hands. Remediation is the hardest, most consequential part of the loop, so in our design it is the most governed and never unsupervised. Governed remediation inside a regulated network is on our roadmap.

The throughline is that audit-ready evidence stops being a quarterly scramble and becomes a byproduct of normal operation. Every decision, who or what proposed a change, what policy applied, what evidence backed it, and who authorized it, is captured as it happens. Zof's Evidence records what was checked today; keeping that record entirely within your segment is part of the on-premises design we scope with teams.

05

What to do Monday morning

You do not need a platform migration to start closing this gap. You need to stop pretending the enclave problem is a tooling preference.

  • Find your highest-risk AI-generated path. Identify the firewalled system with the most AI-assisted commits, likely an EHR or interface integration. That is where your exposure concentrates.
  • Measure your real validation coverage inside the boundary, not outside it. Coverage in a lower environment that does not mirror the enclave is not coverage. Be honest about what is actually validated where the PHI lives.
  • Insist on local-only evidence for anything that runs inside the segment. Prove value with zero egress before deciding what, if anything, should cross the boundary. The default should be that evidence stays put.
  • Start with validation, not remediation. Let the closed loop, understand, test, reproduce, remediate, verify, prove itself under human authorization before you grant any governed autonomous fixing.
06

The bottom line

Continue Reading

Deployment Architecture

Turn governed reliability runs into continuous SOC 2 and GDPR evidence. A compliance playbook for making audits a query, not a scramble.

Zof Reliability Team7 min read
Deployment Architecture

A staged adoption playbook for a risk-averse bank, from read-only reliability observation toward governed remediation, with exit criteria at every stage.

Zof Reliability Team7 min read
Deployment Architecture

A worked example of validating identity issuance and verification flows with governed autonomy, without exposing real PII, biometrics, or credentials to test infrastructure.

Zof Reliability Team7 min read