Repository navigation
Description
A part-of-speech-scoped deletion rule makes metathesis words of another part of speech unparseable. Forward generation still produces them, so ParseWord is incomplete.
Repro
Start from conformance fixture languages/metathesis-phase-isolation (PR #480, 3421588; now languages/metathesis-phase-isolation in the conformance suite) and add one deletion rule to the surface Morphology stratum, scoped to a part of speech that no metathesis word uses:
<PhonologicalRule id="prHDel">
<PhoneticInput><PhoneticSequence><SimpleContext naturalClass="ncH" /></PhoneticSequence></PhoneticInput>
<PhonologicalSubrules>
<PhonologicalSubrule requiredPartsOfSpeech="posRedup">
<PhoneticOutput><PhoneticSequence /></PhoneticOutput>
<Environment>
<LeftEnvironment><PhoneticTemplate><PhoneticSequence><SimpleContext naturalClass="ncVowel" /></PhoneticSequence></PhoneticTemplate></LeftEnvironment>
<RightEnvironment><PhoneticTemplate><PhoneticSequence><SimpleContext naturalClass="ncVowel" /></PhoneticSequence></PhoneticTemplate></RightEnvironment>
</Environment>
</PhonologicalSubrule>
</PhonologicalSubrules>
</PhonologicalRule>(ncH = <SegmentNaturalClass id="ncH"><Segment segment="cH" /></SegmentNaturalClass>; add prHDel to the Morphology stratum's phonologicalRules.)
| Word | Root stratum / POS | Expected | Got |
|---|---|---|---|
nui |
SimpleMeta / posSimpleMeta | NIU |
none |
mu+i |
ComplexMeta / posComplexMeta | MI+3SGU |
none |
Both words still generate forward (they are in the fixture's expected set, and removing prHDel restores them). The rule can never apply to either word in synthesis: wrong part of speech, and their roots live in deeper strata.
What seems to happen
Unapplying the deletion inserts an optional h between every vowel pair, before the part of speech is known, so n u (h) i. The deeper strata's metathesis rules then fail to match u–i adjacency across that optional node, so neither the (h)-present nor the (h)-absent reading reaches the metathesis unapplication. The optional node should be skippable, as it is for rewrite rules.
Notes
- Found while adding reduplication × phonology cases for Prune reduplication matches whose copies cannot agree #519. The fixture now uses
V _ aso it doesn't hit this. - It is independent of Prune reduplication matches whose copies cannot agree #519; master fails the same way.
- Scope unknown: any POS-scoped deletion in a shallower stratum may block metathesis in deeper ones.
Activity
docs(divergences): 049 copy-agreement prune, 050 shared POS-scoped de…
johnml1135 commentedon Oct 28, 2026
PanGloss now parses nui and mu+i with the V_V prHDel variant by letting metathesis analysis match across optional nodes recovered by another rule's unapplication (skip optional nodes between the switch groups; union applied to mandatory nodes only). Fixture: PanGloss conformance-staging/edge-cases/pos-scoped-deletion-blocks-metathesis (grammar + words; hc-conformance on master c245476 fails exactly those two words, NIU|nui and MI+3SGU|mu+?i). Expected parses are hand-derived from forward generation: NIU "niu" + mrSimpleMeta -> "nui"; MI "mi" + 3SGU "+u" -> "mi+u" -> mrComplexMeta -> "mu+i". AnalysisMetathesisRuleSpec's pattern puts the group nodes adjacent, so the inserted optional h breaks the match.
🤖 Generated with Claude Code (drafted by Claude, approved by John Lambert)