pub struct FtsHit {
pub bm25_score: f64,
pub symbol_id: String,
pub qname: String,
pub kind: String,
pub language: String,
pub file: String,
pub line: u32,
pub signature: Option<String>,
pub doc: Option<String>,
pub tier: SymbolTier,
pub ledger_text: String,
pub ledger_flags: String,
}Expand description
A single ranked result from FTS search.
Fields§
§bm25_score: f64BM25 score (negated from SQLite’s negative convention; higher = more relevant).
symbol_id: String§qname: StringOriginal qname (not expanded).
kind: String§language: String§file: StringOriginal file path (not expanded).
line: u32§signature: Option<String>Original signature (not expanded).
doc: Option<String>§tier: SymbolTierSymbol tier: 0=production, 1=utility/preview/sample, 2=test.
ledger_text: StringConcatenated ledger entry summaries (all kinds) in lowercase.
Empty when the symbol has no ledger entries.
Populated at asd index time and stored in the FTS table.
ledger_flags: StringComma-separated ledger kinds present for this symbol, e.g. “ownership,invariant”. Used for fast has_ownership() / has_invariant() checks without reading git objects.
Implementations§
Source§impl FtsHit
impl FtsHit
Sourcepub fn has_ownership(&self) -> bool
pub fn has_ownership(&self) -> bool
True if this symbol has at least one Ownership ledger entry.
Sourcepub fn has_invariant(&self) -> bool
pub fn has_invariant(&self) -> bool
True if this symbol has at least one Invariant ledger entry.
Sourcepub fn has_hazard(&self) -> bool
pub fn has_hazard(&self) -> bool
True if this symbol has at least one Hazard ledger entry.
Sourcepub fn has_ledger(&self) -> bool
pub fn has_ledger(&self) -> bool
True if this symbol has any ledger entries.