Finish long-running agent parity
This commit is contained in:
@@ -14,6 +14,7 @@ use std::thread;
|
||||
use std::time::{Duration, Instant, SystemTime, UNIX_EPOCH};
|
||||
|
||||
const MAX_FILE_BYTES: u64 = 16 * 1024 * 1024;
|
||||
pub(crate) const COMPACTION_OBSERVATION_PREFIX: &str = "Bash job update after context compaction.";
|
||||
|
||||
#[repr(C)]
|
||||
struct WebConfig {
|
||||
@@ -297,7 +298,7 @@ impl Tools {
|
||||
}
|
||||
running.sort();
|
||||
Some(format!(
|
||||
"Bash job update after context compaction. Running jobs still need explicit bash_status or bash_stop if relevant.\n{}",
|
||||
"{COMPACTION_OBSERVATION_PREFIX} Running jobs still need explicit bash_status or bash_stop if relevant.\n{}",
|
||||
running.concat()
|
||||
))
|
||||
}
|
||||
@@ -988,10 +989,10 @@ pub(crate) fn system_prompt(model: ModelChoice, extra: &str) -> String {
|
||||
}
|
||||
}
|
||||
|
||||
pub(crate) fn system_prompt_reminder(model: ModelChoice, extra: &str) -> String {
|
||||
pub(crate) fn system_prompt_reminder(model: ModelChoice) -> String {
|
||||
format!(
|
||||
"[System prompt reminder follows.]\n{}\n[End system prompt reminder.]",
|
||||
system_prompt(model, extra)
|
||||
system_prompt(model, "")
|
||||
)
|
||||
}
|
||||
|
||||
@@ -1256,7 +1257,7 @@ mod tests {
|
||||
}
|
||||
assert!(prompt.ends_with("extra"));
|
||||
assert!(
|
||||
system_prompt_reminder(ModelChoice::DeepSeekV4Flash, "extra")
|
||||
system_prompt_reminder(ModelChoice::DeepSeekV4Flash)
|
||||
.contains("[System prompt reminder follows.]")
|
||||
);
|
||||
assert!(datetime_context().starts_with("Current local date and time at session start:"));
|
||||
|
||||
Reference in New Issue
Block a user