Skip to content

Join عبد to a listed name of God past the first name word, so طارق عبد العزيز reads family عبد العزيز (#694) - #1070

Merged
derek73 merged 12 commits into
masterfrom
claude/bound-anywhere-694
Nov 5, 2026
Merged

derek73 merged 12 commits into
masterfrom
claude/bound-anywhere-694

Conversation

@derek73

@derek73 derek73 commented Nov 5, 2026

Copy link
Copy Markdown
Owner

Closes #694.

parse("طارق عبد العزيز") now gives family عبد العزيز, where 1.4.0 through 2.8.1 gave middle عبد, family العزيز. Wikidata gives family عبد العزيز.

What changed

  • New rule P12 (a bound given name and the word that completes it). A bound given-name word standing after the first name word joins the word after it when its reading lists that word in a new completed_by property. The pair becomes one name unit, and position decides its role.
  • The list. Arabic-script عبد lists 217 spellings of 139 words in ar.toml:
    • the 97 one-word names of God, and الله;
    • 27 other divine epithets;
    • 14 devotional completions (المطلب, النبي, الحسين, المسيح, …);
    • each with its hamza-less and Persian spellings.
  • Why a list, not a letter test. A first draft joined عبد to any following word that opens with the article ال. The design review rejected that as a statistical guess dressed up as a script rule: nisba surnames open with ال too. A closed list is certain, so محمد عبد القريشي keeps family القريشي.
  • The Latin spellings are unchanged. abdul, abdel and abdal list no word, so Tariq Abdul Aziz keeps middle Abdul. On the UK PSC register the pair is a middle name as often as a family, so the join would read worse there. The measurements are in decisions/P12.
  • rules/P5 (bound given names) now says it reads the first name word only, which P12 relies on.
  • rules/O6 (two family names) counts a pair P12 joined as one family word. P5's pair at the start, and a pair a particle chain took, still count as two.

Measured

Taken at 8ba37fa with config_diff.py, comparing against the default with عبد's reading written without the list:

  • Corpora: 309 of 2,448 names holding عبد move: 194 in JRC-Names, 110 in ORCID and 7 committed. All move middle → family, except one Persian name read under a family-first order.
  • ORCID family boxes: 62 records now read right that didn't before, and 0 got worse. The article test had 65 better and 5 worse.
  • Wikidata: 4 of the 7 Arabic-language (ar) disagreements in wikidata_native_agreement.json now agree. The other three join the word before them (عز الدين, شكر الله, ذو الغنى). They need a mechanism of their own and are left for a separate issue.

The recipes for these numbers are in decisions/P12. The commits are kept unsquashed, so the commits the entries cite (44c65f6, 8ba37fa) stay reachable from this PR.

Reviews

Each round ran in subagents (code, design docs, test coverage), and its fixes were reviewed again.

  • Code review. The pair joined across a glued semicolon, which rules/C10 forbids. O6 also counted P5's pair as one word. Both are fixed and tested, and both are now recorded as lessons in nameparser/AGENTS.md and nameparser/_pipeline/AGENTS.md.
  • Design-docs review. Fixed:
    • a false claim about the Arabic comma;
    • P5's unscoped When;
    • counts that did not reproduce;
    • a missing Persian spelling (المولی).
  • Test review. Added:
    • a _ShiftCountingList guard (one-pass join, with its control recorded);
    • build-check mutation rows;
    • case rows for the comma shapes, both family-first orders, nicknames, and a title before a lone pair.
  • Second round. Re-ran a 561,504-row grid and the recorded config_diff command: no defects.

Not in this PR:

  • A delimiter glued to the front of the next word (عبد ;الله) is still joined across. P2's, P3's and P5's joins all share that gap. It is noted in nameparser/AGENTS.md.

🤖 Generated with Claude Code

derek73 and others added 10 commits November 4, 2026 16:35
…لعزيز reads family عبد العزيز (#694)

A bound given name written `before_article` (a new bound_given property,
compiled into the internal Lexicon set bound_before_article) joins a
plain name word after it that opens with the Arabic article ال past the
leading join's piece, the pair one unit placed by position. ar.toml
writes it on عبد. Before a word with no article عبد is a name of its own
(نوال عبد هاشم), which ORCID's family boxes measured. The Latin abdul is
unchanged; decisions/P5 records why, with the PSC and ORCID scores.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…s one family word for O6

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…re-694

# Conflicts:
#	docs/release_log.rst
#	tests/v2/rules_budget.json
@derek73 derek73 added this to the 3.0 milestone Nov 5, 2026
@derek73 derek73 added enhancement vocabulary Per-word vocabulary model and language packs labels Nov 5, 2026
@derek73 derek73 self-assigned this Nov 5, 2026
…re-694

# Conflicts:
#	AGENTS.md
#	docs/design/decisions/README.md
#	docs/design/rules/P-particles-and-surname-prefixes.md
#	docs/design/rules/README.md
#	docs/release_log.rst
#	nameparser/_pipeline/_assemble.py
#	nameparser/_pipeline/_post_rules.py
#	tests/v2/rules_budget.json
@derek73
derek73 merged commit 8425226 into master Nov 5, 2026
13 checks passed
@derek73
derek73 deleted the claude/bound-anywhere-694 branch November 5, 2026 05:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement vocabulary Per-word vocabulary model and language packs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Tariq Abdul Aziz: should a two-word surname like Abdul Aziz stay whole after the given name?

1 participant