deletecontext
Remove outdated or incorrect elements from the development knowledge graph by deleting specific entities, relationships, or observations. Maintains project accuracy as development contexts evolve, ensuring clean and updated representations.
Instructions
A versatile tool for removing elements from the software development knowledge graph. This tool allows precise deletion of entities, relationships between entities, or specific observations from existing entities. It helps maintain an accurate and current representation of the development context as projects evolve.
When to use this tool:
Removing deprecated or completed project components
Deleting obsolete relationships between development entities
Pruning outdated observations that no longer apply
Correcting errors in the knowledge graph
Cleaning up testing or prototype entities
Maintaining graph accuracy as project scope changes
Removing sensitive or confidential information
Archiving completed projects or components
Removing task sequencing relationships
Updating status or priority relationships
Key features:
Three distinct deletion operation types (entities, relations, observations)
Cascading deletion for entities (automatically removes related relations)
Precise deletion of specific observations without removing entire entities
Targeted relation removal with exact matching on from/to/type
Batch operations for efficient cleanup
JSON-formatted response with operation results
Secure validation before deletion
Parameters explained:
type: The deletion operation type to perform, which must be one of:
"entities" - Remove development entities and their relations
"relations" - Remove specific relationships between entities
"observations" - Remove specific observations from entities
data: Operation-specific data structure:
For "entities": Array of entity names to delete
For "relations": Array of objects with { from, to, relationType }
For "observations": Array of objects with { entityName, observations[] }
Deletion behavior by type:
"entities": Completely removes the specified entities and any relations where they appear
"relations": Removes only the exact relations specified, matching on all three attributes
"observations": Removes specific observations from entities while preserving the entities themselves
Safety considerations:
Entity deletion cascades to relations, so be careful when deleting key entities
There is no "undo" operation, so confirm deletions carefully
Partial graph information can lead to inconsistent views
Relations require entities on both ends to exist
Instead of deleting status or priority entities, prefer updating them using appropriate tools
Deleting task sequencing relations may disrupt project planning and dependencies
You should:
Identify the specific elements that need to be removed
Choose the appropriate deletion type (entities, relations, or observations)
Structure your data according to the deletion type's requirements
Start with the most specific deletions (observations) before broader ones
Verify the entities or relations exist before attempting deletion
To update status or priority, create new has_status or has_priority relations rather than deleting old ones
When removing task sequencing, consider how it affects other tasks and milestones
Check the operation result to confirm successful deletion
Consider documenting major deletions as observations on related entities
When removing an entire project, first delete its components for cleaner removal
Input Schema
Name | Required | Description | Default |
---|---|---|---|
data | Yes | Data for the deletion operation, structure varies by type but must be an array | |
type | Yes | Type of deletion operation: 'entities', 'relations', or 'observations' |