fix(rebase): resolve PR #266 conflicts against latest main

This commit is contained in:
chumyin 2026-02-16 19:33:04 +08:00
parent 34306e32d8
commit 2d6ec2fb71
7 changed files with 142 additions and 51 deletions

View file

@ -113,6 +113,7 @@ async fn auto_compact_history(
let summary_raw = provider
.chat_with_system(Some(summarizer_system), &summarizer_user, model, 0.2)
.await
.map(|resp| resp.text_or_empty().to_string())
.unwrap_or_else(|_| {
// Fallback to deterministic local truncation when summarization fails.
truncate_with_ellipsis(&transcript, COMPACTION_MAX_SUMMARY_CHARS)