Make memory signal sync Enzyme-first and source-authority gated#105
Open
jshph wants to merge 1 commit into
Conversation
8029a3f to
b18a6d6
Compare
Rework the nightly Index signal sync away from brittle keyword classification toward semantic exploration grounded in canonical memory. - Delete build-memory-signal-candidates.ts; line-level keyword matching is no longer the primary architecture for deciding what to write. - Rewrite memory-signals.md as a read-first/write-rarely pass: explore with Enzyme when already available (no install/init/refresh), always read USER.md/MEMORY.md as high-authority anchors, read the existing Index graph (read_premises/read_intents), and read past traces and dedupe state for negative evidence about what NOT to recreate. - Route ambiguous desired connections to deferred low-frequency clarification questions instead of silent create_intent. - Keep no-delivery behavior, small caps, dedupe, and safe skips. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
b18a6d6 to
4ee4a14
Compare
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.
Why this matters
Every attendee's agent is only as useful as the graph behind it. Discovery — "who should I meet?" — only returns good people when the user's durable facts and active wants are actually represented as Index premises and signals. Thin-signal users get nothing.
A nightly pass already exists to keep that graph fresh from each user's own long-term memory, before the morning brief is prepared. The problem is how it should decide what to add. We do not want an agent that scrapes keywords out of notes, or that quietly turns something it overheard at the forum into a public-facing "want." That erodes trust: the user never said it, and now their agent is broadcasting it.
This PR makes that pass reason about a person from their own canonical memory, with clear authority boundaries about what is allowed to ground a graph write.
How the pieces relate
Authority boundaries (the safety story)
USER.mdandMEMORY.md— the user's own notebook and curated long-term memory — can groundcreate_premise/create_intent.create_intent.Safety invariants
memorySignals.lastRunDate).create_intentrejection ends that candidate — no silent paraphrase retries.What changed
skills/edge-esmeralda/prompts/memory-signals.mdinto a read-first, write-rarely pass: Enzyme-first exploration (when available), canonical anchors read directly, existing graph + past traces as the dedupe/negative baseline, ambiguity routed to a question.Edge — memory signal sync, ~01:00, before digest prepare ~02:00 and send ~08:00), so installer wiring stays stable.Validation
git diff --check— clean.bun test install/tests/cron_specs.test.ts install/tests/reconcile_digest_crons.test.ts— 23 pass / 0 fail.build-memory-signal-candidates.tsormemory-signal-candidates.json.Residual risks / open questions
memorySignals/ existingsignalElicitationstate. Confirm the exact schema the heartbeat question-delivery path expects before relying on queued clarifications to surface.