Stop two rules reporting things that are not defects - #43
Merged
Merged
Conversation
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>
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.
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 suppressIDon account of theR.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:
CVandPCare 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
ATRandSBR, 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.
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:
A transition and a pause now stand between the pronoun and the thing it points at. All five came from
_split_oversized, where_cut_pointalready declines to separate a prompt from its answer and now declines this too;_segmentdefers 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
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.pyandtest_artefact_lint.py, most of them guards. TheSENT-02trigger intest_rule_triggers.pymoves its pronoun into its own segment, which is the shape that is actually a defect.🤖 Generated with Claude Code