open-source volatility infrastructure
Live option chains, turned into arbitrage-checked vol surfaces.
VolFoundry inverts live Deribit quotes through Black-76, extracts a forward per expiry, fits raw-SVI smiles and a global SSVI surface, then reports static-arbitrage diagnostics with their evaluation domain and tolerance. Everything below this line is running on live market data, in this browser tab — no server, no replay.
Smile — implied vol vs strike
ATM vol by maturity
Methodology
Pricing, calibration & no-arbitrage validation
The pipeline that turns a raw quote into a validated surface, with each step tied to its
source in the literature and to where it runs in the code. Conventions: volatility is decimal
(0.60 = 60%), maturity \(T\) is in years on ACT/365, log-moneyness is \(k=\ln(K/F)\), and
total variance is \(w(k,T)=\sigma^2(k,T)\,T\). Full derivations are in the repository under
docs/derivations/; numbered references are listed below.
Forward-settled European options [1]
Black's forward measure [1]: crypto options settle
against a future, so the forward — not spot — is the state variable.
In VolFoundry: pricers.black76_price evaluates this; iv.implied_volatility
inverts it for \(\sigma\) by Newton on vega with a bracketed (Brent) fallback, holding the root
in \(\sigma\in(0,5]\).
Forward curve from put–call parity
A model-free identity. Regressing \(C-P\) on \(K\) across paired strikes yields
slope \(-e^{-rT}\), hence the discount factor and forward, per expiry — no constant-rate or
zero-basis assumption. In VolFoundry: SurfaceBuilder runs this regression;
the live panels above use Deribit's per-expiry underlying_price as \(F\).
SVI slice parameterisation [3][6]
Gatheral's stochastic-volatility-inspired form [3];
its wing slopes \(b(1\pm\rho)\) obey Lee's moment bound \(\le 2\) [5].
In VolFoundry: svi.calibrate_svi_slice uses the Zeliade quasi-explicit scheme
[6] — outer search over \((m,\sigma)\), inner constrained
least-squares for \((a,b,\rho)\).
Butterfly arbitrage: the \(g(k)\) condition [4]
Non-negative risk-neutral density in Gatheral–Jacquier form [4],
cross-checked against the Breeden–Litzenberger density \(\partial^2C/\partial K^2\ge 0\)
[2]. In VolFoundry: arbitrage evaluates \(g(k)\)
over a stated domain (e.g. \(k\in[-2,2]\), 1001 pts) at a reported tolerance — evidence over that
grid, not a proof over the whole real line.
Calendar arbitrage & the SSVI surface [4]
SSVI couples the slices through ATM total variance \(\theta(T)\) and a \(\varphi(\theta)\) family; Gatheral–Jacquier give the parameter conditions for a calendar- and butterfly-free surface [4]. In VolFoundry: strict validation enforces these during calibration and rejects violating fits, rather than auditing after the fact.
Quote filtering & no-arbitrage bounds
Zero-bid, crossed and stale quotes, sub-day maturities and prices outside the
static no-arbitrage bounds are removed before inversion. In VolFoundry: the
data layer records per-reason drop counts so the surface is auditable — a fit is
only as sound as the quotes beneath it.
References
- Black, F. (1976). The pricing of commodity contracts. Journal of Financial Economics, 3(1–2), 167–179. doi:10.1016/0304-405X(76)90024-6
- Breeden, D. T., & Litzenberger, R. H. (1978). Prices of state-contingent claims implicit in option prices. The Journal of Business, 51(4), 621–651. doi:10.1086/296025
- Gatheral, J. (2004). A parsimonious arbitrage-free implied volatility parameterization. Global Derivatives & Risk Management, Madrid; see also The Volatility Surface (Wiley, 2006).
- Gatheral, J., & Jacquier, A. (2014). Arbitrage-free SVI volatility surfaces. Quantitative Finance, 14(1), 59–71. arXiv:1204.0646
- Lee, R. W. (2004). The moment formula for implied volatility at extreme strikes. Mathematical Finance, 14(3), 469–480. doi:10.1111/j.0960-1627.2004.00200.x
- Zeliade Systems (2009). Quasi-explicit calibration of Gatheral's SVI model. Zeliade White Paper ZWP-0005.
Use it as a library
Pure Python, typed, tested against analytic cases and reference surfaces. Same code path the panels on this page are modelled on.
# install $ pip install volfoundry # live chain → calibrated, validated surface $ volfoundry live --currency BTC --out surface.json # or from Python >>> from volfoundry import Chain, SSVISurface >>> chain = Chain.from_deribit("BTC") >>> surface = SSVISurface.calibrate(chain) >>> surface.validate(domain=(-2, 2), n=1001).is_valid True >>> surface.iv(k=0.0, T=30/365) 0.5812
- 01Quotes in, surface outDeribit live or historical chains, quote hygiene and forward extraction included — not just a curve fitter.
- 02Diagnostics you can quoteButterfly, calendar and density checks returned as data: domain, grid size, tolerance, per-slice minima and rejects.
- 03Deterministic and typedSeeded optimisers, pinned tolerances, full type hints, property tests on the SVI parameter constraints.
- 04MIT licensedRead it, fork it, vendor it. Issues and PRs at the repository.
mark_iv, not an executable price. Numerical no-arbitrage checks are
reported together with their evaluation domain, grid and tolerance and are not a guarantee of
arbitrage-freeness over all strikes and maturities. Validate independently before any
financial use.