Skip to content

itofin

itofin is the Python binding for libitofin, a ground-up port of QuantLib into idiomatic Rust. The Rust core does the numerics; the Python package is a thin, typed surface on top.

  • Fidelity in numerics, usability at the boundary. QuantLib is the oracle for every number; the Python API adds ergonomic conveniences (keyword constructors, price(engine)) without changing the math.
  • Typed and introspectable. Every class ships hand-written .pyi stubs with Google-style docstrings, so editors autocomplete and this site renders the full signature.

Install

pip install itofin
cargo add libitofin

A first taste

from itofin import Settings
from itofin.instruments import OptionType, VanillaOption
from itofin.processes import BlackScholesProcess
from itofin.time import Date

settings = Settings()
settings.set_evaluation_date(Date(15, 6, 2026))
# ... build the process, wrap it in a VanillaOption, attach an engine, read npv()

The full walk-through, in both languages, is on the Getting started page.

Where the docs live

Surface Where
Python API reference This site (see the Python API section)
Rust API reference docs.rs/libitofin - see Rust API
Worked examples example/python and crates/libitofin/examples