Skip to content

quantmind/quantflow

Repository files navigation

PyPI version Python versions Python downloads build codecov

Quantitative analysis and pricing tools.

btcvol

Installation

pip install quantflow

Optional dependencies

  • data — data retrieval: pip install quantflow[data]
  • ai — MCP server for AI clients: pip install quantflow[ai,data]
  • ml — training the Deep Implied Volatility model: pip install quantflow[ml]

Features

  • Stochastic Processes: a library of continuous-time models including Wiener processes, Poisson jumps, CIR mean-reverting dynamics, Heston stochastic volatility, jump-diffusion models, and the Barndorff-Nielsen & Shephard (BNS) model. Each process exposes its characteristic function for analytical pricing.

  • Option Pricing and Calibration: Black-Scholes pricing, implied volatility surfaces, SVI parameterisation, put/call parity, and model calibration (Heston, Double Heston). Includes support for both inverse (crypto) and standard (equity) quoting conventions.

  • Interest Rates: yield curve construction via Nelson-Siegel and Vasicek models, discount factor calculation, and rate interpolation.

  • Market Data: connectors for Deribit, Yahoo Finance, Financial Modeling Prep (FMP), FRED, the Federal Reserve, and US Fiscal Data APIs.

  • Time Series Analysis: exponentially weighted moving averages (EWMA), Kalman filtering, super-smoothers, and OHLC bar utilities.

  • AI Integration: an MCP server that exposes quantflow's data tools to AI assistants.

  • JSON Serializable: all models and pricers are built on Pydantic, making them fully serializable to and from JSON.

Citation

If you use Quantflow in your research, please cite it using the metadata in CITATION.cff.

License

Released under the BSD 3-Clause License.