Repository navigation
Add Hindi, Marathi, Urdu and Nepali strata to the native-script corpus - #862
Merged
Merged
Conversation
The native-script Wikidata corpus held 15 Hindi names and no Urdu, Marathi or Nepali ones: their name-part items are mostly labelled in Latin script only, so 1 to 3 in 100 pooled people align. Larger pools reach usable strata. Measured 2026-10-23 with no quota cap: hi-in 149 of its whole population of 4,806, mr-in 50 of 3,000, ur-pk 24 of its whole 1,456, ur-in 17 of 3,000, ne-np 12 of its whole 170. Dari in Afghanistan gave 4 of 291 and stays out. hi-in grows from quota 15 to 60 in its old position, so its 15 names stay; the build adds 117 names, all new to the snapshot, and moves no existing row. Two Urdu two-word surnames disagree (the Arabic class already recorded); no Devanagari vowel sign or conjunct moved a reading. 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 #862 +/- ##
=======================================
Coverage 99.05% 99.05%
=======================================
Files 47 47
Lines 4669 4669
=======================================
Hits 4625 4625
Misses 44 44 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Review of #862. The four India strata share their people, so the yields the STRATA comments give are now measured in build order (hi-in 147, mr-in 40, ur-in 12 of 3000, its quota exactly), not each stratum alone. The "1 to 3 in 100 pooled" rate was wrong for five of the eight strata it covered and is dropped. The README no longer offers the Devanagari rows as evidence about rules/H2's accepted gap: that gap is a period-marked abbreviation, and no text in the corpus holds a period; the Urdu names carry no combining mark at all. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
derek73
added a commit
that referenced
this pull request
Oct 24, 2026
…araphrase (#863) The README's "Adding a source" paragraph now says to size a stratum from its yield in build order: #862 measured its India strata one at a time, and Indian Urdu's 17 aligned names of 3,000 were 12 behind the strata before it, exactly its quota. AGENTS.md's encoding paragraph credited rules/H2's Accepted clause with excluding Indic vowel signs and Arabic and Hebrew points from the letter class. The exclusion was declined in decisions/nfd-shapes; H2 records only the Indic consequence, a period-marked Bengali or Devanagari abbreviation never reading as a title by shape. 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.
Extends the native-script Wikidata corpus (#693) to South Asian scripts it held little or nothing of.
What changed
Four new strata, and the Hindi one grown, in
build_wikidata_native_corpus.py. Yields were measured 2026-10-23 with no quota cap. The India column is in build order, because the four India strata share their people: each takes no one an earlier one took.hi-inmr-inur-inur-pkne-npur-inyields exactly its quota in build order, so its floor of 10 is its only margin. If a later re-pool loses three of its people, the build stops there.Dari in Afghanistan (
fa-af) was measured and left out: 4 of 291 aligned.The yields are low for the reason the builder already documents: these people's given-name and family-name items are mostly labelled in Latin script only, so the strict word-by-word alignment refuses them. Larger pools were the way to get usable strata without loosening that rule, for example by matching through transliteration.
hi-instays in its old position ahead ofmr-inandur-in. All 15 of its existing names stay in, because the MD5 order makes the old 1,000-person pool a prefix of the new 5,000.Effect
snapshot.jsonl(117 lines added, 0 removed).wikidata_native_agreement.jsongains two names, four role disagreements: the Urdu two-word surnamesرضا خانandاگنی ہوتری, where the parser reads the first word as a middle name. That's the same class as the Arabicعبد العزيزalready recorded.राहुल बजाज,mr-in) with his given-name and family-name items swapped, so the row is scored family-first and agrees.Docs
The builder docstring and
tools/differential/README.md(roster row and native-source paragraph) now name the new strata and their yields. Both used to say Urdu and Marathi were left out.Testing
uv run pytest: 23,332 passed (the serial benchmark tests were not run; they don't read the corpora). After the review fix, the corpus, agreement and snapshot test modules pass again (161 passed).uv run ruff check,uv run mypy: clean.cldr_agreement.py --recordandsnapshot.py --recordre-run. The JA locale rows were not measured locally (namedivider absent), and their recorded entries are kept unchanged.🤖 Generated with Claude Code