Skip to main content
Glama
Forgetful

Forgetful

by ScottRBK

execute_forgetful_tool

Runs any registered Forgetful tool to search, create, update, link, or organize memories, projects, entities, documents, and code artifacts for LLM agents.

Instructions

Execute any registered tool dynamically. Forgetful is a semantic memory system for LLMs.

Quick Start - One-Shot Examples (all required params shown)

Memory Operations:

  • Search: execute_forgetful_tool("query_memory", {"query": "search terms", "query_context": "why searching"})

  • Create: execute_forgetful_tool("create_memory", {"title": "Short title", "content": "Memory content (<2000 chars)", "context": "Why this matters", "keywords": ["kw1", "kw2"], "tags": ["tag1"], "importance": 7, "project_ids": [1]})

  • Create with provenance: execute_forgetful_tool("create_memory", {"title": "...", "content": "...", "context": "...", "keywords": [...], "tags": [...], "importance": 7, "source_repo": "owner/repo", "source_files": ["src/main.py"], "confidence": 0.85, "encoding_agent": "claude-sonnet-4"})

  • Update: execute_forgetful_tool("update_memory", {"memory_id": 1, "content": "new content"})

  • Get: execute_forgetful_tool("get_memory", {"memory_id": 1})

  • Link: execute_forgetful_tool("link_memories", {"memory_id": 1, "related_ids": [2, 3]})

  • Unlink: execute_forgetful_tool("unlink_memories", {"source_id": 1, "target_id": 2})

  • Obsolete: execute_forgetful_tool("mark_memory_obsolete", {"memory_id": 42, "reason": "Outdated approach", "superseded_by": 100})

Project Organization:

  • List: execute_forgetful_tool("list_projects", {})

  • Create: execute_forgetful_tool("create_project", {"name": "Project Name", "description": "What this project is about", "project_type": "development"})

  • Get: execute_forgetful_tool("get_project", {"project_id": 1})

  • Query: execute_forgetful_tool("query_memory", {"query": "search terms", "query_context": "why searching", "project_ids": [1]})

Entities (people, orgs, devices):

  • Create: execute_forgetful_tool("create_entity", {"name": "Sarah Chen", "entity_type": "Individual", "notes": "Backend developer", "aka": ["Sarah", "S.C."]})

  • Search: execute_forgetful_tool("search_entities", {"query": "Sarah"}) # Searches name AND aka

  • Link to memory: execute_forgetful_tool("link_entity_to_memory", {"entity_id": 1, "memory_id": 1})

  • Unlink from memory: execute_forgetful_tool("unlink_entity_from_memory", {"entity_id": 1, "memory_id": 1})

  • Link to project: execute_forgetful_tool("link_entity_to_project", {"entity_id": 1, "project_id": 1})

  • Unlink from project: execute_forgetful_tool("unlink_entity_from_project", {"entity_id": 1, "project_id": 1})

Documents (long-form content >300 words):

  • Create: execute_forgetful_tool("create_document", {"title": "Doc Title", "description": "Brief summary", "content": "Long content...", "document_type": "text", "project_id": 1})

Code Artifacts (reusable snippets):

  • Create: execute_forgetful_tool("create_code_artifact", {"title": "Snippet Title", "description": "What this does", "code": "def example(): pass", "language": "python", "project_id": 1})

Linking Best Practices

Always link related items for discoverability:

  • When creating documents, link atomic memories: create_memory(..., document_ids=[doc_id])

  • When creating code artifacts, link to memories: create_memory(..., code_artifact_ids=[artifact_id])

  • Link memories to each other: link_memories(memory_id=1, related_ids=[2, 3])

  • Link entities to memories: link_entity_to_memory(entity_id=1, memory_id=1)

  • Link entities to projects: link_entity_to_project(entity_id=1, project_id=1)

Tool Categories

memory | project | entity | document | code_artifact | linking | user

Use discover_forgetful_tools(category?) for full parameter details and optional params.


Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "tool_name": "<tool_name>",
      "arguments": "<arguments>"
    },
    "name": "execute_forgetful_tool"
  }
}

Input Schema

NameRequiredDescriptionDefault
argumentsYesDictionary of arguments to pass to the tool
tool_nameYesName of the tool to execute

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.7.0
    • addedInput schema / properties / arguments / description
      Added value: +"Dictionary of arguments to pass to the tool"
    • addedInput schema / properties / tool_name / description
      Added value: +"Name of the tool to execute"
  2. First observedv0.1.0

TDQS

A4.1/5.0
Behavior3/5

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

No annotations and no output schema, so the description carries the full behavioral burden. It discloses that many of the dispatched operations are mutations (create_memory, update_memory, mark_memory_obsolete) and shows the shape of the calls, but says nothing about return format, error behavior for an unknown tool_name or malformed arguments, or whether dispatched writes are reversible. That is a real gap for a universal dispatcher, though the per-tool parameter examples do add genuine context.

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

Conciseness3/5

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

Quick Start examples are front-loaded and well-scannable, and the category list at the end is efficient. However, every example redundantly repeats the full execute_forgetful_tool(...) wrapper rather than showing just tool_name plus arguments, and the catalog substantially duplicates the scope of discover_forgetful_tools, so several sentences do not earn their place.

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

Completeness4/5

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

For a universal dispatcher fronting roughly twenty upstream tools, the description covers the main workflows (memory, project, entity, document, code artifact, linking) with required parameters and a linking-practices section. It is nearly complete, with the remaining hole being dispatch failure semantics and return shape, which no output schema covers.

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

Parameters5/5

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

The schema coverage is 100% but the schema itself is opaque — `arguments` is only described as 'Dictionary of arguments to pass to the tool'. The description compensates by naming the legal tool_name values and listing the argument keys each one expects (e.g. mark_memory_obsolete needs memory_id, reason, superseded_by), which is meaning that exists nowhere in the schema.

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

Purpose5/5

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

States a specific verb and resource: 'Execute any registered tool dynamically', then names the domain (Forgetful semantic memory system). It also names the sibling it is not — 'Use discover_forgetful_tools(category?) for full parameter details' — so an agent can tell dispatch from discovery without opening either schema.

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

Usage Guidelines4/5

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

The description gives concrete when-to-use guidance by enumerating the registered tools (query_memory, create_memory, link_memories, etc.) with required arguments, plus a 'Linking Best Practices' block telling the agent to link related items for discoverability. It falls short of a 5 because it never states exclusions or how this differs from the sibling how_to_use_forgetful_tool, which a confused agent could equally reach for.

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