Skip to content

Releases: visikai/ohlc-toolkit

3.1.3

Choose a tag to compare

@ff137 ff137 released this 28 Oct 16:06
3.1.3
92c04bf

Dependency update release. No ohlc-toolkit API changed.

Breaking

Polars 2 is now required. Any environment that pins polars 1.x has to
upgrade before taking this release.

The certifi floor also rises to 2026.10.19 (PYSEC-2026-4320).

3.1.2

Choose a tag to compare

@ff137 ff137 released this 20 Sep 15:09
ce0e384

Breaking

Generated schedules now refuse members that contradict their own spec.

Constructing a WindowSchedule, LookbackSchedule or HorizonSchedule directly, or rehydrating one through from_dict, now raises ConfigError when:

  • a member is below the recorded minimum, above the recorded maximum, or not a whole multiple of the recorded grain; or
  • the parameters are a combination the generator functions already refuse (a log-spaced endpoint that quantizes outside its range; a metallic seed at or above its floor that quantizes below it).

Before this release these paths checked only emptiness, the cap, type, positivity and repeats. For example, WindowSchedule(LogSpacedSpec(count=2, minimum=60s, maximum=120s, grain=60s), windows=(180s,)) constructed, hashed and round-tripped, and LookbackSchedule accepted maximum=28 beside periods=(99,).

Who is affected: only code that builds or edits schedule payloads by hand. Every schedule produced by log_spaced, metallic_recurrence, explicit, their _lookback and _horizons variants round-trips unchanged, so no schedule id moves. Explicit schedules have no bounds, grain or endpoint rules and are untouched.

The refusal message names the offending member and the bound or grain it violates; horizon schedules say "horizon" where window schedules say "window". Members are never regenerated, repaired or replayed.

Fixed

  • Unrepresentable magnitudes raise ConfigError, not OverflowError or ValueError. An integer too large for a float reached math.isfinite in the recurrence coefficient validator and math.isnan in the window-quality coverage validator; both now range-check before converting. A duration amount longer than the interpreter's integer-conversion limit is refused by Duration.parse with a message naming the limit. Refusal messages echo the value through the bounded-echo helper, so a pathological input cannot put thousands of digits into a message. Accepted coefficients, thresholds and durations are unchanged.
  • The phased harness checks the anchor's phase even when no emit tick lands inside the frame. The check took its residue from the first emit tick and returned early when there was none, so an off-phase anchor was accepted exactly when the emit step cleared the frame, and the caller got an empty result instead of a refusal. The phase now comes from the anchor and the cadence. An in-phase anchor with no tick in the frame still returns the empty grid.

Removed

  • The feature-identity window parser no longer wraps a ValueError that coerce_duration can no longer raise. Every input still refuses with ConfigError; no observable refusal changed.

3.1.1

Choose a tag to compare

@ff137 ff137 released this 14 Sep 09:13
e338c74

Indicator primitives refuse non-finite derived arithmetic with
DataValidationError. Cutler's RSI checks the combined movement before
division, so finite upward and downward totals whose sum overflows can no
longer produce a plausible zero. Relative range, log-volume ratio and
price-to-moving-average validate their derived readings, including quotient
overflow and underflow to zero before a log. Ordinary formulas, boundary
conventions, missing-input nulls, lookbacks and feature identities are
unchanged.

3.1.0

Choose a tag to compare

@ff137 ff137 released this 08 Sep 15:57
dc0aa6d

Added

  • temporal.add_calendar_columns, with second_of_day, second_of_week and day_of_week: a pure UTC calendar decomposition of an Int64 Unix-seconds column. second_of_day and second_of_week place a timestamp inside the UTC day and the UTC week (Monday 0 through Sunday 6); add_calendar_columns turns both into four cyclic columns, cal_mod_sin, cal_mod_cos, cal_dow_sin, cal_dow_cos, so the day and week wrap without a discontinuity. The clock is UTC by construction: there is no timezone parameter, and a Datetime column is refused rather than converted. The column must be exactly Int64, and existing columns of the same names are refused rather than overwritten.

