Support aligning input that's already in IPA (e.g. eng-ipa)
Summary
readalongs align currently rejects IPA input. If you have a text file
that's already been g2p'ed into IPA (for example by a g2p engine that
isn't supported by g2p), there's no way to align it. We should support
-l eng-ipa (and other *-ipa langs) as valid alignment input.
Cause
get_arpabet_langs() in g2p/__init__.py explicitly filters out any
lang ending in -ipa, so these are never offered as valid inputs.
Proof of concept
Removing if not x.endswith("-ipa") in g2p/__init__.py makes readalongs align -l eng-ipa
work (confirmed working against a sandbox install of g2p)
Concerns for a proper solution
Simply un-filtering *-ipa langs pollutes readalongs langs, which
would then list every *-ipa variant (many with poor display names like
IPA, crg-ipa, crk-ipa). Ideally we'd accept *-ipa inputs
without listing them all in readalongs langs.
Priority
Low/medium
Support aligning input that's already in IPA (e.g.
eng-ipa)Summary
readalongs aligncurrently rejects IPA input. If you have a text filethat's already been g2p'ed into IPA (for example by a g2p engine that
isn't supported by
g2p), there's no way to align it. We should support-l eng-ipa(and other*-ipalangs) as valid alignment input.Cause
get_arpabet_langs()ing2p/__init__.pyexplicitly filters out anylang ending in
-ipa, so these are never offered as valid inputs.Proof of concept
Removing
if not x.endswith("-ipa")ing2p/__init__.pymakesreadalongs align -l eng-ipawork (confirmed working against a sandbox install of
g2p)Concerns for a proper solution
Simply un-filtering
*-ipalangs pollutesreadalongs langs, whichwould then list every
*-ipavariant (many with poor display names likeIPA,crg-ipa,crk-ipa). Ideally we'd accept*-ipainputswithout listing them all in
readalongs langs.Priority
Low/medium