File Match • Rust AI Agent SDK
FileMatch: A file match from a search.
FileMatch
Defined in the context module.
Rust AI Agent SDK
A file match from a search.
Fields
| Name | Type | Description |
|---|---|---|
path | String | File path (relative to workspace) |
relevance_score | f32 | Relevance score (0.0 to 1.0) |
line_ranges | Vec<LineRange> | Matching line ranges |
Methods
new
fn new(path: impl Into<String>) -> SelfCreate a new file match.
Parameters:
| Name | Type |
|---|---|
path | impl Into<String> |
relevance_score
fn relevance_score(mut self, score: f32) -> SelfSet relevance score.
Parameters:
| Name | Type |
|---|---|
score | f32 |
line_range
fn line_range(mut self, range: LineRange) -> SelfAdd a line range.
Parameters:
| Name | Type |
|---|---|
range | LineRange |
Source
View on GitHubpraisonai/src/context/mod.rs at line 597