From Empirical ML to Formally Specified AI
The shift from training neural networks on data to building AI systems with mathematical guarantees represents the most significant architectural change in the field since deep learning's ascendance.
For two decades, machine learning operated within a single paradigm: observe patterns in data, optimize a loss function, deploy the result. This empirical approach delivered remarkable capabilities—language models that generate coherent text, vision systems that recognize objects, recommendation engines that predict user behavior with eerie accuracy. But it also created a fundamental problem that no amount of scale or compute has solved: we cannot formally verify what these systems will do in novel situations. We can test them. We can benchmark them. We cannot prove them correct.
Formal specification changes this entirely. Rather than learning behavior from examples, formally specified systems encode mathematical constraints that must hold true across all possible inputs. A formally specified AI system doesn't approximate a solution; it guarantees one, within defined parameters. This is not a minor engineering improvement. It is a categorical difference in how we reason about correctness.
The Thing Everyone Gets Wrong
Most practitioners still treat formal specification as an optional layer—something you add after building an empirical system, like a safety harness bolted onto an existing structure. This misses the point entirely. Formal specification is not a post-hoc verification tool. It is a design methodology that changes what you build from the ground up.
The confusion stems from how we've talked about the problem. We frame it as "making neural networks safer" or "adding interpretability to black boxes." These framings assume the empirical system is the primary artifact and formal methods are supplementary. In reality, the relationship inverts. A formally specified system is the primary artifact. Empirical components—if they exist at all—become subordinate tools for specific, bounded tasks where formal guarantees are either unnecessary or computationally infeasible.
This distinction matters because it changes what problems you can actually solve. An empirically trained system that you later try to verify is like trying to prove the correctness of a program after it's been compiled to machine code. Theoretically possible. Practically intractable. A formally specified system, by contrast, is designed with proof in mind from the first line.
Why This Matters More Than People Realize
The practical consequence is that entire classes of AI applications become viable only through formal specification. Consider a system that must make decisions affecting human safety—medical diagnosis, autonomous vehicle behavior, critical infrastructure control. With empirical ML, you can reduce error rates through more data and better architectures, but you cannot eliminate the possibility of catastrophic failure on edge cases. With formal specification, you can prove that certain failure modes are impossible.
This is not theoretical. Organizations building high-stakes AI systems are already discovering that empirical approaches hit a wall. You can achieve 99.5% accuracy on a benchmark. You cannot achieve 99.5% safety across all possible scenarios without formal guarantees. The gap between "very accurate on test data" and "provably safe in production" is not a matter of engineering effort. It is a matter of methodology.
The second reason this matters: formal specification enables compositional reasoning. Empirical systems are monolithic. You train a model end-to-end, and its behavior emerges from the entire network. Formally specified systems can be decomposed into verified components with known interfaces. This makes them maintainable, auditable, and extensible in ways empirical systems simply are not.
What Changes When You See It Clearly
Once you accept that formal specification is the primary design methodology, your entire approach to building AI systems reorganizes. You start by defining what the system must guarantee, not by collecting training data. You prove properties before you implement them. You use empirical methods only where formal methods cannot reach.
This is not the future of AI. For certain applications, it is already the present. The question is not whether formal specification matters. It is how quickly the field will recognize that empirical ML, for all its achievements, was always a temporary solution to a permanent problem.