@@ -308,12 +308,12 @@ async def put_working_memory(
308308 if user_id is not None :
309309 memory .user_id = user_id
310310
311- # Validate that all structured memories have id (if any)
312- for mem in memory .memories :
313- if not mem .id :
311+ # Validate that all long-term memories have id (if any)
312+ for long_term_mem in memory .memories :
313+ if not long_term_mem .id :
314314 raise HTTPException (
315315 status_code = 400 ,
316- detail = "All memory records in working memory must have an ID" ,
316+ detail = "All long-term memory records in working memory must have an ID" ,
317317 )
318318
319319 # Handle summarization if needed (before storing) - now token-based
@@ -453,17 +453,13 @@ async def search_long_term_memory(
453453 # Extract filter objects from the payload
454454 filters = payload .get_filters ()
455455
456- print ("Long-term search filters: " , filters )
457-
458456 kwargs = {
459457 "distance_threshold" : payload .distance_threshold ,
460458 "limit" : payload .limit ,
461459 "offset" : payload .offset ,
462460 ** filters ,
463461 }
464462
465- print ("Kwargs: " , kwargs )
466-
467463 kwargs ["text" ] = payload .text or ""
468464
469465 # Pass text and filter objects to the search function (no redis needed for vectorstore adapter)
@@ -568,8 +564,6 @@ async def memory_prompt(
568564 redis = await get_redis_conn ()
569565 _messages = []
570566
571- print ("Received params: " , params )
572-
573567 if params .session :
574568 # Use token limit for memory prompt, fallback to message count for backward compatibility
575569 if params .session .model_name or params .session .context_window_max :
0 commit comments