Skip to content

Dunals/python-tts-downloader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

5 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Python TTS Downloader

A lightweight Python script to generate and download AI-powered text-to-speech (TTS) audio files by interfacing with third-party TTS endpoints. This tool supports various voice models and handles MP3 file saving automatically.

🎧 Features

  • Reverse API Integration: Constructs custom payloads to interact with TTS services programmatically.
  • Proxy Support: Implements dynamic proxy rotation to bypass rate limits during bulk generation.
  • Automated File Saving: Automatically downloads and saves generated audio with unique filenames.
  • Customizable Parameters: Allows configuration of voice models (e.g., "alloy", "fable") and speech speed.

πŸ›  Dependencies

  • Python 3.x
  • requests

πŸš€ Usage

  1. Clone the repository:

    git clone [https://github.com/yourusername/python-tts-downloader.git](https://github.com/yourusername/python-tts-downloader.git)
    cd python-tts-downloader
  2. Install dependencies:

    pip install -r requirements.txt
  3. Configuration: Open main.py and update your proxy credentials if needed (or run without proxies for small tests).

  4. Run the script:

    python main.py

πŸ“ Code Example

The script mimics a valid browser request to generate audio:

# Generating audio
generate_and_download("Hello world, this is a test.", voice="fable")
# Output: Saves 'audio_fable_1234.mp3' locally

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages