vmd-hydrate-mcp
v0.2.0Drive VMD for GROMACS/LAMMPS analysis + clathrate-hydrate cage science (needs a local VMD)
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
vmd_status
Report whether VMD is available, its version, and the molecules currently loaded in the persistent session.
load_structure
Load a structure/trajectory into the persistent VMD session for visualization. Supports PDB, GROMACS (.gro/.xtc/.trr), LAMMPS (.data/dump), DCD. Coordinate-only formats (.xtc/.trr/.dcd) require a `topology`. Returns the molid used to reference this molecule in later calls.
| Parameter | Type | Description |
|---|---|---|
path * | string | |
filetype | string | |
topology |
list_molecules
List molecules currently loaded in the VMD session (molid, path, atoms, frames).
set_representation
Set the visual representation of a loaded molecule (e.g. style=NewCartoon, Licorice, VDW, Lines; color=Name, ResType, Beta; selection is a VMD atom-selection string like "water" or "name CA").
| Parameter | Type | Description |
|---|---|---|
molid * | integer | |
color | string | |
material | string | |
selection | string | |
style | string |
render
Render the current view of a loaded molecule headlessly (CPU Tachyon) and return a PNG image. Resolution is capped for safety.
| Parameter | Type | Description |
|---|---|---|
molid * | integer | |
height | integer | |
width | integer |
resolve_selection
Report how many atoms an MDAnalysis selection matches — use this to catch the common 0-atom trap on bare .gro files before running measurements.
| Parameter | Type | Description |
|---|---|---|
path * | string | |
selection * | string | |
topology |
measure_geometry
Measure a distance (2 atom indices), angle (3), or dihedral (4) at a frame. Distances are in Angstrom, angles in degrees.
| Parameter | Type | Description |
|---|---|---|
indices * | array | |
path * | string | |
frame | integer | |
topology |
radius_of_gyration
Radius of gyration (Angstrom) of an atom selection at a frame.
| Parameter | Type | Description |
|---|---|---|
path * | string | |
frame | integer | |
selection | string | |
topology |
hydrate_order_params
Compute clathrate-hydrate water order parameters F3 (tetrahedrality) and F4 (<cos 3phi>) for a frame. F4 ~ 0.7-0.95 indicates hydrate/crystalline order, ~0 liquid, negative ice-Ih. Units are nm; for .gro the native nm parser is used. This is the differentiating capability no other MCP offers.
| Parameter | Type | Description |
|---|---|---|
path * | string | |
cutoff | number | |
frame | integer | |
topology |
hbond_network
Build the water-water hydrogen-bond network for a frame and report bond count and average coordination (the substrate for cage identification). rcut is the O-O cutoff (nm), theta the H-O...O angle cutoff (degrees).
| Parameter | Type | Description |
|---|---|---|
path * | string | |
frame | integer | |
rcut | number | |
theta | number | |
topology |
identify_cages
Identify clathrate-hydrate cages (5^12, 5^12 6^2, 5^12 6^4, ...) from the water H-bond network and classify the crystal structure (sI/sII/sH). Returns per-type cage counts, the structure label, and a confidence. method="TRACE" (all rings) or "HTR" (primitive rings). GROMACS .gro input.
| Parameter | Type | Description |
|---|---|---|
path * | string | |
frame | integer | |
method | string | |
rcut | number | |
theta | number |
render_cages
Render clathrate cages photorealistically (ambient occlusion + shadows, orthographic by default). Each cage type is drawn in ONE unified color for both its water-oxygen vertices and its O-O framework, using a curated palette (512=cyan, 51262=violet, 51264=red, 435663=lime, 51268=blue). Natural-language styling maps directly to the arguments: - "show only the sII large cages" -> cage_types=["51264"] - "... in magenta" -> highlight_color="magenta" (name or #rrggbb) - "emphasize / thicker width" -> emphasis=True (thicker edges + bigger sphe…
| Parameter | Type | Description |
|---|---|---|
path * | string | |
background | string | |
cage_types | ||
colors | ||
emphasis | boolean | |
frame | integer | |
height | integer | |
highlight_color | ||
material | string | |
method | string | |
projection | string | |
width | integer |
add_representation
Add a representation WITHOUT clearing existing ones — layer several reps (e.g. water as Points + solute as VDW). `color` is a coloring METHOD (Name, ResName, ResType, Chain, Beta, ...); `style` is VDW/Lines/Points/ NewCartoon/Licorice/etc.
| Parameter | Type | Description |
|---|---|---|
molid * | integer | |
color | string | |
material | string | |
selection | string | |
style | string |
clear_representations
Remove all representations from a molecule (start a fresh view).
| Parameter | Type | Description |
|---|---|---|
molid * | integer |
rotate_view
Rotate the camera by `degrees` about an axis ('x'/'y'/'z'). In GUI/attended mode (VMD_HYDRATE_MCP_DISPLAY=gui) the visible window updates live.
| Parameter | Type | Description |
|---|---|---|
axis | string | |
degrees | number |
zoom_view
Zoom the view by a multiplicative factor (>1 zoom in, <1 zoom out).
| Parameter | Type | Description |
|---|---|---|
factor | number |
reset_view
Reset/fit the camera to the loaded molecule.
| Parameter | Type | Description |
|---|---|---|
molid | integer |