Purely additive: no existing name, column or signature changes since 3.0.0. Specified by ADR 008 (calendar features and regime context).

3.0.0

Choose a tag to compare

@ff137 ff137 released this 08 Sep 11:21
1b825de

Read this first if you are on 2.x. Two calls that used to return a silently wrong result now refuse it with a ConfigError, which is why this is a major version. Nothing else changes shape: no column, name, payload key or signature is removed or renamed.

  1. phased_lookback and phased_lookback_reference refuse a frame whose measured cadence does not divide the window. Such a frame used to come back with the indicator null end to end and nothing raised. Pick a cadence that divides the window.
  2. metallic_recurrence and metallic_lookback refuse a seed at or above the lower bound that quantization moves below it. The seed used to be dropped by the bound it was meant to satisfy, so the schedule silently started from its second term. Seeding below the bound on purpose still works.

Added. returns.add_forward_excursions adds forward_mfe_{method}_{H} and forward_mae_{method}_{H}, the best and worst an interval reached after t and no later than t + H, on whichever scale ReturnMethod names, with one shared forward_excursion_{method}_{H}_available_at column. schedules.HorizonSchedule, with metallic_horizons, log_spaced_horizons and explicit_horizons, is a schedule of forward horizons with an identity no window schedule shares: same generators, same bounds, its own horizons payload key, so neither reader accepts the other's payload.

Fixed. Horizon schedule refusals name a horizon, not a window, on the generator path and when a recorded payload is read back. tests/test_public_namespace.py pins the environment of the subprocesses it inspects.

Full detail in CHANGELOG.md under 3.0.0.

2.0.0

Choose a tag to compare

@ff137 ff137 released this 06 Sep 13:48
f875895

The windowed-candle frame now has ten columns rather than nine. The new
one is traded_seconds (Int64): how many seconds inside a window
actually saw a trade, counted as volume > 0 over the source rows the
window covers.

If you are on 1.x, three things need your attention. Any code that
asserts the frame's shape breaks — a nine-column check, a positional
unpack, or a schema equality. apply_quality_policy now REQUIRES
traded_seconds and refuses a frame without it rather than silently
checking one threshold. And WindowQualityPolicy gains
min_traded_seconds, defaulting to 0, which preserves 1.x behaviour
exactly — raising it is opt-in.

Frames materialized under 1.x cannot be read as v2 frames.
Re-materialize them, or keep them and pin ohlc-toolkit>=1.0,<2.0.

This release also adds the input-indicator layer: a phased lookback
harness, a feature-identity record that derives a column's name from
the fields that vary, and four primitives — Cutler's RSI, relative
range, log volume ratio, and price-to-moving-average. Snapshot
verification moves into the toolkit, and two schedule bound defects are
corrected, both breaking.

The full changelog is in CHANGELOG.md under ## 2.0.0.

1.0.0

Choose a tag to compare

@ff137 ff137 released this 04 Sep 17:41
4fc904b

First release of the Polars-native temporal contract. Breaking rewrite of the 0.4 surface; see CHANGELOG.md.

1.0.0rc1

1.0.0rc1 Pre-release
Pre-release

Choose a tag to compare

@ff137 ff137 released this 04 Sep 15:01
35f3b07

Release candidate for the 1.0 contract.

0.4.0

Choose a tag to compare

@ff137 ff137 released this 08 Jun 18:40
cd609f9

ohlc-toolkit 0.4.0

BitstampDatasetDownloader is now renamed to DatasetDownloader

Improved support for parsing or formatting timeframes

Added mypy and fixed errors

What's Changed

Full Changelog: 0.3.3...0.4.0

0.3.3

Choose a tag to compare

@ff137 ff137 released this 08 Jun 12:50
b036b02

ohlc-toolkit 0.3.3

Method to calculate future percentage returns has been added.

  • The pandas_ta dependency has been removed in favour of replicating required methods directly within ohlc-toolkit.

What's Changed

  • 📄 Update license by @ff137 in #17
  • ✨ Add function to calculate percentage return by @ff137 in #18
  • 🔖 Release 0.3.3 by @ff137 in #21

Full Changelog: 0.3.2...0.3.3