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.0.tar.gz (18.0 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.0-py3-none-any.whl (17.8 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: prosody_say-0.1.0.tar.gz
  • Upload date:
  • Size: 18.0 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.0.tar.gz
Algorithm Hash digest
SHA256 74415a73d0dfe83445097410e31e6c3143f7192db81eeeb7885efdd55e11ddde
MD5 bd03230a14f7238db07cecf0882ef182
BLAKE2b-256 94faa85cc6e8d041afee90979d6639eada05e75bacd3f1662fb4436968beecfa

See more details on using hashes here.

File details

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

File metadata

  • Download URL: prosody_say-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 17.8 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.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2064659578e3e7c25c534337de63558929efd67c90e296307e7989ae7fe718c8
MD5 51ac3815790a3340d19e7b486a1a9e7f
BLAKE2b-256 6e88b34dc6598547d18ab7f5a5308c7c27176ac90b4b5c5085f6b7ad538a73d6

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