Pull out plain rules file loading code into a new agent_rules
crate (#28383)
Also renames for rules file templated into the system prompt Release Notes: - N/A
This commit is contained in:
parent
020a1071d5
commit
301fc7cd7b
10 changed files with 125 additions and 64 deletions
|
@ -38,12 +38,12 @@ impl AssistantSystemPromptContext {
|
|||
pub struct WorktreeInfoForSystemPrompt {
|
||||
pub root_name: String,
|
||||
pub abs_path: Arc<Path>,
|
||||
pub rules_file: Option<RulesFile>,
|
||||
pub rules_file: Option<SystemPromptRulesFile>,
|
||||
}
|
||||
|
||||
#[derive(Serialize)]
|
||||
pub struct RulesFile {
|
||||
pub rel_path: Arc<Path>,
|
||||
pub struct SystemPromptRulesFile {
|
||||
pub path_in_worktree: Arc<Path>,
|
||||
pub abs_path: Arc<Path>,
|
||||
pub text: String,
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue