Persist session evidence and searchable conversation memory - #58
Merged
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
devhims
marked this pull request as ready for review
September 19, 2026 12:17
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.
Follow-up runs currently retain source evidence mainly through earlier answers and per-run tool records. This can repeat extraction, lose raw data when analysis fails, and reuse ambiguous transcript citation IDs. Older messages also fall outside the eight-turn prompt window without a way for the model to retrieve them.
Add reusable session evidence on the existing Durable Object SQLite and R2 bindings. Complete transcripts, comments, storyboard sheets and frames persist independently of analysis. Explicit refresh bypasses transcript/comment provider caches and preserves version-specific citations. Partial or empty transcripts are not reusable.
Use Cloudflare's experimental Session API for searchable conversation history and model-facing searchable contexts. Original user messages, including failed requests and literal retry messages, are indexed from existing run records. Research, inspection and the shared finalizer can search history, memory, transcript passages and saved visual/comment observations. A paginated reader supports listing older messages. Classification keeps its compact inventory, memory briefing and eight recent turns. Evidence search results resolve to persisted citations; validated memory updates commit with the answer. The finalizer can request one inspection when existing context is insufficient, including for a video recovered from older history, and reserves its last model step for an answer.
Dashboard controls expose stored assets and memory. Deletion removes dependent findings, historical source copies and search entries. SQLite triggers keep context-index deletion and memory correction synchronous; generation checks prevent in-flight retrieval or index backfill from restoring deleted assets. The Session API is isolated behind one adapter using the existing pinned agents@0.21.0 dependency. Custom evidence/memory FTS5 providers preserve citation and deletion rules.
Validation:
Search is lexical, not semantic. Conversation history is indexed from existing runs, but historical run evidence is not retroactively converted into raw assets. Session compaction and frozen context prompts are not enabled; the existing five-step finalizer and cost budgets remain. No production deployment or live Fireworks inference benchmark was performed. Model/provider responses in tests are controlled fixtures.