Run frontier MoE models on hardware you already own β pure C, zero deps, experts streamed from disk. Tiny engine, immense model. π¦
C
docs(degrade-zero): document warm-cache assumption as known limitation
Kritika Garg9a390184264b
diff --git a/docs/ENVIRONMENT.md b/docs/ENVIRONMENT.mdindex 8c49a466..940e4eca 100644--- a/docs/ENVIRONMENT.md+++ b/docs/ENVIRONMENT.md@@ -268,7 +268,7 @@ These are for testing, benchmarking, or internal use β not part of the everyda| `COLI_CORPUS_MINACC` | `50` | Acceptance floor (percent) for the corpus source. Below it over a 24-proposal window the source pauses for 256 tokens, then re-arms β rejected drafts cost real time. || `EXPERT_BUDGET` | `0` (off) | Cap experts loaded per layer (MoE-Spec). **Quarantined:** silently forced to `0` unless `EXPERT_BUDGET_EXPERIMENTAL` is set β every tested value is either no faster or incoherent (issue #303). || `EXPERT_BUDGET_EXPERIMENTAL` | unset | Setting it (any value) allows `EXPERT_BUDGET>0` to actually take effect (expect garbage, #294). |-| `DEGRADE_ZERO` | `0` (off) | **Opt-in approximate mode:** miss slots with per-position gate weight < `DEGRADE_TAU` are zero-filled instead of triggering a blocking disk read. Decode-only (`Sβ€4`). Changes output β must be set explicitly. Measured on OLMoE-1B-7B: `tau=0.03` β +2.9% ppl, 21.8% slots zeroed; `tau=0.05` β +41% ppl. GLM-5.2 and Kimi K3 router contracts are unmeasured β treat `tau=0.03` as OLMoE-calibrated and tune per-model. `[PROF]` footer reports zeroed slot count and top-3 layers by drop share. See PR #906, issue #865. |+| `DEGRADE_ZERO` | `0` (off) | **Opt-in approximate mode:** miss slots with per-position gate weight < `DEGRADE_TAU` are zero-filled instead of triggering a blocking disk read. Decode-only (`Sβ€4`). Changes output β must be set explicitly. Measured on OLMoE-1B-7B: `tau=0.03` β +2.9% ppl, 21.8% slots zeroed; `tau=0.05` β +41% ppl. GLM-5.2 and Kimi K3 router contracts are unmeasured β treat `tau=0.03` as OLMoE-calibrated and tune per-model. `[PROF]` footer reports zeroed slot count and top-3 layers by drop share. See PR #906, issue #865. Calibration assumes a warm expert cache; cold-start transient is not characterized. || `DEGRADE_TAU` | `0.03` | Gate weight threshold for `DEGRADE_ZERO` (clamped to `(0, 1]`). Compared per-position, post-`norm_topk`, pre-`routed_scale` β i.e. as a fraction of each position's routed mass. || `DSA` | on | Dynamic Sparse Attention indexer. `DSA=0` disables. || `DSA_FORCE` | `0` | Force the DSA path on. |diff --git a/docs/tuning.md b/docs/tuning.mdindex 7b18beca..e52f7dc9 100644--- a/docs/tuning.md+++ b/docs/tuning.md@@ -172,6 +172,11 @@ different router contracts and expert counts β their operating points have notbeen measured. Until they are, treat `tau=0.03` as a starting point and verifyquality on your model before relying on it.+**These numbers assume a warm expert cache.** Cold-start sessions β where the cache+begins empty and all experts miss initially β will see higher drop rates until the LRU+fills. The steady-state perplexity delta above is what was measured; cold-start transient+behavior has not been separately characterized.+The feature is decode-only (`Sβ€4` guard, same as `EXPERT_BUDGET`): droppingexperts during prefill corrupts the KV cache. A rescue rule ensures no tokenposition is left with zero routed experts. Resident (pinned or LRU-cached)