Skip to main content
Glama

write_symbols

Atomically write multiple files in one guarded batch, rolling back all changes if any fail, for deadlock-safe multi-file refactoring.

Instructions

Guarded write path (batch). All-or-nothing across files, deadlock-safe. Multi-file refactor? Use instead of N×write_symbol. New symbols: reindex first. For string params containing double quotes/backslashes, keep JSON escaping consistent across the whole string (escape uniformly or prefer full-width quotes), otherwise client-side parameter parsing fails.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
policyNo{all_or_nothing: true} (default) | {false} best-effort
safetyNoSafety profile: fast|standard|strict (default standard)
writesYesREQUIRED: Array of writes. Grouped by file internally.
workspace_dirYesREQUIRED: project root (abs). reindex first if new.
allow_unsafe_no_baseNoBypass base_version requirement for all writes (audited).

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. Changed2 schema fields changedv0.4.5-post9
    • addedInput schema / properties / policy / description
      Added value: +"{all_or_nothing: true} (default) | {false} best-effort"
    • addedInput schema / properties / safety / description
      Added value: +"Safety profile: fast|standard|strict (default standard)"
  2. First observed

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations provided, the description carries the transparency burden. It discloses key behaviors: atomicity ('All-or-nothing across files'), concurrency safety ('deadlock-safe'), and a client-side parsing pitfall (JSON escaping). These go beyond what the schema conveys, though it doesn't describe error handling beyond the atomicity trait.

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 description is three sentences, each earning its place: purpose+behavior, usage guidance+alternative, and a specific parameter caveat. It is front-loaded with the most important info and contains no fluff.

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 complex tool with 5 parameters and nested objects, the description covers the essential contextual aspects: atomicity, deadlock-safety, usage trigger, and a real-world pitfall. It does not explain return values, but no output schema exists, so that's less critical. Given the rich schema, the description is sufficiently complete.

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%, so baseline is 3. The description adds a valuable parameter-related nuance: the JSON escaping warning for string params, which is not present in the schema's per-parameter descriptions. This extra guidance justifies a 4.

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 clearly states it is a 'Guarded write path (batch)' with 'All-or-nothing across files', specifying both the verb (write) and resource (batch of files). It distinguishes itself from the sibling tool write_symbol by explicitly recommending 'Multi-file refactor? Use instead of N×write_symbol'.

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 explicitly gives a when-to-use scenario ('Multi-file refactor?') and an alternative ('Use instead of N×write_symbol'). It also adds a prerequisite ('New symbols: reindex first'). However, it does not explicitly state when NOT to use it or mention other alternatives like edit_batch, 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.

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/wulun811/LiuHe'

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