Canonical docs
In the research projects
The Python project fits a StandardScaler/Ridge pipeline and reuses those evaluated objects. The Compiled project fits its declared LogRegScaler on training features and reconstructs it with the selected round. The scaler reference distinguishes these fitted paths from stateless transforms.
What this package owns
Owns fitted scaler classes, the scaler registry, and the rule-based logic that decides how columns should be transformed. Does not own raw feature creation or the experiment loop itself.
Key entry points
| Entry point | Use case | Notes |
|---|---|---|
LinearScaler |
Rule-based scaling over mixed market-data columns | Exported at the package root |
LogRegScaler |
Standard scaler used by logistic-regression SFDs | Exported at the package root |
RobustScaler |
Median and IQR scaling for outlier-heavy data | Exported at the package root |
CausalRollingRobustScaler |
Robust scaling that adapts to drift, with no look-ahead | Exported at the package root |
RankGaussScaler |
Rank-based Gaussianization | Exported at the package root |
SCALER_REGISTRY |
Resolve scalers by manifest parameter name | Used by set_scaler_from_params() |
build_rules, inverse_transform |
Customize or interpret LinearScaler behavior |
Available from the module-level implementations |
Adjacent modules
limen.experiment.Manifestis the main consumer of this package.limen.transformshandles stateless transforms, which is a different stage from fitted scaling.limen.featuresandlimen.indicatorsproduce the columns that scalers later operate on.
Quick orientation
| Module or family | Responsibility |
|---|---|
linear_scaler.py |
LinearScaler, rule helpers, inverse transform |
logreg_scaler.py |
Logistic-regression tuned scaling |
robust_scaler.py |
Median and IQR scaling |
causal_rolling_robust_scaler.py |
Causal trailing-window median and IQR scaling |
rank_gauss_scaler.py |
Rank-based Gaussianization |
registry.py |
SCALER_REGISTRY |
scalers/├── README.md├── __init__.py├── causal_rolling_robust_scaler.py├── linear_scaler.py├── logreg_scaler.py├── rank_gauss_scaler.py├── registry.py└── robust_scaler.pyMerged source PR · 0102f669Package layout · Limen 6.0.1 · current package validation · package source
Things to know
- Scalers are fit on the training split and then reused on validation and test splits. That fit/apply discipline is part of why this package stays separate from
limen.transforms. LinearScaleruses ordered regex rules. The first matching rule wins.build_rulesplaces overrides before base rules, including existing-key replacements. Each override entry becomes an unescaped^entry$regex; remaining base rules keep their order.- Unrecognized columns fall through to the catch-all
nonerule and stay unchanged. - Columns assigned
standardorlog_standardscaling must have a finite, nonzero training standard deviation.LinearScalerandLogRegScalerdo not guard zero variance; division by zero produces non-finite output.