A regime-switching / Mixture-of-Experts extension of LightGBM.
LightGBM-MoE is a fork of Microsoft LightGBM that implements Mixture-of-Experts (MoE) / Regime-Switching GBDT natively in C++:
ŷ(x) = Σₖ gₖ(x) · fₖ(x)
fₖ(x): Expert k's prediction (K regression GBDTs)gₖ(x): Gate's routing probability for expert k (softmax)K: Number of experts (hyperparameter)
- Python: 3.10+
- OS: Linux (x86_64, aarch64), macOS (Intel, Apple Silicon)
- Build: CMake 3.16+ and a C++ compiler (GCC, Clang, or Apple Clang) when installing from source
# From GitHub (builds from source)
pip install git+https://github.com/kyo219/LightGBM-MoE.git
# Editable install for development
git clone https://github.com/kyo219/LightGBM-MoE.git
cd LightGBM-MoE/python-package
pip install -e .import lightgbm_moe as lgb
params = {
'boosting': 'mixture', # Enable MoE mode
'mixture_num_experts': 3, # Number of experts (search 2-6 for your data)
'mixture_gate_type': 'gbdt', # Most common winner (14/30); search 'leaf_reuse'/'none' too
'mixture_routing_mode': 'token_choice', # Most common winner (19/30); search 'expert_choice' too
'objective': 'regression',
'metric': 'rmse',
'verbose': -1,
}
train_data = lgb.Dataset(X_train, label=y_train)
valid_data = lgb.Dataset(X_valid, label=y_valid, reference=train_data)
model = lgb.train(
params, train_data,
num_boost_round=500,
valid_sets=[valid_data],
callbacks=[lgb.early_stopping(stopping_rounds=50)],
)
# Predictions
y_pred = model.predict(X_test) # Weighted mixture
regime = model.predict_regime(X_test) # Regime index (argmax)
regime_proba = model.predict_regime_proba(X_test) # Gate probabilities (N, K)
expert_preds = model.predict_expert_pred(X_test) # Expert predictions (N, K)Each boosting round runs one soft-EM step (Jordan & Jacobs 1991, GBDT-ified). After a short warmup (default 5 rounds — gate fits r_init first so the first real E-step has a meaningful prior):
per round:
Forward → expert preds f_k(x), gate prior π_k(x)
E-step → r_ik = softmax_k[ log π_k(x_i) + log p(y_i | f_k(x_i), σ_k²) ]
M-step σ² → σ_k² = Σ_i r_ik (y_i − f_k)² / Σ_i r_ik
M-step f → expert k gets +1 tree, gradient = r_ik · ∂L/∂f_k
M-step g → gate gets +K trees, soft CE ∇z = (p − r) / T
r_ik is the posterior probability that sample i was emitted by regime k under the current mixture, not just a routing weight — this is what makes predict_regime_proba well-calibrated rather than just "where the gate happens to point". Three implementation choices distinguish this from a textbook GBDT-MoE — each was a real bug at some point:
| Choice | What it fixes | PR |
|---|---|---|
Per-expert noise scale σ_k² is estimated each round (default since #24) |
Without it, a hand-tuned mixture_e_step_alpha is silently doing what 1/(2σ²) should — y-scale variant, broken across datasets. With it, the responsibility softmax is the actual Bayesian posterior — y-scale invariant. |
#24 |
Bias-free prior split: π_k = softmax(z/T) for the E-step, softmax((z+b)/T) for the actual routing |
DeepSeek "loss-free LB" bias is a routing nudge, not part of the probabilistic model; mixing it into the prior makes the gate spend each iter unlearning the bias the load balancer just added. | #25 |
Soft CE gate with ∇z = (p − r)/T, Hessian = K/(K−1) · p(1−p) / T² (Friedman) |
Earlier code argmax'd r to hard pseudo-labels (dropped the soft routing signal); missing chain-rule mis-scaled Newton steps by T at non-unit temperatures; missing Friedman factor mis-sized leaf values by (K−1)/K. |
#23 |
Three pathology guards worth knowing about:
- Uniform
ris an EM fixed point — same gradient → identical trees →rstays uniform forever. After init, a deterministic sin perturbation breaks the symmetry (no-op whenris non-uniform; onlymixture_init=uniformactually triggers it). Reproducer:examples/em_init_sensitivity.py(#36). - Diversity regularizer sign was inverted in earlier code (pushed experts together). Sign + Huber clip + Hessian damping fix in #26 — the empirical "
mixture_diversity_lambdais the only universal MoE knob" finding (Settings that won) only became real after this. - ELBO is logged every 10 iters (
Σ_i log Σ_k π_k p(y_i | f_k, σ_k²)). Approximate M-step makes small dips normal; persistent / >5% drops have historically meant high expert dropout, adaptive-LR decoupling experts from EM, or a recent gradient/Hessian regression — flagged loudly so we don't miss it.
A v0.7 opt-in (mixture_refit_leaves=true, #37) makes the M-step refit every existing tree's leaves in closed form against the current r_ik before the next tree is appended — recovering classical EM's "free-parameter M-step" within each tree's existing partition. v0.8 (#41) goes one step further with mixture_regrow_oldest_trees=true — discards the oldest trees' splits entirely and rebuilds them via the LightGBM tree learner against current r, extending the M-step to the (split, leaf) pair. Both are opt-in; in the current holdout study leaf refit is effectively ON in 11 / 30 winning configs, so search them like any other knob (see Limitations § v0.7 leaf-value refit and § v0.8 partition re-grow).
Full deep dive with code refs: docs/moe/architecture.md.
Two practical caveats of regime estimation in this model. The first is universal to switching models; the second is specific to this implementation.
EM converges to a local fixed point of r, and which fixed point you reach depends on r_init. This is the same multimodality that makes GMM and HMM fits init-dependent — not unique to MoE-GBDT. Practical implications:
- If the regime is observable from X, prefer
mixture_init=gmm_featuresorkmeans_featuresover the[X, y]-aware variants. Cluster on raw features, not on the label. mixture_initis worth searching over with Optuna — it's not interchangeable across datasets, and there is no universal best init (verified in the 500-trial study).- Don't read
r_ikas "the true regime" of sample i. It's "the regime this run of EM converged to under this init". Different runs with different inits are valid alternative explanations of the same data.
Classical EM rewrites parameters freely between iterations — at iter t+1 the component means/variances can be radically different from t, and that is how EM escapes one basin and finds another mode. Here the experts are gradient-boosted ensembles, so each EM round only appends one tree per expert (historical trees are frozen). The expert function f_k(x) therefore evolves incrementally (one tree of learning_rate-scaled correction per round); r_ik shifts only as fast as the new tree's contribution to loss(y_i, f_k(x_i)) shifts; and the gate's accumulated trees lock in routing toward whichever expert r concentrated on early.
Two consequences worth being honest about:
- Large regime re-assignments don't happen mid-training. Some refinement happens — that's why the #26 diversity term and the #36 symmetry breaker matter — but you don't see the "EM flipped two components" behavior of free-parameter EM. Snapshotting
model.get_responsibilities()from a per-iter callback (see the docstring inpython-package/lightgbm_moe/basic.py:4994) showsrsmoothing toward its fixed point, not bouncing between modes. - This compounds init dependence above — the basin set by
r_initis sticky because the model cannot take big jumps inrto escape it.
The root-cause fix — leaf-value refit-on-r-update, which restores the closed-form M-step on each tree's existing partition structure — landed in v0.7 (#37 / PR #40). Enable with mixture_refit_leaves=true (default false); the M-step then rewrites every existing tree's leaves against the current r_ik before appending the next tree, instead of leaving them frozen at the r of their construction round.
params = {
"boosting": "mixture",
...,
"mixture_refit_leaves": True, # opt-in v0.7 behavior
"mixture_refit_trigger": "elbo", # always | elbo (default safest) | every_n
"mixture_refit_decay_rate": 0.0, # 0.0=full replace, 1.0=no-op
}Empirical position: in the current holdout study, mixture_refit_leaves is effectively ON in 11 / 30 winning configs (counting only winners where it actually runs, i.e. not leaf_reuse) — after the v0.8.1 stale-score fix it is an ordinary knob to search, not only a bad-init safety net (see Settings that won). The pre-v0.8.1 acceptance benches that concluded otherwise ran on the stale-score build and have been removed.
trigger=elbois the safe opt-in: it fires only on an ELBO drop or plateau, so well-behaved EM runs are left alone.gate_type="leaf_reuse"is incompatible with refit and is auto-force-disabled at Init with a one-time warning (refit rewrites expert leaves, but leaf_reuse's gate GBDT stays frozen, producing an asymmetric update).examples/em_refit_regime_evolution.pyplots refit on/off underrandomvsgmminit side by side.
Track regime evolution mid-training with model.get_responsibilities() from a per-iter callback — RegimeEvolutionRecorder in python-package/lightgbm_moe/viz.py does this with a 4-panel diagnostic plot.
v0.7's leaf refit only updates leaf values; the split structures chosen against r_init stay frozen. v0.8 (#41 / PR #42 for the ELBO trigger fix, PR #43 for partition re-grow) extends the M-step to discard old splits and rebuild trees against current r_ik via the LightGBM tree learner — block coordinate ascent on the (split, leaf) pair. Enable on top of mixture_refit_leaves=true:
params = {
"boosting": "mixture",
...,
"mixture_refit_leaves": True,
"mixture_regrow_oldest_trees": True, # opt-in v0.8 behavior
"mixture_regrow_per_fire": 3, # 3 is the empirical sweet spot
"mixture_regrow_mode": "replace", # "replace" | "delete" (ablation)
}Partition re-build does what leaf refit can't: when the early-iter splits encode r_init's wrong partition, no leaf-value optimization rescues that — splits have to be re-chosen.
- Search it like any other knob:
mixture_regrow_oldest_treesis part of the--moe-space widesearch in the benchmark. The pre-v0.8.1 acceptance benches ("Optuna declines refit/regrow") ran on the stale-score build and have been removed. gate_type="leaf_reuse"is auto-disabled whenmixture_regrow_oldest_trees=truefor the same reason as v0.7 leaf refit (asymmetric update against the frozen leaf-reuse gate GBDT). One-time warning at Init.
If your problem genuinely needs mode-discovery (unsupervised regime detection where regime structure is unknown a priori), a free-parameter EM with K random restarts is still structurally stronger: each restart escapes the entire init basin, while regrow only rebuilds a few of the oldest trees within one run.
MoE's gating mechanism wins on regime-structured data — but the honest baseline is not single-model naive LightGBM, it's a K-way ensemble of LightGBMs with the same total tree budget. Simply averaging K independent models with different seeds gives variance reduction "for free"; the question is whether MoE's learned routing beats that. The study below answers it: MoE clearly wins on synthetic (−20.2 % vs the ensemble) — the case where the regime is a deterministic function of X — and on fred_gdp (−2.3 %, every seed), where the holdout window contains a genuine regime shock (COVID quarters). On vix and hmm it wins some seeds and loses others (+2.1 % / +2.3 % on the mean), and on data without regime structure it ties the ensemble (−1.3 % to +1.6 %). Compute trade-off: MoE costs roughly 3–13 × naive single-model time and 1–4 × naive-ensemble time per fold (up to 31 × / 8 × on houses). Net rule: try MoE when (a) you believe the regime is observable from your features or your evaluation window contains regime shifts, and (b) your wall time has ~10 × headroom over single-model LightGBM — and search it over several seeds, because a single CV winner can generalize badly.
Methodology note (v0.8.1). This table supersedes the pre-v0.8.1 benchmark, which had four defects found in a methodology audit: (1) the headline was the minimum CV score over 500 Optuna trials — the selection metric itself, a winner's-curse-biased estimate that rewards larger search spaces; (2) early stopping validated on the scoring fold; (3) the
vixfeatures leaked the full-sample mean (lookahead for a mean-reverting series — and a regime proxy, precisely the signal a gate exploits); (4)sp500/vixtargets were misaligned by one step. All four are fixed and the old results have been removed. The oldvix−6.9 % win was retracted as a leak artifact; the oldfred_gdploss flipped to a win once a holdout containing the COVID quarters was actually evaluated.Re-measured on v0.8.4 (October 2026). The v0.8.1 table had one more defect, in the library rather than the protocol:
mixture_gate_type="leaf_reuse"routed samples through stateful sparse-bin iterators shared across OpenMP threads, so the gate misrouted samples nondeterministically (PR #61). Everyleaf_reusemeasurement before that fix is invalid — including the v0.8.1vix−5.0 % win, whose winners leaned onleaf_reuse. The table below is the fixed build, withdeterministic=trueon every variant so each (dataset, seed) cell reproduces bit-for-bit.
Protocol: the final 20 % of every series is a chronological holdout never seen by Optuna.
Hyperparameters are selected by expanding-window time-series CV (5 folds, 1-step embargo,
early stopping on the chronological tail of each training window — never on the scoring
fold) over the first 80 %; the CV winner is retrained once and scored once on the holdout.
500 Optuna trials per (variant × dataset × seed) over the full MoE search space
(--moe-space wide: all inits including gmm_features/kmeans_features, K ∈ 2–6, gate
temperature annealing, entropy λ, expert dropout, load-balance α, refit/regrow), 3 seeds
(synthetic/hmm redraw data, TPE + models reseed), reported as holdout RMSE mean ± std.
Every (dataset, seed) cell runs in its own process (--parallel 6, num_threads=4 per
trial) with deterministic=true and sequential Optuna (--n-jobs 1), so a cell reproduces
bit-for-bit; the merge refuses parts from a dirty tree or from different builds. Build
provenance (git commit, lib sha256, dataset sha256s) is recorded in the output. Results:
bench_results/headline_v084/ (study_summary.json +
study_report.md; the 99 MB per-trial JSON and the 33 MB of per-cell slice plots are
regenerated by the run and not committed).
The third variant — naive-ensemble — is a K-way (K ∈ {2, 3, 4}) seed-ensemble of
standard LightGBMs that share hyperparameters but diverge per-member via the seed
master-seed override. Same total tree budget as MoE (K × num_boost_round), same Optuna
search space as naive-lightgbm plus K, same 500-trial budget. It is the fair ablation for
"is gating doing real work, or would any K-way ensemble suffice?" — see PR #33.
Regime datasets — where the gating hypothesis is tested:
| Dataset | Shape | naive | ensemble | MoE | MoE vs naive | MoE vs ensemble |
|---|---|---|---|---|---|---|
synthetic |
2000 × 5 | 4.840 ± 0.311 | 4.723 ± 0.327 | 3.770 ± 0.222 | −22.1 % | −20.2 % |
vix |
3763 × 13 | 1.768 ± 0.091 | 1.739 ± 0.051 | 1.776 ± 0.219 | +0.4 % | +2.1 % |
fred_gdp |
311 × 12 | 1.553 ± 0.011 | 1.540 ± 0.017 | 1.504 ± 0.003 | −3.1 % | −2.3 % |
hmm |
2000 × 5 | 2.216 ± 0.244 | 2.208 ± 0.242 | 2.258 ± 0.308 | +1.9 % | +2.3 % |
Non-regime control datasets (Grinsztajn et al. 2022 regression track) — standard i.i.d. tabular regression with no regime structure. The control group: if MoE beat the ensemble here too, the "regime routing" story would be confounded with generic capacity.
| Dataset | Shape | naive | ensemble | MoE | MoE vs naive | MoE vs ensemble |
|---|---|---|---|---|---|---|
houses |
10000 × 8 | 50109 ± 902 | 48816 ± 1005 | 48668 ± 533 | −2.9 % | −0.3 % |
cpu_act |
8192 × 21 | 2.498 ± 0.297 | 2.448 ± 0.336 | 2.416 ± 0.332 | −3.3 % | −1.3 % |
elevators |
10000 × 18 | 0.002357 ± 0.000080 | 0.002296 ± 0.000060 | 0.002332 ± 0.000099 | −1.1 % | +1.6 % |
wine_quality |
6497 × 11 | 0.6146 ± 0.0141 | 0.6065 ± 0.0126 | 0.6034 ± 0.0120 | −1.8 % | −0.5 % |
Noise-floor datasets (next-day S&P 500 returns) — a sanity check, not a test: every variant sits at the irreducible noise floor (all differences ≤ 0.4 %), so MoE invents no structure where there is none.
| Dataset | Shape | naive | ensemble | MoE | MoE vs naive | MoE vs ensemble |
|---|---|---|---|---|---|---|
sp500_basic |
3762 × 13 | 0.01102 ± 0.00001 | 0.01103 ± 0.00002 | 0.01103 ± 0.00001 | +0.1 % | +0.0 % |
sp500 |
3711 × 28 | 0.01109 ± 0.00003 | 0.01104 ± 0.00001 | 0.01105 ± 0.00001 | −0.4 % | +0.0 % |
Read the tables together. On regime data MoE beats the capacity-matched ensemble where
the regime is strongly observable from X (synthetic, −20 %, every seed) or the holdout
crosses a regime break (fred_gdp, −2.3 %, every seed, with a 5 × tighter seed spread than
the ensemble). vix and hmm are mixed: on vix MoE wins the CV on every seed and the
holdout on two of three (−3 % to −7 %), but the third seed's winner generalizes badly
(+15 %) and drags the mean to +2.1 %; on hmm, where the regime is only weakly observable
through two noisy proxy columns, MoE ties two seeds and loses one. On the controls MoE
beats naive by 1–3 % but merely matches the ensemble (−1.3 % to +1.6 %): on i.i.d.
data MoE's gain over naive is explained by generic K-way capacity, and learned routing adds
nothing without structure to route on. That is the attribution result the regime wins need.
Measured with six cells running concurrently at num_threads=4 each, so absolute seconds
are not comparable to earlier tables; the ratios are the point.
| Dataset | naive | ensemble | MoE | MoE / naive | MoE / ensemble |
|---|---|---|---|---|---|
synthetic |
0.041 | 0.210 | 0.311 | 7.5 × | 1.5 × |
fred_gdp |
0.013 | 0.108 | 0.098 | 7.3 × | 0.9 × |
sp500_basic |
0.018 | 0.086 | 0.109 | 6.0 × | 1.3 × |
sp500 |
0.026 | 0.189 | 0.200 | 7.5 × | 1.1 × |
vix |
0.038 | 0.146 | 0.406 | 10.7 × | 2.8 × |
hmm |
0.032 | 0.184 | 0.163 | 5.0 × | 0.9 × |
houses |
0.136 | 0.512 | 4.189 | 30.8 × | 8.2 × |
cpu_act |
0.074 | 0.309 | 0.638 | 8.6 × | 2.1 × |
elevators |
0.064 | 0.203 | 0.845 | 13.1 × | 4.2 × |
wine_quality |
0.149 | 0.598 | 0.505 | 3.4 × | 0.8 × |
Regime datasets span the regime-switching applicability spectrum: one MoE-ideal synthetic,
two real-world series (canonical references in the regime-switching literature), and one
HMM with known ground-truth labels. All time-series generators follow the audited
alignment convention: row t's features use information available at time t only; the
target is the value at t + 1 (verified by tests/python_package_test/test_benchmark_methodology.py).
-
Source: internal generator in this repo (
generate_synthetic_datainexamples/benchmark.py). -
Construction: five i.i.d. Gaussian features; the regime is a deterministic function of
X, so the gate can route perfectly:regime = (0.5·X1 + 0.3·X2 − 0.2·X3 > 0) y | regime=0 : 5·X0 + 3·X0·X2 + 2·sin(2·X3) + 10 + ε y | regime=1 : −5·X0 − 2·X1² + 3·cos(2·X4) − 10 + ε ε ~ N(0, 0.5²)The two regimes use opposite-sign coefficients on the same features — a single GBDT is forced to average them, which is exactly the failure mode MoE is built to avoid.
- Source: Yahoo Finance, symbol
^VIX,2010-01-01to2024-12-31. - Index methodology: CBOE VIX.
- Construction: target is next-day VIX level. Features: lagged VIX at lags {1, 2, 3, 5, 10} plus MA / rolling-volatility features computed on a causally demeaned series (expanding past-only mean — the pre-v0.8.1 version demeaned with the full-sample mean, which leaked "above/below the all-time mean" into the features; the current numbers are measured leak-free). Generator:
generate_vix_data.
- Source: FRED series
GDPC1— Real Gross Domestic Product, Chained 2017 Dollars, Quarterly, Seasonally Adjusted Annual Rate (BEA via FRED, no auth, CSV endpoint). - Methodology cite: Hamilton, J. D. (1989). A New Approach to the Economic Analysis of Nonstationary Time Series and the Business Cycle. Econometrica 57(2), 357-384. https://www.jstor.org/stable/1912559.
- Construction: target is the quarterly growth rate
100·Δlog(GDP); features are 4 lags of growth (Hamilton's MS-AR(4)) plus engineered MA / volatility / regime-proxy features. The regime (expansion / recession) is genuinely latent — there is no oracle column. The chronological holdout contains the COVID quarters, which is exactly where MoE's win comes from. Generator:generate_fred_gdp_data.
- Source: internal generator in this repo (
generate_hmm_data). - Methodology cite: Rabiner, L. R. (1989). A Tutorial on Hidden Markov Models and Selected Applications in Speech Recognition. Proceedings of the IEEE 77(2), 257-286. https://www.cs.ubc.ca/~murphyk/Bayes/rabiner.pdf.
- Construction: hidden state evolves as a 3-state Markov chain with persistent (95 % diagonal) transitions; emissions are Gaussian with well-separated means
{−3, 0, +3}and varying scales{0.4, 0.7, 1.0}. Two of the five feature columns carry a weak linear signal of the hidden state; the rest are pure noise. Returns ground-truth regime labels — usable for measuring regime recovery, not just RMSE.
- Source: OpenML v1 originals (data_ids 537 / 197 / 216 / 287), from the regression-on-numerical-features track of Grinsztajn, L., Oyallon, E., & Varoquaux, G. (2022). Why do tree-based models still outperform deep learning on typical tabular data? NeurIPS Datasets & Benchmarks.
- Preprocessing (ours, documented): numeric columns only, NaN rows dropped, seeded shuffle, 10k-row cap (tabular-benchmark "medium-sized" convention). Rows carry no temporal meaning, so the chronological splits behave like random splits here.
Real-world fetches (FRED, yfinance, OpenML) are cached under examples/data_cache/
(gitignored); sha256 checksums of every cache file are recorded in each study's output
JSON, so any run can be tied to the exact bytes it saw. First run pulls from the network;
subsequent runs are offline.
From the 30 winning MoE configs (10 datasets × 3 seeds). The knobs that were frozen at their defaults before v0.8.1 are active in nearly every winner; the structural choices (init, gate type, routing, K) have no universal winner.
| Knob | Finding |
|---|---|
mixture_diversity_lambda |
active (> 0.02) in 28 / 30 winners |
mixture_expert_dropout_rate |
active in 26 / 30 — was frozen at 0 pre-v0.8.1 |
mixture_load_balance_alpha |
active in 29 / 30 — was frozen at 0 |
mixture_gate_entropy_lambda |
active in 21 / 25 gate-equipped winners — was frozen at 0 |
| gate temperature | T_init > 1.5 in 12 / 25 gate-equipped winners — search it, don't fix T = 1.0 |
mixture_refit_leaves |
effectively ON in 11 / 30 (it is force-disabled under leaf_reuse, so only gbdt/none winners count) — an ordinary knob to search, not a default |
mixture_regrow_oldest_trees |
effectively ON in 6 / 30 |
mixture_hard_m_step |
soft (False) in 15 / 30 — a coin flip; search it |
mixture_init / mixture_gate_type / mixture_routing_mode / K |
no universal winner (random 9, gmm 6, gmm_features 5, uniform 5, tree_hierarchical 3, kmeans_features 2 / gbdt 14, leaf_reuse 11, none 5 / token 19, expert 11 / K spread 2–6) — search them |
# Full headline study: 10 datasets × 3 seeds × 3 variants, 500 trials, wide MoE space.
# ~5 h on 12 cores. Finished cells are reused, so rerunning the command resumes.
python examples/comparative_study.py --parallel 6 --out bench_results/headline_v084/study.json
# Smoke test (~2 min)
python examples/comparative_study.py --trials 10 --seeds 42 \
--datasets synthetic,fred_gdp --out bench_results/smoke.json
# A/B two builds of the C++ core with the same protocol
LGBM_MOE_PACKAGE_DIR=/path/to/other/python-package \
python examples/comparative_study.py --trials 300 --seeds 42,43,44 \
--out bench_results/study_other_build.json| Topic | Doc |
|---|---|
| Full parameter reference (MoE core, Gate, Smoothing, Prediction APIs) | docs/moe/parameters.md |
| Optuna search templates | docs/moe/optuna-recipes.md |
| Per-expert hyperparameters & role-based recipe | docs/moe/per-expert-hp.md |
| Expert Choice routing | docs/moe/advanced-routing.md |
| Progressive training (EvoMoE) & gate temperature annealing | docs/moe/advanced-progressive.md |
Expert collapse prevention & diagnose_moe |
docs/moe/advanced-collapse.md |
| SHAP analysis for MoE components | docs/moe/shap.md |
int8 & use_quantized_grad compatibility (8-axis matrix) |
docs/moe/int8-compat.md |
| Architecture & EM-loop deep dive (incl. v0.7 leaf-refit §2.7) | docs/moe/architecture.md |
| v0.8 partition re-grow design (math + impl plan) | docs/v0.8/partition_regrow_design.md |
MIT license. Based on Microsoft LightGBM.
