pub struct StreamOptionsConfig {
pub temperature: Option<f64>,
pub max_tokens: Option<u64>,
pub session_id: Option<String>,
pub transport: StreamTransport,
}Expand description
Serializable representation of StreamOptions.
The api_key field is intentionally omitted — secrets should not be
persisted in config snapshots.
Fields§
§temperature: Option<f64>Sampling temperature.
max_tokens: Option<u64>Output token limit.
session_id: Option<String>Provider-side session identifier.
transport: StreamTransportPreferred transport protocol.
Implementations§
Source§impl StreamOptionsConfig
impl StreamOptionsConfig
Sourcepub fn to_stream_options(&self) -> StreamOptions
pub fn to_stream_options(&self) -> StreamOptions
Convert back to StreamOptions, leaving api_key as None.
Trait Implementations§
Source§impl Clone for StreamOptionsConfig
impl Clone for StreamOptionsConfig
Source§fn clone(&self) -> StreamOptionsConfig
fn clone(&self) -> StreamOptionsConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for StreamOptionsConfig
impl Debug for StreamOptionsConfig
Source§impl Default for StreamOptionsConfig
impl Default for StreamOptionsConfig
Source§fn default() -> StreamOptionsConfig
fn default() -> StreamOptionsConfig
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for StreamOptionsConfig
impl<'de> Deserialize<'de> for StreamOptionsConfig
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 From<&StreamOptions> for StreamOptionsConfig
impl From<&StreamOptions> for StreamOptionsConfig
Source§fn from(opts: &StreamOptions) -> Self
fn from(opts: &StreamOptions) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for StreamOptionsConfig
impl RefUnwindSafe for StreamOptionsConfig
impl Send for StreamOptionsConfig
impl Sync for StreamOptionsConfig
impl Unpin for StreamOptionsConfig
impl UnsafeUnpin for StreamOptionsConfig
impl UnwindSafe for StreamOptionsConfig
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