Add salutations, offices and ranks in other languages to TITLES - #608
Merged
Merged
Conversation
TITLES had no salutation for Finnish, Estonian, Romanian, Croatian/Serbian, Icelandic, Czech, Lithuanian, Malay, Filipino, Georgian and others, so "Herra Väinö Johansson" read given 'Herra'. 41 words join TITLES, grouped by language in titles.py, and knt (Knight) joins SUFFIX_ACRONYMS beside kt with a 'Knt' case mask. Thirteen of the words are borne as names, though rarely as the first word of one (greve, graaf, knight, herra, hrabia, ...). They ship on the graf precedent (Derek's call): a name that begins with one gives it to the title, as "Graf Steffi" already did. rules.md#H1 gains an Accepted clause for that cost, and decisions.md#salutation-titles records the per-word counts plus the Excluded (TITLES) rows (ông/bà, thiru, puan, pan, rodina, gróf, marshal, justice, ...). The one corpus mover is the new H1 example "Greve Anna", classified in all five ledgers; three comma rules' claims grow by "Greve, Anna". Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Second review round: the class overrides C-i's position test for measured leading-position bearers, not its uncertainty fallback, so C-i's entry now carries a dated pointer to the one exception and its scope (TITLES, these words). The entry also says the excluded side of the line was judged without counts, so the line is not reproducible from the record. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #608 +/- ##
=======================================
Coverage 98.98% 98.98%
=======================================
Files 45 45
Lines 4241 4241
=======================================
Hits 4198 4198
Misses 43 43 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
derek73
added a commit
that referenced
this pull request
Oct 4, 2026
One conflict, the two 1.4.0 comma-family claims both sides had moved: both dated comments kept, re-recorded over the merged corpus (441). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Merged
5 tasks done
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.
Closes #606.
What changes
41 words join
TITLES, grouped by language innameparser/config/titles.py. They cover salutations (Mr / Mrs / Miss) and ranks ("Count") in Finnish, Estonian, Romanian, Croatian/Serbian, Icelandic, Dutch, Czech, Polish, Lithuanian, Swedish, Malay, Filipino and Georgian, plus Danish/Norwegian/Germanfamilieand the English officescommissioner,counselandadministrator.knt(Knight) joinsSUFFIX_ACRONYMSbesidekt, with aKntcase mask.Herra Väinö JohanssonHerra, middleVäinöHerra, givenVäinöFamilie HansenFamilieFamilie, familyHansenPolice Commissioner James GordonPolice, givenCommissionerPolice Commissioner, givenJamesSir John Smith KntSmith, familyKntSmith, suffixKntJohn Smith, Knt.Knt.Knt.The graf class: borne as names, shipped anyway (decided)
The issue proposed shipping
greve,graafandknight, all borne as surnames, on the precedent ofgraf, which already ships though Steffi Graf exists. The spot-check the issue asked for (forebears.io, 2026-10-04) found ten more of its words borne as names: herra, batoni, ponas, counsel, ponia, ginoo, ginang, binibini, hrabia and kreivi. Most of them are surnames written last; a few have small given-name or surname-first counts. All thirteen ship by decision, and each is marked# borne.Gladys KnightandKnight, Gladyskeep familyKnight.Graf Steffialready did.Greve Annagives titleGreve, familyAnna, andHerra Wijayaloses its given name the same way. Declaring a family-first order does not help; a comma does.rules.md#H1.decisions.md#salutation-titlesrecords the counts and that this is an exception to#vocabulary-collisionsC-i, scoped toTITLESand these words. C-i itself carries a dated pointer to it.Excluded
Recorded in decisions.md's
Excluded (TITLES)block:ông/bà: Ông is a surname and Vietnamese names lead with it. A case row pins this underFAMILY_FIRST_GIVEN_LAST.thiruandpuan: given names.pan: the Chinese surname Pan, which leads.rodina: a Russian surname, often written surname-first.gróf: unverified.cik,paron,tikin, Latinjanab: unverified.marshalandjustice: given names.gravoswas dropped rather than excluded, because it couldn't be confirmed as the Greek word for "Count". The Greek word itself, κόμης, is not added and not excluded; it is left as an open decision.Measurement
Greve Anna. It is classified in all five ledgers; three comma rules' recorded claims grow byGreve, Anna(reach only).Review
Two
design-docs-reviewerrounds ran. The first round's five findings are fixed in the first commit: the class described too narrowly, the given-name cost not stated, a moot Fru argument, an ambiguous recipe, and the H5 trailing period. The second round's two findings are fixed in the second commit: the exception framed against the wrong part of C-i, and the uncounted excluded side.Test plan
uv run pytest: 11294 passed, 336 skipped, 3 xfaileduv run mypy,uv run ruff checksphinx-build -b doctest docs🤖 Generated with Claude Code