pub struct RetrievalFailureRecord {
pub conversation_id: Option<ConversationId>,
pub turn_index: i64,
pub failure_type: RetrievalFailureType,
pub retrieval_strategy: String,
pub query_text: String,
pub query_len: usize,
pub top_score: Option<f32>,
pub confidence_threshold: Option<f32>,
pub result_count: usize,
pub latency_ms: u64,
pub edge_types: Option<String>,
pub error_context: Option<String>,
}Expand description
A single retrieval failure event to be persisted.
Fields§
§conversation_id: Option<ConversationId>Conversation this failure occurred in. None when persistence is not yet
initialized (first-turn edge case).
turn_index: i64Turn counter within the conversation. Use 0 when unavailable.
failure_type: RetrievalFailureTypeHow the recall failed.
retrieval_strategy: StringName of the retrieval strategy that was attempted.
query_text: StringThe query text (truncated to 512 chars by crate::RetrievalFailureLogger::log).
query_len: usizeByte length of the original query before any truncation.
Note: query_text is truncated to 512 chars by crate::RetrievalFailureLogger::log,
so query_len may exceed query_text.len() for multibyte inputs.
top_score: Option<f32>Top score returned, if any results were produced.
confidence_threshold: Option<f32>Configured confidence threshold at failure time.
result_count: usizeNumber of results returned (0 for NoHit).
latency_ms: u64Wall-clock duration of the recall operation in milliseconds.
edge_types: Option<String>JSON-serialized list of graph edge types used (graph recall only).
error_context: Option<String>Error message or timeout context for Error/Timeout variants.
Truncated to 256 chars by crate::RetrievalFailureLogger::log to bound channel memory.
Trait Implementations§
Source§impl Clone for RetrievalFailureRecord
impl Clone for RetrievalFailureRecord
Source§fn clone(&self) -> RetrievalFailureRecord
fn clone(&self) -> RetrievalFailureRecord
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for RetrievalFailureRecord
impl RefUnwindSafe for RetrievalFailureRecord
impl Send for RetrievalFailureRecord
impl Sync for RetrievalFailureRecord
impl Unpin for RetrievalFailureRecord
impl UnsafeUnpin for RetrievalFailureRecord
impl UnwindSafe for RetrievalFailureRecord
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,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§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 moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request