Skip to main content
Glama

cad_change_writeback

Destructive

Write modified source files back to original shared-drive or PDM checkout locations with backups and safeguards for conflicts, read-only files, or disallowed paths; confirm=false previews the plan.

Instructions

把已发布版本中修改过的源文件回写到原位置(共享盘 / PDM 检出目录)。confirm=false 只列出计划; 原文件先备份到发布目录 _writeback_backup;原文件期间被别人改过(冲突)、只读(PDM 未检出)、 或不在 policy.writeback_allow 中的都不会覆盖。平台新建的文件不回写,需按公司流程入库。

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": "cad_change_writeback"
  }
}

Input Schema

NameRequiredDescriptionDefault
confirmNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already declare destructiveHint=true and non-idempotent, and the description adds substantial context beyond them: originals are backed up to _writeback_backup first, files conflicting with outside edits, read-only (PDM not checked out), or outside policy.writeback_allow are skipped rather than overwritten. That is exactly the safety-critical behavior an agent needs before calling a destructive writeback.

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 core action is front-loaded in the first clause, followed by the dry-run mode and then the exclusion rules in a compact sequence. It is dense but every clause carries operational meaning; minor tightening of the backup/policy sentences would be possible.

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?

For a destructive, non-idempotent single-parameter tool, the description covers backup behavior, conflict/read-only/policy exclusions, and the platform-created-file carve-out. An output schema exists, so return values need not be described, and nothing an agent needs before invoking is missing.

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 description coverage is 0%, so the description must carry the parameter — and it does, explaining that confirm=false only lists the plan (dry-run) while the write occurs otherwise. Only the explicit meaning of confirm=true is left implicit.

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 + resource: writing back modified source files from a published version to their original locations (shared drive / PDM checkout directory). It also scopes what it will NOT do (files newly created on the platform are not written back), which lets an agent distinguish this from the other cad_change_* lifecycle 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?

It states the operating context (after a published version) and explains the confirm=false dry-run mode that lists the plan before any write. It does not explicitly name a sibling alternative for the 'list only' case, so it stops short of full routing guidance.

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