Fix compaction loop for small models or large input (#5803)

This commit is contained in:
David Katz
2025-12-16 14:51:40 -05:00
committed by GitHub
parent d2358f7eaa
commit bd00ca2db0
2 changed files with 19 additions and 9 deletions
+1 -2
View File
@@ -320,8 +320,7 @@ async fn do_compact(
continue;
} else {
return Err(anyhow::anyhow!(
"Failed to compact messages: context length still exceeded after {} attempts with maximum removal",
removal_percentages.len()
"Failed to compact: context limit exceeded even after removing all tool responses"
));
}
}