Skip to content

Stop the chain before a trailing title after a family comma (#623) - #635

Merged
derek73 merged 4 commits into
masterfrom
feat/issue-623-comma-given-read
Oct 11, 2026
Merged

derek73 merged 4 commits into
masterfrom
feat/issue-623-comma-given-read

Conversation

@derek73

@derek73 derek73 commented Oct 11, 2026 •

Copy link
Copy Markdown
Owner

Summary

After a family comma, assign's walk over the given part already reads a trailing title run (H5), so Smith, John Prof. reads title 'Prof.'. But group bounded the particle chain there by trailing_start, which reads the suffix peel alone. So the chain took the title into the particle's name before the walk ever saw it.

Input Before Now
Smith, John van der Berg Prof. middle 'van der Berg Prof.' title 'Prof.', middle 'van der Berg'
Smith, Jan van Prof. middle 'van Prof.' title 'Prof.', family 'van Smith'
Smith, John Prof. title 'Prof.' unchanged
Smith, John van der Berg Prof (bare) middle 'van der Berg Prof' unchanged

At that site the chain's bound is now _pieces.trailing_run_start: the start of the run tail_reading takes, titles included. The chain stops in front of the title and the walk reads it.

  • Nothing new is counted. Only the chain's stop moves, so the issue's words-to-spare question doesn't arise. The comma's own readings of a numeral or a bare acronym don't move (Smith, John van der Berg VI keeps middle 'van der Berg VI').
  • The issue's open question: P6 reads after the title run, as though the title were absent. Smith, Jan van Prof. attaches van to the family, as Smith, Jan van does.
  • The bound is asked only where a particle stands past the chain's lead, checked by an inline tag scan. Without one the chain merges nothing, so this also drops the trailing_start call master made on every family-comma part.
  • Declined (Derek): the issue's full proposal. That was reading the given part's run once ahead of the chain and splitting it off, as Rethink the credential-run rule (S2): read a name's trailing run once, over name units, and bind it before any join #614 does for comma-less names. It would add a second reader beside assign's own walk, and the transparency measurement below finds no text the narrower bound leaves broken that the read would mend.

Measured (against 4d5631c, py3.11, import asserted on each side; recipes in decisions.md#H5)

  • Given-part grid (18,480 texts under the three orders and lenient_comma_suffixes=False): 17,340 of 73,920 parses move a role (4,335 texts under each configuration), and no parse moves only a report. All but 500 parses (125 texts) put a trailing period-marked title into the title field.
  • H5 transparency (the parse with a trailing title, compared with the parse without it plus the title): broken on 392 of 5,390 texts, against 3,048 on master, and none newly broken. By cause:
    • 352 are H1's move of the name behind a title into an empty family.
    • 40 are P5's existing post-comma abdul join taking the title (24 after a named family, Smith, abdul Dr.; 16 behind an empty head). rules.md#H5 already records this gap.
  • S2 stress grid's comma half: 56 moves. Where does Freiherr St John Smith MA start: should a title that is also a particle open the name? #624's title-particle grid: 24. All are the same class.
  • No change: Merge the trailing run's particle runs in group, so S2's read needs no BOUND stop or report gathering #625's particle grid, every corpus name and case text, and Where does Freiherr St John Smith MA start: should a title that is also a particle open the name? #624's comma-tail grid.
  • Five differential gates: all exit 0 with a new fix(#623) rule in every ledger. On the 2.x surfaces the rule includes _ambiguities, for P6's report on Smith, Jan van Prof..
  • Frames: the reference rows don't move.
    • A family-comma name with a particle pays 2 more with no trailing run (Smith, John van der Berg 282 → 284) and 4 with a suffix.
    • The moved shapes pay 38 to 73 in a sample (Smith, John van der Berg Prof. 310 → 360). An unmoved particle name ending in a suffix and a title pays 20 to 22.
    • A name without a particle pays less (Smith, John Quincy 221 → 213, Doe, John MA 254 → 227).

Tests

  • New rows: a_trailing_title_after_a_family_comma_stops_the_chain and a_particle_before_a_trailing_title_after_a_comma_attaches (fix(#623); 1.4.0 and 2.3.0 read middle 'van der Berg Prof.' / 'van Prof.'), and the bare-title contrast a_bare_title_word_after_a_comma_stays_in_the_chain (parity).
  • More rows from the review, each fix(#623):
    • Smith, Freiherr von Berg Prof. and Smith, John von und zu Berg Prof. hold the particle check. Two narrowings of it (scanning from the name's start instead of the chain's lead, and testing single-token particles only) had passed every test while undoing readings master gives.
    • , Jan van Prof. covers the empty head.
  • the_chain_runs_again_where_its_merges_free_the_acronym (parity, from the second review): holds the re-ask after the chain (Smith, Freiherr van Berg X.Y.Z.).
  • test_a_given_part_with_no_particle_skips_the_chain_bound: holds the particle check's frame saving. With the check removed, Smith, John Prof. costs 250 frames against 207.
  • Negative control: with the old bound, 8 tests fail. That covers both fix(#623) rows on the core and facade surfaces, the three new rules.md#H5 examples, and the field-sweep count.
  • Field-sweep count: re-recorded from 1150 to 1156, for P6's report on the two rows that carry it, under the three orders.

Review

Fix commit: pins the particle check, adds the empty-head row, and corrects the decisions entry's causes, units and frame claim. rules.md#H5 no longer says the bound is the walk's own run, P6's interacts gains H5, and three stale comments now name the new bound.

Recorded, not fixed. The bound is tail_reading's run, and assign's walk reads the given part by its own predicates. Where they disagree about a word behind a title, the chain stops for a title the walk doesn't take. The cases are:

  • a title before a numeral (Smith, John Mc Prof. VI)
  • a title before a particle (Smith, John van Prof. Mc)
  • a period-marked title-particle that P6 attaches (Smith, John van MA St.)

All of these are garbage input. Over about 1.6 million generated rows, and over a 134,720-pair transparency grid, no text that is transparent to its title on master is broken on the branch.

Follow-ups found, outside this change:

The first-round claim that the re-ask after the chain changes no reading was wrong. Removing it moves 400 grid parses on master and on the branch alike. The new parity row Smith, Freiherr van Berg X.Y.Z. now holds it.

Second fix commit: adds the re-ask row, corrects the transparency example (which had been read in the wrong direction), the frame test's control (the bound is entered twice) and the frame range, and names #636 and #637.

Third fix commit: gives the transparency grid's recipe, notes the re-ask's second path (garbage, no row), and names both ends of the frame ranges.

Docs

Closes #623

🤖 Generated with Claude Code

Assign's walk over a family comma's given part already reads the
trailing title run (H5), but group bounded the particle chain there by
`trailing_start`, the suffix peel alone, so the chain took the title
into the particle's name first: `Smith, John van der Berg Prof.` read
middle 'van der Berg Prof.' where `Smith, John Prof.` and `John van der
Berg Prof.` read title 'Prof.'. At that site the bound is now
`_pieces.trailing_run_start`, the run `tail_reading` takes with its
titles, so the walk reads the title; P6 then reads the given part as
though the title were absent (`Smith, Jan van Prof.` → family 'van
Smith'). The bound is asked only where a particle stands past the
chain's lead.

Measured against 4d5631c: 17,340 role moves on an 18,480-text
given-part grid (four configurations), all but 500 the title moving
into the title field; H5 transparency broken on 392 texts against
master's 3,048, none new. S2 and title-particle grids move only this
class; the corpora, the case table and #625's grid do not move. Five
gates exit 0 with a fix(#623) rule. Reference frames unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@derek73 derek73 self-assigned this Oct 11, 2026
@codecov

codecov Bot commented Oct 11, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.02%. Comparing base (4d5631c) to head (132c6c0).

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #635   +/-   ##
=======================================
  Coverage   99.02%   99.02%           
=======================================
  Files          46       46           
  Lines        4495     4511   +16     
=======================================
+ Hits         4451     4467   +16     
  Misses         44       44           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@derek73 derek73 added this to the 2.4 milestone Oct 11, 2026
derek73 and others added 2 commits October 11, 2026 00:08
The review found the bound's particle gate held by no test, two of its
narrowings undoing readings master gives (a scan from the name's start
rather than the chain's lead, and a test of single-token particles
alone): rows `Smith, Freiherr von Berg Prof.` and `Smith, John von und
zu Berg Prof.` now hold them, an empty-head row (`, Jan van Prof.`) the
comma sweep asks for, and a frame test the gate's saving. Each mutation
fails a test.

Recorded rather than fixed: where `tail_reading`'s run and the walk
disagree on a word behind a title (a numeral, a particle, a period-
marked title-particle) the chain stops for a title the walk does not
take; every such shape is garbage. Corrected the entry's causes (352
H1, 40 P5), its units and its frame claim; rules.md#H5 no longer says
the bound is the walk's run; P6's interacts gains H5; three stale
comments name the new bound.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The re-ask after the chain still decides readings: removed, it moves
400 given-part grid parses on master and here alike (`Smith, Freiherr
van Berg X.Y.Z.` keeps given 'van Berg X.Y.Z.', as 1.4.0 reads it), and
no test held it; a parity row does now. The entry's claim that it
changed nothing, and its transparency example, read backwards, are
corrected; the frame test's control says the bound is entered twice;
the frame range is the sampled one; the follow-ups name #636 and #637.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The third review of #623 found the 134,720-pair transparency figures
stated with no recipe; the entry gives it now. The re-ask also decides
a main segment's run with a name piece inside it (`Freiherr van Berg
Dr. X.Y.Z.`), a garbage shape no row holds; the frame ranges name both
ends.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@derek73
derek73 merged commit 3b2b6f0 into master Oct 11, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Should Smith, John van der Berg Prof. read title 'Prof.' as John van der Berg Prof. does?

1 participant