
On April 28, 2025, the entire electrical grid of Spain and Portugal collapsed in five seconds. Not five minutes — five seconds. A cascading failure wiped out 15 gigawatts of generation capacity, leaving 60 million people without power for up to ten hours and causing multiple fatalities. The initial blame fell on renewable energy. The actual cause was far more alarming: the grid's control systems couldn't enforce their own safety rules fast enough to prevent a voltage spiral that was invisible at the monitoring level where operators were looking.
For anyone building or buying AI systems for critical infrastructure, this event is a turning point. The same class of AI that writes your emails and summarizes your meetings — probabilistic large language models — is now being pitched to manage power grids, water systems, and industrial controls. Our research into the Iberian blackout reveals why that's a dangerous path, and what "Deep AI" built on physics and logic offers instead.
What Actually Happened on April 28

Forget the renewable energy debate. On the morning of the blackout, renewables were generating 78% of Spain's electricity — a high number, but within operating parameters. The real problem was voltage management, specifically something called reactive power.
Think of reactive power as the pressure in a water system. Active power is the water flowing through your tap; reactive power is what keeps the pressure steady so the system doesn't surge or collapse. Power plants are legally required to absorb or inject reactive power to keep voltages stable — in Spain, this is codified in a regulation called Operating Procedure 7.4, which mandates that generators maintain at least 30% of their maximum capacity available for voltage control.
That morning, the grid experienced low-frequency oscillations — a kind of electrical wobble. Operators responded by connecting additional transmission lines and adjusting settings on high-voltage DC links. These interventions successfully dampened the oscillations but had a side effect: they pushed voltages higher across the network.
The transmission-level monitors showed voltages at 418 kV — within limits. But at the collector substations one level down, voltages had already hit 242 kV — well past the breaking point.
This was the observability gap that made the blackout inevitable. Operators were watching the highway while the crash was happening on the on-ramp. When local voltages exceeded protection thresholds, generators began tripping offline automatically. Fifteen gigawatts vanished in a five-second cascade. One major facility didn't just fail to absorb reactive power — it actively injected more, pouring fuel on the fire. We detail the full technical sequence in our interactive analysis of the Iberian blackout.
The Rule Was Clear. The System Couldn't Follow It.
This is the part that should concern every infrastructure leader. The rule existed. P.O. 7.4 was explicit: when voltages rise, absorb reactive power. Multiple generation facilities either responded too slowly or didn't respond at all. One did the opposite of what physics demanded.
Why? Because the controllers running these plants — legacy systems using decades-old proportional-integral-derivative (PID) logic — are tuned for steady-state conditions. They work fine when the grid is calm. During a rapid oscillation event with voltages swinging across multiple variables simultaneously, they're like a thermostat trying to manage a house fire.
The failure wasn't a lack of rules. It was a lack of systems capable of enforcing those rules in real time, under stress, at the speed the grid actually moves.
Why Chatbot AI Makes This Worse, Not Better
The enterprise AI market is flooded with what we call "wrapper" solutions — applications that put a user-friendly interface on top of large language models like GPT-4 or Claude. These models are extraordinary at language tasks. They are fundamentally unfit for controlling physical systems, for three reasons.
They guess instead of calculating. LLMs generate the most statistically plausible output based on training data. In a grid crisis, "plausible" and "physically correct" can be opposites. A language model might report that voltages are stabilizing because that's what usually happens after oscillation events — even as sensor data shows a diverging cascade.
They're too slow. Cloud-based AI calls take 500 milliseconds to several seconds. The Iberian grid lost 15 GW in five seconds. By the time an API response arrives, the blackout is already underway. Physics-informed neural networks running at the grid edge can respond in under 1 millisecond — fast enough to intervene before a cascade completes.
They can't be verified. You cannot mathematically prove that an LLM will obey Kirchhoff's voltage law or any other physical constraint. It treats "likely" and "correct" as the same thing. For a power grid serving 60 million people, that distinction is the difference between the lights staying on and a national emergency.
A probabilistic model optimizes for plausibility. A physics-informed model optimizes for truth. In critical infrastructure, those are not the same thing.
What "Deep AI" Actually Means for Grid Control

