Skip to main content
Glama

duplicate_memory

Create an independent copy of a memory file under a new path, giving it its own address and history. Use to fork a memory into a variant while leaving the original unchanged.

Instructions

MUTATING: copy one curated memory file to a new path under a new stable identity. Writes to local disk and appends to the change timeline. The original is left untouched, and the copy gets its own docmancer://memory address and its own history, so the two diverge from here and editing one does not affect the other. Use it to fork an existing memory into a variant. Use move_memory instead when the original should not survive. Not idempotent: calling it twice with the same new_relative_path fails on the second call rather than creating a second copy. Parameters: address identifies the file to copy; new_relative_path is the copy's path in the tree, including the .md suffix, and must not already exist; expected_hash is the source file's current content_hash from read_memory, which guards against copying a revision you have not seen; project_path project root whose memory tree the operation applies to. Omit it to use the machine-wide tree, and always omit it when this server was started pinned to a project. Returns an object with the new copy's address, path, content_hash, and revision id.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
addressYesStable docmancer://memory/<id> address, relative path, or exact title of the memory file.
project_pathNoProject root whose memory tree the operation applies to. Omit it to use the machine-wide tree, and always omit it when this server was started pinned to a project.
expected_hashYesThe file's current content_hash from a prior read_memory call. A stale value fails safely instead of overwriting a newer revision.
new_relative_pathYesRelative path, including the .md suffix, for the memory file inside its selected memory tree.
Behavior5/5

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

The description goes well beyond the annotations (readOnlyHint=false, idempotentHint=false) by disclosing concrete side effects: 'Writes to local disk and appends to the change timeline,' original untouched, copy gets its own history, and the exact failure behavior on second call. This adds valuable context about mutations, safety (expected_hash), and project pinning behavior.

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?

Although longer than typical, every sentence earns its place. The structure is logical: core action, side effects, usage alternatives, idempotency warning, parameter explanations, project_path nuance, and return value. No redundancy or filler; information is dense but well-organized.

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

Completeness5/5

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

With no output schema, the description correctly specifies the return object ('address, path, content_hash, and revision id'). It also covers critical context such as project_path behavior, expected_hash safety, the divergence behavior, and failure mode, making it fully complete for a mutation tool of this complexity.

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% with detailed descriptions for each parameter, so the baseline is 3. The description adds meaning by noting new_relative_path 'must not already exist' and explaining expected_hash as a guard against copying unseen revisions, providing slightly more context than the schema alone.

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

Purpose5/5

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

The description opens with a specific verb and resource: 'copy one curated memory file to a new path under a new stable identity.' It clearly distinguishes from siblings by stating 'Use move_memory instead when the original should not survive,' and reinforces the copy semantics by explaining divergence and independent histories.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly states when to use ('Use it to fork an existing memory into a variant') and when not to ('Use move_memory instead when the original should not survive'). Also provides operational guidance on project_path omission and warns against non-idempotent double calls, giving clear context and exclusions.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/docmancer/docmancer'

If you have feedback or need assistance with the MCP directory API, please join our Discord server