Skip to main content
Glama

fs_delete

Deletes files or directories inside the sandbox, requiring deletion to be enabled; set recursive to true when removing a directory.

Instructions

删除沙箱内的文件或目录(需开启 files.allow_delete)。

Args: path: 相对于沙箱根目录的路径。 recursive: 删除目录时必须为 true。

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": {
      "path": "<path>"
    },
    "name": "fs_delete"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathYes
recursiveNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.5/5.0
Behavior3/5

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

With no annotations at all, the description carries the full behavioral burden, and it does disclose two important traits: the config prerequisite and the requirement that recursive be true to remove directories. It does not say the deletion is permanent/irreversible, what happens to non-empty directories when recursive is false, or whether missing paths raise an error — significant omissions for a destructive tool with zero annotation coverage.

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 and the config prerequisite are front-loaded in the first line, followed by terse per-parameter notes. No filler, though the docstring-style Args block is slightly redundant with the schema's parameter names.

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

Completeness3/5

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

An output schema exists, so return values need not be explained, and the two parameters are both covered. What is missing for a destructive operation with no annotations is the consequence model: irreversibility, failure modes, and whether the sandbox root itself can be removed.

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 compensate, and it largely does: path is defined as relative to the sandbox root, and recursive is defined in terms of the condition that requires it (directories), which is far more useful than the bare boolean default of false. Only edge cases (empty string, absolute paths, symlinks) are undocumented.

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?

States a specific verb and resource: delete a file or directory inside the sandbox. An agent can distinguish it from fs_write/fs_read/fs_stat without inspecting the schema. It does not explicitly contrast with siblings, but no sibling performs deletion, so the purpose is unambiguous.

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

Usage Guidelines3/5

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

Adds a real gating condition (files.allow_delete must be enabled) that the agent would otherwise discover only by failing. However it gives no guidance on when deletion is appropriate versus alternatives, no warning to confirm with the user first, and no mention of error behavior for missing or non-empty targets.

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