We use the term Deep AI to distinguish from surface-level AI applications. Deep AI doesn't wrap a language model around a dashboard. It embeds the laws of physics and the logic of regulations directly into the AI's decision-making architecture. Three layers work together.
The first layer uses Physics-Informed Neural Networks — neural networks whose training process is constrained by the actual differential equations governing power system behavior. When these networks make a control decision, they don't just pattern-match against historical data. They solve the underlying physics in real time. In testing, this approach provides active damping of the kind of oscillations that preceded the Iberian blackout up to 87 times faster than conventional optimization methods.
The second layer is what we call the neuro-symbolic sandwich. A neural network handles pattern recognition and prediction — the intuitive part. But every output passes through a symbolic logic layer that encodes regulatory rules as hard constraints. If the neural layer suggests injecting reactive power during an overvoltage event, the symbolic layer physically blocks that command. The scenario where a plant "added rather than absorbed" reactive power becomes impossible — not unlikely, not flagged for review, but architecturally impossible.
The third layer moves intelligence to the edge of the grid itself. Instead of relying on centralized control rooms polling data every few seconds, specialized controllers at collector substations run continuous optimization loops every 100 milliseconds. This directly addresses the observability gap that made the Iberian blackout invisible until it was too late.
The goal isn't a smarter control room. It's a grid whose control layer is physically incapable of executing an action that violates safety protocols.
From Reactive Recovery to Immune Response
After the blackout, restoring power to Spain and Portugal took nearly 24 hours — a painstaking manual process of restarting isolated "islands" of generation and carefully reconnecting them. Our research into multi-agent reinforcement learning for grid restoration, detailed in our full technical deep-dive, shows how autonomous AI agents operating in a hierarchy — local agents managing individual power islands, coordinating agents overseeing synchronization — could compress that timeline dramatically.
During the actual recovery, Morocco contributed 900 MW and France contributed 2 GW of support. Routing that power optimally to the highest-priority areas while maintaining voltage stability across a fragmented grid is exactly the kind of complex, multi-variable problem that reinforcement learning agents excel at — provided they operate within deterministic safety boundaries rather than probabilistic best guesses.
What About the EU AI Act?
Grid control systems fall under "critical infrastructure" in the EU AI Act's high-risk classification. This means every automated decision must be explainable and auditable. Language model wrappers fail this test categorically — they cannot provide a causal chain for their outputs.
A neuro-symbolic system produces decision traces that read like an engineering log: oscillation detected at 0.63 Hz, voltage limit of 435 kV exceeded at collector substation, symbolic layer enforced mandatory reactive absorption at 30% of maximum capacity, voltage stabilized at 418 kV. That's the kind of audit trail that satisfies both regulators and the engineers who need to trust the system with their grid.
Does This Mean Ripping Out Everything?

No. The transition from legacy control to Deep AI doesn't require a wholesale replacement. We've mapped a phased approach that starts with closing the observability gap — deploying high-resolution sensors at collector substations and feeding that data into digital twin simulations. Think of it as giving the grid a full-body scan instead of just checking its pulse.
The second phase layers symbolic safety guardrails on top of existing controllers. If a legacy PID system attempts to inject reactive power during an overvoltage, the guardrail intercepts and corrects the command. No hardware replacement needed — just an intelligent safety net.
Only in the final phase do edge-native physics-informed controllers replace legacy systems at the most critical nodes, transforming the grid from a system that reacts to failures into one that preemptively stabilizes disturbances at the speed of electricity.
The Real Lesson of April 28
The Iberian blackout wasn't a failure of renewable energy. It was a failure of intelligence — the gap between having safety rules and being able to enforce them in the five-second window that separates a manageable disturbance from a continental-scale blackout. Sixty million people experienced that gap firsthand.
As grids worldwide increase renewable penetration and decrease the synchronous generation that once provided natural stability, this gap will only widen. Filling it with probabilistic AI that optimizes for "plausible" instead of "physically correct" isn't a solution. It's a more sophisticated way to repeat the same mistake.
The 2025 Iberian blackout was a five-second exam that the world's grid control systems failed. The question now is whether we study for the next one or hope it doesn't come.
We'd welcome hearing from grid operators, utility leaders, and infrastructure engineers who are grappling with these questions. The physics won't wait for the industry to catch up — but the engineering to get ahead of it already exists.