Remote compact for API-key users (#7835)

This commit is contained in:
pakrym-oai
2025-12-12 10:05:02 -08:00
committed by GitHub
Unverified
parent 9429e8b219
commit b3ddd50eee
11 changed files with 101 additions and 78 deletions
+4 -1
View File
@@ -2175,7 +2175,10 @@ pub(crate) async fn run_task(
// as long as compaction works well in getting us way below the token limit, we shouldn't worry about being in an infinite loop.
if token_limit_reached {
if should_use_remote_compact_task(&sess) {
if should_use_remote_compact_task(
sess.as_ref(),
&turn_context.client.get_provider(),
) {
run_inline_remote_auto_compact_task(sess.clone(), turn_context.clone())
.await;
} else {