Skip to main content
Glama

update_memento

Modify stored memories by updating titles, content, summaries, tags, or importance levels to maintain accurate and current information in your knowledge base.

Instructions

Update an existing memento

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
memory_idYesID of the memory to update
titleNo
contentNo
summaryNo
tagsNo
importanceNo

Implementation Reference

  • The handle_update_memento function handles the logic for updating existing memory entries in the database.
    @handle_tool_errors("update memory")
    async def handle_update_memento(
        memory_db: SQLiteMemoryDatabase, arguments: Dict[str, Any]
    ) -> CallToolResult:
        """Handle update_memory tool call.
    
        Args:
            memory_db: Database instance for memory operations
            arguments: Tool arguments from MCP call containing:
                - memory_id: ID of memory to update (required)
                - title: New title (optional)
                - content: New content (optional)
                - summary: New summary (optional)
                - tags: New tags list (optional)
                - importance: New importance score (optional)
    
        Returns:
            CallToolResult with success message or error
        """
        # Validate input arguments
        validate_memory_input(arguments)
    
        memory_id = arguments["memory_id"]
    
        # Get existing memory
        memory = await memory_db.get_memory(memory_id, include_relationships=False)
        if not memory:
            return CallToolResult(
                content=[TextContent(type="text", text=f"Memory not found: {memory_id}")],
                isError=True,
            )
    
        # Update fields
        if "title" in arguments:
            memory.title = arguments["title"]
        if "content" in arguments:
            memory.content = arguments["content"]
        if "summary" in arguments:
            memory.summary = arguments["summary"]
        if "tags" in arguments:
            memory.tags = arguments["tags"]
        if "importance" in arguments:
            memory.importance = arguments["importance"]
    
        # Update in database
        success = await memory_db.update_memory(memory)
    
        if success:
            return CallToolResult(
                content=[
                    TextContent(
                        type="text", text=f"Memory updated successfully: {memory_id}"
                    )
                ]
            )
        else:
            return CallToolResult(
                content=[
                    TextContent(type="text", text=f"Failed to update memory: {memory_id}")
                ],
                isError=True,
            )
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full disclosure burden but fails to deliver. It does not specify partial vs. full replacement semantics, what happens if the memory_id doesn't exist, whether the operation is atomic, or what constitutes a successful update. The term 'update' implies mutation but lacks critical behavioral context.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness2/5

Is the description appropriately sized, front-loaded, and free of redundancy?

While brief at four words, this represents under-specification rather than effective concision. Given the low schema coverage, lack of annotations, and mutation complexity, the description is inappropriately sized—every sentence fails to earn its place because critical information is absent.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 6-parameter mutation tool with no output schema and minimal input documentation, the description is severely incomplete. It lacks coverage of updatable fields, return values, error scenarios, and relationships to the 15+ sibling tools in the memento ecosystem.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is only 17% (just memory_id described). The description fails to compensate for this gap, mentioning none of the five undocumented parameters (title, content, summary, tags, importance). It does not explain that unspecified fields likely remain unchanged, nor the 0-1 scale for importance, nor tag formatting expectations.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose3/5

Does the description clearly state what the tool does and how it differs from similar tools?

States the specific action (update) and resource (memento) and distinguishes from create/delete siblings via 'existing'. However, fails to differentiate from similar update-like siblings such as adjust_memento_confidence or boost_memento_confidence, leaving ambiguity about which modification tool to use.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The word 'existing' minimally implies this requires a pre-existing memento ID, suggesting when NOT to use it for new entries. However, it provides no explicit guidance on when to choose this over store_memento, adjust_memento_confidence, or other mutation tools, and mentions no prerequisites or error conditions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/x-hannibal/mcp-memento'

If you have feedback or need assistance with the MCP directory API, please join our Discord server