scriptconv-copyleft 0.2.1a1__tar.gz → 0.2.2a1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/PKG-INFO +2 -2
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/pyproject.toml +1 -1
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/mul.py +4 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/version.py +1 -1
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft.egg-info/PKG-INFO +2 -2
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft.egg-info/SOURCES.txt +1 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft.egg-info/requires.txt +1 -1
- scriptconv_copyleft-0.2.2a1/tests/test_misaki_zh_zero.py +19 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/LICENSE +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/README.md +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/__init__.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/__init__.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/_vendored/__init__.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/_vendored/kog2p/COPYING +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/_vendored/kog2p/LICENSE.md +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/_vendored/kog2p/__init__.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/_vendored/kog2p/rulebook.txt +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/_vendored/reginute/COPYING +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/_vendored/reginute/LICENSE +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/_vendored/reginute/SOURCE +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/_vendored/reginute/lt_kirciai.tsv +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/_vendored/reginute/lt_kreipiniai.tsv +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/_vendored/reginute/lt_raides.tsv +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/eu.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/fa.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/gl.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/ja.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/ko.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/lt.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/readings.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft.egg-info/dependency_links.txt +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft.egg-info/top_level.txt +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/setup.cfg +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_espeak_acute_stress.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_espeak_french_english_switch.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_espeak_get_lang_case.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_espeak_lt_accent.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_lang_default_region.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_match_lang_direction.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_match_lang_preferred_value.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_misaki_ja_reader.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_phonemizers_base.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_phonemizers_cjk_ar.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_phonemizers_friendly_import_errors.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_phonemizers_identity.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_phonemizers_misaki_british.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_phonemizers_punctuation.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_readings.py +0 -0
- {scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_transphone_extra_declares_auto_installs.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: scriptconv-copyleft
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.2a1
|
|
4
4
|
Summary: scriptconv phonemizer backends whose code or dependencies are copyleft (GPL, LGPL, AGPL)
|
|
5
5
|
Author-email: TigreGotico <contact@tigregotico.com>
|
|
6
6
|
License-Expression: Apache-2.0 AND GPL-3.0-only AND CC-BY-4.0
|
|
@@ -67,7 +67,7 @@ Requires-Dist: pykakasi<3,>=2.3; extra == "test"
|
|
|
67
67
|
Requires-Dist: epitran>=1.26.1; extra == "test"
|
|
68
68
|
Requires-Dist: g2pk; python_version < "3.13" and extra == "test"
|
|
69
69
|
Requires-Dist: regex; extra == "test"
|
|
70
|
-
Requires-Dist: misaki[en,ko]; python_version < "3.13" and extra == "test"
|
|
70
|
+
Requires-Dist: misaki[en,ko,zh]; python_version < "3.13" and extra == "test"
|
|
71
71
|
Requires-Dist: fugashi; python_version < "3.13" and extra == "test"
|
|
72
72
|
Requires-Dist: jaconv; python_version < "3.13" and extra == "test"
|
|
73
73
|
Requires-Dist: mojimoji; python_version < "3.13" and extra == "test"
|
|
@@ -42,7 +42,7 @@ fa = ["persian_phonemizer", "hazm>=0.10", "spacy>=3.7,<4.0"]
|
|
|
42
42
|
ja = ["pykakasi>=2.3,<3"]
|
|
43
43
|
ja-phonemizers = ["pykakasi>=2.3,<3"]
|
|
44
44
|
ko = ["g2pk; python_version<'3.13'", "regex"]
|
|
45
|
-
test = ["pytest", "pytest-timeout", "espyak", "pycotovia", "ahotts_g2p", "pykakasi>=2.3,<3", "epitran>=1.26.1", "g2pk; python_version<'3.13'", "regex", "misaki[en,ko]; python_version<'3.13'", "fugashi; python_version<'3.13'", "jaconv; python_version<'3.13'", "mojimoji; python_version<'3.13'", "unidic-lite; python_version<'3.13'", "spacy>=3.7,<4.0; python_version<'3.13'", "linguatag[langcodes]>=0.2.3a1", "packaging", "pyopenjtalk-plus[onnxruntime]>=0.4.1.post10"]
|
|
45
|
+
test = ["pytest", "pytest-timeout", "espyak", "pycotovia", "ahotts_g2p", "pykakasi>=2.3,<3", "epitran>=1.26.1", "g2pk; python_version<'3.13'", "regex", "misaki[en,ko,zh]; python_version<'3.13'", "fugashi; python_version<'3.13'", "jaconv; python_version<'3.13'", "mojimoji; python_version<'3.13'", "unidic-lite; python_version<'3.13'", "spacy>=3.7,<4.0; python_version<'3.13'", "linguatag[langcodes]>=0.2.3a1", "packaging", "pyopenjtalk-plus[onnxruntime]>=0.4.1.post10"]
|
|
46
46
|
|
|
47
47
|
[project.urls]
|
|
48
48
|
Homepage = "https://github.com/TigreGotico/scriptconv-copyleft"
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/mul.py
RENAMED
|
@@ -514,6 +514,10 @@ class MisakiPhonemizer(BasePhonemizer):
|
|
|
514
514
|
|
|
515
515
|
def phonemize_string(self, text: str, lang: str) -> str:
|
|
516
516
|
pho = self._get_phonemizer(lang)
|
|
517
|
+
if self.get_lang(lang) == "zh":
|
|
518
|
+
# misaki's zh front end keeps the zero sign 〇 (U+3007) as a symbol. Wiktionary, "〇", Chinese: "Used to
|
|
519
|
+
# express a zero digit in a number", with the sense of 零, so it reads as 零.
|
|
520
|
+
text = text.replace("\u3007", "零")
|
|
517
521
|
phonemes, tokens = pho(text)
|
|
518
522
|
return phonemes
|
|
519
523
|
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft.egg-info/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: scriptconv-copyleft
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.2a1
|
|
4
4
|
Summary: scriptconv phonemizer backends whose code or dependencies are copyleft (GPL, LGPL, AGPL)
|
|
5
5
|
Author-email: TigreGotico <contact@tigregotico.com>
|
|
6
6
|
License-Expression: Apache-2.0 AND GPL-3.0-only AND CC-BY-4.0
|
|
@@ -67,7 +67,7 @@ Requires-Dist: pykakasi<3,>=2.3; extra == "test"
|
|
|
67
67
|
Requires-Dist: epitran>=1.26.1; extra == "test"
|
|
68
68
|
Requires-Dist: g2pk; python_version < "3.13" and extra == "test"
|
|
69
69
|
Requires-Dist: regex; extra == "test"
|
|
70
|
-
Requires-Dist: misaki[en,ko]; python_version < "3.13" and extra == "test"
|
|
70
|
+
Requires-Dist: misaki[en,ko,zh]; python_version < "3.13" and extra == "test"
|
|
71
71
|
Requires-Dist: fugashi; python_version < "3.13" and extra == "test"
|
|
72
72
|
Requires-Dist: jaconv; python_version < "3.13" and extra == "test"
|
|
73
73
|
Requires-Dist: mojimoji; python_version < "3.13" and extra == "test"
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft.egg-info/SOURCES.txt
RENAMED
|
@@ -36,6 +36,7 @@ tests/test_lang_default_region.py
|
|
|
36
36
|
tests/test_match_lang_direction.py
|
|
37
37
|
tests/test_match_lang_preferred_value.py
|
|
38
38
|
tests/test_misaki_ja_reader.py
|
|
39
|
+
tests/test_misaki_zh_zero.py
|
|
39
40
|
tests/test_phonemizers_base.py
|
|
40
41
|
tests/test_phonemizers_cjk_ar.py
|
|
41
42
|
tests/test_phonemizers_friendly_import_errors.py
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"""misaki zh reads the zero sign 〇 (U+3007) as it reads 零.
|
|
2
|
+
|
|
3
|
+
Wiktionary, "〇", Chinese: "Used to express a zero digit in a number", with the sense of 零. The expected phonemes
|
|
4
|
+
are the ones misaki gives for the same text written with 零."""
|
|
5
|
+
import sys
|
|
6
|
+
|
|
7
|
+
import pytest
|
|
8
|
+
|
|
9
|
+
from scriptconv_copyleft.phonemizers.mul import MisakiPhonemizer, MisakiZhPhonemizer
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
@pytest.mark.skipif(sys.version_info >= (3, 13), reason="misaki declares Requires-Python <3.13")
|
|
13
|
+
@pytest.mark.parametrize("cls", [MisakiZhPhonemizer, MisakiPhonemizer])
|
|
14
|
+
@pytest.mark.parametrize("text", ["二〇二四", "〇 〇 七", "電話是五五五〇一〇〇。"])
|
|
15
|
+
def test_the_zero_sign_reads_as_zero(cls, text):
|
|
16
|
+
phonemizer = cls()
|
|
17
|
+
spoken = phonemizer.phonemize_string(text, "zh")
|
|
18
|
+
assert "〇" not in spoken
|
|
19
|
+
assert spoken == phonemizer.phonemize_string(text.replace("〇", "零"), "zh")
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/eu.py
RENAMED
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/fa.py
RENAMED
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/gl.py
RENAMED
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/ja.py
RENAMED
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/ko.py
RENAMED
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/scriptconv_copyleft/phonemizers/lt.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_espeak_acute_stress.py
RENAMED
|
File without changes
|
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_espeak_get_lang_case.py
RENAMED
|
File without changes
|
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_lang_default_region.py
RENAMED
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_match_lang_direction.py
RENAMED
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_match_lang_preferred_value.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_phonemizers_cjk_ar.py
RENAMED
|
File without changes
|
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_phonemizers_identity.py
RENAMED
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_phonemizers_misaki_british.py
RENAMED
|
File without changes
|
{scriptconv_copyleft-0.2.1a1 → scriptconv_copyleft-0.2.2a1}/tests/test_phonemizers_punctuation.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|