Repository navigation
Conversation search: index a growing transcript incrementally, debounced to one pass per 30 s - #374
Merged
Merged
Conversation
…ost resumes fs.sessionText at the stored checkpoint (offset after the last consumed line, inode, a digest of the head and of the bytes before the offset) and the index appends; a replaced, truncated or rewritten file gets a full pass; a transcript indexed in this run is re-indexed at most once per SEARCH_REINDEX_DEBOUNCE_MS (30 s). Index migration 15 (session_text_state.resume); wire minor 8 (fs.sessionText resume, from, checkpoint) Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
… fails and retries as a full pass; the same-length in-place rewrite the cheap check cannot see goes to the tech-debt tracker Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…de tests: the rewound version-13 file lacks session_text_state.resume, and the upgrade applies 14 and 15 Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
SSFSKIM
added a commit
that referenced
this pull request
Oct 30, 2026
…-load; the window's fields take WIRE_MINOR 9 beside #374's resume Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
SSFSKIM
added a commit
that referenced
this pull request
Oct 30, 2026
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.
The search index re-read a transcript's whole text from byte 0 (
fs.sessionText) every time its size changed, so a large transcript a terminal session was writing cost seconds of CPU per append. This makes the pass incremental.\nseparator).fs.sessionTexttakes it back asresumeand answersfrom(0 for a full pass) and, on the last page, the nextcheckpoint. The host resumes only when the inode is the same, the file is at least the offset long and both digests match; otherwise it reads from byte 0 and the index replaces the text. A resumed pass re-checks the prefix at its end and fails (then retries as a full pass) if it changed meanwhile.\nin the worker (readline is gone) so the offset is exact in bytes. A line counts as consumed once it ends in\n, or, for the unterminated last line, once it parses as JSON; a torn line is left for the next pass, which starts at it. A pass cut short clears the checkpoint, so the next one is a full pass.SEARCH_REINDEX_DEBOUNCE_MS(30 s,src/services/index/source.ts) after its last pass finished; bursts of appends coalesce into one pass of the latest state. First indexing after a start is immediate.session_text_state.resume);WIRE_MINOR8 with the manifest regenerated (fs.sessionTextgains optionalresumeinput andfrom/checkpointoutput).engine-host/fs/service.tsgets a two-line pass-through ofresume(searchText).Measured on a 383 MB synthetic transcript (this MacBook, loaded): one append cost about 1.0 s of CPU before (a full pass, 1.05 and 1.02 s in two runs) and about 1 ms after, reading 4.3 KB of appended lines plus four 4 KiB fingerprint spans.
Not covered, by design: an in-place, same-length rewrite of a transcript's middle that touches neither fingerprint span (logged in
docs/tech-debt-tracker.md).Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)