Use case · Treasury & risk

Close the risk book while the market is open.

The Monday reality: positions in one workbook, FX in a terminal, VaR in a Python job someone reruns by hand, and a PDF at 4pm. In Grid it's one model — live FX, revalued positions, VaR three ways — computing continuously, with an API your other systems read directly.

Grids
@
01 · The model

Monday morning, as source.

risk-book.gridgrid
# live inputs, with a floor under them
eur_usd = FX_RATE("EUR", "USD")
rate = eur_usd DEFAULT 1.08

# the book, revalued as rates move
mv_usd = notionals * prices * rate

# risk, three ways, same cells
var_hist = VAR_HISTORICAL(returns, 0.95)
var_mc = VAR_MONTE_CARLO(returns, 0.95, 10, 100000)
sharpe = SHARPE(returns, 0.02, 252)

# never stale for the 9am call
EVERY 15min SKIP MISSED THEN
  refresh_stamp = NOW()
END

Every function here is in the catalog; DEFAULT keeps the book computing while a quote is in flight, and the schedule declares what happens to missed runs.

Not a demo. A working domain.

The canonical library ships a full portfolio risk engine and treasury control plane — position translation, carry, duration stress, liquidity ladders — as working models, not slideware.

More MondaysAll use cases