Repository navigation
parse("Andrew") reports no ambiguity, but given-or-family is a guess #449
Description
Activity
- added a commit that references this issue
on Aug 29, 2026 - added a commit that references this issue
on Sep 8, 2026 - added a commit that references this issue
on Sep 8, 2026 Shipped in 2.3.0 via #518 as
AmbiguityKind.GIVEN_OR_FAMILY("given-or-family").What reports. A name of one name word that nothing else decided is read by rules.md#O5's convention — given under the default order, family under a declared family-first one — and now says so, with
detailnaming the field the convention chose (the kind cannot, because the field followsname_order; thePARTICLE_OR_GIVENprecedent). The report is emitted at the one site in assign that places the word. Your framing from #445 is the rule's statement: given or family is a guess, the parser picks one to be consistent, and the guess is recorded.The measured population is 27 corpus names, not the three or four the issue's naive count suggested — because a conjunction join reads as ONE unit (
Duke of Edinburgh,John of the Doe), a lone word beside a suffix is still a lone word (Smith Jr.,'Smitty' Jones Jr.,Donald mc), a glued-honorific peel can leave a Latin word the script cannot order (Andersonさん), and three names have a script rule that declined to decide (マイケル,王·Smith,田中、太郎). Derek chose to report on the whole O5 population as the rule defines it rather than narrow the emitter to bare words.What stays silent, and why: a title anywhere in the name, before or after a family comma (
Dr. Smith,John V, Dr.); a family comma that names a family (Smith, Andrew); a maiden marker (#445'sSmith née Jones); a nickname standing alone (N3); bound-given, particle and initial-shape claims (abdul,de,J.); and every name a script rule ordered (W4) — the guard tests whether ascript_ordersentry RESOLVED the order, not whether it agreed with the declaration, so毛泽东is silent under FAMILY_FIRST as well. A nickname or a suffix standing BESIDE the lone word decides nothing about its field, so those names report; the first draft claimed otherwise and the mutation counts (nine and one names) corrected it.Your compatibility note — "a new AmbiguityKind member is a public enum addition" — holds, and the enum's own contract licenses it in a minor release; it went in as an Additions bullet the way
SEGMENTATIONdid in 2.1.0.HumanNameexposes no ambiguities, so the v1 surface is untouched. The differential compares_ambiguitiesfrom baseline 2.0 on: 27 names diff on that pseudo-field alone, classified under six rules (one Latin alternation and five literal CJK-bearing rules the honorific guard forces), and no role changed for any corpus name under any order.The "honest output" flag the #471 close-out deferred to this bundle is this kind. Rationale:
decisions.md#O5, the 2026-09-07 entry.- added 4 commits that reference this issue
on Oct 8, 2026
A name with exactly one name word carries no information about which field that word belongs to. The library reads it as the given name so the same input always reads the same way — a convention, not a determination — and reports nothing:
rules.md#A1already sets the contract this falls under: "where the text's structure or a word's reading is genuinely uncertain, the parse completes on the best reading and carries an ambiguity report naming the doubt." This is such a case and carries none.AmbiguityKindhas seven members and no given-or-family fork;PARTICLE_OR_GIVENis the shape one would follow.The hard part is the condition, not the report
mechanisms.md#AMBIGUITY-AT-THE-DECISION-SITErequires a fork to fire where the outcome was chosen, not where the code arrived — its recorded failure is a fork reported for all 39 ambiguous particles on"Dr. Van Jr."on the weaker test."Exactly one name word" is the weaker test. Measured over the 1,085 differential corpus names, a naive lone given word, nothing else decided it condition fires on 19:
Only three or four are the case this issue is about. The rest have real structure in the input — particles, conjunctions, a comma — and the parse made a decision about them; they merely end up as a single unit afterwards. A fork there would cry wolf.
So the condition wanted is closer to "no vocabulary, no structure and no rule contributed to this reading" than to a word count, and working that out is the substance of the issue.
Where it must not fire
Every rule that carves an exception from the lone-word convention has decided the word, so none of these is a guess:
AndrewDr. Smith'Smitty' SmithSir JohnSmith née JonesNote #445 reduces this issue's population: it turns a class of guesses into determinations. Measure the fork's reach after #445 lands, not before.
Also worth weighing
AmbiguityKindmember is a public enum addition, so it is a compatibility surface in a way a parse fix is not..ambiguities, and the differential gate reports ambiguity changes, so the blast radius should be measured before the reading is chosen.Raised by Derek on #445: "given or family is really a guess. we have no information, it could be either. we pick one to be consistent." #445 records that framing in
rules.md#O5— the convention is written as a convention — so adding the report later changes behavior against a rule that already describes the doubt rather than contradicting one that denied it.