Repository navigation
Migrate the H rules to the skeleton format; split out H7 (#761, part 5) - #779
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
H1: the Except holds only the rows where a particle surname keeps the family; the ambiguous-or-bare sentence and its given-name rows go back to the listing-record Accepted bullet. H6: the outside-When boundary row moves to the main fence, and the German-ranks clause says it means the ranks the title vocabulary lists. H2: 'single-letter initial', so the T5 pointer reads in T5's terms. H5: the bound-word lead no longer points the other way from its body. 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☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Derek's decision on the gap the migration found: 'Smith, Esq. John' reads suffix 'Esq. John', as C13 says and as the parser already does. H2 gains the Precedence bullet, its Then names the exception, and decisions/H2 records it with the measured scope: of the suffix words, the 22 that start no S8 run (duals, ambiguous acronyms, abd/mc/vd) still read as a title there. Three new examples, so corpus_rules.jsonl and snapshot.jsonl each gain three names; no reading moves. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Derek's decision on the gap the migration found: H4 is about an input that holds no name word but vocabulary, while its join clause reported title-or-name for 'Smith and King' and 'Attorney General of Minnesota'. rules/H7 carries the clause verbatim save 'as well' and a dated corpus count; H4 and H7 point at each other, O5's pointer names both, decisions/H7 opens with Standing and records the split, and assign's emitter comment quotes H7 so its implemented: line holds. H7 gains examples where the clause had none, so corpus_rules.jsonl and snapshot.jsonl gain their names; no reading moves. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Oct 20, 2026
derek73
added a commit
that referenced
this pull request
Oct 21, 2026
…retired-ID guard (#761 follow-up) (#788) * Quote the bullet a citation comment names (#761 follow-up) Fourteen comments named a rule's Except or Accepted bullet by description and quoted nothing, so test_doc_citations could not check them. Each now quotes the bullet (an Except bullet by its whole bold lead, which bullet_lead_findings holds it to) beside its rule ID, says which clause the code implements or pins, and points at the decisions entry. Two named the wrong bullet: test_parser.py's 'M2 Accepted row' is M2's Except bullet on post-comma text, and test_pieces.py's 'no-comma peel's Accepted limit' is S7's. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * Add the Except-fence check to the design review's axis 3 (#761 follow-up) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * Refuse a rule file that reuses a retired rule's ID (#761 follow-up) PR #786 replaced the tombstone with 'A retired rule's decisions entry records the retirement', which left 'never reused' unenforced. A retired rule's decisions file now carries a line opening 'Retired:', and test_no_rule_reuses_a_retired_id refuses a rule file with that ID. The reader lives in tests/v2/design_docs.py. A misspelled Retired line and one in a file keyed by no rule ID are findings too, since either would switch the refusal off silently. No rule is retired yet, so the real-tree test refuses nothing; test_a_rule_file_reusing_a_retired_id_is_refused builds a synthetic decisions file and a rule file reusing its ID and is the negative control (it fails with the ID check disabled, measured). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * Address the design-docs review (#761 follow-up) - test_properties: drop the two maiden-clause pairs said to differ; measured, both spellings of each read alike since #601, and M2's bullet the new citation quoted accepts no such split. - _extract: the M3 contrast is a suffix word ('née PhD'), not V, which M2 also reads as the maiden name. - Retired: a numbered '1. Retired:' line is a misspelling too (the new row failed against the old pattern first). - docs/design/AGENTS.md axis 3: two incidents on the record (H1 in #779, S3's Msc.Ed. row in #783), not three; a row Then decides may belong under Accepted. The skip list names the new guard. - cases.py: shape 7's U+00B7 half is what the W4 Except decides. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- 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.
Part of #761.
This PR moves H1–H6 (the titles and honorifics section) from the block format to the skeleton format, one commit per rule. Later commits fix review findings and carry out Derek's two decisions (below): H2 states that C13 wins, and H4's join clause becomes H7. No parse changes, and the migration commits change no rule's meaning:
git show.tests/v2/rules_budget.jsonis re-recorded. Each H row changes format, showing as its old row beside its new one. The word counts grow because bullet leads were added; no new clause reads a new signal.Where the old clauses went
H1
Sir van Goghreads given 'van'.Prince Harryread Harry as a given name? (prince,princess,lord,ladyare titles but not given-name titles) #519), and graf/greve/herra.H2
Dr. inž. Janez Novakreadsinž.as the given name #652).H3
H4
MD DDS).Jr.).H5
Mary Jane King.).rules/H5comment in_group.py), it now says "particle chain".H6
Sta. Maria).Old
interacts:IDsH1 (old: C3 C8 O5 H3 H5 H6 P2 P3 P5 M2 S1 S2 N1 N3)
van der Berg, SirandSheik Abu Bakarcarry it.H2 (old: C5 C6 C8 S3 P4 H5 H6 W3 W4 S9 T5)
H3 (old: C1 H1 H4 H5 H6 S2)
H4 (old: H1 H2 H3 H5 S2 O5)
H5 (old: H1 H2 H3 H4 M2 P2 P5 P6 S2 C1)
H6 (old: C1 C3 H1 H2 H3 M2 P1 P2 P4 S2 W3)
Dr. de la Vega, JuanandFreiherr von Berg, Ed.Decided (Derek, 2026-10-20): the two gaps this migration found
His words: "Yes to both: C13 wins over H2 for a listed suffix word (Precedence bullet on H2, no behavior change), and H4's join clause moves to its own new H rule. Do it in PR #779."
Smith, Esq. John→ suffix "Esq. John",Smith, Insp. John→ title "Insp.",Smith, Ma. John→ title "Ma.". decisions/H2 has the dated entry.Smith, <Word>. John:Cpl.,Ms.,Sr.…), 7 ambiguous acronyms (Ma.,Do.…), andAbd.,Mc.andVd..Smith, Ma. Johnbeside it. Extending the win to all 22 would be a behavior change, and is not proposed.interacts:name H7._assign.py's emitter comment quotes H7, so H7'simplemented:holds. Twocases.pynotes now name H7.cases.py), so H7's are new.Prince of Walesis the boundary.Corpus and snapshot:
corpus_rules.jsonlandsnapshot.jsonlgain the new examples' names (3 for H2, and 6 more for H7, withAttorney General of Minnesotaalready in another corpus file). No existing reading moves (snapshot.py --recordadded names only).Review fixes
Sta. Mariarow (outside When) moves to the main fence, and the German-ranks clause now reads "German ranks the title vocabulary lists". The old wording overclaimed:Markgraf,LandgrafandFreiinare unlisted and do not peel.interacts:gains H7, and decisions/H7'sElsewhere:line is set apart from the bullet above it.Still for Derek: found in review, already on master, not fixed here
St Sir de Mesnil(family-first) → given "de Mesnil". H1's Except says a never-given particle with a word behind it keeps the family (P1's fold), anddeis one. The Accepted sentence the row stands under covers only an ambiguous or bare particle. The real reason is that a title-particle (St) opening the run stops P1's fold; decisions/H1 records it and no rule states it. Master's block text had the same mismatch.Smith, Dr King Jrreads title "Dr King", given "Smith", suffix "Jr". H3's give-back does not fire, because H1's comma-with-only-titles reading takes the input first. Whether H3's "part carrying the given name" should cover this shape is open, and I have not verified that it is a defect.Verification
uv run pytest: 22,154 passed, 123 skipped, 3 xfailed (at 4be2b4a; doc tests rerun at a839d5a).uv run mypyanduv run ruff check: clean.🤖 Generated with Claude Code