Skip to main content
Glama

sync_memory

Idempotent

Add shared rules to every agent instruction file via a managed block and sync missing rules across targets, returning a diff before applying changes.

Instructions

Add shared rules to every agent's instruction file via a managed block.

rules: rules to add; omit to sync the drift (rules some agents are missing). targets: agents to update (claude -> CLAUDE.md, codex/cursor/opencode -> AGENTS.md, gemini -> GEMINI.md); defaults to agents that already have one. scope: "project" (repo files) or "user" (~/.claude, ~/.codex, ~/.gemini). Returns a unified diff. Writes only when apply=true, and only edits the

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "sync_memory"
  }
}

Input Schema

NameRequiredDescriptionDefault
applyNo
rulesNo
scopeNoproject
projectNo
targetsNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.0

TDQS

A4.3/5.0
Behavior5/5

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

Beyond the idempotentHint and destructiveHint=false annotations, it discloses the two genuinely important behaviors: nothing is written unless apply=true (so a call is a preview by default) and writes are confined to the agent-history begin/end managed block, meaning hand-written content is untouched. That is exactly the mutation-safety context an agent needs before invoking a write-capable tool.

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

Conciseness5/5

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

The core action is front-loaded, then the three most ambiguous parameters are defined in one line each, and it closes with the return value and write-safety constraint. There is no filler, and the parameter-per-line layout makes it easy to scan.

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 5-parameter mutation tool with zero schema descriptions, it covers operation modes, targeting defaults, scope values, write gating, and edit boundaries; an output schema exists, so return values need no further elaboration. The omission of the project parameter is the only substantive gap.

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?

With 0% schema description coverage, the description carries the full burden, and it defines rules, targets (including the agent-name to filename mapping such as claude -> CLAUDE.md and codex/cursor/opencode -> AGENTS.md), scope ('project' repo files vs 'user' home dirs), and apply's write gate. The fifth parameter, project, is never mentioned, which is the one remaining semantic hole.

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 first sentence gives a specific verb (add shared rules) and resource (every agent's instruction file via a managed block), and the 'rules: omit to sync the drift' clause clarifies a second mode of operation. It is clear what the tool does, but it doesn't explicitly contrast itself with nearby siblings such as suggest_rules or suggest_instruction_updates, leaving that inference to the agent.

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?

It gives concrete when-to-use conditions per parameter: omit rules to reconcile drift that some agents are missing, and targets default to agents that already have an instruction file. Scope values are spelled out with their filesystem meaning. What is missing is explicit guidance on when to call suggest_rules or list_agent_memory instead, so the routing story is incomplete.

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