The one thing no code has ever truly produced
Every number a computer generates is, strictly speaking, fake. When a program calls random(), it runs a deterministic algorithm (a fixed mathematical formula) that produces a sequence of numbers which merely looks unpredictable. Feed it the same starting seed, and you get the exact same sequence every time. This is why they are called pseudo-random number generators. The “pseudo” is doing real work. The machine is not discovering randomness, but performing it.
True randomness cannot be derived from logic. A deterministic system (one that follows rules) cannot, by definition, produce an output that is free from rules. This is not a limitation of current hardware or software, but a mathematical ceiling.
Claude Shannon, who effectively invented information theory, showed that information or data itself has entropy (a measure of genuine unpredictability). A perfectly random sequence carries maximum entropy: knowing the first billion digits tells you nothing at all about digit one billion and one. No formula can produce this. Formulae, by their nature, carry structure.
To get true randomness, computers must go outside themselves and ask the physical world for a number the universe hasn’t decided yet.
Modern hardware random number generators sample genuinely unpredictable physical phenomena: the thermal noise in a resistor, the timing jitter in an oscillator, the quantum behaviour of photons hitting a half-silvered mirror.
These events are random because, according to quantum mechanics, no prior information can predict them. The universe, at its base layer, does not run on a fixed seed. Heisenberg’s uncertainty principle is not an engineering problem to be solved with better instruments. It is a fundamental feature of how reality is structured: some things are not determined until they are measured.
This is the concrete, physical sense in which randomness is a kind of bedrock.
It sits below computation, below logic, below everything that can be reasoned about in advance. Every system that needs genuine unpredictability, like cryptography, statistical sampling, Monte Carlo simulation, or clinical trial design, ultimately has to reach down to this layer and borrow some entropy from the physical world. The random number is not generated. It is harvested.
Cryptography: A predictable seed would make every encrypted connection reversible. A random token would make it irreversible
Quantum mechanics: Prove that quantum randomness is not hidden determinism; there are no secret variables underneath it
Statistical power: Random sampling works precisely because it is unmanipulable- a sample no one can predict cannot be gamed, which is what gives it evidentiary weight
For governance systems like audits, validations, and inspections, this property is not incidental. It is the entire mechanism. A validation that fires on a schedule can be worked around.
A validation that fires on true randomness inherits something the universe itself provides: the guarantee that no prior knowledge is sufficient to escape it. The mystery customer is powerful because they are, in a practical sense, drawing from the same well of leverage shared by randomisation.
The Franchise Phenomenon: Reflected in Every Distributed System
Somewhere right now, a Subway outlet is making a sandwich. The bread may or may not be the regulation 6 inches. The portion weight may or may not match the spec. The staff may or may not have washed their hands in the last hour. Subway’s corporate headquarters does not know. The regional manager does not know. The franchise agreement says these things must be so, but the franchise agreement is a document, not a sensor.
This is the foundational problem of distributed operations, and it is not unique to fast food.
It appears wherever a central authority needs consistent behaviour from nodes it cannot directly observe.
Examples: A bank and its branch tellers, a pharmaceutical company and its contract manufacturers, a technology platform and its third-party integrations.
The centre sets the standard, and the edge executes. And in between, there is a gap: a zone of unobserved behaviour where the standard either holds or it doesn’t.
The naive solution is surveillance: watch everything, always. Install cameras, add logging, mandate check-ins, require sign-offs. But this approach collides with a hard constraint at scale.
Watching everything costs roughly as much as doing everything twice.
And it changes the relationship between centre and edge from one of trust-with-verification to one of control-with-resentment, which, counterintuitively, often produces worse outcomes. When people feel monitored constantly, they optimise for the metrics being measured, instead of optimising for alignment with the underlying standard more organically.
The goal of governance is not to watch every action. It is to make non-compliance the less rational choice, even when no one is watching.
🔖 Related Read
What the franchise model discovered, through decades of operational iteration, is that this goal does not require omniscience. It requires credibility and unpredictability.
Enter the mystery customer: a trained auditor who visits any outlet, at any time, without announcement, and evaluates the full experience against the brand standard. The power of this mechanism is not that it catches every violation. It is that it makes the probability of being caught non-zero and non-schedulable.
The franchise owner who might cut corners on a slow Tuesday has to weigh that decision against a simple, unresolvable question: is today the day? The deterrent lives in the uncertainty instead of the expensive audit.
Data Contracts: The Franchise Agreement for Data
Software teams building data pipelines have been in the franchise problem for years without naming it that way. An upstream service produces data, and a downstream team consumes it. In between, there is an implicit handshake: unstated assumptions about schema, freshness, cardinality, null rates, and value ranges.
These assumptions are almost never written down. They exist in Slack threads, tribal knowledge, and the quiet dread of the on-call engineer who knows that something upstream changed last Tuesday but cannot say precisely what.
The failure mode is always the same: the upstream team ships a change that seems local, like renaming a column, changing a data type, or adding a new null case. The downstream team’s dashboard breaks undetected, the customer-facing metric gets corrupted without triggering alerts, and three days later, someone notices.
The post-mortem reveals no villain. There was no intent to break anything, and just no shared, written understanding of what the upstream team had agreed to produce.
Data contracts are an attempt to close this gap structurally, before anything breaks. A data contract is a formal declaration made collaboratively by the consumer and producer of a dataset: here is the schema I need. Here is the schema we can commit to. Here is the field-level semantics. Here are the SLAs on freshness and completeness. Here is what constitutes a breaking change, and here is the notice period before I make one.
The contract is signed like the franchise agreement: it is negotiated at onboarding instead of being litigated after the fact.
🔖 Related Read
This shift in ownership is the contract’s most underrated effect. Before contracts, data quality failures produce blame diffusion: the producer says they didn’t know anyone was relying on that field, while the consumer says they couldn’t have known it would change.
After contracts, the ownership is unambiguous and traceable. Unambiguous blame is the only kind that produces durable behaviour change, because it closes the escape routes that allow teams to tell themselves it wasn’t really their fault.
Contracts also solve a subtler problem: they make the implicit legible. Most data pipelines fail because of invisible assumptions that were never stress-tested against the real world.
Writing a contract forces the consumer to articulate what exactly they’re expecting and the producer to articulate what they are actually committing to: a discipline that routinely surfaces misunderstandings before they become incidents. The act of drafting the contract is itself a form of pre-mortem.
Randomised Validation: Why Constant Gates are the Wrong Answer and What to Do Instead
Here is where most data teams make a predictable mistake. They hear “data contracts” and immediately design a validation gate that fires on every record, every pipeline run, every hour of every day.
The thinking is intuitive: we have a standard, so we should check every unit of output against that standard. This feels like rigour. In practice, at production scale, it is expensive, brittle, and, most importantly, not actually necessary to achieve the governance outcome you want.
Consider what a franchise does with its mystery customer programme. The audits are real, and the consequences for failure are real. But Subway does not send a mystery customer to every outlet every day.
That would cost more than the franchise revenue it protects.
Instead, audits are randomised in both timing and frequency: any outlet might be visited tomorrow, or next week, or in three months. The point is that no outlet can know when, which means every outlet has to behave as if the answer is today.
This is the insight that statistical sampling has been formalising since the 1930s: you do not need to inspect the entire population to make reliable inferences about it. You need a sample that is sufficiently large, unbiased, and (critically for governance) unpredictable to the entity being sampled.
The last property is the one that prevents gaming. A quality check that fires every Monday morning at 9 am is a quality check that a motivated producer can pass while failing every other time. A quality check that fires on a randomly drawn 8% of batches is a quality check that cannot be scheduled around.
The randomised validation model in practice:
Sample stochastically. Fire full schema, business-rule, and statistical checks on a random subset, typically 5-15% of records or batches, calibrated to the cost of a miss versus the cost of compute.
Make the sampling truly random. Not a cron job or every nth record. Draw from hardware entropy or a cryptographically secure RNG, one that the producer cannot predict or reverse-engineer.
Alert with full lineage. When a validation fires, surface it with the full causal chain. Which producer, which job, which commit, which field. Without lineage, a validation is an alarm with no address on it.
Set consequence at contract time. The producer should know before going live: a failed validation triggers an SLA breach. This is the franchise agreement clause, not a surprise after the fact.
Instrument the tails. Always-on lightweight checks for volume anomalies and null rate spikes are cheap enough to run constantly. Reserve deep validation for the random sample. Think of the cheap checks as the smoke detector and the random deep audit as the fire inspection.
The compound effect of this architecture is significant. A pipeline processing ten million records a day with full validation on every record might spend 40% of its compute on validation alone: compute that produces no output, only catches errors that a well-maintained contract would prevent in the first place.
Shifting to randomised deep validation with cheap always-on monitoring can reduce that overhead to under 5%, while delivering the same or better deterrent effect on producer behaviour.
The mystery customer programme costs a fraction of a full inspection regimen and achieves more behavioural compliance, because it exploits the psychology of uncertainty rather than the economics of exhaustive coverage.
There is also a more subtle engineering benefit. Constant validation gates become production dependencies. When the validator goes down, the pipeline stops. When the validation schema is wrong, legitimate data gets blocked. Randomised sampling is asynchronous by design.
When the node at the edge is an AI
Model Context Protocol (MCP) is a specification that defines how AI models interact with external tools and data sources.
At its simplest, it is a standard interface: an AI agent can call a calendar, a CRM, a code repository, a data warehouse, or any other system through a defined set of declared capabilities. The agent knows what it can call. The system knows who is calling and with what scope. And the organisation that deployed the agent has, in principle, a record of what the agent was permitted to do.
MCP matters for the same reason the franchise agreement matters: because it defines what the agent has agreed to do. This is a subtle but important distinction. Before MCP, deploying an AI agent with access to business systems was an act of faith bounded only by the model’s training. And of course, integration overhead.
MCP shifts the trust model. An agent operating under an MCP definition has a declared operational envelope: these are the tools I can use, these are the data sources I can access, this is the scope of permission I have been granted.
Anything outside that envelope is structurally off-limits, not just discouraged. The agent doesn’t need to exercise good judgment about whether it should write to the production database. It simply cannot, because no tool in its context permits it.
MCP turns the question from “what is this AI capable of?” to “what has this AI agreed to do and who is checking?”
But the MCP definition alone is, like the data contract alone, insufficient. A contract without enforcement is a suggestion. The question is: what is the enforcement mechanism for AI agent behaviour, and how does it avoid the traps of either constant surveillance or no surveillance at all?
The answer, by now, should be familiar. You do not audit every action an AI agent takes.
At the scale of agentic automation, where a single deployed agent might take hundreds of actions per hour across dozens of users, a full audit is neither feasible nor desirable.
What you do instead is maintain an append-only action log and run randomised deep audits against it: a percentage of completed agent sessions, drawn unpredictably, reviewed against the MCP-defined scope and the organisation’s intent.
The team that deployed the agent knows the audits happen. They do not know when. This is, again, the mystery customer. The agent’s principal and the team responsible for it behave as though any session might be the one under review, because any session might be. Back to randomised deep validation with cheap always-on monitoring strategy.
Governed Autonomy: The Architecture that Scales
There is a coherent architecture running through all four of these threads. It does not belong to food service, data engineering, or AI safety specifically. It is an answer to a more general question:
how do you give distributed nodes the autonomy they need to be useful, while ensuring they remain reliably aligned with the standards of the centre that authorised them?
The answer has four components, each of which mirrors a layer of the franchise model:
The Governed Autonomy Stack
Declare before deploy.
Every node (dashboard, service, AI agent, franchise outlet) publishes a contract before it goes live. The contract defines the operational envelope and is agreed to by the node’s owner.Assign ownership at the source. Both consumer and producer of a data asset can own its contract, depending on the asset type (e.g., a consumer-aligned data product’s contract is typically owned by the consumer while a source-aligned data product’s contract is owned by the producer). Ownership makes accountability traceable through the organisational graph: there is always a named person whose problem it is.
Validate randomly, not constantly. Sample validations draw from true or cryptographically secure randomness, fire on unpredictable subsets, and surface failures with full lineage. The deterrent effect is independent of frequency. The cost scales with sample rate.
Make consequence proportional and pre-announced. The mystery customer programme has teeth because the consequence of failing an audit is known at contract time. The franchise owner signed the agreement. The data producer accepted the SLA breach policy. The AI deployment team knew the scope violation would trigger a review. Surprise consequences produce resentment, while pre-announced consequences produce self-governance.
This is, in behavioural terms, the difference between compliance and conformance. Compliance is doing the right thing because someone is watching. Conformance is doing the right thing because the cost-benefit analysis, once the audit probability is non-zero, favours it unconditionally.
The deeper principle here comes from mechanism design: the branch of economics and game theory that asks not “how do we monitor rational actors?” but “how do we design the rules so that rational actors monitor themselves?”
This works not by making the centre omniscient, but by making the edge uncertain, which is a natural property of the edge. And uncertainty, as we established at the very beginning of this argument, is something the universe is genuinely very good at providing.
You cannot build a system that watches everything. But you can build a system where everything behaves as if it might be watched, and that turns out to be almost as good.
🔖 Related Read
MD101 Connect ☎️
If you have any queries about the piece, feel free to connect with the author(s). Or connect with the MD101 team directly at community@moderndata101.com 🧡
Author Connect 💬
Connect with Animesh on LinkedIn 💬
From MD101 team 🧡
🌎 Global Modern Data Report 2026
The Modern Data Report 2026 is a first-principles examination of why AI adoption stalls inside otherwise data-rich enterprises. Grounded in direct signals from practitioners and leaders, it exposes the structural gaps between data availability and decision activation.
With hundreds of datapoints from 500+ data leaders and experts from across 64 countries, this report reframes AI readiness away from models and tooling, and toward the conditions required and/or desired for reliable action.


















