# 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 = "car-voice"
version = "0.34.0"
build = "build.rs"
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Voice I/O capability for CAR — mic capture, VAD, listener/speaker traits"
readme = "README.md"
license = "Apache-2.0"
repository = "https://github.com/Parslee-ai/car"

[features]
default = []

[lib]
name = "car_voice"
path = "src/lib.rs"

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

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

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

[dependencies.async-trait]
version = "0.1"

[dependencies.base64]
version = "0.22"

[dependencies.car-engine]
version = "0.34.0"

[dependencies.car-eventlog]
version = "0.34.0"

[dependencies.car-inference]
version = "0.34.0"

[dependencies.car-secrets]
version = "0.34.0"

[dependencies.cpal]
version = "0.15"

[dependencies.crossbeam-channel]
version = "0.5"

[dependencies.dashmap]
version = "6"

[dependencies.dirs]
version = "6"

[dependencies.futures]
version = "0.3"

[dependencies.hound]
version = "3"

[dependencies.log]
version = "0.4"

[dependencies.ndarray]
version = "0.16"

[dependencies.once_cell]
version = "1"

[dependencies.ort]
version = "2.0.0-rc.10"

[dependencies.regex]
version = "1"

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

[dependencies.ringbuf]
version = "0.4"

[dependencies.rodio]
version = "0.20"
features = [
    "mp3",
    "wav",
]
default-features = false

[dependencies.rubato]
version = "0.15"

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

[dependencies.serde_json]
version = "1"

[dependencies.tempfile]
version = "3"

[dependencies.thiserror]
version = "2"

[dependencies.tokio]
version = "1"
features = ["full"]

[dependencies.tokio-tungstenite]
version = "0.27"
features = ["rustls-tls-webpki-roots"]

[dependencies.tokio-util]
version = "0.7"
default-features = false

[dependencies.toml]
version = "0.8"

[dependencies.tracing]
version = "0.1"

[dependencies.voice_activity_detector]
version = "0.2"

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

[dev-dependencies.tokio]
version = "1"
features = [
    "full",
    "test-util",
]

[target.'cfg(all(target_os = "macos", car_system_audio))'.dependencies.cidre]
version = "=0.11.3"
features = ["av"]

[target.'cfg(all(target_os = "macos", car_system_audio))'.dependencies.futures-channel]
version = "0.3"

[target.'cfg(all(target_os = "macos", target_arch = "aarch64", not(car_skip_mlx)))'.dependencies.car-inference]
version = "0.34.0"
features = ["mlx-metal"]

[target.'cfg(all(target_os = "macos", target_arch = "aarch64", not(car_skip_mlx)))'.dependencies.mlx-rs]
version = "0.25"
features = [
    "accelerate",
    "safetensors",
]
default-features = false

[target.'cfg(not(target_os = "macos"))'.dependencies.whisper-rs]
version = "0.14"
default-features = false

[target.'cfg(target_os = "macos")'.dependencies.anyhow]
version = "1"

[target.'cfg(target_os = "macos")'.dependencies.block2]
version = "0.6"

[target.'cfg(target_os = "macos")'.dependencies.coreaudio-sys]
version = "0.2"

[target.'cfg(target_os = "macos")'.dependencies.objc2]
version = "0.6"

[target.'cfg(target_os = "macos")'.dependencies.objc2-avf-audio]
version = "0.3"
features = [
    "AVSpeechSynthesis",
    "AVAudioBuffer",
    "AVAudioFormat",
    "block2",
]

[target.'cfg(target_os = "macos")'.dependencies.objc2-foundation]
version = "0.3"

[target.'cfg(target_os = "macos")'.dependencies.objc2-speech]
version = "0.3"
features = [
    "SFSpeechRecognizer",
    "SFSpeechRecognitionRequest",
    "SFSpeechRecognitionResult",
    "SFSpeechRecognitionTask",
    "SFTranscription",
]

[target.'cfg(target_os = "macos")'.dependencies.uuid]
version = "1"
features = ["v4"]

[target.'cfg(target_os = "macos")'.dependencies.whisper-rs]
version = "0.14"
features = ["metal"]

[lints.clippy]
assertions_on_constants = "allow"
doc_lazy_continuation = "allow"
empty_line_after_doc_comments = "allow"
field_reassign_with_default = "allow"
large_enum_variant = "allow"
needless_range_loop = "allow"
result_large_err = "allow"
too_many_arguments = "allow"
type_complexity = "allow"
unnecessary_sort_by = "allow"

[lints.rust.unexpected_cfgs]
level = "warn"
priority = 0
check-cfg = [
    "cfg(car_system_audio)",
    "cfg(car_skip_mlx)",
    "cfg(car_skip_cuda)",
]
