VoiceConfig (schema/voice.rs)

moltis · crates/config/src/schema/voice.rs · rust · MIT
voice

Defines comprehensive Rust structs for configuring TTS and STT providers, used in moltis applications.

// Source: https://github.com/moltis-org/moltis | License: MIT | Copyright 2025 Fabien Penso
// Provided via justclaw.it.com; keep this notice with the code.
use {
    secrecy::Secret,
    serde::{Deserialize, Serialize},
};

fn default_true() -> bool {
    true
}

/// Voice configuration (TTS and STT).
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(default)]
pub struct VoiceConfig {
    pub tts: VoiceTtsConfig,
    pub stt: VoiceSttConfig,
}

/// Voice TTS configuration for moltis.toml.
#[derive(Debug, Clone, Serialize, Deserialize)]
#[serde(default)]
pub struct VoiceTtsConfig {
    /// Enable TTS globally.
    pub enabled: bool,
    /// Preferred TTS provider. `None` means auto-select the first configured.
    pub provider: Option<VoiceTtsProvider>,
    /// Provider IDs

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search for more like it.

Get a free API key