Skip to main content
Glama

Save File

save_file

Export molecular selections or complete PyMOL sessions to a file, with the output format set by the file extension.

Instructions

Save a selection/session to a file (format from extension).

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

Input Schema

NameRequiredDescriptionDefault
pathYesOutput path; extension sets format (.pdb, .pse, .png, .mol2, ...).
stateNoState to save (-1 = current, 0 = all).
selectionNoSelection to save.all

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.9/5.0
Behavior2/5

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

With no annotations, the description carries full behavioral burden and falls short: it does not say whether an existing file is overwritten, whether the target directory must exist, what permissions or state prerequisites apply, or how errors surface. Only the format-from-extension rule adds behavior beyond the schema, and that rule is already in the path parameter description.

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?

A single short sentence that front-loads the verb and resource with no wasted words. It is efficient but bordering on under-specified given the absence of annotations.

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 no explanation, and all three parameters are self-documenting. What remains missing for a filesystem-writing tool is any disclosure of overwrite behavior and failure conditions, which an agent needs before invoking it.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the path/state/selection semantics are already fully documented, including the -1 current vs 0 all convention. The description's parenthetical about extension-based format duplicates the path description rather than adding meaning, so baseline 3 applies.

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 ('Save') and resource ('selection/session to a file'), plus the format-inference rule from the extension. This clearly separates it from siblings like render_image or run_pml, though it never names an alternative explicitly.

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

Usage Guidelines2/5

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

There is no when-to-use guidance and no explicit alternatives. The only implied context is that the extension determines the format, leaving the agent to infer that this is the persistence step after building a selection or session.

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