pub struct FallbackCustomVoice {
pub caching_enabled: Option<bool>,
pub provider: ProviderTrue,
pub server: Server,
pub chunk_plan: Option<ChunkPlan>,
}
Fields§
§caching_enabled: Option<bool>
This is the flag to toggle voice caching for the assistant.
provider: ProviderTrue
This is the voice provider that will be used. Use custom-voice
for providers that are not natively supported.
server: Server
This is where the voice request will be sent. Request Example: POST https://{server.url} Content-Type: application/json { "message": { "type": "voice-request", "text": "Hello, world!", "sampleRate": 24000, …other metadata about the call… } } Response Expected: 1-channel 16-bit raw PCM audio at the sample rate specified in the request. Here is how the response will be piped to the transport: response.on('data', (chunk: Buffer) => { outputStream.write(chunk); });
chunk_plan: Option<ChunkPlan>
This is the plan for chunking the model output before it is sent to the voice provider.
Implementations§
Source§impl FallbackCustomVoice
impl FallbackCustomVoice
pub fn new(provider: ProviderTrue, server: Server) -> FallbackCustomVoice
Trait Implementations§
Source§impl Clone for FallbackCustomVoice
impl Clone for FallbackCustomVoice
Source§fn clone(&self) -> FallbackCustomVoice
fn clone(&self) -> FallbackCustomVoice
Returns a duplicate of the value. Read more
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for FallbackCustomVoice
impl Debug for FallbackCustomVoice
Source§impl Default for FallbackCustomVoice
impl Default for FallbackCustomVoice
Source§fn default() -> FallbackCustomVoice
fn default() -> FallbackCustomVoice
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for FallbackCustomVoice
impl<'de> Deserialize<'de> for FallbackCustomVoice
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for FallbackCustomVoice
impl PartialEq for FallbackCustomVoice
Source§impl Serialize for FallbackCustomVoice
impl Serialize for FallbackCustomVoice
impl StructuralPartialEq for FallbackCustomVoice
Auto Trait Implementations§
impl Freeze for FallbackCustomVoice
impl RefUnwindSafe for FallbackCustomVoice
impl Send for FallbackCustomVoice
impl Sync for FallbackCustomVoice
impl Unpin for FallbackCustomVoice
impl UnwindSafe for FallbackCustomVoice
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more