Skip to content

fix(temporal)!: qualify shared calendar grids, feature windows and labels - #98

Merged
stefan-jansen merged 42 commits into
mainfrom
fix/issue76-timestampless-row-mode
Oct 18, 2026
Merged

stefan-jansen merged 42 commits into
mainfrom
fix/issue76-timestampless-row-mode

Conversation

@stefan-jansen

@stefan-jansen stefan-jansen commented Oct 17, 2026 •

Copy link
Copy Markdown
Contributor

Closes #76. Closes #94.

This is the maintainer-directed temporal-contract consumer batch. It normally integrates the existing published-Specs component PR102, daily-grid component PR104 and labeling component PR95 with row-only and finite temporal feature windows. Reviewed head: c69845d, based on prior main3507071; merged asb0d2027.

Merged as b0d2027 on2026-10-18T02:23:53Z after all40applicable checks passed and one configured315skip. Exact reviewedc698/tested syntheticd7c6/actual mergedb0dtrees match6ecdca0. Issues76/94closed. Components95/102/104closed as consolidated after verifying their original ancestry and preserving recoverable history. Landed branches retired safely. Source-only maintainer-batching policy98fe25b is included, not a separate policy-only PR. No release or deployment.

Latest correction: shared session-label identifiers no longer fabricate physical elapsed duration. Actual installed6cf produces4days from July3/7 identifiers; a declared naive New York clock also targets the wrong exit across spring DST (01:00 +2physical hours exited03:00 instead of04:00). The exact installed base fails29cases with72positive controls. The repair reuses the existing numerical kernel on UTC instants and restores input clock representation. Shared identifiers leave duration unset; standalone legacy Date differences remain unchanged.

Current qualification

  • Runtime fix47917fd:628focused labeling/contract cases and full4,695normal-JIT tests pass236.57s,57configured exclusions/17warnings. Canonical NUMBA_DISABLE_JIT=1 full4,695tests pass209.39s; all project/higher-critical thresholds pass95.91%line/89.99%branch. During that canonical run, only the later calendar docstring/task-guide correction occurred; no producer/test/dependency behavior changed. These are unchanged-runtime results, not a frozen-final-tree assertion.
  • Finalc69845d corrects stale helper guidance after merged CryptoCalendar daily sessions. Actual90calendar cases pass. All-file hooks/Ruff/format/ty and strict docs2.88s pass.
  • Exact final normally installed wheel:368public API/grid/window/annualization/label/config/crypto tests pass each Python3.12/3.13/3.14. All200Engineer and nine publishedSpecs package files match immutable artifacts at actual isolated site-packages origins; all30packages are dependency-consistent. Executable installed docs pass.
  • Local final wheel SHA256ee1365e036de309f2cc05dae0dd85475187b925aeeab7fdf164759f7e17f5a44; sdist0fdb6c94a1d852605d999b3fa8f76f2fe64a44f6093e0114df000349e4545a09. Independently bound hosted syntheticd7c6candidate wheel129424bf430f4328d2cb9d9144f7c85f744a9ea30e4f79da6647ee114d7c7409and sdist0a37f96e7312166b3e07ef5cec79e30f9be65147092ffeb15bdb09727a70130a match across full/native artifact builds. All40applicable final-revision hosted source/wheel/native/coverage/type/security/docs/package checks passed before the guarded merge.

The latest incremental merge includes PR95's timestamp-free legacy export repair at 2259bae. Its actual public installed-package workflow fails to save an Object-valued unknown duration before the fix; twelve new source cases fail before repair and 427 labeling cases pass afterward. The combined head passes 135 focused cases and the full qualification below.

