feat(memory): add progressive wiki and drain Dream history (#4477)

This commit is contained in:
chengyongru authored and GitHub committed 2026-11-18 16:28:43 +08:00
1 parent 9ccf3b6214
commit 74d070f699
40 files changed
+1513 -738

No files matched your search

+4 -3
View File
@@ -194,10 +194,11 @@ async def test_compacted_session_waits_for_new_input_without_continuation(
assert response.content == "Hello!"
loop.provider.chat_stream_with_retry.assert_awaited_once()
sent = loop.provider.chat_stream_with_retry.call_args.kwargs["messages"]
expected_summary = reloaded.metadata["_last_summary"] if summary != "(nothing)" else None
assert sent[0]["role"] == "system"
assert sent[0]["content"] == loop.context.build_system_prompt(channel="cli", session_summary=expected_summary)
assert [message["role"] for message in sent] == ["system", "user"]
expected_summary = reloaded.metadata["_last_summary"] if summary != "(nothing)" else None
assert sent[0]["content"] == loop.context.build_system_prompt(
channel="cli", session_summary=expected_summary, has_cron=False,
)
assert sent[1]["content"].startswith("hi\n\n")
assert "File access: no workspace restriction." in sent[1]["content"]