wadachi-spec (轍)
The zero-I/O frecency-ranking core shared across the pleme-io fleet — one
formula for directories (wadachi), command history (skim-tab), and zoxide
imports, so they cannot drift.
Authored as the pleme-io TYPED-SPEC + INTERPRETER TRIPLET:
- Typed border —
FrecencyRankingSpec+DecayKind+RankPhase. - Authored Lisp spec —
specs/frecency.lispdeclares the canonical instances (skimtab-parity,zoxide-parity) as data. - Interpreter —
apply(spec, entries, env)walks the phases against a mockableFrecencyEnvironment(the clock is the only side effect → tests are deterministic).
use ;
use NaiveDate;
let now = from_ymd_opt.unwrap.and_hms_opt.unwrap;
let ranked = apply.unwrap;
assert!;
skimtab-parity is Σ 1/(1+age_days) — behavior-identical to skim-tab's
historical frecency_score, which makes adopting this crate in skim-tab a
behavior-preserving extraction. MIT.