Skip to content

feat: add MemoryStore with deduplication-aware storage#9

Merged
daniel-harperdb merged 1 commit intofeat/score-normalizationfrom
feat/dedup-store
Mar 19, 2026
Merged

feat: add MemoryStore with deduplication-aware storage#9
daniel-harperdb merged 1 commit intofeat/score-normalizationfrom
feat/dedup-store

Conversation

@daniel-harperdb
Copy link
Collaborator

Summary

Adds a MemoryStore custom resource with built-in deduplication.

  • Before inserting, searches for similar existing memories using vector similarity
  • Configurable dedupThreshold (default 0.95) — memories above this similarity are considered duplicates
  • On duplicate: updates metadata and timestamp instead of creating a new record
  • On new: generates embedding server-side and inserts
  • Returns { action: "created" | "deduplicated", id: string }

Stacked on #8 (score-normalization).

Test plan

  • Unit tests included (test/dedup-store.test.js)
  • Manual test: store same text twice, verify dedup behavior
  • Manual test: store similar but different text, verify new record created
  • Test with custom dedupThreshold values

@daniel-harperdb daniel-harperdb force-pushed the feat/score-normalization branch from e5d6033 to 4312696 Compare March 19, 2026 20:57
@daniel-harperdb daniel-harperdb merged commit 37ce11a into feat/score-normalization Mar 19, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant