Skip to main content
Glama
MemoryHub
by hookmt

mem_save

Stores a new validated long-term memory entry with project context, source reference, and tags for shared or private agent knowledge.

Instructions

Zapisuje nowy wpis do pamięci długoterminowej z heurystyczną walidacją P04 pól i tagów (druga linia obrony; nie zastępuje wykluczenia źródeł).

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": {
      "project": "<project>",
      "title": "<title>",
      "content": "<content>",
      "source_ref": "<source_ref>",
      "tags": "<tags>"
    },
    "name": "mem_save"
  }
}

Input Schema

NameRequiredDescriptionDefault
tagsYesLista tagów ułatwiających wyszukiwanie (np. ['sprzet', 'rekuperacja', 'wentylator']).
scopeNoZasięg zapisu: 'shared' (domyślnie: baza wspólna dla obu agentów) lub 'private' (własna baza prywatna agenta).shared
titleYesZwięzły tytuł wpisu podsumowujący fakt lub decyzję.
authorNoAutor wpisu ('AG', 'Codex', 'User'). Domyślnie 'AG'.AG
contentYesPełna treść merytoryczna faktu, ustalenia lub decyzji architektonicznej.
item_idNoOpcjonalny własny identyfikator wpisu. Jeśli istnieje, sprawdzana jest zgodność projektu.
projectYesIdentyfikator projektu (np. 'PROJECT_ALPHA', 'PROJECT_BETA', 'GLOBAL').
created_atNoOpcjonalny znacznik czasu utworzenia ISO (np. przy imporcie danych archiwalnych).
entry_typeNoTyp wpisu ('decyzja_projektowa', 'fakt_sprzetowy', 'regula_operacyjna', 'stan_infrastruktury'). Domyślnie 'decyzja_projektowa'.decyzja_projektowa
source_refYesOdnośnik do kanonicznego źródła (np. 'NOTATNIK.md:L120', 'guide.md#section').
last_verified_atNoOpcjonalny znacznik czasu faktycznej weryfikacji. Jeśli brak przy nowym wpisie, status weryfikacji pozostaje pusty.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.1/5.0
Behavior3/5

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

With no annotations, the description carries the full burden. It does disclose a non-obvious behavioral trait: writes pass through heuristic 'P04' validation of fields and tags that acts as a second line of defense. However, it never says what happens when validation fails (rejection, warning, partial write), nor what is returned, and the 'P04' label is unexplained jargon.

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

Conciseness4/5

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

A single, front-loaded sentence with no filler; the core action leads and the validation qualifier follows in parentheses. It is efficient, though the jargon-dense phrasing reduces readability without adding compensating detail.

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 an 11-parameter mutation with no annotations and no output schema, one sentence is thin. It omits failure behavior, duplicate/collision handling on item_id, what the caller receives back, and any permission or scope implications of writing to the shared base.

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

Parameters3/5

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

Schema description coverage is 100%, so every one of the 11 parameters is already documented in the schema (scope, author, entry_type, item_id, timestamps, etc.). The description adds nothing beyond a generic mention of 'fields and tags', so the baseline 3 applies.

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

Purpose4/5

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

The description names a specific verb and resource ('Zapisuje nowy wpis do pamięci długoterminowej'), which is distinct from all listed siblings (deprecate, get_details, list, purge, search_index). It stops short of explicitly contrasting itself with any alternative, but the action is unambiguous.

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?

There is no statement of when to use this tool versus alternatives, no preconditions, and no guidance on choosing scope='shared' vs 'private' or entry_type. The clause about not replacing source exclusion is a caveat about the validation layer, not usage routing.

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