catchlaw-rule-enginelisted
Install: claude install-skill zakariaf/CatchLaw
# Catchlaw Rule Engine
The engine never decides what a fisher should do; it states which rules were found, which one bites
first, and which instrument says so. This skill owns the pure-Dart `rule_engine` package — the
resolution pipeline, specificity ladder, tie contract, expiry tagging, finding precedence, the
no-rule-found state and the species normalisation contract. It owns neither the `Result` spine,
sealed-class style and reference schema, nor the sentence printed from a finding.
Read the reference for the task at hand:
- `references/resolution-algorithm.md` — selection predicate, lineage collapse, zone ancestry,
specificity ladder, tie matrix, expiry axis, finding precedence, worked traces, edge cases.
- `references/normalisation-contract.md` — nfkc ordering, tatweel and harakat, alef and ya folding,
ta-marbuta collapse, definite-article dual indexing, Arabic-Indic digits, acceptance test.
Run `scripts/check_rule_engine.sh` before a PR.
Rows arrive as plain Dart records: DAOs and indices belong to `catchlaw-reference-database`, the
content that fills them to `catchlaw-content-pipeline`, the `Result` spine to
`error-handling-typed-results`, sealed-class and complexity policy to
`dart3-idioms-and-coding-standards`, and the printed sentence to `catchlaw-verdict-contract`.
## Non-negotiable rules
1. **An expired ruleset is TAGGED, never filtered away.** No resolution query may mention `valid_to`
in a `WHERE`, and no Dart pipeline may `.where((r) => r.validTo!.