Skip to main content

A prosody processing library for TTS synthesis with say command.

Project description

prosody_synthesizer

A prosody processing library for TTS synthesis on macOS that computes dynamic pitch, rate, and volume adjustments based on sentiment and energy analysis. This library relies on the system say command, which is available only on macOS.


Features

  • Sentiment and Energy Analysis: Uses NLTK’s VADER and basic lexical heuristics to derive a sentence‐level “energy” and sentiment (compound) score.
  • Dynamic Shifts: Adjusts speech rate and pitch dynamically within each phrase.
  • macOS say Integration: Outputs text with inline TTS commands (e.g. [[rate]], [[pbas]]), then invokes say.
  • Object-Oriented Design: Encapsulated in a ProsodySynthesizer class for easy usage.

Requirements

  1. macOS
    This library uses the built-in say command, so it won't work on Windows or Linux unless you adapt those TTS calls.

  2. Python <3.12 (recommended)

    • Although no strict upper-bound is enforced, note that spaCy may not yet support Python 3.13.
    • If you encounter issues on future Python versions, consider using 3.6–3.12.
  3. Dependencies

    • nltk
    • numpy
    • spacy

Required Data Downloads

Download Required Resources

Before using prosody_say, ensure that the necessary NLTK and spaCy resources are installed. You can do this by running:

prosody-download-resources

Installation

  1. Install from PyPI :
    pip install prosody_synthesizer
    

2. **Install from source**:
   ```git clone https://github.com/yourusername/prosody_synthesizer.git
   cd prosody_synthesizer
   pip install .
   ```

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

prosody_say-0.1.1.tar.gz (18.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

prosody_say-0.1.1-py3-none-any.whl (18.2 kB view details)

Uploaded Python 3

File details

Details for the file prosody_say-0.1.1.tar.gz.

File metadata

  • Download URL: prosody_say-0.1.1.tar.gz
  • Upload date:
  • Size: 18.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for prosody_say-0.1.1.tar.gz
Algorithm Hash digest
SHA256 7d82724ef41533bbb2a18d012f6ea1ab3f9de778b9f10dfcc5b467ec5f412f49
MD5 9c5063a9715ffe2e004d0ff3d40663bf
BLAKE2b-256 18b44c3fd19fb10d9d90ac8211d1911d84d93a9957912a3c3b2ba0bc096b7c16

See more details on using hashes here.

File details

Details for the file prosody_say-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: prosody_say-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 18.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for prosody_say-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 8bb27b9bff7203c90e756168e8a809a7a4241582d7c6c3132a0ddca0f0dff3ce
MD5 f4e5be2f6bbe71bc45a619002518ded9
BLAKE2b-256 ae52852f51e09ff2badf0f6dbe21cdb472547307a3971f303329d43e8a8fef03

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page