pub struct SearchHit {
pub score: u32,
pub node: NodeSummary,
pub snippet: Option<String>,
}Expand description
A relevance-ranked search hit: a node summary plus its score.
Fields§
§score: u32Relevance score (higher is better); see search for how it is derived.
node: NodeSummaryThe matching node.
snippet: Option<String>A short, whitespace-collapsed excerpt of the node’s captured
meta.content (see [content_snippet]), so a model that never calls
explain still has real grounding text. None for pure symbol/config
nodes with no content — the summary (name/kind/path) is the grounding then.
Trait Implementations§
impl StructuralPartialEq for SearchHit
Auto Trait Implementations§
impl Freeze for SearchHit
impl RefUnwindSafe for SearchHit
impl Send for SearchHit
impl Sync for SearchHit
impl Unpin for SearchHit
impl UnsafeUnpin for SearchHit
impl UnwindSafe for SearchHit
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