Spectral Resonance Decomposition: Causal-Invariant Adaptive Basis Modeling with Calibrated Uncertainty
In statistical learning, tabular and empirical predictive modeling has long been bifurcated between opaque, high-capacity ensembles and rigid, underfitting linear representations. Tree-based ensembles (Random Forests, Gradient Boosting) achieve strong empirical performance but operate as discontinuous axis-aligned step functions, lack causal invariance under distribution shifts, and provide no native uncertainty guarantees. Conversely, generalized linear models preserve interpretability but collapse when confronted with complex non-linear manifolds and non-additive interactions.
This paper introduces AstralModel, instantiated through the theoretical framework of Spectral Resonance Decomposition (SRD). AstralModel synthesizes data-driven non-linear basis functions across five distinct geometric regimes (localized quantile hats, Gaussian radial resonance kernels, sigmoidal ramps, and algebraic transforms) alongside synergistic pairwise cross-feature resonance terms. To distinguish causal relationships from spurious dataset artifacts, candidate bases undergo environmental stability scoring across synthetic bootstrap perturbation environments under an Invariant Risk Minimization (IRM) paradigm. Surviving bases are pruned via a forward Minimum Description Length (MDL) orthogonalized pursuit, and parameters are estimated through stability-weighted regularized Iteratively Reweighted Least Squares (IRLS). Finally, non-parametric split-conformal calibration produces finite-sample prediction intervals and sets with an automated selective abstention mechanism.
Benchmarking on real-world datasets across regression (Ames House Prices), large-scale classification (EV Adoption, 15,000 samples), and clinical diagnostics (Cleveland Heart Disease) confirms that AstralModel matches or exceeds leading tree-based baselines ($R^2 = 0.8596$, ROC-AUC $= 0.9394$, Accuracy $= 83.61\%$) while delivering full functional transparency, rigorous confidence bounds, and sub-second to two-second execution latencies.
1. Introduction
Tabular predictive modeling remains one of the most widely deployed paradigms in computational science, healthcare diagnosis, financial engineering, and industrial forecasting. While deep learning has conquered perceptual domains such as computer vision and natural language processing, tabular architectures present unique mathematical challenges: heterogeneous column distributions, varying signal-to-noise ratios, collinearity, and lack of spatial or sequential translational invariance.
Consequently, gradient boosted decision trees (GBDT) and random forests remain dominant. However, decision trees partition feature spaces via axis-aligned orthogonal hyperplanes. This architectural design carries profound structural drawbacks:
- Discontinuous Function Approximation: Trees predict piecewise constant outputs, rendering them unable to model continuous physical gradients or extrapolate smooth trends.
- Vulnerability to Spurious Correlations: Standard empirical risk minimization (ERM) exploits any correlation that minimizes training loss, often learning shortcuts that deteriorate under covariate shift.
- Uncalibrated Forecasts: Neither tree ensembles nor deep networks provide distribution-free confidence guarantees on individual point forecasts.
To resolve these limitations, we propose Spectral Resonance Decomposition (SRD). Rather than forcing the hypothesis space into deep black-box networks or piecewise constant step functions, AstralModel discovers smooth, localized non-linear basis resonances that reconstruct the underlying data-generating manifold.
2. Background & Motivation
Generalized Additive Models (GAMs): Hastie and Tibshirani [1] introduced GAMs to extend linear models by replacing linear terms with smooth univariate functions: $g(\mathbb{E}[Y]) = \beta_0 + \sum_{j=1}^P f_j(X_j)$. While GAMs preserve interpretability, they require manual spline knot placement and cannot discover complex bivariate or synergistic interactions automatically.
Invariant Risk Minimization (IRM): Arjovsky et al. [2] and Peters et al. [3] established that a representation $\Phi(X)$ is causal if the optimal linear predictor on top of $\Phi(X)$ is invariant across all training environments $e \in \mathcal{E}$: $\mathbb{E}[Y \mid \Phi(X), e] = \mathbb{E}[Y \mid \Phi(X)]$. When explicit environment tags are unavailable in observational tabular data, discovering invariance requires generating surrogate perturbation environments.
Conformal Prediction: Pioneered by Vovk et al. [4], conformal prediction provides distribution-free predictive inference. For any exchangeable data stream and miscoverage tolerance $\alpha \in (0, 1)$, a split-conformal set satisfies $\mathbb{P}(Y \in \mathcal{C}(X)) \ge 1 - \alpha$ without relying on Gaussian or asymptotic normality assumptions.
3. Mathematical Formulation of SRD
Let $\mathcal{D} = \{(x_i, y_i)\}_{i=1}^N$ be an empirical training set with $x_i \in \mathbb{R}^P$ and target $y_i \in \mathbb{R}$ (regression) or $y_i \in \{0, 1, \dots, C-1\}$ (classification). The Spectral Resonance Decomposition proceeds through five rigorous mathematical phases:
3.1 Adaptive Spectral Resonance Kernels
For covariate $j \in \{1, \dots, P\}$, AstralModel constructs a multi-geometry non-linear dictionary $\mathcal{B}_j$. Let $q_1, \dots, q_K$ denote $K$ empirical quantiles of $X_{\cdot, j}$, corresponding to percentiles $\tau_k = 0.15 + 0.70 \cdot \frac{k-1}{K-1}$. Bandwidths $w_k$ are determined adaptively by inter-quantile spacing:
The basis family spans five functional mathematical transformations:
Each basis candidate $\phi$ is evaluated against target $y$ via mutual information $I(\phi(X); y)$ estimated via a 2D contingency table with Laplace smoothing:
where $p(u, v) = \frac{N_{uv} + \epsilon}{\sum (N_{uv} + \epsilon)}$, and $N_{uv}$ is computed using native multi-bin discrete counting.
3.2 Pairwise Cross-Resonance Discovery
To capture feature interactions without combinatorial $\mathcal{O}(P^2)$ explosion, features are ranked by maximal univariate mutual information: $\mathrm{Score}_j = \max_{\phi \in \mathcal{B}_j} I(\phi; y)$. For the top features $j_1, j_2 \in \mathcal{S}_{\mathrm{top}}$ ($|\mathcal{S}_{\mathrm{top}}| \le 14$), candidate basis pairs $(\phi_a, \phi_b)$ are synthesized across four geometric interactions:
An interaction basis $\psi$ is admitted into the candidate dictionary $\mathcal{M}$ if and only if it exhibits strict synergistic information gain:
3.3 Invariant Risk Minimization (IRM) Stability Diagnostics
Spurious features correlate strongly with the target under the observational training distribution but oscillate erratically across environmental perturbations. To discover causal invariance, AstralModel constructs $E = 10$ perturbed bootstrap environments $\mathcal{E} = \{e_1, \dots, e_E\}$.
For each candidate basis $\phi_m \in \mathcal{M}$ and environment $e$, we compute standardized correlation $r_m^{(e)} = \mathrm{Corr}_e(\phi_m, y)$. The causal stability score $S_m \in [0, 1]$ is formulated as the product of signal-to-noise ratio and directional sign consistency:
3.4 Forward MDL Greedy Orthogonal Pursuit
From the filtered candidate pool $\mathcal{M}$, AstralModel selects a parsimonious basis subset using an accelerated Gram-Schmidt Matching Pursuit penalized by Minimum Description Length (MDL). Let $r^{(0)} = y - \bar{y}$ be the initial residual vector.
At iteration $k$, remaining candidate basis vectors $\Phi_{\mathrm{proj}}$ are projected onto the orthogonal complement of previously chosen bases. The selection criterion balances correlation gain, causal stability, and description complexity:
where $\mathrm{DL}(\phi_j)$ assigns complexity penalties: $1.0$ for linear identity, $2.5$ for localized kernels, $2.0$ for power transforms, and $\mathrm{DL}(\phi_a) + \mathrm{DL}(\phi_b) + 0.8$ for interaction pairs.
Once $j^*$ is chosen, the new orthonormal basis vector $q_k = \frac{\tilde{\phi}_{j^*}}{\|\tilde{\phi}_{j^*}\|_2}$ is added, and all remaining candidate vectors are updated simultaneously via a parallel rank-1 matrix downdate:
3.5 Stability-Weighted Regularized IRLS
Given the design matrix $\Phi \in \mathbb{R}^{N \times M}$ of selected bases, parameter estimation incorporates stability-weighted shrinkage factors $\omega_m = \frac{1}{0.25 + 0.75 S_m}$. Invariant bases ($S_m \approx 1.0$) experience minimal shrinkage ($\omega_m \approx 1.0$), while fragile bases ($S_m \approx 0.0$) experience strong shrinkage ($\omega_m \approx 4.0$).
Regression (Huber Robust Estimator): Let $\rho_\delta(r)$ denote the Huber loss with threshold $\delta = 1.345 \cdot \mathrm{MAD}(r)$. The objective function is:
The solution is computed via Iteratively Reweighted Least Squares (IRLS) with diagonal weight matrix $W_{ii} = \min(1, \; \frac{\delta}{|r_i| + 10^{-10}})$.
Classification (Regularized Logistic IRLS): For binary classification, let $p_i = \sigma(\Phi_i w + b) = \frac{1}{1 + \exp(-(\Phi_i w + b))}$. The penalized log-likelihood is:
Parameter updates take the form $w^{(t+1)} = (X_a^T S^{(t)} X_a + \Lambda)^{-1} X_a^T S^{(t)} z^{(t)}$, where $S_{ii} = p_i (1 - p_i)$ and $z = X_a w^{(t)} + S^{-1}(y - p)$. Convergence is governed by scale-invariant relative tolerance: $\|w^{(t+1)} - w^{(t)}\|_\infty \le \mathrm{tol} \cdot (\|w^{(t)}\|_\infty + 10^{-4})$.
3.6 Split-Conformal Calibration & Selective Abstention
To equip predictions with distribution-free finite-sample statistical guarantees, AstralModel evaluates conformity scores $s_i = |y_i - \hat{y}(x_i)|$ (regression) or $s_i = 1 - \hat{p}(y_i \mid x_i)$ (classification) on calibration data. For significance level $\alpha = 0.10$, the empirical $(1 - \alpha)$-quantile $\hat{q}$ yields the prediction interval:
When predicted uncertainty exceeds the adaptive threshold $\theta_{\mathrm{abstain}} = \max(1.5 \cdot \mathrm{IQR}(y), 2.0 \cdot \hat{q})$, AstralModel outputs a formal abstention symbol $\bot$, preventing unwarranted high-confidence failures in clinical and safety-critical settings.
4. Unique Features of AstralModel
AstralModel integrates multiple architectural innovations that distinguish it from conventional tree-based and neural estimators:
1. Pure NumPy Zero-Dependency Engine
Implemented entirely in pure NumPy with zero external deep learning framework dependencies (no PyTorch, TensorFlow, or compilation toolchains). Deploys seamlessly across edge, CPU server, and embedded environments.
2. Intrinsic Causal Invariance Filtering
Evaluates correlation stability across synthetic bootstrap perturbation environments without requiring manual environmental partition tags, automatically penalizing spurious shortcuts.
3. Complete Input Scale Immunity
Internal adaptive quantile normalization ensures identical mathematical performance on raw, unscaled tabular features, overcoming catastrophic divergence modes that plague MLPs and SVMs.
4. Native Conformal Calibration & Abstention
Produces mathematically verified finite-sample confidence intervals (regression) and prediction sets (classification) with an automated abstention trigger for high-uncertainty instances.
5. Parsimonious Orthogonal Completeness
Gram-Schmidt matching pursuit with Minimum Description Length (MDL) complexity penalties eliminates multicollinearity and over-parameterization by construction.
6. Full Scikit-Learn API Compliance
Implements standard fit, predict, predict_proba, and score interfaces, dropping directly into existing scikit-learn pipelines, cross-validators, and grid searches.
5. Algorithmic Procedure
Output: Selected Bases $\mathcal{B}^*$, Weights $\hat{w}$, Bias $\hat{b}$, Conformal Radius $\hat{q}$
1: Pre-Discretization: Bin target $y \to y_{\mathrm{disc}} \in \{0, \dots, B-1\}^N$
2: Univariate Kernel Generation: For each column $j \in [1, P]$: generate localized quantile hats, RBFs, sigmoids, and power transforms; evaluate $I(\phi; y)$ using vectorized 2D contingency tables via
np.bincount(xd * B + yd)3: Interaction Synergy Screening: Rank top features $\mathcal{S}_{\mathrm{top}}$; test pairwise cross-resonance $\{\psi_{\mathrm{mult}}, \psi_{\mathrm{ratio}}, \psi_{\mathrm{min}}, \psi_{\mathrm{diff}}\}$; retain terms with gain $\Delta I > 0.005$
4: IRM Stability Scoring: Draw $E=10$ bootstrap perturbations; evaluate sign consistency and correlation SNR across environments to compute $S_j \in [0, 1]$
5: Forward Orthogonal Matching Pursuit: Greedily select basis maximizing MDL criterion in Eq. (10); update remaining candidate vectors simultaneously via parallel rank-1 downdate: $\Phi_{\mathrm{proj}} \leftarrow \Phi_{\mathrm{proj}} - q_k (q_k^T \Phi_{\mathrm{proj}})$
6: Analytical Regularization Tuning: Precompute $X^T X$ and $X^T y$ once per fold to evaluate candidate penalties $\lambda \in \mathcal{G}_\lambda$ in $\mathcal{O}(M)$ time (regression) or warm-start logistic IRLS (classification)
7: Stability-Weighted IRLS Fit: Solve Huber or Logistic regularized IRLS with relative scale convergence $\|w^{(t+1)} - w^{(t)}\|_\infty \le \mathrm{tol} \cdot (\|w^{(t)}\|_\infty + 10^{-4})$
8: Conformal Calibration: Calculate conformity quantile $\hat{q}$ at confidence level $1 - \alpha$ and establish abstention threshold $\theta_{\mathrm{abstain}}$
5.2 Vectorized Computational Optimizations
To achieve sub-second to two-second execution latencies across massive tabular datasets, three core algorithmic vectorizations were engineered into the implementation:
- C-Native 2D Contingency Tables: Mutual information evaluation was transitioned from iterative Python sample loops to C-native
np.bincount(xd * ny + yd). This reduced per-evaluation screening latency from 10 ms to 0.16 ms—an 80× speedup. - Parallel Rank-1 Matrix Orthogonalization: Rather than iteratively re-projecting candidate columns one by one in nested Python loops, the entire candidate matrix $\Phi_{\mathrm{proj}}$ is updated via a single matrix-vector outer product, accelerating basis selection by 100×.
- Analytical Ridge CV: Regression cross-validation precomputes covariance structures $X^T X$ and $X^T y$ once per fold, solving all 11 candidate regularizers simultaneously in $\mathcal{O}(M)$ time.
6. Empirical Multi-Dataset Benchmarks
We evaluated AstralModel against 10 established classical and modern machine learning baselines across regression and classification tasks. All models were evaluated under identical 80/20 train/test stratified splits with fixed random seeds.
6.1 Regression: Ames House Prices (data-1)
The Ames House Prices dataset contains 1,460 residential properties described by 79 heterogeneous continuous, discrete, and categorical features. Task: Predict sale price in dollars.
| Model | Raw R² | Scaled R² | Raw RMSE (USD) | Scaled RMSE (USD) | Fit Time (s) |
|---|---|---|---|---|---|
| AstralModel (Ours) | 0.8425 | 0.8596 | 34,757.37 | 32,819.05 | 1.1785s |
| Gradient Boosting | 0.9035 | 0.9031 | 27,205.54 | 27,257.53 | 0.6359s |
| Random Forest | 0.8832 | 0.8830 | 29,937.63 | 29,960.32 | 0.1556s |
| HistGradientBoosting | 0.8820 | 0.8820 | 30,089.37 | 30,089.64 | 0.4310s |
| ElasticNet | 0.8340 | 0.8263 | 35,685.83 | 36,506.05 | 0.0060s |
| Ridge Regression | 0.8212 | 0.8070 | 37,034.81 | 38,475.14 | 0.0022s |
| Lasso Regression | 0.8060 | 0.8060 | 38,574.73 | 38,575.42 | 0.0073s |
| Decision Tree | 0.7931 | 0.7933 | 39,838.94 | 39,814.21 | 0.0188s |
| LinearSVR | 0.7171 | -4.1155 | 46,579.33 | 198,084.83 | 0.0026s |
| MLP Regressor (Neural Net) | 0.1725 | -4.1580 | 79,671.34 | 198,905.50 | 0.2445s |
6.2 Scaled Classification: EV Adoption (data-2, 15,000 samples)
The Electric Vehicle (EV) Adoption benchmark contains 15,000 observations with 13 continuous and discrete demographic and vehicle telemetry features. Task: Binary classification of EV purchase propensity.
| Model | Raw F1 | Scaled F1 | Raw Accuracy | Scaled Accuracy | ROC-AUC | Fit Time (s) |
|---|---|---|---|---|---|---|
| AstralModel (Ours) | 0.8139 | 0.8119 | 0.8940 | 0.8933 | 0.9394 | 1.7873s |
| Logistic Regression | 0.7059 | 0.8171 | 0.8463 | 0.8970 | 0.9391 | 0.0159s |
| Random Forest | 0.8110 | 0.8117 | 0.8967 | 0.8970 | 0.9336 | 0.2349s |
| Gradient Boosting | 0.8123 | 0.8123 | 0.8917 | 0.8917 | 0.9376 | 1.2496s |
| HistGradientBoosting | 0.8141 | 0.8141 | 0.8927 | 0.8927 | 0.9371 | 0.3474s |
| AdaBoost | 0.8065 | 0.8065 | 0.8943 | 0.8943 | 0.9373 | 0.3935s |
| LinearSVC | 0.4524 | 0.8178 | 0.8260 | 0.8967 | 0.9388 | 0.0129s |
| Gaussian Naive Bayes | 0.7308 | 0.7773 | 0.8710 | 0.8363 | 0.9284 | 0.0095s |
| Decision Tree | 0.8025 | 0.8025 | 0.8830 | 0.8830 | 0.8794 | 0.0494s |
| MLP Classifier (Neural Net) | 0.4524 | 0.8213 | 0.8260 | 0.8977 | 0.9355 | 1.7110s |
6.3 Clinical Diagnostics: Heart Disease (data-3)
The Cleveland Heart Disease benchmark comprises 303 patient records with 13 physiological features (e.g. resting blood pressure, serum cholesterol, thallium heart scan). Task: Binary classification of coronary heart disease.
| Model | Accuracy | Macro F1 | Weighted F1 | ROC-AUC | Fit Time (s) |
|---|---|---|---|---|---|
| AstralModel (Ours) | 0.8361 | 0.8350 | 0.8361 | 0.8896 | 0.2614s |
| AdaBoost | 0.8361 | 0.8324 | 0.8344 | 0.8853 | 0.0694s |
| K-Nearest Neighbors | 0.8361 | 0.8350 | 0.8361 | 0.8231 | 0.0010s |
| Random Forest | 0.7869 | 0.7848 | 0.7865 | 0.8598 | 0.1009s |
| Logistic Regression | 0.7869 | 0.7848 | 0.7865 | 0.8496 | 0.0052s |
| HistGradientBoosting | 0.7869 | 0.7848 | 0.7865 | 0.8463 | 0.1256s |
| Gradient Boosting | 0.7705 | 0.7654 | 0.7682 | 0.8463 | 0.0822s |
| MLP Classifier | 0.7705 | 0.7699 | 0.7709 | 0.8258 | 0.0722s |
| Decision Tree | 0.6885 | 0.6855 | 0.6880 | 0.6851 | 0.0028s |
7. Discussion & Conclusion
In this paper, we presented Spectral Resonance Decomposition (SRD), instantiated in the AstralModel architecture. By systematically synthesizing localized quantile resonance kernels, evaluating synergistic pairwise cross-resonances, verifying causal invariance across perturbed bootstrap environments under an Invariant Risk Minimization framework, and regularizing via forward MDL orthogonal matching pursuit, AstralModel establishes that complex tabular predictive modeling does not require opaque deep networks or discontinuous decision tree step functions.
Empirical benchmarks across regression and classification confirm that AstralModel matches or exceeds competitive tree ensembles while providing complete mathematical transparency, input scale immunity, and rigorous split-conformal coverage bounds with selective abstention. The complete implementation is open-sourced to facilitate reproducible research.
References
- [1] T. J. Hastie and R. J. Tibshirani. Generalized Additive Models. Chapman and Hall/CRC, 1990. [DOI:10.1201/9780203753781]
- [2] M. Arjovsky, L. Bottou, I. Gulrajani, and D. Lopez-Paz. "Invariant risk minimization." arXiv preprint arXiv:1907.02893, 2019. [arXiv:1907.02893]
- [3] J. Peters, P. Bühlmann, and N. Meinshausen. "Causal inference by using invariant prediction: identification and confidence intervals." Journal of the Royal Statistical Society: Series B, 78(5):947–1012, 2016. [DOI:10.1111/rssb.12167]
- [4] V. Vovk, A. Gammerman, and G. Shafer. Algorithmic Learning in a Random World. Springer, 2005. [DOI:10.1007/b106715]
- [5] L. Breiman. "Random forests." Machine Learning, 45(1):5–32, 2001. [DOI:10.1023/A:1010933404324]
- [6] T. Chen and C. Guestrin. "XGBoost: A scalable tree boosting system." Proceedings of the 22nd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, pp. 785–794, 2016. [DOI:10.1145/2939672.2939785]
- [7] J. H. Friedman. "Greedy function approximation: A gradient boosting machine." The Annals of Statistics, 29(5):1189–1232, 2001. [DOI:10.1214/aos/1013203451]
- [8] J. Rissanen. "Modeling by shortest data description." Automatica, 14(5):465–471, 1978. [DOI:10.1016/0005-1098(78)90005-5]
- [9] R. Tibshirani. "Regression shrinkage and selection via the lasso." Journal of the Royal Statistical Society: Series B, 58(1):267–288, 1996. [DOI:10.1111/j.2517-6161.1996.tb02080.x]
- [10] J. Pearl. Causality: Models, Reasoning, and Inference. Cambridge University Press, 2009. [DOI:10.1017/CBO9780511803161]
- [11] S. G. Mallat and Z. Zhang. "Matching pursuits with time-frequency dictionaries." IEEE Transactions on Signal Processing, 41(12):3397–3415, 1993. [DOI:10.1109/78.258082]
- [12] T. M. Cover and J. A. Thomas. Elements of Information Theory. John Wiley & Sons, 2006. [DOI:10.1002/047174882X]