Skip to content

Commit e680532

Browse files
committed
chore(release): consolidate to 0.17.0, unified release for Black-76 and Garman-Kohlhagen
1 parent 0c26f7c commit e680532

3 files changed

Lines changed: 37 additions & 45 deletions

File tree

CHANGELOG.md

Lines changed: 35 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -7,17 +7,36 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10-
## [0.17.1] - 2026-04-26
10+
## [0.17.0] - 2026-04-26
11+
12+
Release adding two new closed-form pricing models:
13+
- **Black-76** (Black 1976) for European options on futures and forwards.
14+
- **Garman–Kohlhagen** (1983) for European FX options.
1115

12-
Minor release adding the Garman–Kohlhagen (1983) closed-form pricing
13-
model for European FX options. The new variant
14-
`PricingEngine::ClosedFormGK` is appended at the tail of the enum so
15-
the existing variants keep their implicit discriminants and no major
16-
bump is required (`PricingEngine` has been `#[non_exhaustive]` since
17-
0.17.0).
16+
The bump to `0.17.0` is required because `PricingEngine` is now
17+
`#[non_exhaustive]` (a semver-breaking change for downstream exhaustive
18+
matches). Both new variants are appended at the tail of the enum to
19+
preserve existing discriminants and avoid further major bumps.
1820

1921
### Added
2022

23+
**Black-76 model** (Black 1976):
24+
- `pricing::black_76`: closed-form `black_76(option) -> Result<Decimal, PricingError>`
25+
for European options on futures / forwards. Reuses the existing `d1`
26+
/ `d2` / `big_n` helpers; `Decimal` end-to-end via `d_mul` / `d_sub`;
27+
`tracing::instrument` on the entry point. Only `OptionType::European`
28+
is supported — American, Bermuda and exotics return
29+
`PricingError::UnsupportedOptionType`.
30+
- `pricing::Black76` trait with default `calculate_price_black_76`
31+
(mirrors `BlackScholes`).
32+
- `pricing::PricingEngine::ClosedFormBlack76` variant + dispatch from
33+
`price_option`.
34+
- `greeks::utils::calculate_d_values_black_76` `pub(crate)` helper.
35+
- `examples/examples_pricing/src/bin/black_76.rs`: runnable demo
36+
(Hull canonical example, ITM commodity-futures call, unified-API
37+
dispatch, short-side sign convention).
38+
39+
**Garman–Kohlhagen model** (Garman & Kohlhagen 1983):
2140
- `pricing::garman_kohlhagen`: closed-form
2241
`garman_kohlhagen(option) -> Result<Decimal, PricingError>` for
2342
European options on FX spot rates. Structurally identical to BSM
@@ -32,52 +51,25 @@ bump is required (`PricingEngine` has been `#[non_exhaustive]` since
3251
- `examples/examples_pricing/src/bin/garman_kohlhagen.rs`: runnable
3352
demo (Hull canonical USD/GBP, ITM EUR/USD with FX parity check,
3453
unified-API dispatch, symmetric-rate degenerate case).
35-
- `lib.rs` mermaid: new `FX / Currency` subgraph routing
36-
`garman_kohlhagen -> FX Spot`.
37-
38-
### Changed
39-
40-
- `pricing/mod.rs` Core Models / Model Selection Guidelines /
41-
Performance Considerations now include Garman–Kohlhagen with the
42-
explicit field mapping `risk_free_rate -> r_d`,
43-
`dividend_yield -> r_f`, `underlying_price -> S`.
4454

45-
## [0.17.0] - 2026-04-26
46-
47-
Major release adding the Black-76 closed-form pricing model for European
48-
options on futures and forwards. The bump to `0.17.0` is required because
49-
`PricingEngine` is now `#[non_exhaustive]` (a semver-breaking change for
50-
downstream exhaustive matches) and the addition of
51-
`PricingEngine::ClosedFormBlack76` shifts the implicit discriminant of
52-
`PricingEngine::MonteCarlo` from `1` to `2`.
53-
54-
### Added
55-
56-
- `pricing::black_76`: closed-form `black_76(option) -> Result<Decimal, PricingError>`
57-
for European options on futures / forwards. Reuses the existing `d1`
58-
/ `d2` / `big_n` helpers; `Decimal` end-to-end via `d_mul` / `d_sub`;
59-
`tracing::instrument` on the entry point. Only `OptionType::European`
60-
is supported — American, Bermuda and exotics return
61-
`PricingError::UnsupportedOptionType`.
62-
- `pricing::Black76` trait with default `calculate_price_black_76`
63-
(mirrors `BlackScholes`).
64-
- `pricing::PricingEngine::ClosedFormBlack76` variant + dispatch from
65-
`price_option`.
66-
- `greeks::utils::calculate_d_values_black_76` `pub(crate)` helper.
67-
- `examples/examples_pricing/`: new workspace member with binary
68-
`black_76` (Hull canonical example, ITM commodity-futures call,
69-
unified-API dispatch, short-side sign convention).
55+
**Infrastructure updates**:
56+
- `examples/examples_pricing/`: new workspace member with binaries for
57+
both models.
7058
- `lib.rs` mermaid: `Forward-Priced` subgraph routing
71-
`black_76 -> {Future, Forward}`.
59+
`black_76 -> {Future, Forward}`; new `FX / Currency` subgraph routing
60+
`garman_kohlhagen -> FX Spot`.
7261

7362
### Changed
7463

7564
- `pricing::PricingEngine` is now `#[non_exhaustive]` so future engine
7665
variants do not require a new major bump.
7766
- `pricing::mod.rs` Core Models / Model Selection Guidelines /
78-
Performance Considerations now include Black-76.
67+
Performance Considerations now include both Black-76 and
68+
Garman–Kohlhagen with explicit field mapping documentation.
7969
- `financial_types` bumped to `0.2.2` (adds `UnderlyingAssetType::Future`
8070
and `UnderlyingAssetType::Forward`).
71+
- `PricingError` and `GreeksError` pass-through in closed-form dispatch
72+
(BS, Black-76, GK) for full error-variant fidelity.
8173

8274
## [0.16.5] - 2026-04-20
8375

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "optionstratlib"
3-
version = "0.17.1"
3+
version = "0.17.0"
44
edition = "2024"
55
authors = ["Joaquin Bejar <jb@taunais.com>"]
66
description = "OptionStratLib is a comprehensive Rust library for options trading and strategy development across multiple asset classes."

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
// into, so the lint is silenced in `#[cfg(test)]` only.
1111
#![cfg_attr(test, allow(clippy::indexing_slicing))]
1212

13-
//! # OptionStratLib v0.17.1: Financial Options Library
13+
//! # OptionStratLib v0.17.0: Financial Options Library
1414
//!
1515
//! ## Table of Contents
1616
//! 1. [Introduction](#introduction)

0 commit comments

Comments
 (0)