rust-tts-wrapper 1.6.2

Cross-platform TTS wrapper with C API — mirrors js-tts-wrapper / SwiftTTSWrapper
Documentation
# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2021"
name = "rust-tts-wrapper"
version = "1.6.2"
build = "build.rs"
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Cross-platform TTS wrapper with C API — mirrors js-tts-wrapper / SwiftTTSWrapper"
readme = "README.md"
keywords = [
    "tts",
    "text-to-speech",
    "speech",
    "accessibility",
    "assistive-technology",
]
categories = [
    "accessibility",
    "api-bindings",
    "multimedia::audio",
]
license = "MIT"
repository = "https://github.com/AACTools/rust-tts-wrapper"

[features]
avsynth = ["speechmarkdown"]
cloning = [
    "cloud",
    "dep:zip",
    "symphonia/caf",
    "symphonia/alac",
    "reqwest/multipart",
]
cloud = [
    "cloud-core",
    "reqwest",
    "tungstenite",
    "uuid",
    "url",
    "symphonia",
]
cloud-core = [
    "dep:base64",
    "speechmarkdown",
    "dep:sha2",
]
default = [
    "system",
    "cloud",
    "sherpaonnx",
    "display_names",
]
display_names = [
    "dep:icu_displaynames",
    "dep:icu_locid",
]
floravox = [
    "dep:floravox-core",
    "dep:floravox-g2p",
    "floravox-g2p/onnx",
    "speechmarkdown",
]
floravox-lexicons = [
    "floravox",
    "dep:voicegarden-lexicons",
]
omnivoice-local = [
    "dep:hound",
    "ssml-expand",
]
pocket-timing = [
    "dep:ort",
    "dep:ndarray",
    "dep:hound",
    "dep:floravox-ssml",
    "speechmarkdown",
    "ssml-expand",
]
qwen3-local = [
    "dep:base64",
    "ssml-expand",
]
sapi = [
    "windows",
    "speechmarkdown",
]
sherpaonnx = [
    "sherpa-onnx",
    "dep:sherpa-onnx-models",
]
speechmarkdown = ["dep:speechmarkdown-rust"]
ssml-expand = ["dep:floravox-ssml"]
system = ["speech-dispatcher"]
tungstenite = ["dep:tungstenite"]
url = ["dep:url"]
uuid = ["dep:uuid"]

[lib]
name = "rust_tts_wrapper"
crate-type = [
    "cdylib",
    "staticlib",
    "lib",
]
path = "src/lib.rs"

[[example]]
name = "advanced-features-demo"
path = "examples/advanced-features-demo.rs"

[[example]]
name = "edge-bare-envelope"
path = "examples/edge-bare-envelope.rs"

[[example]]
name = "edge-speechmarkdown"
path = "examples/edge-speechmarkdown.rs"

[[example]]
name = "edge-style"
path = "examples/edge-style.rs"

[[example]]
name = "gemini_live"
path = "examples/gemini_live.rs"

[[example]]
name = "list-pocket"
path = "examples/list-pocket.rs"

[[example]]
name = "pocket-engine-demo"
path = "examples/pocket-engine-demo.rs"

[[example]]
name = "pocket-prof"
path = "examples/pocket-prof.rs"

[[example]]
name = "pocket-smoke"
path = "examples/pocket-smoke.rs"

[[example]]
name = "pocket-timing-demo"
path = "examples/pocket-timing-demo.rs"

[[example]]
name = "quick-start"
path = "examples/quick-start.rs"

[[example]]
name = "simple-test"
path = "examples/simple-test.rs"

[[example]]
name = "streaming-audio-demo"
path = "examples/streaming-audio-demo.rs"

[[example]]
name = "timeline-demo"
path = "examples/timeline-demo.rs"

[[example]]
name = "voice-clone"
path = "examples/voice-clone.rs"
required-features = ["cloning"]

[[example]]
name = "word-boundary-demo"
path = "examples/word-boundary-demo.rs"

[[test]]
name = "cloning_live"
path = "tests/cloning_live.rs"

