Repository navigation
Add locales.MY, a Burmese pack: U and Daw as titles, nine syllables kept name words - #1480
Merged
Merged
Conversation
…ept name words (#1231) my.toml gains the salutations u and daw written default = false, and locales.MY chooses my with a lexicon fragment taking out the particle readings of san, la, le, do, da, du, te, di and van, Burmese name syllables, as locales.VI's takes out Vietnamese ones. DEVIATES declares every name holding one of the nine as a word. rules/H11: a one-letter title written with its period is the initial it spells where the letter has a capital, at classify's title tag and the period-joined derivation's chunk test, so U. S. Grant, U.S. Grant and Grant, U.S. read as the default reads them under the pack. The default holds no such title, so no default parse moves; the committed snapshot gains the rule examples only. Registered, with contents, removal, comma-shape, order and U. tests, rotators, case rows, H11 tests with negative controls, and the CLDR locale view's my file (19/24 with and without the pack). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
rules/H11 and decisions/H11 state the one-letter title veto; rules/H1 gains the Burmese title-and-one-word cost; decisions/vocabulary- collisions gains a Standing line and a dated entry with the population, its recipe and the pack's cost on other names; mechanisms.md and the locales AGENTS.md name the second removing pack. docs/languages.rst gains a Burmese section with when not to use the pack, docs/locales.rst and README.rst the pack's rows, the release log a bullet. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…tial under MY (#1231) The review found U. still read as a title through the comma count (U. Smith, Ed reversed), the title phrase (Vice U. Smith), the glued-stop cut (Dr.U. Smith), the set-apart clause ((U.) Smith), C2's third part (its report lost) and the group suggester. _lexicon._spells_a_cased_initial is now the one predicate, asked after each reader's membership hit and a C-level length test, so only a one-letter title pays a frame; _vocab._title_chunk is folded back into its two callers. The H8, given-title and trailing-title tags take the veto too, and the title phrase reads a vetoed word as no title and no phrase member. Tests: a 288-row two-input invariant (a caller's q title against the default, every comma shape, order and reader) with its recorded control (228 rows move with the veto off); every kind of title reading a caller can write; a Greek capital; the reviewers' U. shapes under MY, with ambiguities compared; the suggester. locales.MY also takes out do's credential reading: with san no particle, AUNG SAN DO read suffix 'DO' (nameparser/vocab/AGENTS.md, "A reading taken out"). rules/H11 is rewritten: the Bengali case a boundary, the chunk bullet reworded, the Because's universal dropped, and a Burmese U written with its stop recorded as accepted. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
decisions/H11 names every reader the veto is asked at, the invariant and its control, and the Burmese U written with a stop as accepted. decisions/vocabulary-collisions re-takes its figures at the fix commit (committed 273 of 7,656, TSE 116,114, PSC 3,859), counts the fixes by word over the 151 fixes, scores a leading U. by the parse, records do's credential, the Maori Te and the other credential syllables, and corrects Britain's figure. vocabulary-model's Standing line names MY beside VI. docs/locales.rst's scope list reaches a comma part and Filipino names, its table is in order; docs/languages.rst names the nine words' cost exactly, do's credential and U written with a stop; the release log's limit sentence names the words; my.toml's notes no longer claim a universal. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e lesson (#1231) The fix commit's code and design-docs reviews found four more readers still claiming U. under the pack or a caller's one-letter title: T8's two tests of the word before a glued one (Juan dela U. Sta.Maria read family 'dela U. Sta.Maria'; U. J.Smith lost its report), the Thai glued-title walk (U. นายสมชาย), classify's title-phrase fork (a false title-or-name report) and a title run's addressing by its last word (Mr. and Q. Smith). Each now asks the predicate; the invariant grid gains their shapes (360 rows, control 279, each module's veto seen), the phrase test compares ambiguities, and a run test pins the addressing. rules/H11 gains Accepted rows for U.Daw and the fullwidth stop; decisions/H11 names the reads left out and why. docs/locales.rst and mechanisms.md name do's credential among the fragment's removals, the scope list reaches a U after a title, the capitals figure states its recipe, and nameparser/AGENTS.md records the class: a veto on a vocabulary set reaches every reader of the set. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…1231) Decided 2026-11-19, reversing the working answer that U. with a full stop stays an initial under the pack: a caller who chose the pack is reading Burmese names, no Burmese list measured writes U. as an initial, and vetoing a one-letter dotted title at every reader of the title vocabulary was new machinery on the shared parse path. The pipeline, _lexicon, _suggest and their tests return to master's; rules/H11 and decisions/H11 are removed with their index lines and the nameparser/AGENTS.md paragraph they earned. Under the pack U. Thein Sein and U. S. Grant now read title 'U.', pinned as the accepted reading in tests/v2/test_locales.py and the case rows; my.py, my.toml and docs/languages.rst say so as a reason not to apply the pack to a mixed list, the release log too. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…l state (#1231) decisions/vocabulary-collisions: a Standing clause and a bullet record that U. is read as the title vocabulary reads it under the pack, decided 2026-11-19, reversing working answer (3), with the reason and what the drafted rule had required; the population re-taken (154 moved, 152 fixed, 0 broken; 2,835 to 2,987 of 2,990), the committed corpora (279 of 7,644, the U. and period-joined costs named), and the Accepted bullet's U. and J.u.n.i.o.r. costs. The snapshot and the rules corpus differ from master by rules/H1's U Thant example alone. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The final review found the record narrower than what the pack does. U. is the title wherever the title vocabulary reads one, after a family comma (Smith, U., the given name lost), in brackets, in Grant, U.S. and glued to a title, and Daw. ending a name, not only opening it; and a removed particle opening the family before a comma lets a short given name after it read as a credential (Van Buren, Ed). The decisions entry, my.py, docs/languages.rst and docs/locales.rst now say so, tests pin Smith, U., John (U.) Smith and the comma cost, and a rotator holds the trailing Daw.; nameparser/vocab/AGENTS.md's "A reading taken out" names the comma shape. Decisions 6 and 15 of decisions/vocabulary-model name both removing packs. Corrected: Thakin opens 7 names, Mg reads a title in 10, the committed count's tree, and rules/H1's bullet credits the title's addressing, not position. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
docs/languages.rst no longer says de la loses its la (it reads as by default save ending the given part after a family comma). The comma cost counts 4 committed names and reaches a given part of initials (De La Cruz, M.J. K.L.), now a test row; the vocab AGENTS.md lesson asks for both. An initial U. behind a title is the title too (Dr. U. Smith), in my.py, languages.rst, the decisions entry and a test row. The FEC figure is replaced by a recipe that counts the names the pack moves (22 of 409). A test comment no longer contradicts its row, rules/H1's bullet credits the title being no given-name title, and Sayadaw's 9 names are written after the name. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Round five found each list of positions still short. The docs, my.py, my.toml, the release log and the decisions entry now say U. is the title wherever the parser reads a title, with examples, and that only a bare U. between two name words stays an initial; docs/languages.rst says de la reads as by default in Juan de la Cruz and can read otherwise in other shapes, and that Sayadaw is a name word as by default. The FEC figure counts names holding U as a word only (16 of 351 move, 3 losing their given name), its regex no longer matching U chunks inside joined words. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
docs/languages.rst: a U. among or ending the given names stays an initial (Smith, John U.), not only one between two name words; a Korean surname U reads as the title written with no comma (U Minjun), not after one (U, Minjun). docs/locales.rst's table row says the pack reads U and Daw as titles wherever a title is read. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…1231) Round seven found "wherever a title is read" false in the other direction: a U. ending a name, and U or Daw ending the given part after a family comma, stay name words. docs/locales.rst's row now gives an example, and docs/languages.rst, my.py, my.toml, the release log and the decisions entry say an initial U. can be the title, with examples on both sides, claiming no complete list. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The test comment over the accepted U. readings no longer claims "wherever it reads a title", and the decisions entry's list of places says a U. ending the name stays a name word, where Daw. reads as the title, instead of likening the two. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
derek73
added a commit
that referenced
this pull request
Nov 19, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Nov 19, 2026
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 #1231
Adds
locales.MY, an opt-in Burmese pack. Under it,UandDawopening a name read as titles, and nine syllables that other languages read as particles stay name words. The pack is vocabulary plus its pack file. Nothing on the shared parse path changes:git diff origin/master --stat -- nameparser/_pipeline nameparser/_lexicon.py nameparser/_parser.py nameparser/_suggest.pyis empty.parser_for(locales.MY)U Thein SeinU, middleThein, familySeinU, givenThein, familySeinDaw Aung San Suu KyiDaw, middleAung, familySan Suu KyiDaw, givenAung, middleSan Suu, familyKyiHenry Van ThioVan ThioVan, familyThioU. S. GrantU., middleS.U., givenS.(the accepted cost)What it does
nameparser/vocab/my.tomlgainsuanddawassalutationreadings writtendefault = false, with their vetting on each word:Uis a Korean surname and an initial,Dawa US surname.nameparser/locales/my.pychoosesmyand carries a lexicon fragment, aslocales.VIdoes for Vietnamese syllables. The fragment removes the particle readings ofsan,la,le,do,da,du,te,diandvan, anddo's credential reading. A vocabulary file cannot remove another file's reading.DEVIATESdeclares every name that holds one of the nine as a word._REGISTRY,locales.available()(tests, docs, README),_ROTATORS, the CLDRLOCALE_FILESwith a re-recordedcldr_agreement_locales.json, mechanisms.md#LOCALE-PACKS-PURE-DATA, decisions/vocabulary-model's Standing line, the locales AGENTS.md exemplar table, and docs/locales.rst's tables. The CLI's--localeandconfig_diff.py'splain:MYread the registry and needed no change.U Thant; and a dated entry in decisions/vocabulary-collisions.md holding every figure below with its recipe.Decisions to confirm
These are the coordinator's working answers to the issue's five questions, plus decisions made while building it. Each lists what the other answer would cost.
locales.MY, rather than amy.tomlchoice alone. The removals need a pack fragment, because a choice never makes a name reading settle a clash (decision 15 of decisions/vocabulary-model). The name:myis the BCP 47 tag of Burmese, and packs are named by language tag, with country packs adding a region (es_ar,pt_br). ButMYis also Malaysia's country code, and the repository holds a Malaysian local corpus namedmy-candidates, whose language is Malay (ms). The docs and the pack docstring say so. Other answer: a name such asMY_MMorBURMESEwould avoid the clash but break the language-tag convention every other pack follows.Ko,Ma,Maungand the ethnic prefixes (Saw,Sai,Nang,Naw,Khun,Mahn) stay name words. Other answer: making them titles would take a real given syllable from names such asMaung Maung KyawandKo Ko Lwin. In the population below 47 names open withMaung, 14 withKo, 14 withMa, 72 withSawand 94 withSai. Their family names already read right, and only the title field would change.U.with a full stop is read as the title vocabulary reads it. The working answer was thatU.stays an initial under the pack. This PR first built that as a new rule, drafted as H11. It required a one-letter word written with its period, in a script with capitals, to be the initial it spells and never a title, at every reader of the title vocabulary. Two review rounds found it needed asking at more than a dozen readers on the shared parse path, so it was dropped. The reasons: a caller who chose the pack is reading Burmese names, and no Burmese list measured writesU.as an initial. Under the pack, an initialU.can be read as the title:U. S. Grant→ titleU., andSmith, U.andDr. U. Smith→ no given name.John U. SmithandSmith, John U.keep it an initial. The docs give this as a reason not to apply the pack to a mixed list, and tests pin it. Read a one-letter title only at the head of a name, with its period (H. Budi Santosogives givenH.; IndonesianH.andR.) #1205 asks the same of IndonesianH..U Thant. A title and one name word reads the word as the family, as rules/H1 reads it everywhere: titleU, familyThant. It is recorded as an Accepted bullet in H1. Other answer: reading it as the given name needs a new switch or a pack-only rule (Policy.lone_name_wordcovers one-word names only).Bogyoke,Thura,Thakin,Sayadaw,Ashin). In the populationThakinopens 7 names,ThuraandAshin4 each, andBogyokeandSayadawnone (Sayadawis written after the name in all 9 that hold it). Other answer: adding them asdefault = falsetitles would fix those few names, and each would need its own vetting.do's credential reading is taken out too. Withsanno longer a particle,AUNG SAN DOread suffixDOunder the pack, where the default reads familySAN DO. This is the removal-unmasks-a-reading shape that nameparser/vocab/AGENTS.md warns about, and the review found it. VI removes it for the same reason. Other answer: keep the credential, soJane Doe, DOkeeps suffixDOunder the pack (it now gives givenDO), and Burmese names in capitals ending inDOlose that syllable to the suffix.PE,LAT,RA,EIandSI, which are read as credentials both by default and under the pack: 12 names in the population once every name is upper-cased. These are proposed as a follow-up issue.Measured (2026-11-19, the pack's final state, on master
6560abde)The Myanmar population. It was rebuilt by the issue's recipe in a scratch folder, and nothing was cached or committed. The sources are OpenSanctions'
sanctionsandpepstargets.simple.csv, persons withmmamong their countries (names and aliases), plus Wikidata's English labels of people with Myanmar citizenship and a Burmese label. That gives 2,990 clean Latin names.config_diff.pyreads only the committed and local corpora, so a scratch probe stands in for it.Sir U Thwin) and 1 between two wrong ones (two names in one string).U/Daw, with or without its full stop, as the title, and the last word as the family): 2,835 of 2,990 by default (94.8%), 2,987 under the pack (99.9%).Ra, read as the credential RA (Khar Ra, the same by default), and the joined string.Mg, Maung written short, is read as the militaryMGin 10 names, the same as by default (ShouldMg, Maung written short, read as a given name? (Mg Mg Ayegives title 'Mg Mg') #1232).The cost to names that are not Burmese (the docs say when not to use the pack):
U,U.orDaw:Daw Thida,U Kyaw Win, H1'sU Thant, and the Western initialU. S. Grant.Uchunk, which now reads as a title:John Smith J.u.n.i.o.r.,John Smith U.S. Dean., andU.S. and U.K. Ambassador Jane Doe.van130,da20,do19 andla11.Van Buren, Edgives suffixEd, andDe La Cruz, M.J. K.L.gives suffixM.J. K.L.. This is recorded and tested as a cost.UorU.as a word move, and 3 of those lose their given name.config_diff.py score default plain:MY, share of records with every box agreeing:The US, UK, Spain, the Philippines and Mexico each move by 0.4 of a point or less. ORCID cannot measure the honorifics: its Myanmar holders open no box with
U.myfile is in Burmese script, and reads 19/24 with and without the pack.The default is untouched. Against
origin/master, the committedsnapshot.jsonlandcorpus_rules.jsonleach gain one line, rules/H1's newU Thantexample, and change none.tools/perf/call_count.py --against origin/masterreads 197.72 on both sides.Sweeps
Every comma shape (none, full, one word, empty head, past the second comma), all three orders, and Title case, capitals and lower case. Also covered: dotted
Daw.andU.(opening, after a comma, in brackets, ending the name), each syllable in mixed case and in capitals,DOafter a family comma beside its mixed-case control, and a removed particle opening the part before a comma.uanddaware ASCII; theDEVIATEScut treats a combining mark as a boundary, which over-declares.Checks
uv run pytest(run without thejaextra, which is absent from this venv),uv run pytest -n0 -m serial,uv run mypy,uv run ruff check,uv run sphinx-build -b doctest docsand-b html,python -m doctest README.rst, and the changed test modules on Python 3.15 in a separate environment.Review
Every applicable pr-review-toolkit agent reviewed the PR, plus the design-docs-reviewer, and each fix commit was reviewed again.
code-reviewer,pr-test-analyzer(with mutations),comment-analyzer,code-simplifieranddesign-docs-reviewer(all twelve axes). Findings fixed in d5c7e4d and 10edc1d:AUNG SAN DOread suffixDOunder the pack;U.as right;code-revieweranddesign-docs-reviewer. Findings fixed in eb87f47:do's credential, the scope list, the capitals recipe.code-revieweranddesign-docs-reviewerover the final diff against master. Findings fixed in 07d4264:U.cost recorded wherever the title vocabulary reads a title, not only opening a name;Van Buren, Ed), new to the record;code-reviewerfound it clean.design-docs-reviewerfound errors in the fix, corrected in fa2d5fc:de laoverstated;Dr. U. Smithmissing from theU.sites;design-docs-reviewer. It found thede lasentence and the lists ofU.positions still incomplete, an FEC regex that also matchedUchunks inside joined words, my.toml and the release log still narrow, and theSayadawdoc line wrong. Fixed in the next commit, which states the costs in general terms with examples instead of position lists.design-docs-reviewerfound three wordings too narrow or too wide, corrected in 87a7a55.design-docs-reviewerfound "wherever a title is read" false the other way, corrected in 32f1d8c, which states theU.cost by examples and claims no complete list.design-docs-reviewerfound a test comment and one decisions clause still in the retired form, corrected in 8756189.design-docs-reviewer: clean.silent-failure-hunter: no error handling or fallback.type-design-analyzer: no new type; the pack is aLocaleinstance.🤖 Generated with Claude Code