fix: Part C correctness — C1 embedBatch length, C4 default branch, C6 transcript escape - #173
Open
aadivyaraushan wants to merge 2 commits into
Open
Conversation
…ags (C1/C4/C6) Part C correctness from Autoloops#145: fail closed on incomplete embedBatch results, resolve default branch via ls-remote or unknown, and neutralize early-close tags in working-memory prompts so pasted transcript content cannot break the evidence fence. Co-authored-by: Cursor <cursoragent@cursor.com>
Add a 5s timeout on ls-remote, reuse/rename the existing main scope when default_branch changes, and reject wrong-length embedding vectors in tests. Co-authored-by: Cursor <cursoragent@cursor.com>
37 tasks
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
Fixes three Part C correctness items from #145 (explicitly C1, C4, and C6; not C5 / #108):
dimensions-mismatchedembedBatchresults inensureEmbeddingsbefore anygraph_object_embeddingsinsert (no more silent empty BLOBs viaINSERT OR IGNORE).mainwhenorigin/HEADis missing: trygit ls-remote --symref origin HEAD, else store/reportunknown. Non-git folder context still usesmain.</filtered_session_transcript>inside transcript content (ZWSP after</) so pasted/hostile session text cannot break the evidence fence; real wrapper tags unchanged.Test plan
npm run build && npm run typechecknpm test(includes newcheck-embed-batch-length.js+check-worker-transcript-escape.js, updatedcheck-repo-context.js)Unit gate (commit
22f61f8)Dry-run gate (same commit; disposable
GREPLICA_HOME)C4 — default branch no longer guessed as main
C1 — embeddings no longer silently corrupt
C6 — prompt containment holds
Made with Cursor