delete_error
Remove an error record from the Tribal Knowledge Service by specifying its UUID. Confirm deletion status based on record existence.
Instructions
Delete an error record.
Args:
error_id: UUID of the error record
Returns:
True if deleted, False if not found
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| error_id | Yes |
Implementation Reference
- src/mcp_server_tribal/mcp_app.py:224-239 (handler)MCP tool handler for 'delete_error'. Converts string error_id to UUID and delegates deletion to the storage layer.@mcp.tool() async def delete_error(error_id: str) -> bool: """ Delete an error record. Args: error_id: UUID of the error record Returns: True if deleted, False if not found """ try: uuid_id = UUID(error_id) return await storage.delete_error(uuid_id) except ValueError: return False
- Concrete implementation of delete_error in ChromaStorage, which performs the actual deletion in ChromaDB.async def delete_error(self, error_id: UUID) -> bool: """Delete an error record by ID.""" try: result = self.collection.get(ids=[str(error_id)]) if not result["ids"]: return False self.collection.delete(ids=[str(error_id)]) return True except Exception: return False
- Abstract method definition in StorageInterface that the MCP handler calls.@abc.abstractmethod async def delete_error(self, error_id: UUID) -> bool: """ Delete an error record by ID. Args: error_id: The UUID of the error record to delete Returns: True if the error was deleted, False otherwise """ pass