Struct LlmMessageSnapshot
pub struct LlmMessageSnapshot {
pub input: Vec<MessageSnapshot>,
pub output_text: Option<String>,
pub output_tool_calls: Vec<ToolCallSnapshot>,
pub system_instructions: Option<String>,
}Expand description
Full prompt/completion content for one llm.call, captured and
credential-scrubbed at the agent-loop boundary so the OTel exporter can emit
gen_ai.input.messages / gen_ai.output.messages / gen_ai.system_instructions.
Populated at the agent-loop capture boundary whenever the observability-otel
feature is active; None otherwise (other observers and non-OTel builds leave
it None). Capture is policy-agnostic: whether the snapshot is actually
exported — and at which privacy level (off / redacted / full) — is
decided by the owning OtelObserver’s instance content config at the OTel
export boundary, not by the capture path.
Fields§
§input: Vec<MessageSnapshot>Non-system input messages, in send order.
output_text: Option<String>Assistant text output, if any. Empty text is captured as None.
output_tool_calls: Vec<ToolCallSnapshot>Tool calls the assistant emitted this turn.
system_instructions: Option<String>System prompt, carried separately from input.
Trait Implementations§
Source§impl Clone for LlmMessageSnapshot
impl Clone for LlmMessageSnapshot
Source§fn clone(&self) -> LlmMessageSnapshot
fn clone(&self) -> LlmMessageSnapshot
1.0.0 (const: unstable) · §fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for LlmMessageSnapshot
impl RefUnwindSafe for LlmMessageSnapshot
impl Send for LlmMessageSnapshot
impl Sync for LlmMessageSnapshot
impl Unpin for LlmMessageSnapshot
impl UnsafeUnpin for LlmMessageSnapshot
impl UnwindSafe for LlmMessageSnapshot
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more