Expand description
Pure-function lifecycle + decay layer. Functions take inputs, return outputs, never touch disk. M5b’s sweep calls these to decide transitions and persist; M5a’s doctor calls them for read-only display.
Structs§
- Lifecycle
Thresholds - Runtime-immutable lifecycle thresholds, derived from
SkillLifecycleConfig.
Enums§
- Note
Kind - The two knowledge shapes a
Category::Noteskill can carry.
Constants§
- AUTO_
ARCHIVE_ AGE_ DAYS - AUTO_
ARCHIVE_ CONFIDENCE - DEMOTE_
EMERGING_ SUCCESS_ RATE - DEMOTE_
EMERGING_ USES - Demotion thresholds — values that MUST drop BELOW. Hysteresis: lower than the symmetric promotion threshold to prevent flap.
- DEMOTE_
STABLE_ SUCCESS_ RATE - DEMOTE_
STABLE_ USES - DEPRECATED_
NO_ SUCCESS_ DAYS - DEPRECATED_
SUCCESS_ RATE - MIN_
CONFIDENCE - MIN_
DWELL_ HOURS - NOTE_
FACT_ HALF_ LIFE_ FACTOR - Default half-life multiplier for
kind=factnotes. - NOTE_
RULE_ HALF_ LIFE_ FACTOR - Default half-life multiplier for
kind=rulenotes. - PROMOTE_
DRAFT_ USES - Promotion thresholds — values that MUST be exceeded.
- PROMOTE_
EMERGING_ AGE_ DAYS - PROMOTE_
EMERGING_ SUCCESS_ RATE - PROMOTE_
EMERGING_ USES - PROMOTE_
STABLE_ AGE_ DAYS - PROMOTE_
STABLE_ SUCCESS_ RATE - PROMOTE_
STABLE_ USES
Functions§
- calculate_
decay - Compute decayed confidence given an anchor, last success time, and the half-life for the current lifecycle state.
- cap_
for_ provenance - Cap a proposed lifecycle state for LLM-authored, uncurated skills.
- half_
life_ days - Half-life (days) for confidence decay, indexed by current state.
- half_
life_ factor_ for - Decay half-life multiplier for
manifestunder thresholdst— notes get per-kind curves; everything else (and a missing manifest) is 1.0. - lifecycle_
rank - Total order over lifecycle states. Public because the federation snapshot floor (mur-core) compares against the same ranking — a duplicated table drifting from this one would silently change what federates.
- next_
state - Compute what state the skill should be in given its current stats and the current time. PURE — does not mutate. Idempotent: calling this twice with the same inputs returns the same output.
- note_
kind - Kind of a note manifest:
Category::Note+ aruletag →Rule; a plain note is aFact(facts are the default larval form; rules are explicit). Non-note skills have no kind. - on_
promotion - Called by the M5b sweep AFTER persisting a promotion. Resets the confidence anchor so the new half-life applies from current, not stale, confidence. Without this, a skill promoted from Draft to Emerging would carry its already-decayed anchor under the longer Emerging half-life and appear artificially fresh forever.
- transition_
allowed - Returns true if the transition from
fromtotomay be persisted right now. Even whennext_statesays a transition is warranted, this guard prevents: