Expand description
The moderation policy engine (Phase 1).
A read-only conviction engine: communities declare declarative policies, the
engine evaluates evidence and reports convictions — “member X was convicted
of rule Y, here is the proof” — and the CONSUMER (GUI, mod bot, send
pipeline) decides every fate. The engine holds no keys, performs no I/O, and
never sentences; evaluate is a pure function of its inputs, so any two
clients holding the same inputs reach byte-identical conclusions.
Design: MOD_POLICY_ENGINE_DESIGN.md (repo root, local). The scoring core,
pipeline order, id preimages and canonical encoding there are wire-frozen;
the reference values in combine’s tests are the first conformance
vectors. The shipped raid assessor (super::raid) is the ancestor of the
cohort/join_burst rules and keeps serving the console until the facade
swaps over.
Re-exports§
pub use types::*;
Modules§
- combine
- The combinator and the frozen selection pipeline (§3.1, §3.2 — wire contract).
- document
- The policy document: what a community declares, and what the validator refuses (§5, §6, §12).
- engine
evaluate— the pure conviction engine (§1, §3.2, §5).- harness
- Side-by-side harness: run the engine against a live community and diff its verdicts against the shipped assessor.
- matchers
- Text and link matching (§6) — the deterministic rules.
- normalize
- The frozen normalizer bundle (§7.4) — bundle version 1.
- presets
- The preset library: what an admin picks instead of writing a document.
- types
- Wire-frozen report and policy types (design doc §4, §12, §13).