Skip to content

Add "abd" to BOUND_GIVEN_NAMES, and let a word in two vocabularies satisfy the join reserve - #400

Open
derek73 wants to merge 1 commit into
masterfrom
fix/abd-bound-given-name
Open

Add "abd" to BOUND_GIVEN_NAMES, and let a word in two vocabularies satisfy the join reserve#400
derek73 wants to merge 1 commit into
masterfrom
fix/abd-bound-given-name

Conversation

@derek73

@derek73 derek73 commented Aug 18, 2026

Copy link
Copy Markdown
Owner

abd Allah Smith read given abd, middle Allah, where abdul Rahman Smith reads given abdul Rahman. The spellings that write the article as its own word — Abd Allah, Abd al-Rahman — match none of abdul/abdel/abdal, and the Arabic-script عبد has covered the same word since #269, so only the Latin side was short.

abd Allah Smith          ->  given='abd Allah'   family='Smith'      (was given='abd', middle='Allah')
Smith, abd Allah         ->  given='abd Allah'   family='Smith'
abd Rahman Ahmed Salem   ->  given='abd Rahman'  middle='Ahmed'      (pairwise, like abdul)

Why the wordlist alone doesn't do it

abd is also the postnominal ABD ("All But Dissertation") in SUFFIX_ACRONYMS. The join's reserve counted every piece except titles and suffixes — so the bound word's own piece didn't count toward the three it needed, and the rule declined silently on the common three-word shape. Adding the word and stopping there changes nothing:

                                  abd Allah Smith        Jane Smith, ABD
wordlist only                     unchanged (broken)     suffix='ABD'
+ move to acronyms-ambiguous      given='abd Allah'      given='ABD'  <- credential lost
+ drop from SUFFIX_ACRONYMS       given='abd Allah'      family='ABD' <- credential lost
+ fix the reserve count           given='abd Allah'      suffix='ABD'

The last row is this PR. The claimed piece now counts, which is what the reserve means: it asks whether enough other words are left to spare, and the piece the rule has already claimed as a name is not one of them to spare. Both readings survive — position tells them apart, so Jane Smith ABD, Jane Smith, ABD and Jane Smith A.B.D. all still read the credential as a suffix.

Same shape as #397

Dual set membership shrinking a count that gates a rule is exactly the Catalan i finding — there it shrinks the rootname count P3's single-letter carve-out tests. Second instance in two days. The general question (should membership in one set suppress a word from a count gating a rule keyed on another?) stays open on #397; this PR fixes only the instance in front of it, where the count was wrong on its own terms.

Verification

abd is the only shipped word in both sets — measured, not assumed — so nothing else can move. All 751 differential corpus names are byte-identical and the harness reports 0 unexplained at the 1.4.0 baseline. The corpus contains no abd name, so that is a blast-radius check, not evidence for the fix; the evidence is the tests.

Mutation-verified: reverting the count line alone puts abd Allah Smith back to given abd. The stage-level test in test_group.py uses a synthetic word in both vocabularies, so it pins the mechanism rather than the wordlist, and asserts the reserve still declines at two name words.

3522 tests pass, mypy clean. Per-word evidence comments added on both sides of the collision, in the #: style, so a future editor of either set sees the other.

🤖 Generated with Claude Code

@derek73 derek73 self-assigned this Aug 18, 2026
@derek73
derek73 force-pushed the fix/abd-bound-given-name branch from fce7dd3 to e862284 Compare August 18, 2026 10:18
@derek73 derek73 added this to the v2.2 milestone Aug 18, 2026
@codecov

codecov Bot commented Aug 18, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.53%. Comparing base (55a7822) to head (0b11278).

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #400   +/-   ##
=======================================
  Coverage   98.53%   98.53%           
=======================================
  Files          44       44           
  Lines        2942     2942           
=======================================
  Hits         2899     2899           
  Misses         43       43           

☔ 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.

"abd Allah Smith" read given 'abd', middle 'Allah' where "abdul Rahman
Smith" reads given 'abdul Rahman'. The spellings that write the
article as its own word -- Abd Allah, Abd al-Rahman -- match none of
abdul/abdel/abdal, and the Arabic-script عبد has covered the same word
since #269, so only the Latin side was short.

Adding the word alone does not fix it, which is why this is not a
one-line change. `abd` is also the postnominal ABD ("All But
Dissertation") in SUFFIX_ACRONYMS, and the join's reserve counted
every piece except titles and suffixes -- so the bound word's own
piece did not count toward the three it needed, and the rule declined
silently on the common three-word shape. The claimed piece now counts,
which is what the reserve means: it asks whether enough OTHER words
are left to spare, and this piece is not one of them to spare.

Measured, the vocabulary-only alternatives each cost something this
does not: moving `abd` to SUFFIX_ACRONYMS_AMBIGUOUS loses
"Jane Smith, ABD", and dropping it from SUFFIX_ACRONYMS loses the
postnominal outright. Keeping both readings costs nothing here --
position tells them apart, and all three credential spellings still
parse.

`abd` is the only shipped word in both sets (asserted by measurement,
not assumption), so nothing else moves; all 751 differential corpus
names are byte-identical and the harness reports 0 unexplained.

Same shape as #397, where dual membership shrinks the rootname count
P3's carve-out tests -- recorded at decisions.md#P5, with the general
question left open on that issue.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@derek73
derek73 force-pushed the fix/abd-bound-given-name branch from e862284 to 0b11278 Compare August 18, 2026 10:34
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.

1 participant