Move session summaries off blocking /new#328
Merged
rwmjhb merged 1 commit intoCortexReach:masterfrom Mar 27, 2026
Merged
Conversation
Collaborator
|
session summary 从同步 command:new 移到异步 before_reset,方向对,beta.10 的 OpenClaw hook 模型也更适合这种做法。eventual consistency 对 /new 场景可以接受。 麻烦 rebase 到最新 master,需要确认的测试:
rebase + 测试过后可以合 👍 |
Contributor
Author
|
Found a bug in OpenClaw preventing it from succeeding. All other tests passed except for on OpenClaw's side; I've opened a PR: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
systemSessionMemoryfrom the blockingcommand:newhook to asyncbefore_resetbefore_resetmessages when available, withsessionFilefallbacksession-summarymemory format unchangedWhy
systemSessionMemorycurrently does embedding + LanceDB writes inline on/new, which can delay✅ New session startednoticeably for larger sessions.OpenClaw already exposes
before_resetas a fire-and-forget hook with the previous session messages available, so this summary can still be stored without blocking/new.Tradeoffs
/newturn/new, that summary may not be available yetTesting
node --test test/session-summary-before-reset.test.mjs