PyThaiNLP / pythainlp

Thai Natural Language Processing in Python.
https://pythainlp.org/
Apache License 2.0
975 stars 272 forks source link

docs: clarify output of tone_detector #918

Closed kristw closed 3 months ago

kristw commented 3 months ago

Description

อยากให้ช่วยอธิบาย output ของ function tone_detector ใน util เพิ่มเติมครับ ผมไม่คุ้นเคยกับตัวย่อพวกนี้มากนักเลยไม่แน่ใจว่า l, m, h, r, f คือเสียงอะไรบ้าง

Expected results

updated docstring

Current results

def tone_detector(syllable: str) -> str:
    """
    Thai tone detector for syllables

    :param str syllable: Thai syllable
    :return: syllable's tone (l, m, h, r, f or empty if it cannot be detected)
    :rtype: str

Steps to reproduce

open the code

PyThaiNLP version

current

Python version

3.8

Operating system and version

OS X Sonoma 14.5

More info

No response

Possible solution

No response

Files

No response

github-actions[bot] commented 3 months ago

Hello @kristw, thank you for your interest in our work!

If this is a bug report, please provide screenshots and minimum viable code to reproduce your issue, otherwise we can not help you.

wannaphong commented 3 months ago

เป็น Tonal Composition of Thai Syllables ครับ สามารถอ่านเพิ่มเติมได้ที่ http://www.thai-language.com/ref/tone-rules ครับ

kristw commented 3 months ago

ขอบคุณครับ