Repository navigation
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the
|
…audit CHANGELOG follows the base branch; release PRs carry the entry.
…radiction floor - Delete facets for a flushed batch with one scan per target type instead of one full facet scan per deleted record. - Requeue a delete whose target read failed, so its facets are cleaned up on the next flush instead of being dropped. - Track each contradiction's raw penalty against a base confidence and apply the change in the floored value, so undoing one contradiction does not lift confidence while another still holds it at the floor. - Cover search and vector restoration on the final supersedes undo.
… finite - Re-add an un-superseded memory to the vector index with its session, embed text and memory context; the previous two-argument call never embedded it. - Treat a memory without a stored confidence as 1 in the contradicts reaction, so the stored value never becomes NaN, and type the field. - Rebuild the keyword index after a replace import from the store passed to the handler; the previous closure referenced an undefined name.
A contradiction on a memory with no stored confidence started from 1, so the stored value could rise above the type salience and promote a contradicted fact in retention. Start from 0.5, the default salience.
…e' into feat/iii025-s2b-cascade-audit
This was referenced Nov 10, 2026
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.
Summary
Stage 2b of the iii 0.25 stack. It targets #1639 (then #1637, #1636 and #1634). Everything here runs through observers when observe bindings are active; with
AGENTMEMORY_BINDINGS=triggernone of it is bound and behavior is unchanged.mem::compress,mem::summarize,mem::graph-extract,mem::consolidate-pipeline,mem::reflectandmem::skill-extractroute thrown errors and soft failures (output.success == false) tomem::record-failure. Each failure becomes a*-failedaudit row with its code, a 300-character message, target ids andretryable(timeouts, connection errors, open breaker, 429/5xx,compression_failed). Identical(function, code)failures inside a fixed 60 s window collapse into one row; the next row carriesdedupedCount.mem::statusgainsfailures: { transient, permanent, lastAt }, which counts every failure. The observer metadata carriessource_fn, so rows name the function that failed, not the observer.state::on-changedobserver on deletes inmem:obs:*,mem:memories,mem:lessonsand lesson soft-deletes removes BM25 and vector entries at once. Facet cleanup and sessionobservationCountreconciliation are batched: one flush per 500 ms or 200 ids, single-flight, retried after a failed flush. Deleting 300 observations wrote 2 cascade audit rows, not 300 full scans.supersedes,contradictsandextendsrelations update their target memory. Reactions are tracked per(target, type)inmem:relation-reactions, with the set of contributing relations:supersedesmarks the target non-latest and halves its strength once; later supersedes only join.contradictsdecays confidence cumulatively, with a 0.05 floor.extendslinks the source intorelatedIds.contradictsis allowed.mem::relate: writes torelatedIdsnow take the per-memory lock and re-read the row, so they no longer overwrite a concurrent reaction. The lock is reentrant for self-relations.replaceimport. The vector index is not rebuilt here.Live verification (engine 0.25.0, state 0.22.22, http 0.22.8, fake OpenAI-compatible server)
compress-failedrow,functionId: mem::compress,code: compression_failed,retryable: true; 8 failures → 1 row; status counters moveisLatest:false, strength 7 → 3.5; after first delete unchanged (1 contributor left); after second deletetrue/ 7 restored and mark removedobservationCountequals the real key countgate:large-store --small --assertNot covered
AGENTMEMORY_BINDINGS=trigger, or workers withoutstate::on-changed) there are no delete cascades or relation reactions.mem::remember/mem::evolveonto this handler are left for later.Test plan
npm run build,npm run skills:gen,npm run docs:sync,npm run skills:checknpm test: 4159 passed, 6 skippedtest/cascade-audit.test.ts: failure classification and fixed-window dedupe, multi-relation undo, cumulative contradicts with floor, mutual contradicts, supersedes cycle, extends undo, idempotent replay, delete batching (one facet read, one key listing per session), flush failure without unhandled rejection, items queued mid-flush, self-relation lockFixes #1624. Refs #766 #768 #938 #1157.