Add deterministic modal-force drafting lint + library tool

↗ view on GitHub · Eli Ziff · 2026-07-28 · 3f1319a2

legalDraftingLint: the citable, rule-like subset of drafting guidance
as exact-span findings with severity and autofix eligibility - 'may
not' prohibition ambiguity (federal legistic guidance: prohibitions
take 'must not'; no blind autofix, intent is residual semantics),
'and/or' (Law Smells ambiguous-syntax class), stacked-modal typos
(error), and mixed shall/must obligation registers (one finding at the
minority form, not per-hit spam), plus a document modal profile.
Detection is deterministic; a model only ever judges the bounded
excerpt - the deep-research report's lint-first/escalate-second
pattern, and its one idea today's suite had not already covered.

Wired as library_drafting_lint (allowlist-checked, capped findings).
5/5 unit tests; smoke over real corpus: Criminal Code 2.26M chars ->
shall 1723 / must 275 register drift + 58 may-not + 6 and-or; ON ESA
and the CX collective agreement profile as expected (CBAs are
and/or-dense, will-register). localAssistantTools tests 8/8.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018bhP89cYSdEEjHNPnxacns
Repository eliziff/Beaver
Author Eli Ziff <eliasziff@gmail.com>
Authored
Parents 96c629bb
Stats 3 files changed , +246
Part of Deterministic legal-text tools ("SLA audit organs")

Capture this commit into my fork

Download a Markdown prompt that tells Claude how to port this exact commit into your working tree. Run it via claude -p < capture-commit-3f1319a2.md from inside the repo you want the change in.

⬇ Download capture-commit-3f1319a2.md