Skip to content

fix: address review feedback on semantic memory - #791

Open
Dhirenderchoudhary wants to merge 1 commit into
Nano-Collective:feat/semantic-memoryfrom
Dhirenderchoudhary:fix/619-semantic-memory-review-fixes-v3
Open

fix: address review feedback on semantic memory#791
Dhirenderchoudhary wants to merge 1 commit into
Nano-Collective:feat/semantic-memoryfrom
Dhirenderchoudhary:fix/619-semantic-memory-review-fixes-v3

Conversation

@Dhirenderchoudhary

Copy link
Copy Markdown
Contributor

Description

  • Retrieval: added a stopword list and a minimum relevance-ratio threshold to findRelevantMemories so incidental word overlap (e.g. "the", "in") no longer scores as relevant
  • /memory propose: capped candidates per message and truncated evidence to snippets instead of full messages; explicit user statements can now be proposed even without matching one of the five keyword categories, while uncategorized assistant chatter is still filtered out
  • Added /memory accept <n> to save a proposal directly instead of retyping it into /remember
  • Wired project-memory recall into --plain and --acp, matching what the TUI already did (previously memories saved on those surfaces were never recalled)
  • The semanticMemoryEnabled setting now gates writes (/remember, /memory accept), not just recall
  • Added docs/features/semantic-memory.md and /remember//memory entries in commands.md
  • Non-blocking cleanups: fixed a read-modify-write race in SemanticMemoryManager, fixed the token-budget loop silently reordering memories by size, fenced the injected memory content in the system prompt, removed a dead MemorySourceType value, fixed an order-dependent warning on accepted proposals

Closes #619

Type of Change

  • Bug fix

Changeset

  • Added a changeset (pnpm changeset) describing this change for the changelog

Testing

Automated Tests

  • New features include passing tests in .spec.ts/tsx files
  • All existing tests pass (pnpm test:all completes successfully)
  • Tests cover both success and error scenarios

Manual Testing

  • Tested with Ollama
  • Tested with OpenRouter
  • Tested with OpenAI-compatible API
  • Tested MCP integration (if applicable)

Checklist

  • Code follows project style guidelines
  • Self-review completed
  • Documentation updated (if needed)
  • No breaking changes (or clearly documented)
  • Appropriate logging added using structured logging (see CONTRIBUTING.md)

@Dhirenderchoudhary
Dhirenderchoudhary marked this pull request as ready for review August 6, 2026 10:10
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