{"id":18077337,"url":"https://github.com/parisneo/parler-tts-fastapi","last_synced_at":"2026-03-05T12:02:07.182Z","repository":{"id":255269393,"uuid":"849069102","full_name":"ParisNeo/parler-tts-fastapi","owner":"ParisNeo","description":null,"archived":false,"fork":false,"pushed_at":"2024-08-29T09:54:20.000Z","size":37,"stargazers_count":6,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-06T00:41:40.329Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ParisNeo.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":"2024-08-28T23:21:05.000Z","updated_at":"2025-01-25T08:30:58.000Z","dependencies_parsed_at":null,"dependency_job_id":"79f66b83-70e2-4d03-a1e9-6b45dfd19ebc","html_url":"https://github.com/ParisNeo/parler-tts-fastapi","commit_stats":null,"previous_names":["parisneo/parler-tts-fastapi"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ParisNeo/parler-tts-fastapi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ParisNeo%2Fparler-tts-fastapi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ParisNeo%2Fparler-tts-fastapi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ParisNeo%2Fparler-tts-fastapi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ParisNeo%2Fparler-tts-fastapi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ParisNeo","download_url":"https://codeload.github.com/ParisNeo/parler-tts-fastapi/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ParisNeo%2Fparler-tts-fastapi/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30123729,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-05T11:11:57.947Z","status":"ssl_error","status_checked_at":"2026-03-05T11:11:29.001Z","response_time":93,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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-31T11:24:07.821Z","updated_at":"2026-03-05T12:02:07.167Z","avatar_url":"https://github.com/ParisNeo.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Parler-TTS-FastAPI\n\n![Python](https://img.shields.io/badge/Python-3.7%2B-blue)\n![FastAPI](https://img.shields.io/badge/FastAPI-0.68.0%2B-green)\n![License](https://img.shields.io/badge/License-Apache%202.0-blue)\n![Version](https://img.shields.io/badge/Version-1.1-brightgreen)\n[![GitHub issues](https://img.shields.io/github/issues/ParisNeo/parler-tts-fastapi)](https://github.com/ParisNeo/parler-tts-fastapi/issues)\n[![GitHub stars](https://img.shields.io/github/stars/ParisNeo/parler-tts-fastapi)](https://github.com/ParisNeo/parler-tts-fastapi/stargazers)\n\n## Project Overview\n- **Author**: ParisNeo (Research Engineer)\n- **Version**: 1.1\n- **Description**: This project implements a FastAPI-based web service for the Parler-TTS (Text-to-Speech) model. It provides endpoints for generating speech from text input, supporting both single-request and streaming responses. The API can output audio in base64 encoded format or as WAV files.\n\n## Key Features\n- Text-to-speech generation with customizable voice descriptions\n- Streaming capability for processing longer texts\n- Support for base64 and WAV output formats\n- GPU acceleration support\n- Sentence-by-sentence processing for streaming responses\n- FastAPI server with automatic Swagger UI documentation\n\n## Requirements\n- Python 3.7+\n- FastAPI\n- Uvicorn\n- PyTorch\n- Parler-TTS\n- Transformers\n- SoundFile\n- Pydantic\n- NLTK\n\n## Installation\n\n1. Install PyTorch with CUDA support (if available):\n   ```\n   pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu121 --upgrade\n   ```\n\n2. Install the required dependencies:\n   ```\n   pip install -r requirements.txt\n   ```\n\n## Usage\n\n1. Start the server:\n   ```\n   python parler_tts_server.py [--host HOST] [--port PORT] [--use-gpu]\n   ```\n   \n   Options:\n   - `--host`: Host to run the server on (default: 0.0.0.0)\n   - `--port`: Port to run the server on (default: 8593)\n   - `--use-gpu`: Use GPU for inference if available\n\n2. The server will start running on the specified host and port (default: `http://0.0.0.0:8593`).\n\n3. Access the API documentation at `http://\u003chost\u003e:\u003cport\u003e/docs`.\n\n## API Endpoints\n\n### POST /generate_speech\n\nGenerates speech from the given text and voice description.\n\n**Request Body:**\n```json\n{\n  \"text\": \"Hello, how are you?\",\n  \"voice_description\": \"A friendly, warm female voice\",\n  \"output_format\": \"base64\"\n}\n```\n\n**Response:**\n- Base64 encoded WAV file or WAV file directly, depending on the specified output format.\n\n### POST /generate_speech_stream\n\nStreams generated speech for longer texts, processing sentence by sentence.\n\n**Request Body:**\nSame as `/generate_speech`\n\n**Response:**\n- Streaming response with audio data in the specified format.\n\n### GET /\n\nReturns a welcome message.\n\n## Error Handling\n\nThe server includes error handling. If an error occurs during speech generation, it will return a 500 Internal Server Error with details about the error.\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.\n\n## License\n\nThis project is licensed under the Apache 2.0 License.\n\n## Acknowledgements\n\nThis project uses the Parler-TTS model. Please refer to the [Parler-TTS repository](https://github.com/parler-tts/parler-tts) for more information about the model and its license.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fparisneo%2Fparler-tts-fastapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fparisneo%2Fparler-tts-fastapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fparisneo%2Fparler-tts-fastapi/lists"}