[[test]]
name = "elevenlabs_timestamps_fallback"
path = "tests/elevenlabs_timestamps_fallback.rs"

[[test]]
name = "ffi_conformance"
path = "tests/ffi_conformance.rs"

[[test]]
name = "ffi_lifecycle"
path = "tests/ffi_lifecycle.rs"

[[test]]
name = "ffi_safety"
path = "tests/ffi_safety.rs"

[[test]]
name = "floravox_live"
path = "tests/floravox_live.rs"

[[test]]
name = "gemini_provider"
path = "tests/gemini_provider.rs"

[[test]]
name = "integration"
path = "tests/integration.rs"

[[test]]
name = "integration_tests"
path = "tests/integration_tests.rs"

[[test]]
name = "pocket_tokenizer"
path = "tests/pocket_tokenizer.rs"

[[test]]
name = "polly_live"
path = "tests/polly_live.rs"

[[test]]
name = "qwen3_local_live"
path = "tests/qwen3_local_live.rs"

[[test]]
name = "qwen_live"
path = "tests/qwen_live.rs"

[[test]]
name = "sherpaonnx_live"
path = "tests/sherpaonnx_live.rs"

[[test]]
name = "sherpaonnx_models"
path = "tests/sherpaonnx_models.rs"

[[test]]
name = "trait_methods"
path = "tests/trait_methods.rs"

[dependencies.anyhow]
version = "1"

[dependencies.base64]
version = "0.23"
optional = true

[dependencies.floravox-core]
version = "=0.8.8"
optional = true

[dependencies.floravox-g2p]
version = "=0.8.8"
optional = true
default-features = false

[dependencies.floravox-ssml]
version = "0.8.8"
optional = true

[dependencies.hound]
version = "3"
optional = true

[dependencies.icu_displaynames]
version = "0.11"
features = ["compiled_data"]
optional = true

[dependencies.icu_locid]
version = "1.4"
optional = true

[dependencies.ndarray]
version = "0.17"
features = ["std"]
optional = true

[dependencies.ort]
version = "=2.0.0-rc.14"
features = [
    "std",
    "download-binaries",
    "ndarray",
    "tls-native",
]
optional = true
default-features = false

[dependencies.reqwest]
version = "0.12"
features = [
    "blocking",
    "json",
    "rustls-tls",
]
optional = true
default-features = false

[dependencies.serde]
version = "1"
features = ["derive"]

[dependencies.serde_json]
version = "1"

[dependencies.sha2]
version = "0.11"
optional = true

[dependencies.sherpa-onnx]
version = "=1.13.8"
optional = true

[dependencies.sherpa-onnx-models]
version = "1.1"
optional = true

[dependencies.sherpa-onnx-sys]
version = "=1.13.8"
optional = true

[dependencies.speechmarkdown-rust]
version = "0.5.2"
optional = true

[dependencies.symphonia]
version = "0.5"
features = [
    "mp3",
    "wav",
    "pcm",
]
optional = true
default-features = false

[dependencies.tungstenite]
version = "0.30"
features = ["rustls-tls-webpki-roots"]
optional = true

[dependencies.url]
version = "2.5.8"
optional = true

[dependencies.uuid]
version = "1.23.2"
features = ["v4"]
optional = true

[dependencies.voicegarden-lexicons]
version = "0.3"
optional = true

[dependencies.zip]
version = "8"
features = ["deflate"]
optional = true
default-features = false

[dev-dependencies.tempfile]
version = "3"

[build-dependencies.cbindgen]
version = "0.29"

[target.'cfg(target_os = "linux")'.dependencies.speech-dispatcher]
version = "0.16"
optional = true

[target.'cfg(target_os = "macos")'.build-dependencies.cc]
version = "1"

[target.'cfg(target_os = "windows")'.dependencies.windows]
version = "0.62"
features = [
    "Win32_Media_Speech",
    "Win32_Media_Audio",
    "Win32_System_Com",
    "Win32_System_Ole",
]
optional = true

[lints.clippy]
all = "warn"
cargo = "warn"
pedantic = "warn"

[profile.release]
lto = true
codegen-units = 1
strip = true