Fix Herdr Sidebar session linkage and context trends - #590
Merged
Conversation
added 4 commits
August 26, 2026 12:51
Signed-off-by: Justin Lee <justinlee@91app.com>
Signed-off-by: Justin Lee <justinlee@91app.com>
Signed-off-by: Justin Lee <justinlee@91app.com>
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.
繁中簡述
這個 PR 修正並完善 Herdr Sidebar 的 session observability:恢復 native session linkage、保留啟動時的 agent status,並讓 context% 趨勢在 session 歷史超出 index tail 或只剩 contextless subagent row 時仍能正確顯示。
目前 Sidebar 會:
beta1m作為 context denominator provenance↑或↓Problem
The Sidebar intentionally reads only the last 4 MiB of
index.ndjson. That bounded read can contain a matching contextless subagent row while the main conversation's context samples are older in the same session:The session was technically linked, so the old repair guard did not run. Separately, coarse context buckets could make a materially changing context percentage look flat, and imported rows did not always retain the authoritative 1M-window fact.
What changed
Session identity and status
Context history recovery
Rendering and provenance
beta1mwhen available, so a 1M context window is not downgraded to the 200K fallback.↑/↓direction cues while keeping the newest sample right-anchored.Verification
CCXRAY_HOMEand export disabled: 2395/2395 passedgit diff --check: passed49%↓)Scope and limits