Add qdrant-delete tool for memory management#116
Open
sascha08-15 wants to merge 1 commit intoqdrant:masterfrom
Open
Add qdrant-delete tool for memory management#116sascha08-15 wants to merge 1 commit intoqdrant:masterfrom
sascha08-15 wants to merge 1 commit intoqdrant:masterfrom
Conversation
Add a delete tool that removes memories by semantic search, enabling cleanup of stale or contradictory entries. The tool finds the closest matching point(s) and deletes them, returning confirmation of what was removed. Changes: - QdrantConnector.delete() method using semantic search + point deletion - qdrant-delete tool registration in MCP server (write-mode only) - TOOL_DELETE_DESCRIPTION setting for customization - 5 integration tests covering deletion scenarios - README documentation for the new tool and env var Closes qdrant#74, closes qdrant#69 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Author
|
Verified two previously unchecked test-plan items against the current delete implementation:
So the remaining unchecked item in this PR is the manual MCP inspector / One more repo-management note: issue #101 is specifically the delete request, so this PR is the one that should close it on merge. That likely belongs in the PR body as |
Closed
Author
|
fastmcp inspection done. |
4 tasks
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
Adds a
qdrant-deletetool that removes memories by semantic search, enabling cleanup of stale or contradictory entries. This addresses a gap where memories could be stored and retrieved but never removed, leading to accumulation of outdated information.QdrantConnector.delete()— finds the closest matching point(s) via embedding similarity and deletes them, returning the deleted entries for confirmationqdrant-deletetool — registered alongsideqdrant-store(write-mode only, respectsread_onlysetting), withcollection_namepartial application when a default is configuredTOOL_DELETE_DESCRIPTION— customizable tool description via environment variable, consistent with existingTOOL_STORE_DESCRIPTION/TOOL_FIND_DESCRIPTIONMotivation
Without a delete capability, stale memories accumulate and can contradict newer information. Users have no way to clean up outdated entries, which degrades the quality of semantic search results over time.
Closes #101, closes #74, closes #69
Test plan
fastmcp dev)read_onlymode does not exposeqdrant-deleteCOLLECTION_NAMEdefault applies to delete toolDesign decisions
qdrant-find)limit=1— conservative default to avoid accidental mass deletion; callers can increase if neededif not self.qdrant_settings.read_only:block, consistent withqdrant-store