Skip to main content
Glama

Stash — Shared AI Memory

Write memory

write

Store a memory entry into a namespace. Use this constantly — for facts, rules, lessons, patterns, goals, progress, decisions, preferences, project context, people, workflows, inferences, and anything the user implies. One idea per entry. Write with enough detail that a future session can act on this memory cold — include what, why, edge cases, and consequences. Every entry written to Stash is a token you can drop from your active context window, making every subsequent LLM call cheaper. When in doubt, write it. An unwritten memory is a lost memory and a cost you keep paying. Always name the namespace: there is no default, so pass path (or namespace) — write({path: "/projects/", content: "..."}) — and pass "/" explicitly to write to the root.

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": {
      "content": "<content>"
    },
    "name": "write"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathNoNamespace to write to, e.g. /projects/myapp. Required unless 'namespace' is given instead. There is no default: pass "/" explicitly to write to the root.
contentYesMemory text to store.
namespaceNoAlias for 'path'.

Output Schema

NameRequiredDescriptionDefault
brainYes
tokensYes
created_atYes
entry_uuidYes
next_actionsNo
namespace_pathYes
similar_existingNo

Schema Changelog

Changes observed during successful MCP inspections.

No schema history has been recorded yet.

TDQS

A3.9/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=false, destructiveHint=false, idempotentHint=false, openWorldHint=false, so the safety profile is covered. The description adds genuinely non-structured context: the token-economy rationale for offloading context, the strict requirement that a namespace be supplied because no default exists, and the expectation of self-sufficient detail for cold reads. It omits the consequence of non-idempotency (whether repeated identical writes create duplicates or overwrite) and any error behavior.

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?

The purpose and the namespace requirement are correctly front-loaded, but the body is padded with motivational restatement — "When in doubt, write it. An unwritten memory is a lost memory and a cost you keep paying" — and the token-cost point is made twice. The long idealized content taxonomy is useful, yet several sentences are rhetoric rather than instruction.

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 simple single-entry write with a full output schema, the description covers purpose, granularity (one idea per entry), content depth, and the mandatory namespace. What an agent still cannot answer from the definition is whether a second identical write duplicates or supersedes, which matters given idempotentHint=false, and whether namespaces must pre-exist (mkns exists as a sibling).

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

Parameters4/5

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

Schema coverage is 100% and the schema already documents path, namespace-as-alias, and the explicit "/" for root, so most of the description's parameter text is duplication. It earns a step above baseline by supplying a concrete call form, write({path: "/projects/<name>", content: "..."}), and by stating the path-or-namespace precedence in one place, which is easier to act on than reading two sibling property descriptions.

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?

"Store a memory entry into a namespace" gives a specific verb (store) and resource (memory entry) plus the scoping concept of a namespace. It is clear on its own, but it never distinguishes itself from plausible siblings such as batch_write (bulk cost-efficient path) or update (revision path), so an agent must infer the boundary from names alone.

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 when-to-use guidance is unusually explicit and enumerated (facts, rules, lessons, patterns, goals, progress, decisions, preferences, project context, people, workflows, inferences) and reinforced with a default heuristic, "When in doubt, write it." It stops short of exclusions or alternatives — nothing says when to prefer batch_write for many entries or update to revise an existing one — so it lands at clear-context-without-alternatives.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources