Skip to content

fix(memory): consolidation prompt isolation, Update in-place semantics, concurrent embeddings#2400

Merged
bug-ops merged 1 commit intomainfrom
2362-consolidation-prompt
Mar 29, 2026
Merged

fix(memory): consolidation prompt isolation, Update in-place semantics, concurrent embeddings#2400
bug-ops merged 1 commit intomainfrom
2362-consolidation-prompt

Conversation

@bug-ops
Copy link
Copy Markdown
Owner

@bug-ops bug-ops commented Mar 29, 2026

Summary

Test plan

  • cargo +nightly fmt --check — clean
  • cargo clippy --all-targets --all-features --workspace -- -D warnings — 0 warnings
  • cargo nextest run --workspace --all-features --lib --bins — 7235 passed (+2 new tests)
  • Updated run_consolidation_sweep_update_db_state to verify in-place semantics (no new row inserted, content changed on existing row)
  • Added apply_consolidation_update_in_place — verifies same row ID with updated content, join table entry, source marked consolidated=1
  • Added apply_consolidation_update_skips_below_threshold — verifies content unchanged when confidence < threshold

Closes #2362, #2364, #2365

@github-actions github-actions bot added documentation Improvements or additions to documentation memory zeph-memory crate (SQLite) rust Rust code changes bug Something isn't working labels Mar 29, 2026
@bug-ops bug-ops enabled auto-merge (squash) March 29, 2026 23:24
@github-actions github-actions bot added the size/L Large PR (201-500 lines) label Mar 29, 2026
…s, concurrent embeddings (#2362, #2364, #2365)

- Split consolidation LLM prompt into Role::System (instructions) + Role::User
  (memory entries) to prevent adversarial content injection (#2362)
- Add apply_consolidation_update: in-place UPDATE on target_id instead of
  duplicating apply_consolidation_merge; target_id is no longer ignored (#2364)
- Replace sequential embed loop with futures::future::join_all for concurrent
  embedding in run_consolidation_sweep (#2365)
- Update run_consolidation_sweep_update_db_state test for new in-place semantics
- Add apply_consolidation_update_in_place and apply_consolidation_update_skips_below_threshold tests
@bug-ops bug-ops force-pushed the 2362-consolidation-prompt branch from 25160ad to fcfccc0 Compare March 29, 2026 23:32
@bug-ops bug-ops merged commit 9581664 into main Mar 29, 2026
47 of 49 checks passed
@bug-ops bug-ops deleted the 2362-consolidation-prompt branch March 29, 2026 23:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working documentation Improvements or additions to documentation memory zeph-memory crate (SQLite) rust Rust code changes size/L Large PR (201-500 lines)

Projects

None yet

1 participant