Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion EN_PHONES.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ Disclaimer: Author is an ML researcher, not a linguist, and may have butchered o
- `ʊ`: As in `wood => wˈʊd`.
- `ʌ`: As in `sun => sˈʌn`.

**Dipthong Vowels (4)**
**Diphthong Vowels (4)**
- `A`: The "eh" vowel sound, like `hey => hˈA`. Expands to `eɪ` in IPA.
- `I`: The "eye" vowel sound, like `high => hˈI`. Expands to `aɪ` in IPA.
- `W`: The "ow" vowel sound, like `how => hˌW`. Expands to `aʊ` in IPA.
Expand Down
2 changes: 1 addition & 1 deletion misaki/he.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ def __call__(self, text: str, preserve_punctuation = True, preserve_stress = Tru
"""
Convert Hebrew text to IPA
Text is expected to be with diacritics (niqqud)
Enable debug to return Word objects that contais detailed conversion information
Enable debug to return Word objects that contains detailed conversion information
"""

return mishkal.phonemize(text, preserve_punctuation=preserve_punctuation, preserve_stress=preserve_stress)
Expand Down
2 changes: 1 addition & 1 deletion misaki/tone_sandhi.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ def _yi_sandhi(self, word: str, finals: List[str]) -> List[str]:
if word.find(YI) != -1 and all(
[item.isnumeric() for item in word if item != YI]):
return finals
# "一" between reduplication words shold be yi5, e.g. 看一看
# "一" between reduplication words should be yi5, e.g. 看一看
elif len(word) == 3 and word[1] == YI and word[0] == word[-1]:
finals[1] = finals[1][:-1] + "5"
# when "一" is ordinal word, it should be yi1
Expand Down
2 changes: 1 addition & 1 deletion misaki/transcription.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@


# Duanmu (2000, p. 37) and Lin (2007, p. 68f)
# Diphtongs from Duanmu (2007, p. 40): au, əu, əi, ai
# Diphthongs from Duanmu (2007, p. 40): au, əu, əi, ai
# Diphthongs from Lin (2007, p. 68f): au̯, ou̯, ei̯, ai̯
FINAL_MAPPING: Dict[str, List[Tuple[str, ...]]] = {
"a": [("a0",)], # /
Expand Down
8 changes: 4 additions & 4 deletions misaki/vi_cleaner/datestime_vi.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def _expand_full_date(match):


def _expand_range_full_date(match):
prefix, space, day_start, hypen, day_end, seporator1, month, seporator2, year, suffix = match.groups(
prefix, space, day_start, hyphen, day_end, seporator1, month, seporator2, year, suffix = match.groups(
0)
space = "" if space == 0 else space
day_start = _remove_prefix_zero(day_start)
Expand All @@ -96,7 +96,7 @@ def _expand_day_month(match):


def _expand_range_day_month(match):
prefix, space, day_start, hypen, day_end, seporator1, month, suffix = match.groups(
prefix, space, day_start, hyphen, day_end, seporator1, month, suffix = match.groups(
0)
space = "" if space == 0 else space
day_start = _remove_prefix_zero(day_start)
Expand Down Expand Up @@ -133,13 +133,13 @@ def _expand_quarter_month_year(match):


def _expand_range_month_year(match):
prefix, space, month_start, hypen, month_end, seporator, year, suffix = match.groups(
prefix, space, month_start, hyphen, month_end, seporator, year, suffix = match.groups(
0)
space = "" if space == 0 else space
month_start = _remove_prefix_zero(month_start)
month_end = _remove_prefix_zero(month_end)
year = _remove_prefix_zero(year)
if not _is_valid_date(1, int(month_start)) or not _is_valid_date(1, int(month_end)) or hypen == seporator:
if not _is_valid_date(1, int(month_start)) or not _is_valid_date(1, int(month_end)) or hyphen == seporator:
return match.group(0)
return space + " tháng " + n2w(month_start) + " đến tháng " + n2w(month_end) + " năm " + n2w(year) + suffix + " "

Expand Down