Skip to main content
Glama
ks6573
by ks6573

write_file

Write text content to any file path, automatically creating parent directories and overwriting existing files by default. Use for saving notes, configs, scripts, or output.

Instructions

Write text content to a file at the given path. Creates parent directories as needed. Overwrites by default. Use for saving notes, configs, scripts, or any text output.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYesAbsolute or home-relative path where the file should be written.
contentYesText content to write.
overwriteNoIf false, returns an error if the file already exists. Default true.
Behavior4/5

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

Annotations indicate this is a write operation (readOnlyHint=false, destructiveHint=false, idempotentHint=false). The description adds behavior not captured by annotations: creates parent directories, overwrites by default. It also implies that setting overwrite=false will error on existing files (matching the schema). This is valuable context. No contradiction found.

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, all of which provide distinct, useful information. It front-loads the core purpose in the first sentence, then adds creation behavior and use cases. No wasted words or redundancy.

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?

Given the relative simplicity of this tool (3 parameters, all documented, no output schema), the description covers the core purpose, key behavioral constraints (parent dir creation, overwrite default), and typical use cases. It lacks some details like error conditions or permissions, but this is sufficient for an AI agent to select and invoke the tool correctly in most contexts.

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% for parameters, so the schema already documents path, content, and overwrite. The description adds semantic context beyond the schema: 'absolutely or home-relative path' clarifies path format, and 'overwrites by default' reinforces the overwrite behavior. 'Text content to write' is aligned with the content parameter but adds no new information.

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 states exactly what the tool does: 'Write text content to a file at the given path.' This clearly identifies the verb (write), resource (file), and key behavior (overwrites by default). It also indicates primary use cases ('saving notes, configs, scripts, or any text output'), distinguishing it from other file operations like read_file or delete_file.

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?

The description mentions it overwrites by default and creates parent directories as needed, which are important usage considerations. It also gives examples of when to use it (saving notes/configs/scripts). However, it doesn't explicitly mention alternatives like edit_file or run_shell_command for file writing, so it's missing explicit when-not-to-use guidance.

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/ks6573/SysControl'

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