Skip to content

Stop two rules reporting things that are not defects - #43

Merged
jepegit merged 1 commit into
mainfrom
lint-precision
Sep 9, 2026
Merged

jepegit merged 1 commit into
mainfrom
lint-precision

Conversation

@jepegit

@jepegit jepegit commented Sep 9, 2026

Copy link
Copy Markdown
Owner

SYM-02: 158 warnings, 126 distinct tokens, most of them not acronyms

Two classes accounted for the bulk.

A word set in capitals by typography. AND, OF, AT, UNIV, TEXAS, AUSTIN, REVIEW, PAPERS — every one from a heading or a page stamp. A token whose neighbours are also capitals is a word of a phrase, not an acronym. Neighbours must be two letters or more: a lone capital beside a token is a variable, and "R equals ID IG" would otherwise suppress ID on account of the R.

A chemical formula whose subscript has already been spoken. CH two, SO four, PO four, PF three, WO three, YH three, HNO three. Expanding one is not a thing anyone can do.

The spoken number is what makes this safe to act on: CV and PC are element runs too — carbon-vanadium, phosphorus-carbon — and they are real acronyms (cyclic voltammetry, propylene carbonate) that are never followed by a subscript. Both are tested as must-still-fire.

And it reports on the first occurrence that is a use. Reporting on the first occurrence full stop meant an acronym whose first appearance was inside an all-caps heading got skipped entirely — which hid ATR and SBR, both genuinely never expanded and both used in running prose further down.

SENT-02 was half right, and the other half was a planner bug

Nine warnings. Four were harmless: two consecutive sentences of a paper, quoted in two consecutive beats.

"…as observed in one experiment and will be discussed in further detail. It can be difficult to distinguish between hydroxide, peroxide and oxide…"

The listener heard the referent three seconds ago. The rule's own description says "whose antecedent is in another beat" — and the check never looked at the beat before.

Five were real, and every one was a boundary the planner chose:

"Still on synthesis. This is apparent in the superior cycling of the cell…"

A transition and a pause now stand between the pronoun and the thing it points at. All five came from _split_oversized, where _cut_point already declines to separate a prompt from its answer and now declines this too; _segment defers the same way when the clock allows.

The judgement both need lives in one place, mimem.verbalize.cohesion — because whether such a sentence is a defect is not a property of the sentence at all. It is a property of what the programme puts in front of it.

Corpus

before after
SYM-02 158 134
SENT-02 9 0
errors 2 2

SENT-02's five real cases are now absent from the audio rather than merely unreported.

13 new test cases in tests/unit/test_cohesion.py and test_artefact_lint.py, most of them guards. The SENT-02 trigger in test_rule_triggers.py moves its pronoun into its own segment, which is the shape that is actually a defect.

🤖 Generated with Claude Code

SYM-02 raised 158 warnings across twelve papers, 126 of them distinct tokens, and
the majority were neither acronyms nor unexpanded. Two classes accounted for most
of it.

A word set in capitals by typography rather than because it is an acronym: AND,
OF, AT, UNIV, TEXAS, AUSTIN, REVIEW, PAPERS, all of them from a heading or a page
stamp. A token whose neighbours are also capitals is a word of a phrase, and the
neighbours have to be two letters or more, because a lone capital beside a token is
a variable -- "R equals ID IG" would otherwise suppress ID on account of the R.

And a chemical formula whose subscript the number verbalizer has already said: CH
two, SO four, PO four, PF three, WO three, YH three, HNO three. The spoken number
is what makes this safe to act on, because CV and PC are element runs too --
carbon-vanadium, phosphorus-carbon -- and they are real acronyms that are never
followed by a subscript.

The rule now reports on the first occurrence that is a *use*. Reporting on the
first occurrence full stop meant an acronym whose first appearance was inside an
all-caps heading got skipped entirely, which hid ATR and SBR.

SENT-02 was the other one, and it was half right. Nine warnings, of which four were
two consecutive sentences of a paper quoted in two consecutive beats -- the
listener heard the referent three seconds ago, and "...will be discussed in further
detail. It can be difficult to distinguish..." is how the paper reads. The rule's
own description says "whose antecedent is in another beat", and the check never
looked at the beat before.

The other five were real, and every one was a boundary the planner had chosen:
"Still on synthesis. This is apparent in the superior cycling of the cell..." puts
a transition and a pause between the pronoun and the thing it points at. So the
planner no longer cuts there -- neither when segmenting nor when splitting an
oversized segment, where all five of these came from. SENT-02 goes to zero on the
corpus, and four of those nine were noise while five were audio nobody should ship.

The judgement the two share now lives in one place, mimem.verbalize.cohesion,
because whether such a sentence is a defect is not a property of the sentence at
all -- it is a property of what the programme puts in front of it.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@jepegit
jepegit merged commit 8f9838b into main Sep 9, 2026
4 checks passed
@jepegit
jepegit deleted the lint-precision branch September 9, 2026 05:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant