Learning your voice
Mining a personal rule package from writing you have already done.
The built-in rules encode general advice. lawlint learn encodes yours —
generating a rule package from prose you have already written.
lawlint learn ~/my-writing/
Point it at a file or a directory of .docx, .md, or .txt. Requires a
configured model; see Setting up AI features.
How it works
A statistical pass over the whole corpus
Local and deterministic. Measures the distributions that characterize your writing — sentence length, opener variety, punctuation habits — across everything you gave it.
An AI mining pass over a small sample
Only a sample goes to the model, and only to name the patterns the statistical pass surfaced. The bulk of your corpus is never uploaded.
A self-consistency gate
Every generated rule is run back against your own corpus, and any rule that flags your own prose is discarded. A rule package derived from your writing that fires on your writing would be worse than useless.
Options
lawlint learn ~/my-writing/ --out .lawlint/rules/house
lawlint learn draft.docx --model anthropic:<model>
PATHpath
A file or directory of your writing (.docx, .md, .txt).
path--out?path
Where to write the generated rule package.
path.lawlint/rules/personal--model?string
Mining model, overriding the lawlint init AI preferences.
stringUsing the result
The output is an ordinary rule package — a style.yaml manifest and a
rules/ directory of Markdown files, exactly as if you had written it by
hand. Read it, edit it, delete the rules you
disagree with, and commit it.
lawlint init’s default config already lists .lawlint/rules in ruleDirs, so
a package written to the default --out is picked up automatically. Otherwise:
lawlint --rule-dir .lawlint/rules/house draft.md