by assafkip
Deterministic Claude Code hook that catches AI-sounding writing before you publish. Banned words, cadence tells, em dashes, stats. Runs locally, no tokens.
The deep catalog scan for this skill is still queued. Run an instant dependency check now instead.
# Add to your Claude Code skills
git clone https://github.com/assafkip/voice-gateNo comments yet. Be the first to share your thoughts!
Unlocks once the catalog security scan passes (runs nightly).
voice-gate is a Claude Code hook and Python CLI that scans your drafts for the patterns that make writing read as machine-generated, then blocks the write until you fix them. It runs locally, needs nothing beyond python3, and drops into any repo with no path edits.
This free repo ships the core voice-lint detector and a starter ruleset you can edit. The paid kit, Writing Voice Gate, adds the substance detector, the headline and LinkedIn and email format checks, a one-command installer, and a test suite. Link in the footer.
Version 1.0.0. Updated 2026-05-28.
Copy two files and one config line.
mkdir -p .claude/hooks/voice-gate
cp hooks/voice-lint.py hooks/voice_gate_config.py .claude/hooks/voice-gate/
cp -r config .claude/hooks/voice-gate/config
Then add the hook to .claude/settings.json (see config/settings.example.json):
{
"hooks": {
"PostToolUse": [
{
"matcher": "Edit|Write|MultiEdit",
"hooks": [
{ "type": "command", "command": "python3 .claude/hooks/voice-gate/voice-lint.py" }
]
}
]
}
}
Restart Claude Code. On every save to a content file, the gate runs. If a draft trips a rule, the write is blocked with a line-by-line report.
Run your draft through the gate before you publish, not after.
python3 hooks/voice-lint.py examples/bad-draft.md
voice-lint flags the deterministic fingerprints of machine prose:
config/banned-words.txt).config/banned-phrases.txt.87%, "the study found", "according to research").No model is in the loop. It never hallucinates a verdict and never spends a token to run.
Grammarly checks grammar for correctness. AI detectors hand you a probability score after the fact, and they are easy to game. voice-gate is neither. It is a gate wired into your editor's save event. Instead of scoring, it blocks, and it points at the exact line and the exact rule. You fix the line and move on. Everything runs before you publish, on your own machine.
| Banned-word linter | AI detector | voice-gate | |
|---|---|---|---|
| Catches overused words | Yes | No | Yes |
| Catches filler phrases | Some | No | Yes |
| Catches cadence tells | No | No | Yes |
| Runs deterministically, no tokens | Varies | No | Yes |
| Blocks the write in Claude Code | Rarely | No | Yes |
| Editable word lists, no code change | Sometimes | No | Yes |
Yes. Every check is a plain Python CLI. Run python3 hooks/voice-lint.py draft.md
in any pipeline, any CI job, any pre-commit hook. The Claude Code wiring is
convenience, not a requirement.
The word and phrase lists are plain text files. Open config/banned-words.txt
and config/banned-phrases.txt and edit them. For everything else, including
which file paths the gate fires on, copy config/voice-gate.config.example.json
to voice-gate.config.json and point the VOICE_GATE_CONFIG env var at it.
Some rules ship off by default because they are house style, not universal tells. You opt into those in the config.
Add <!-- voice-lint-skip --> anywhere in the file. Skips are per-file and
explicit, so an exception is a decision, not a default.
Will it flag my code? No. It strips code fences, inline code, and frontmatter before checking prose.
Does it phone home? No. There are no network calls and no telemetry.
What does it cost? This repo is free and MIT-licensed. The full Writing Voice Gate is a one-time 29 dollars on Gumroad.
This free repo is the seed. The paid Writing Voice Gate adds the substance detector that catches drafts with no witness, no named thing, and no number, the four format checks for headlines and LinkedIn and email, the one-command installer, and the test suite.
I build these gates for teams. If you want the same discipline wired into your own writing pipeline, grab a slot: https://calendar.app.google/cMFvhvDsfi9iyWYy9