Scope and behavior

  • Explicit calendar=None accepts timestamp-free OHLCV rows in input observation order without loading a calendar provider or requiring assume_sorted=True.
  • Named-calendar execution validates the declared daily/intraday grid before interpreting supplied returns. Calendar selection remains explicit argument, declared feed metadata, then NYSE.
  • Daily session-label identifiers preserve their displayed dates and validate actual schedules per asset, including holidays, overnight venues, missing sessions, duplicate/off-schedule labels and empty/singleton inputs. No missing prices are filled and no rows are inserted or dropped.
  • A session period N includes the current session's causal original bars and the preceding N-1 scheduled sessions. Holidays, lunch breaks and shortened sessions with no retained bars do not become observed-date counts. No resampling or future session close enters an earlier feature.
  • Elapsed periods use positive duration strings/timedeltas over the physical UTC interval (timestamp - duration, timestamp], including through DST. Warmup requires observed coverage and the numerical statistic's sample count.
  • The existing finite kernels and their parameters, annualization, output aliases and panel isolation are retained. Recursive EMA/RSI and unqualified multi-window definitions reject temporal units explicitly.
  • Lazy execution prevents filter/projection/slice pushdown from discarding warmup history. No new Specs wire fields or second calendar keyword are introduced.
  • Calendar-aware labels preserve explicit argument, config, feed and NYSE selection, including omitted versus null JSON/YAML/copy behavior. Explicit None labels observation rows without timestamps or provider loading.
  • Session labels use the existing barrier engine and expire at the final available bar of the Nth following scheduled session. A valid barless shortened session still counts; the deadline never extends into a later session merely to obtain a positive holding offset. Daily observation/expected-bar labels can span session rows; elapsed labels reject session identifiers.
  • Shared session identifiers retain label_time but leave physical label_duration unset. Instant duration arithmetic and elapsed exits honor declared timezones across DST, preserving timestamp representations, precision, sparse events and panel isolation.
  • Empty filtered tables and timestamp-free legacy labels retain portable Parquet schemas. Standalone legacy numerical definitions and explicit custom/auto-gap compatibility remain distinct from shared completeness validation.

Dependencies and compatibility

The three component heads are normal ancestors of the reviewed batch, preserving their source and regression history. They are closed as consolidated after the verified batch merge, not merged separately. Runtime metadata honestly requires published ml4t-specs>=0.2.0,<0.3.0. Independent CI101 is merged; final Python3.15support remains separately owned by PR93, refreshed only after this batch landed. This is next-minor0.2development, not the historical0.1.7patch or a release request.

Completed runtime and artifact qualification at 85764b5

  • Full normal-JIT suite: 4,608 passed, 57 deselected, 17 warnings.
  • Canonical NUMBA_DISABLE_JIT=1 coverage suite: 4,608 passed; all project and release-critical thresholds pass, with 95.89% line and 89.95% branch coverage.
  • Normally installed exact wheel: 262 public API/grid/feature/label/annualization/Parquet cases and six config cases pass on each of Python 3.12, 3.13 and 3.14, including all 28 empty/export regressions. Actual timeout enforcement and strict markers are enabled; all three dependency environments are consistent. The earlier c8d603c qualification used a different 250-case selection and retains its tested revision.
  • Every 200 Engineer and nine published Specs package files match their immutable wheels at actual site-packages origins. Published Specs 0.2.0 is installed, not a source checkout or substituted dependency.
  • Ruff, formatting, ty, all hooks, wheel/sdist builds, Twine, executable documentation and strict MkDocs pass. The installed-wheel documentation workflows also pass.
  • Wheel SHA256: 5089be5e6c6ad40a2903a63519f5f135df746e35ac5447ad881ae2c0d91ca1df.
  • Sdist SHA256: 09d46968df95e358c7a2f613bf7c012fb177360c5bb2ef17bc4ead50da0dbb2c.

Regression evidence

Actual public price-to-return-to-feature workflows fail before implementation. Real producer mutations that count rows/observed dates as sessions, strip timezones, misinterpret declared naive timestamps, or allow lazy predicate pushdown each fail the numerical consumers they should prevent. Correct producers were restored before clean checks and commits. Independent annualization regressions are now maintained in public CI.

All applicable current-head hosted checks completed before the ordinary exact-head merge. Final Python3.15support remains separately gated in93. No all-feature temporal support, release or deployment is claimed.

AI assistance: Codex reviewed the existing source and discussion, reproduced the public workflows, implemented and reviewed source/tests/docs, and executed the listed checks. No independent human review is claimed.

Copilot AI balanced review requested due to automatic review settings October 17, 2026 14:44

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@stefan-jansen stefan-jansen changed the title fix(api): accept timestamp-free observation rows in row mode feat(api): honor row mode and causal session/elapsed feature windows Oct 17, 2026
@stefan-jansen stefan-jansen changed the title feat(api): honor row mode and causal session/elapsed feature windows fix(temporal)!: qualify shared calendar grids, feature windows and labels Oct 18, 2026
@stefan-jansen
stefan-jansen merged commit b0d2027 into main Oct 18, 2026
41 checks passed
@stefan-jansen
stefan-jansen deleted the fix/issue76-timestampless-row-mode branch October 18, 2026 02:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix: adopt shared calendar contract in session-aware labeling Rolling features count rows as time across missing bars

2 participants