tetos


Nametetos JSON
Version 0.2.1 PyPI version JSON
download
home_pageNone
SummaryUnified interface for multiple Text-to-Speech (TTS) providers
upload_time2024-04-23 03:39:04
maintainerNone
docs_urlNone
authorNone
requires_python>=3.8
licenseApache-2.0
keywords tts text-to-speech speech audio ai nlp
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # TeToS
<!--index start-->

[![PyPI](https://img.shields.io/pypi/v/tetos)](https://pypi.org/project/tetos/)
[![Python](https://img.shields.io/pypi/pyversions/tetos)](https://pypi.org/project/tetos/)
[![License](https://img.shields.io/pypi/l/tetos)](https://www.apache.org/licenses/LICENSE-2.0)
[![Downloads](https://pepy.tech/badge/tetos)](https://pepy.tech/project/tetos)
[![Documentation Status](https://readthedocs.org/projects/tetos/badge/?version=latest)](https://tetos.readthedocs.io/latest/?badge=latest)

A unified interface for multiple Text-to-Speech (TTS) providers.


## Supported TTS providers

- [Edge-TTS](https://github.com/rany2/edge-tts)
- [OpenAI TTS](https://platform.openai.com/docs/guides/text-to-speech)

  Required parameters:

  - `api_key`: OpenAI API key

- [Azure TTS](https://docs.microsoft.com/en-us/azure/cognitive-services/speech-service/text-to-speech)

  Required parameters(Please refer to the documentation to get the secrets):

  - `speech_key`: Azure Speech service key
  - `speech_region`: Azure Speech service region

- [Google TTS](https://cloud.google.com/text-to-speech?hl=zh-CN)

  Requirements:

  - [Enable the Text-to-Speech API in the Google Cloud Console](https://console.developers.google.com/apis/api/texttospeech.googleapis.com/overview?project=586547753837)
  - Environment variables `GOOGLE_APPLICATION_CREDENTIALS` pointing to the service account key file

- [Volcengine TTS(火山引擎)](https://console.volcengine.com/sami)

  Required parameters:

  - `access_key`: Volcengine access key ID. ([Get it here](https://console.volcengine.com/iam/keymanage/))
  - `secret_key`: Volcengine access secret key. ([Get it here](https://console.volcengine.com/iam/keymanage/))
  - `app_key`: Volcengine app key

- [Baidu TTS](https://ai.baidu.com/tech/speech/tts)

  Required parameters:

  - `api_key`: Baidu API key
  - `secret_key`: Baidu secret key

  [Get both at the console](https://console.bce.baidu.com/ai/#/ai/speech/app/list)

- [Minimax TTS](https://www.minimaxi.com/document/speech-synthesis-engine?id=645e034eeb82db92fba9ac20)

  Required parameters:

  - `api_key`: Minimax API key
  - `group_id`: Minimax group ID

  Get both at the [Minimax console](https://www.minimaxi.com/user-center/basic-information)


## Installation

Requires Python 3.8 or higher.

```bash
pip install tetos
```

## CLI Usage

```
tetos PROVIDER [PROVIDER_OPTIONS] TEXT [--output FILE]
```

Please run `tetos --help` for available providers and options.

Examples

```
tetos google "Hello, world!"
tetos azure "Hello, world!" --output output.mp3   # save to another file
tetos edge --lang zh-CN "你好,世界!"  # specify language
tetos openai --voice echo "Hello, world!"  # specify voice
```

## API Usage

Use Azure TTS as an example:

```python
from tetos.azure import AzureSpeaker

speaker = AzureSpeaker(speech_key='...', speech_region='...')
speaker.say('Hello, world!', 'output.mp3')
```

The initialization parameters may be different for other providers.

## Behind a proxy

TeTos respects the proxy environment variables `HTTP_PROXY`, `HTTPS_PROXY`, `ALL_PROXY` and `NO_PROXY`.

## TODO

- [x] Google TTS
- [ ] SSML support

## License

[Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0)

<!--index end-->

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "tetos",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "tts, text-to-speech, speech, audio, ai, nlp",
    "author": null,
    "author_email": "Frost Ming <me@frostming.com>",
    "download_url": "https://files.pythonhosted.org/packages/37/11/69293e702f9d572d909b3ef2355099de4ef5866aab69f260045817fb3a16/tetos-0.2.1.tar.gz",
    "platform": null,
    "description": "# TeToS\n<!--index start-->\n\n[![PyPI](https://img.shields.io/pypi/v/tetos)](https://pypi.org/project/tetos/)\n[![Python](https://img.shields.io/pypi/pyversions/tetos)](https://pypi.org/project/tetos/)\n[![License](https://img.shields.io/pypi/l/tetos)](https://www.apache.org/licenses/LICENSE-2.0)\n[![Downloads](https://pepy.tech/badge/tetos)](https://pepy.tech/project/tetos)\n[![Documentation Status](https://readthedocs.org/projects/tetos/badge/?version=latest)](https://tetos.readthedocs.io/latest/?badge=latest)\n\nA unified interface for multiple Text-to-Speech (TTS) providers.\n\n\n## Supported TTS providers\n\n- [Edge-TTS](https://github.com/rany2/edge-tts)\n- [OpenAI TTS](https://platform.openai.com/docs/guides/text-to-speech)\n\n  Required parameters:\n\n  - `api_key`: OpenAI API key\n\n- [Azure TTS](https://docs.microsoft.com/en-us/azure/cognitive-services/speech-service/text-to-speech)\n\n  Required parameters(Please refer to the documentation to get the secrets):\n\n  - `speech_key`: Azure Speech service key\n  - `speech_region`: Azure Speech service region\n\n- [Google TTS](https://cloud.google.com/text-to-speech?hl=zh-CN)\n\n  Requirements:\n\n  - [Enable the Text-to-Speech API in the Google Cloud Console](https://console.developers.google.com/apis/api/texttospeech.googleapis.com/overview?project=586547753837)\n  - Environment variables `GOOGLE_APPLICATION_CREDENTIALS` pointing to the service account key file\n\n- [Volcengine TTS(\u706b\u5c71\u5f15\u64ce)](https://console.volcengine.com/sami)\n\n  Required parameters:\n\n  - `access_key`: Volcengine access key ID. ([Get it here](https://console.volcengine.com/iam/keymanage/))\n  - `secret_key`: Volcengine access secret key. ([Get it here](https://console.volcengine.com/iam/keymanage/))\n  - `app_key`: Volcengine app key\n\n- [Baidu TTS](https://ai.baidu.com/tech/speech/tts)\n\n  Required parameters:\n\n  - `api_key`: Baidu API key\n  - `secret_key`: Baidu secret key\n\n  [Get both at the console](https://console.bce.baidu.com/ai/#/ai/speech/app/list)\n\n- [Minimax TTS](https://www.minimaxi.com/document/speech-synthesis-engine?id=645e034eeb82db92fba9ac20)\n\n  Required parameters:\n\n  - `api_key`: Minimax API key\n  - `group_id`: Minimax group ID\n\n  Get both at the [Minimax console](https://www.minimaxi.com/user-center/basic-information)\n\n\n## Installation\n\nRequires Python 3.8 or higher.\n\n```bash\npip install tetos\n```\n\n## CLI Usage\n\n```\ntetos PROVIDER [PROVIDER_OPTIONS] TEXT [--output FILE]\n```\n\nPlease run `tetos --help` for available providers and options.\n\nExamples\n\n```\ntetos google \"Hello, world!\"\ntetos azure \"Hello, world!\" --output output.mp3   # save to another file\ntetos edge --lang zh-CN \"\u4f60\u597d\uff0c\u4e16\u754c\uff01\"  # specify language\ntetos openai --voice echo \"Hello, world!\"  # specify voice\n```\n\n## API Usage\n\nUse Azure TTS as an example:\n\n```python\nfrom tetos.azure import AzureSpeaker\n\nspeaker = AzureSpeaker(speech_key='...', speech_region='...')\nspeaker.say('Hello, world!', 'output.mp3')\n```\n\nThe initialization parameters may be different for other providers.\n\n## Behind a proxy\n\nTeTos respects the proxy environment variables `HTTP_PROXY`, `HTTPS_PROXY`, `ALL_PROXY` and `NO_PROXY`.\n\n## TODO\n\n- [x] Google TTS\n- [ ] SSML support\n\n## License\n\n[Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0)\n\n<!--index end-->\n",
    "bugtrack_url": null,
    "license": "Apache-2.0",
    "summary": "Unified interface for multiple Text-to-Speech (TTS) providers",
    "version": "0.2.1",
    "project_urls": {
        "Documentation": "https://tetos.readthedocs.io/latest/",
        "Repository": "https://github.com/frostming/tetos"
    },
    "split_keywords": [
        "tts",
        " text-to-speech",
        " speech",
        " audio",
        " ai",
        " nlp"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "48a89f4f4d9e002b526a91de73fc6ad6683a4fe04591ae1deed6563ed1c49ea6",
                "md5": "e7fd0bee3c8c5de8c2c5f9f47b82703b",
                "sha256": "d4a2ed572c32ed5036939b73e28b13b482161c295b6dcc9c6eacdb4f79aeb72b"
            },
            "downloads": -1,
            "filename": "tetos-0.2.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "e7fd0bee3c8c5de8c2c5f9f47b82703b",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 23146,
            "upload_time": "2024-04-23T03:39:02",
            "upload_time_iso_8601": "2024-04-23T03:39:02.923488Z",
            "url": "https://files.pythonhosted.org/packages/48/a8/9f4f4d9e002b526a91de73fc6ad6683a4fe04591ae1deed6563ed1c49ea6/tetos-0.2.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "371169293e702f9d572d909b3ef2355099de4ef5866aab69f260045817fb3a16",
                "md5": "653de110a7dc88921f4b13fcc934c196",
                "sha256": "cac0647495e517839ae16fb1a6f38b14a1dc310797dd58bb26751309701ff305"
            },
            "downloads": -1,
            "filename": "tetos-0.2.1.tar.gz",
            "has_sig": false,
            "md5_digest": "653de110a7dc88921f4b13fcc934c196",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 20185,
            "upload_time": "2024-04-23T03:39:04",
            "upload_time_iso_8601": "2024-04-23T03:39:04.449498Z",
            "url": "https://files.pythonhosted.org/packages/37/11/69293e702f9d572d909b3ef2355099de4ef5866aab69f260045817fb3a16/tetos-0.2.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-04-23 03:39:04",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "frostming",
    "github_project": "tetos",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "tetos"
}
        
Elapsed time: 0.23714s