use std::path::PathBuf;
pub mod batch_items;
pub mod model_path;
pub mod output_path;
pub mod tokenizer;
pub mod voice_prompt;
#[derive(Debug, Clone, Default)]
pub struct IoArgs {
pub output: PathBuf,
pub file: Option<PathBuf>,
pub output_dir: Option<PathBuf>,
pub save_prompt: Option<PathBuf>,
pub load_prompt: Option<PathBuf>,
pub debug: bool,
pub tracing: bool,
}
#[derive(Debug, Clone, Default)]
pub struct ModelArgs {
pub model: Option<String>,
pub model_path: Option<PathBuf>,
pub device: String,
pub dtype: String,
}
#[derive(Debug, Clone, Default)]
pub struct GenerationArgs {
pub max_tokens: usize,
pub temperature: Option<f64>,
pub top_k: Option<usize>,
pub top_p: Option<f64>,
pub repetition_penalty: Option<f64>,
pub seed: Option<u64>,
pub greedy: bool,
pub subtalker_temperature: Option<f64>,
pub subtalker_top_k: Option<usize>,
pub subtalker_top_p: Option<f64>,
pub no_subtalker_sample: bool,
}
#[derive(Debug, Clone)]
pub struct SynthesisItem {
pub text: String,
pub language: String,
pub output: PathBuf,
}
#[derive(Debug, Clone)]
pub struct VoiceCloneParams {
pub ref_audio: Option<PathBuf>,
pub ref_text: Option<String>,
pub x_vector_only: bool,
pub save_prompt: bool,
}
#[derive(Debug, Clone, Default)]
pub struct VoiceArgs {
pub language: String,
pub text: Option<String>,
pub speaker: Option<String>,
pub instruct: Option<String>,
pub voice_design: Option<String>,
pub ref_audio: Option<PathBuf>,
pub ref_text: Option<String>,
pub x_vector_only: bool,
}
#[derive(Debug, Clone)]
pub enum SynthesisMode {
CustomVoice {
speaker: String,
instruct: Option<String>,
},
VoiceDesign {
description: String,
},
VoiceClone {
audio: PathBuf,
transcript: Option<String>,
x_vector_only: bool,
},
}