Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
PYMOL_MCP_HISTORYNoDirectory for session history files, or 'off' to disable. Default is ~/.pymol-mcp/. Set to a custom path or 'off'.
PYMOL_MCP_LOG_LEVELNoLog level for the MCP server. Set to 'INFO' or 'DEBUG' to enable logging. Default is no logging.

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": false
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
parse_and_executeA

Executes a single PyMOL command given in literal PyMOL syntax.

NOT a natural-language interface. user_input is matched against a fixed table of command patterns; anything else is rejected rather than guessed at. Translate the user's request into PyMOL syntax yourself, then call this once per command. Use list_commands to look up exact syntax.

instance is the port of the PyMOL to drive. Leave it unset when only one is running. With several running an unset instance is an error rather than a guess, since driving the window the user is not watching looks exactly like the command doing nothing. Call list_instances to see the choices.

Translating requests: "Load PDB 1UBQ and show it as cartoon" -> parse_and_execute("fetch 1ubq") -> parse_and_execute("as cartoon, 1ubq") "Colour chain A red" -> "color red, chain A" "Show sticks for residues 1-50" -> "show sticks, resi 1-50" "Open /data/model.pdb" -> "load /data/model.pdb" "Select the binding site" -> "select site, byres (polymer within 5 of ligand)"

Common mistakes:

  • Multiple commands in one call. "fetch 1ubq and show cartoon" fails; the whole string is read as one filename/code.

  • load for a PDB ID. load takes a file path; use fetch for a 4-character accession code like 1ubq.

  • Selections as prose. Write show cartoon, chain A, not show cartoon for chain A -- the selection is a second argument after a comma.

  • Conversational filler. "please show cartoon" does not match; send "show cartoon".

Selections use full PyMOL algebra (chain A and resi 1-50, not solvent, byres (... within 5 of ...)). Commas separate arguments, so a selection containing a comma must be rewritten with + (resi 1+2+3).

Returns PyMOL's output, or a message describing the parse/execution failure.

list_instancesA

Lists the running PyMOL instances and what each has loaded.

Each PyMOL claims its own port, so several can run at once. Pass a port as instance to parse_and_execute to drive that specific one. Use this when a command reports the choice is ambiguous, or when the user refers to a particular window.

The loaded object names are what distinguish one window from another; a port number on its own identifies nothing to a human.

list_commandsA

Lists the PyMOL commands parse_and_execute accepts.

Without filter, returns every command name with a one-line description. With filter (a substring matched against names and descriptions), returns full detail for the matches: the exact regex the input must satisfy, plus each parameter's name, whether it is required, its default, and its allowed values. Use it to confirm syntax before calling parse_and_execute.

Examples: filter="color" for the colouring commands, filter="cartoon" for cartoon-related ones, filter="fetch" for the exact fetch signature.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

TDQS

A4.6/5.0

Scored across 3 tools

Disambiguation5/5

Each tool serves a distinct purpose: list_commands provides command syntax, list_instances shows running instances, and parse_and_execute executes commands. There is no overlap.

Naming Consistency5/5

All tool names use lowercase snake_case with a verb_noun pattern (list_commands, list_instances, parse_and_execute). The naming is consistent and predictable.

Tool Count5/5

With 3 tools, the set is well-scoped for the server's purpose—providing help, instance information, and command execution. No unnecessary tools.

Completeness4/5

The tool surface covers the core workflow of querying syntax, checking instances, and executing commands. A minor gap is the lack of a direct way to get the current state or result of previous commands, but agents can work around this.

Maintenance

ActivityActive
ResponsivenessNo issues