Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consonant descriptions missing manner #11

Open
trenslow opened this issue Feb 25, 2022 · 0 comments
Open

Consonant descriptions missing manner #11

trenslow opened this issue Feb 25, 2022 · 0 comments

Comments

@trenslow
Copy link

Hi,

I recently stumbled on this project and I have to say I'm quite impressed. It's a fresh take on all the other projects related to IPA in Python. Keep it up!

One thing I noticed while playing around was that in the consonant descriptions, we don't see the manner of articulation, neither from the command line nor when calling it from code. For example:

## command line
python -m gruut_ipa describe 'f' | jq .
{
  "text": "f",
  "letters": "f",
  "tone": "",
  "tones": [],
  "accents": [],
  "stress": "",
  "type": "Consonant",
  "place": "labio-dental",
  "voiced": false,
  "nasalated": [],
  "raised": [],
  "elongated": false
}

## from python script
gruut_ipa.Phoneme('f').to_dict()
{'text': 'f',
 'letters': 'f',
 'tone': '',
 'tones': [],
 'accents': [],
 'stress': '',
 'type': 'Consonant',
 'place': 'labio-dental',
 'voiced': False,
 'nasalated': [],
 'raised': [],
 'elongated': False}

I can tell the information is there if I call the consonant object, it just seems like the information is lost when converting this object to the dict/json output.

gruut_ipa.Phoneme('f').consonant
Consonant(ipa='f', type=<ConsonantType.FRICATIVE: 'fricative'>, place=<ConsonantPlace.LABIO_DENTAL: 'labio-dental'>, voiced=False, velarized=False, sounds_like=<ConsonantSoundsLike.NONE: ''>, length=<PhonemeLength.NORMAL: 'normal'>, alias_of=None)

I think it has to do with the code in the main file calling for the 'type' of the consonant object, but I'm not in a position to debug it at the moment. The internal type is fricative and the python type is Consonant. This could be fixed by example by referring to the consonant 'type' as the consonant 'manner', which is in line with IPA standards.

Looking forward to your feedback. Thanks again for the awesome tool!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant