File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -430,14 +430,7 @@ def generate_session_title(self) -> None:
430430 system = system ,
431431 temperature = self .temperature ,
432432 )
433- title = resp .text ()
434- if resp .reasoning :
435- r = resp .reasoning
436- if title .startswith (r ):
437- title = title [len (r ):]
438- else :
439- title = title .replace (r , "" )
440- title = title .strip ()
433+ title = resp .text_without_reasoning ()
441434 if title :
442435 store .apply_title (title )
443436 if self .store .title :
@@ -531,7 +524,7 @@ def compact_conversation(self) -> tuple[bool, str]:
531524 resp , _ = self .client .chat_sync (
532525 [Msg (role = "user" , content = conversation )], system = system
533526 )
534- summary = resp .text ()
527+ summary = resp .text_without_reasoning ()
535528 if not summary :
536529 return False , "Compaction failed: empty summary."
537530 frame = config .COMPACT_HEADER + summary + config .COMPACT_SEPARATOR
@@ -575,7 +568,7 @@ def summarize_conversation(self) -> str:
575568 resp , _ = self .client .chat_sync (
576569 [Msg (role = "user" , content = conversation )], system = system
577570 )
578- summary = resp .text ()
571+ summary = resp .text_without_reasoning ()
579572 except Exception as e : # noqa: BLE001
580573 return f"Summary failed: { e } "
581574 if not summary :
You can’t perform that action at this time.
0 commit comments