Skip to main content
Glama

memory_file_context_tool

Store or refresh a file's current-state TLDR keyed by content hash, and check before reading whether cached context is still fresh; unchanged files return fresh without writing.

Instructions

Return and refresh a file's current-state TLDR, keyed by content hash.

Use this after reading a file to store what the file now does, or before a read to check whether a cached TLDR is still fresh. An unchanged file returns fresh: true without writing.

Args: path: File path, relative to the project or absolute reason: Why the file state was captured statement: Optional override for the generated TLDR details: Optional additional details tags: Extra tags refresh: Update the stored TLDR when the content changed title: Optional title override project: Optional project root path

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": {
      "path": "<path>"
    },
    "name": "memory_file_context_tool"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathYes
tagsNo
titleNo
reasonNo
detailsNo
projectNo
refreshNo
statementNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.11.0

TDQS

A3.6/5.0
Behavior3/5

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

With no annotations at all, the description carries the full behavioral burden, and it does disclose the key trait: an unchanged file returns fresh: true without writing, and refresh controls whether a changed file's TLDR is updated. However, it says nothing about what happens when refresh is false and content changed, whether the write is durable, permission or auth requirements, or concurrency behavior for a tool that mutates stored memory.

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?

The purpose and the usage rule are front-loaded in the first two sentences, then the parameters are enumerated compactly. The Args block is partly redundant with the schema but justified given the 0% schema coverage; no sentence is wasted, though nothing is grouped or ordered by importance.

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

Completeness3/5

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

An output schema exists, so return shapes need not be explained, and the caching/no-write behavior is covered. Still, for a tool with eight parameters, zero schema descriptions, and no annotations, the definition leaves the meaning of 'TLDR' generation, the storage target, and the failure/edge behavior underspecified for confident invocation.

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 0%, so the description must compensate, and it does list all eight parameters. Some entries add real meaning (path may be relative or absolute; refresh updates when content changed), but others merely restate the name (tags: Extra tags, title: Optional title override, details: Optional additional details), leaving half the surface effectively undocumented.

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?

It names a specific verb pair (return and refresh) and a specific resource (a file's current-state TLDR) with a stated keying mechanism (content hash), which is far more than a restatement of the tool name. It stops short of naming a sibling, but the before-read/after-read framing already separates it from the register_file_* tools.

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 second sentence gives two concrete invocation contexts: after reading a file to record what it now does, and before a read to check cached freshness. That is clear when-to-use guidance. It does not name an alternative tool or an explicit when-not-to-use case, so it falls short of a 5.

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