Repository navigation
Keep Cheikh and Sultan as given names under a strict Arabic or Malay choice - #1521
Merged
Merged
Conversation
…choice (#1463) ar.toml gives cheikh a given reading and ms.toml gives sultan one, each with the counts it was read from, so a strict ar or ms choice keeps the rules/H9 gate that fr.toml's, ar.toml's and tr.toml's name readings give every other choice. Both words leave STRICT_UNGATED. The default and every plain choice move nothing: _compiled.py is unchanged and the snapshot holds; Reading.languages of a given Cheikh gains ar, of a given Sultan ms. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…cope (#1463) Give cheikh and sultan a family reading beside the given one, as batch F gave sultan in ar.toml, so Reading.languages names the file under strict. Widen the test to a full name before a family comma, Dr. and Haji in front, nicknames, Jr., the en-joined strict choices with their title phrases, and the shipped MS pack, pinning the one report strict and plain read differently. Narrow the decisions entry to the pairs it measured, state how strict reads a family-first name, count the score's dropped records directly, and run the AGENTS control in a scratch copy. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…1463) The score's titled filter cannot drop a Cheikh or Sultan record, both words being in titles_ambiguous by default, so the entry says so and gives the score's own populations (63 and 8 + 2). The re-taken pairs' lead names only them, the unsupported "bin Sultan" leaves the note and the entry, and the AGENTS lesson limits the remove() shortcut to a word no other kept file holds a reading of that kind on. A test holds the family readings' purpose, the file Reading.languages names. Co-Authored-By: Claude Opus 5.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.
Relates to #1463
A strict choice reads only the chosen languages' files.
cheikh's only name readings sat in fr.toml andsultan's in ar.toml and tr.toml, so strictarand strictmskept the chosen file's title reading and lost the rules/H9 (the title phrase) gate:Cheikh Kaddariunder strictarread titleCheikh, givenKaddari, andSultan Zulkarnainunder strictmsread titleSultan, familyZulkarnain, in 3.0.0 through 3.1.0.This gives
cheikhgivenandfamilyreadings in ar.toml andsultanthe same in ms.toml, each with the counts it was read from, and takes both words offSTRICT_UNGATEDin tests/v2/test_reading_index.py. Thefamilyreadings follow the 2026-11-03 batch F precedent forsultanin ar.toml: they move no role, and they name the file inReading.languages.Counted first (the issue's third question)
tools/name_usage.py cheikh sultan --boxeswith--countryfor the Maghreb, Egypt, Mauritania, Senegal, Saudi Arabia and Malaysia, 2026-11-21:cheikhsultanbin Sultan(PatentsView 1)Senegal's 81
cheikhgiven boxes are fr.toml's readings, Wolof names written in French.What moves
Measured on master
81a24221, strict against strict with thegivenreading added, scored against the filed boxes (config_diff.py score):armsThat reproduces the issue's 8 records for
arin its four countries; Mauritania, which the issue did not sample, adds 4. The score's titled filter cannot hide any of these records: it counts a title as listed only where the default'stitlesholds it, and by default both words are intitles_ambiguous(rules/H9). So the 12 and the 1 cover every record the score reads: 63 ORCID records holdingcheikh, and 8 ORCID and 2 PatentsView records holdingsultan.Across trees, the readings of 3,567 local and committed names holding either word under
default,plain:ar,plain:ms,plain:MS,plain:fr,strict:ar,strict:ms,strict:ar+enandstrict:ms+en, compared line by line between master and this branch:strict:ar,strict:ar+enCheikhstrict:msSultan, 8 reading a credential afterX Sultan,as the suffix, 1 report only (Sultan II)strict:ms+ennameparser/config/_compiled.pyis unchanged, andtests/v2/test_snapshot.pypasses without a re-record.Reading.languagesof a given or familyCheikhgainsarbesidefr, and of a given or familySultangainsmsbesidearandtr. That is by default and under every choice that keeps the file.locales.MSsince #1514#1514's honours don't touch
sultan.locales.MSalready readSultan Zulkarnainas givenSultan, and strictmsnow reads it the same way. A ruler's style opening a name (Sultan Rahmat ibni Sultan Kamil) reads givenSultanunder strictms, as it does by default and under the pack. Behind a style it stays the title where the style words are chosen (His Majesty Sultan Rahmatunder strictms+en).What stays open on #1463
gd,hr,sk,slandhi, andmarquis,marquise,tho,standsushri, are not measured here. Nor are thenl,fr,caandgapairs (0 of 822 records moved in the issue's table),ptandpt-PT, ormy's ranks (ShouldRabe a name by default as well as a credential and a title? (Kim Ragives suffixRa; Korean and Burmese names) #1483). They stay inSTRICT_UNGATED, and the decisions entry does not record them as wanted.Bin. I re-took the pairs the issue measured, with their gates restored:ben62,bin6,it7,fil2,pt-BR1, 0 broken.Binopening a Chinese given name in a Malaysian list (Bin Qiaoyu) is recorded as a cost accepted under strict's premise. docs/locales.rst already states that premise: strict is "for data you know to be of one origin".La Reinaunder strictfilis a cost the premise does not answer. It is left with the pair.Bin, that bullet of the decisions entry is the one to change.Docs
docs/design/decisions/vocabulary-model.md: a dated entry, "2026-11-21 KeepCheikhandSultanas given names under a strict Arabic or Malay choice (Cheikh Mansourunder strictargives titleCheikh, no family) #1463".STRICT_UNGATED's comment records the move.nameparser/vocab/AGENTS.md: a lesson from this PR's own negative control. Copying the base'sconfig/_index.pyreverts every reading at once, so revert one TOML in a scratch copy and rebuild.Tests
test_a_strict_choice_reads_a_regated_word_as_its_plain_choice_doescompares strict with plain, field by field and report by report. It covers:ar,ms,ar+enandms+enchoices and the shippedlocales.MS, under all three name ordersDr.andHajiin frontJr.,II, and a credential strict does not list after a commaGrand Cheikh,His Majesty Sultan,Sultan of Johor)Negative control: with either TOML file reverted and the index rebuilt, that word's rows fail, along with the reviewed-table test.
Local runs, all passing:
build.py --checkparity_check.py(0 of 774)Review
Review-toolkit aspects run on the first commit: code (
pr-review-toolkit:code-reviewer), tests and comments (pr-review-toolkit:pr-test-analyzer), design docs (design-docs-reviewer). Both fix commits were reviewed again: the review of the first fix found six more problems, which the second fix answers.🤖 Generated with Claude Code