The London Whale
(2012)
The new formula divided by a sum instead of an average.
The model under-stated risk by roughly half.
JPMorgan's Chief Investment Office lost ~$6.2 billion on a credit derivatives position in the first half of 2012. The position grew so large the trader who built it became known industry-wide as “the London Whale.” A model that mis-stated the position's risk by roughly half is one of several failures the post-mortems converged on.
Sources · U.S. Senate Permanent Subcommittee on Investigations, “JPMorgan Chase Whale Trades” (2013) · JPMorgan task-force report, January 2013 · SEC enforcement actions 2013-2014 · Bloomberg, The Wall Street Journal, Reuters coverage 2012-2013.
The Chief Investment Office's synthetic credit portfolio used a Value-at-Risk (VaR) model to constrain how much capital the trading desk could deploy. The model was managed in part through a spreadsheet that aggregated risk metrics across the position. The VaR limit was a hard guardrail: when the metric crossed it, trading activity had to be reduced.
In early 2012, the desk built a revised VaR model and rebuilt parts of it in a new spreadsheet. According to the Senate subcommittee's report, one calculation was supposed to divide a sum of variances by the count of observations: producing an average. The new spreadsheet implementation divided by the sum, not the count. Mathematically, this approximately halved the resulting VaR figure for that calculation.
The under-stated VaR fed the guardrail check. The guardrail kept reading below the threshold even as the position grew large enough that the true VaR would have triggered the limit weeks earlier. The desk continued to add risk in good faith: the model said it was safe to do so. By the time the position blew up, the firm held a derivative book it could neither hedge nor unwind without moving the market.
The position became too large to hide. Other market participants began identifying the trader, and JPMorgan disclosed a $2 billion loss in May 2012. The loss ultimately grew to roughly $6.2 billion. Investigations followed: SEC, OCC, FBI, Senate Permanent Subcommittee. The spreadsheet error is one of several failures the reports converge on (others include risk-policy violations, valuation disputes, and management oversight). The architectural failure of the model is the one most relevant to us here.
$6.2 billion in mark-to-market trading losses. ~$1 billion in regulatory penalties (SEC, OCC, FCA combined). Senior departures. Substantial reputational damage. The firm acknowledged in its own task-force report that the model had been “improperly implemented” in the workbook in question.
The architectural cause is not that the modeler was careless or that JPMorgan didn't care about risk. The architectural cause is that a spreadsheet has no structural way to express the invariant “VaR_new must produce the same dimensional result as VaR_canonical.”A new formula was written; the substrate could not compare its output dimensions to the previous formula's. No type system flagged that the new calculation produced a quantity with the wrong units. No cross-validation assertion fired. The substrate accepted the new VaR as if it were the same kind of number as the old one. From the moment of the rewrite, the guardrail was checking a number that no longer meant what the guardrail thought it meant.
=SUMPRODUCT(variances) / COUNT(variances)=SUMPRODUCT(variances) / SUM(variances)Dimensional inference would
have flagged it at compile.
In Flatland, variances is a typed Vector(Variance). The canonical VaR formula would have produced Variance(USD²) when divided by Count. The implemented formula: divided by Variance(USD²) instead: produces a dimensionless ratio, which the dimensional inference pass would warn on the moment the IR was compiled. The guardrail itself would be a typed assertion against Variance(USD²) specifically. The substitute number would refuse to land in it.
The point isn't that the JPMorgan team would have caught the error with a different tool. The point is that a spreadsheet substrate cannot express the constraint that the new formula must produce a quantity of the same dimensional kind as the old. A typed compilation substrate can. The model and the guardrail share a contract. When the contract breaks, the compiler refuses to run.
Compile a model with assertions
that have units behind them.
Three questions. A typed compile. The dimensional inference pass runs. The assertions check. When something's wrong, the compiler tells you which assumption broke: before it ships.


