Phonemizer

Latest version: v3.3.0

Safety actively analyzes 681812 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 3

3.3.0

**This version depends on python>=3.8 (was >=3.6 in previous versions). Tests now requires pytest>=6.0**

* improvements

* Replaced dependency to deprecated `pkg_resources` by `importlib` (requires `python>=3.8`).
* Replaced deprecated `setup.py` by `pyproject.toml`.

* bug fix

* `espeak` backend: words mismatch now works when using custom word separators. See [issue 169](https://github.com/bootphon/phonemizer/issues/169).

3.2.1

* **bug fixes**

* Fixed a bug when trying to restore punctuation on a multiline text.
See issue 129

3.2.0

* **bug fixes**

* Fixed a bug when trying to restore punctuation on very long text.
See 108

* **improvements**

* Improved consistency with the handling of word separators when
preserving punctuation, and when using a word separator that is
not a literal space character. See
106

* **new features**

* Added the option to define punctuation with a regular expression.
Previously only strings were accepted. See 120

* In the python API, the ``punctuation_marks`` parameter can now be
passed to ``phonemize`` (or a backend constructor) as a ``re.Pattern``
that defines which characters will be matched as punctuation.
Passing ``punctuation_marks`` as a str will continue to function as
before, treating each character in the string as a punctuation mark.

* Added the optional parameter ``--punctuation_marks_is_regex`` to the CLI
interface. When used, the CLI will attempt to compile a ``re.Pattern``
from the value passed to ``--punctuation-marks``.

3.1.1

ChangeLog

* **improvements**

* Preserve empty lines in texts when using `--preserve-empty-lines`.
Without this option, empty lines used to be automatically dropped.
See [PR 103](https://github.com/bootphon/phonemizer/pull/103)

* **new features**

* Type hinted most of `phonemizer`'s API. This makes the usage of our API
a bit clearer, and can be easily leveraged by IDE's and type checkers to
prevent typing issues.

3.0.1

ChangeLog

* **improvements** in README after JOSS reviews

* **bug fixes**

* The method `BaseBackend.phonemize` now raises a `RuntimeError` if the input text is a str instead of a list of of str (was only logging an error message).

* Preserve punctuation alignement when using `--preserve-punctuation`, was inserting a space before each punctuation token, see [issue 97](https://github.com/bootphon/phonemizer/issues/97).

3.0

breaking change

* Do not remove empty lines from output. For example:

python
this is now
phonemize(["hello", "!??"]) == ['həloʊ ', '']
this was
phonemize(["hello", "!??"]) == ['həloʊ ']


* Default backend in the `phonemize` function is now `espeak` (was `festival`).

* `espeak-mbrola` backend now requires `espeak>=1.49`.

* `--espeak-path` option renamed as `--espeak-library`and `PHONEMIZER_ESPEAK_PATH` environment variable renamed as `PHONEMIZER_ESPEAK_LIBRARY`.

* `--festival-path` option renamed as `--festival-executable` and `PHONEMIZER_FESTIVAL_PATH` environment variable renamed as `PHONEMIZER_FESTIVAL_EXECUTABLE`.

* The methods `backend.phonemize()` from the backend classes take only a list of str a input text (was either a str or a list of str).

* The methods `backend.version()` from the backend classes returns a tuple of int instead of a str.

improvements

* `espeak` and `mbrola` backends now rely on the `espeak` shared library using the `ctypes` Python module, instead of reliying on the `espeak` executable through subprocesses. This implies drastic speed improvments, up to 40 times faster.

new features

* New option `--prepend-text` to prepend the input text to phonemized utterances, so as to have both orthographic and phonemized available at output.

* New option `--tie` for the `espeak` backend to display a tie character within multi-letter phonemes. (see issue [74](https://github.com/bootphon/phonemizer/issues/74)).

* New option `--words-mismatch` for the `espeak` backend. This allows to detect when espeak merge consecutive words or drop a word from the orthographic text. Possible actions are to ignore those misatches, to issue a warning for each line where a mismatch is detectd, or to remove those lines from the output.

bugfixes

* phonemizer's logger no more conflicts with other loggers when imported from Python (see PR [61](https://github.com/bootphon/phonemizer/pull/61)).

Page 1 of 3

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.