Skip to main content
Glama
Zifu Memory
by tanbopiao

zifu_replace

Replace an entity's outdated fact with a new statement, marking the old fact as replaced and preserving its history for audit.

Instructions

契约2:改口走 replace,旧事实标记 replaced 并留痕,历史不删。

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": {
      "old_id": "<old_id>",
      "new_statement": "<new_statement>",
      "reason": "<reason>",
      "entity": "<entity>"
    },
    "name": "zifu_replace"
  }
}

Input Schema

NameRequiredDescriptionDefault
entityYes
old_idYes
reasonYes
new_statementYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.3/5.0
Behavior3/5

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

With no annotations supplied, the description carries the behavioral burden and does disclose key behavior: the old fact is marked replaced, a trace is kept, and history is not deleted. It still omits permissions, idempotency, failure handling, and other mutation-side effects.

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 description is a single compact sentence with the action front-loaded after the contract label. It avoids verbosity, though the unexplained '契约2' prefix adds minor noise.

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 a four-parameter mutation tool with no annotations and 0% schema description coverage, the description is too thin. It omits parameter meanings and invocation prerequisites, though the existing output schema reduces the need to describe return values.

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

Parameters2/5

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

Schema description coverage is 0% for four required parameters. The description only vaguely implies old_id and new_statement through '旧事实' and '改口'; it never explains what 'reason' or 'entity' mean or how any parameter maps to the operation.

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 states that changing a statement goes through replace and that the old fact is marked replaced, so an agent can infer the core replace operation. It does not name sibling tools such as zifu_write or zifu_assert to distinguish behavior, and the '契约2' label is unexplained.

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 a clear trigger: use replace when '改口' (changing a statement). It does not state when not to use the tool or name alternatives, so it falls short of explicit when/when-not guidance.

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