summarization fetch failed

This commit is contained in:
Storme-bit
2026-04-19 15:17:30 -07:00
parent 7824404319
commit a674f4d774
2 changed files with 1 additions and 2 deletions

View File

@@ -59,6 +59,7 @@ async function generateSummary(episodes, existingSummary = null) {
}
async function maybeSummarize(session, allEpisodes) {
console.log('[summarization] MEMORY_URL:', MEMORY_URL)
// 1. Sum total tokens for this session
const totalTokens = allEpisodes.reduce((sum, ep) => sum + (ep.token_count || 0), 0);
if (totalTokens < THRESHOLD_TOKENS) return; // under threshold — nothing to do