refactor(memory): unify structured consolidation flow

This commit is contained in:
chengyongru
2026-08-19 18:40:20 +08:00
committed by chengyongru
parent d4de0e4e3d
commit 16be6b0f36
14 changed files with 257 additions and 340 deletions
+1 -2
View File
@@ -10,7 +10,6 @@ from pathlib import Path
from nanobot.agent.context import ContextBuilder
from nanobot.runtime_context import RuntimeContextBlock
from nanobot.session.summary import SessionSummary
class _FakeDatetime(real_datetime):
@@ -125,7 +124,7 @@ def test_session_summary_replaces_interleaved_recent_history_entry(tmp_path) ->
"later telegram event",
session_key="telegram:chat-1",
)
summary = SessionSummary(overview, real_datetime(2026, 8, 19, 10, 0))
summary = {"text": overview, "last_active": "2026-08-19T10:00:00"}
prompt = builder.build_system_prompt(
session_key=session_key,