Research: investigate hierarchical TruncatedNormal sampling geometry - #1288
Draft
AlexanderFengler wants to merge 9 commits into
Draft
Conversation
Contributor
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: trueThanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
AlexanderFengler
changed the base branch from
codex/1269-bound-aware-group-priors
to
codex/1269-truncated-normal-experimental-base
September 1, 2026 00:47
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose and status
This is the research-only sink PR for the hierarchical
TruncatedNormalnumerical investigation. It is not a production feature PR and must not be
merged into
main.codex/1269-truncated-normal-experimental-baseat exact candidate commit9e7002f00e7ff40524a8afc9e83b62723461c98fcodex/1282-qualify-truncated-hierarchyat47274ca0and evidence remain intact independently of Fix safe priors for unmatched group-only effects #1272.
The only permitted intersection with the production prior-robustification
stream is a later, small policy/default bridge PR justified by the completed
numerical evidence.
Completed research machinery
and 748 planned cells with exact prior, truth, data, seed, initialization,
precision, artifact, and decision contracts;
deterministic datasets, exact transformed starts, process/cache isolation,
immutable data/start/chain evidence, and atomic final markers;
precision and artifact hashes, and recompute all gradient, convergence,
efficiency, recovery, backend, and SBC gates in the assessor;
gating, always-run aggregation, and uploaded raw evidence.
Canonical result
Canonical run
33410419447
on exact commit
8fdd272breturnedscreening-fail. Qualification andstress were correctly skipped.
no missing evidence.
two-sided, current Bambi lower-only, and HSSM softmax beta.
R-hat up to 2.97, bulk ESS 2.33, BFMI 0.029, and every retained draw at 1,023
leapfrog steps.
The LBA reporting exception is fixed in
dbb2858e; the failed chain remainsimmutable evidence and its scientific interpretation is unchanged.
Current conclusion
The proposed automatic centered native-
TruncatedNormaldefault is notqualified. Direct PyMC failures show that the observed problem sits below
HSSM and Bambi, but they do not by themselves demonstrate a PyMC software bug.
The leading explanation is difficult centered hierarchical funnel geometry,
amplified near bounds by the truncation normalization and, in some HSSM cases,
by prior calibration, initialization, and likelihood geometry.
Passing local density/gradient contracts argue against recurrence of the
historical local wrong-gradient defect for the nine completed cells. The
canonical LBA gradient contract did not complete, so LBA still requires an
explicit likelihood audit.
Next decision-grade work
Focused child PRs should extend this research sink prospectively:
and Hessian with an independent closed-form oracle over boundary-distance
and hierarchy-scale grids.
independently coded centered TN, exact inverse-CDF non-centering of group
coefficients, and exact inverse-CDF non-centering of both hyper-location and
group coefficients.
interior truth, weak versus informative data, current versus calibrated
anchors, diagnostic start variants, repeated fixed seeds, and PyMC versus
NumPyro.
DDM, and LBA; for LBA, separately audit likelihood values and gradients and
compare the identical hierarchy under Gaussian and LBA likelihoods.
Decision rules remain prospective:
are the primary cause;
bug reproducer;
unsuitable as an automatic HSSM default;
and requalify without weakening thresholds or rerolling failed seeds.
Frozen v2 contract
05d8be96204f124abe723fb38f65080631d2cdcb7c9b776428201ee66045e15eValidation
actionlint1.7.12 passeduv lock --check --offlinegit diff --checkpassedTracks #1282.