Skip to main content

FileMatch

Defined in the context module.
Rust AI Agent SDK A file match from a search.

Fields

NameTypeDescription
pathStringFile path (relative to workspace)
relevance_scoref32Relevance score (0.0 to 1.0)
line_rangesVec<LineRange>Matching line ranges

Methods

new

fn new(path: impl Into<String>) -> Self
Create a new file match. Parameters:
NameType
pathimpl Into&lt;String&gt;

relevance_score

fn relevance_score(mut self, score: f32) -> Self
Set relevance score. Parameters:
NameType
scoref32

line_range

fn line_range(mut self, range: LineRange) -> Self
Add a line range. Parameters:
NameType
rangeLineRange

Source

View on GitHub

praisonai/src/context/mod.rs at line 597