pub struct ChatSpanParams<'a> {
pub provider_id: &'static str,
pub model: &'a str,
pub streaming: bool,
pub max_tokens: Option<u32>,
}Available on crate feature
otel only.Expand description
Inputs needed to open a chat {model} CLIENT span.
Bundled so call sites stay readable and so the field set can grow
(e.g. extra gen_ai.request.* attributes) without churning every
caller. Mirrors the attributes set by agent_loop::turn::build_llm_span.
Fields§
§provider_id: &'static strRaw SDK provider id (e.g. anthropic, openai-responses).
Normalised to the gen_ai.provider.name semconv value
internally via provider_name::normalize.
model: &'a strModel the SDK is asking for (gen_ai.request.model).
streaming: boolWhether the call streams (agent_sdk.llm.streaming).
max_tokens: Option<u32>Configured output-token cap, if any
(gen_ai.request.max_output_tokens).
Trait Implementations§
Source§impl<'a> Clone for ChatSpanParams<'a>
impl<'a> Clone for ChatSpanParams<'a>
Source§fn clone(&self) -> ChatSpanParams<'a>
fn clone(&self) -> ChatSpanParams<'a>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl<'a> Copy for ChatSpanParams<'a>
Auto Trait Implementations§
impl<'a> Freeze for ChatSpanParams<'a>
impl<'a> RefUnwindSafe for ChatSpanParams<'a>
impl<'a> Send for ChatSpanParams<'a>
impl<'a> Sync for ChatSpanParams<'a>
impl<'a> Unpin for ChatSpanParams<'a>
impl<'a> UnsafeUnpin for ChatSpanParams<'a>
impl<'a> UnwindSafe for ChatSpanParams<'a>
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