Repository navigation
perf(langgraph): index exact IDs in history snapshots - #1431
Merged
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
…ry-rendering-integration
blove
marked this pull request as ready for review
November 2, 2026 05:35
blove
enabled auto-merge (squash)
November 2, 2026 05:36
This branch was successfully deployed
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.
A completed response can send a full 10,001-message values snapshot through reconciliation. Exact-ID matching previously restarted a linear transcript search for every incoming row, requiring 50,015,001 predicate visits in the matching ordered case. Use an ephemeral first-index map for multirow snapshots, preserving the first duplicate match and updating actual IDs after appends or fallback assignments. Single-row/delta lookup and content/cross-ID fallbacks retain their existing behavior.
Also skip unchanged classifier text within its existing generation lifecycle. A real-template regression reduces 500 redundant historical classifier pushes to zero while preserving in-place changes, generation reset, and failed-update retry. The batch regression exercises actual restore → stream → full values synchronization, bounds predicate visits to one transcript scan, and verifies complete ordered content, identity, and terminal delivery. Edge controls cover duplicates, reordered/repeated/appended IDs, falsy IDs, aliases, stale snapshots and canonical restrictions.
Validation on Node 24.20.0:
Fresh package-based native comparison completed: 24/24 functional cases and complete traces passed (12 control, 12 candidate), with all 12 exact fixture pairs retained and independently audited. Across the three 10,000-message rounds, observed maximum renderer task intervals were 219–244 ms → 169–192 ms for follow mode and 232–262 ms → 158–203 ms for history-reading. Many ≥50 ms tasks remain (74–86 across arms); layout/GC results are mixed. These are whole-capture wall intervals on one machine, control arm first, not function-attributed timings or complete task-population coverage. Both arms are local builds; neither is labeled registry stock. This optimizes exact-ID lookup for matching batches; content fallback can still scan. No CPU-time, FPS or general performance-ranking claim is made. Raw traces remain local and historical stock/candidate results stay separate.
Postmerge verification at
6643790a: full CI including production smoke passed. A separate reverse-order native replication passed all 24 cases with complete traces; independent raw recomputation matched all reported counts and witnesses. At H10000, maximum observed task ranges were 209–237 ms control versus 175–181 ms merged for follow, and 227–234 ms versus 166–173 ms for history reading. Long-task counts, layout and GC were mixed; all twelve pairs remain in local evidence. These are local package builds and whole-capture wall intervals, with one-machine/order limitations, not published-stock, CPU-time, function-attributed or FPS measurements. A subsequent main commit changes only unrelated documentation and has its own CI run.