Expand description
Unified parametric decay module.
All temporal and spatial decay in CELLSTATE is unified under the Weibull survival function, a single parametric family that subsumes exponential decay, heavy-tail decay, and sharp-cutoff decay:
S(x; τ, β) = exp( -ln(2) · (x / τ)^β )where:
x ≥ 0— independent variable (time in days, graph depth in hops, …)τ > 0— half-life parameter:S(τ; τ, 1) = 0.5β > 0— shape parameter:β = 1.0→ standard memoryless exponential (current recency default)β > 1.0→ super-exponential with sharp sigmoid-like cutoffβ < 1.0→ sub-exponential with heavy tail (graph proximity, etc.)
§Mathematical Properties (all verified by property tests)
- P1 (Identity):
S(0; τ, β) = 1for allτ, β > 0 - P2 (Half-life):
S(τ; τ, 1) = 0.5 - P3 (Monotonicity):
x₁ ≤ x₂ ⟹ S(x₁) ≥ S(x₂) - P4 (Bounds):
0 ≤ S(x) ≤ 1for allx ≥ 0 - P5 (Asymptotic):
lim_{x→∞} S(x) = 0 - P6 (Smoothness):
Sis C^∞ forx > 0
§Subsumption of Legacy Decay Functions
| Legacy function | Equivalent call |
|---|---|
0.5^(t/7) (note recency) | parametric_decay(t, &{7.0, 1.0}) |
0.5^(t/30) (artifact rec.) | parametric_decay(t, &{30.0, 1.0}) |
0.5^(t/7) (warmth decay) | parametric_decay(t, &{7.0, 1.0}) |
1 - d/D (graph linear) | Replaced by parametric_decay(d, &{…}) |
Re-export path: cellstate_core::decay::*
Structs§
- Decay
Params - Configuration for a parametric decay function.
- Scoring
Decay Config - Per-factor decay configuration.
Functions§
- exponential_
decay - Convenience: standard exponential decay with the given half-life.
- parametric_
decay - Weibull survival function:
S(x; τ, β) = exp(-ln(2) · (x/τ)^β)