{"id":17347865,"url":"https://github.com/floriansw/tts2php","last_synced_at":"2025-07-05T16:33:19.919Z","repository":{"id":88742363,"uuid":"76692198","full_name":"FlorianSW/tts2php","owner":"FlorianSW","description":"WebTTS Service based on pico2wave and php","archived":false,"fork":false,"pushed_at":"2016-12-17T17:44:33.000Z","size":14,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-01T15:45:48.781Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/FlorianSW.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-12-16T23:20:58.000Z","updated_at":"2016-12-17T17:27:08.000Z","dependencies_parsed_at":null,"dependency_job_id":"443ae1e9-7aa8-44bb-926a-cb764d2a56fe","html_url":"https://github.com/FlorianSW/tts2php","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FlorianSW%2Ftts2php","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FlorianSW%2Ftts2php/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FlorianSW%2Ftts2php/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FlorianSW%2Ftts2php/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/FlorianSW","download_url":"https://codeload.github.com/FlorianSW/tts2php/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245832753,"owners_count":20679704,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-15T16:50:22.794Z","updated_at":"2025-03-27T11:21:37.702Z","avatar_url":"https://github.com/FlorianSW.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# tts2php\nThis WebTTS service is mostly based on the idea of https://github.com/openhab/openhab/wiki/Use-local-TTS-with-squeezebox and is a\nbit extended. It now also uses caching, so that not each request has to be transformed using the configured TTS binary again. It\nalso now supports different TTS and encoding binaries (default is pico2wave and sox).\n\n# Requirements\n* A TTS binary on your machine, where the script should run, e.g. pico2wave (pre-configured, you just need to install the binary, e.g.\n  `apt-get install libttspico-utils`)\n* A webserver (e.g. nginx)\n* php (\u003e= 5.4)\n* composer\n* (optional) An object cache, like redis (redis is the only one implemented in this repository for now)\n\n# Installation\nSimply clone or download and unpack this repository to your webserver and run `composer update` to fetch the latest versions of all\nneeded dependencies. That's basically it. However, you need to install at least one TTS Service and, if it doesn't output mp3 files\ndirectly, an encoder (such as sox) to generate an mp3 file from the resulting file of your TTS Service. E.g. the following steps are needed\nto setup this script with pico2wave and sox:\n\n* Install pico2wave: `apt-get install libttspico-utils`\n* Install sox and the mp3 library: `apt-get install libsox-fmt-mp3`\n* Install redis-server for caching: `apt-get install redis-server`\n* Clone this repository\n* Copy the configuration file `config-default.php` to `config.php`\n* Review the settings in `config.php`, especially:\n * `defaultLanguage`: If no `lang` parameter is passed to the URL of this script, this is the language code, which will be used by\n    default to transform the text into audio. The value depends on the supported language codes of the TTS binary.\n * `ttsService` -\u003e `serviceBinary`: The location of the binary will be called directly by this script, so it must exist.\n * `encoderService`: Review the parameters passed to sox to make sure they make sense for your use case. See the manpage of sox for other\n   allowed parameters.\n * `objectCache` -\u003e `arguments`: The named arguments here will be passed directly to the `predis` redis client, see https://packagist.org/packages/predis/predis\n   to learn the allowed values. Especially authentication data must be provided, if your redis-server needs authentication.\n\nRequest the script to convert text to audio: http://\u003cyour-host\u003e:\u003cyour-port\u003e/path/to/index.php?msg=Hello%20World!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffloriansw%2Ftts2php","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffloriansw%2Ftts2php","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffloriansw%2Ftts2php/lists"}