Flag every em dash, escalate at three per paragraph - #4
Merged
Conversation
Split em-dash-overuse into two rules: em-dash (info) flags any em dash, while em-dash-overuse (now warning, up from info) still catches three or more in one paragraph. error stays unused -- measured against Moby-Dick and Walden, 3+ em-dash paragraphs are too common (6-11%) to call zero-false-positive. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XKKu3wVKfjzVU5Dd8wzL9E
examples_ok for em-dash used hyphens standing in for em dashes -- bad typography endorsed as acceptable. Replace with real prose showing correct hyphen and en-dash usage, and add a lone-dash examples_bad fixture (the shape a model reaches for most). Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XKKu3wVKfjzVU5Dd8wzL9E
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
em-dash(structure,info): flags any em dash, not just dense paragraphsem-dash-overuse(3+ em dashes in one paragraph) bumped frominfotowarningerrorstays reserved: measured against Moby-Dick and Walden, 3+ em-dash paragraphs occur in 6-11% of paragraphs, well above "essentially zero false-positive risk"Test plan
rspec— 181 examples, 0 failuresinfo em-dash+ 1xwarning em-dash-overuse, exit 1--/-text stays clean, exit 0sloplint ruleslists both rules with correct severities🤖 Generated with Claude Code
https://claude.ai/code/session_01XKKu3wVKfjzVU5Dd8wzL9E