Skip to main content
Glama
COMSOL Multiphysics MCP Server

COMSOL Multiphysics MCP Server

by zixuanguo89

export_touchstone

Exports S-parameters from RF COMSOL models to Touchstone files, creating the export feature and optionally running it immediately.

Instructions

Create (optionally run) a Touchstone (S-parameter) export feature.

Touchstone export is only meaningful for RF models with S-parameters (ElectromagneticWaves/Electrical Circuit terminals). Creating the feature works on any model; running it requires such a model.

Args: tag: export feature tag. path: output Touchstone path; tried with the filename properties of the feature (filename / touchstonefilename). plotgroup: optional plot group tag to bind. properties: extra properties, e.g. {"touchstoneversion": "1.0"}, {"referenceimpedance": "50[ohm]"}, {"smatrix": "..."}. run: run the export immediately (default True). model: model name/tag (None = current model).

Returns: {"tag", "type", "properties", "ran", "path", "size", "exists"}.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "export_touchstone"
  }
}

Input Schema

NameRequiredDescriptionDefault
runNo
tagNotouch1
pathNo
modelNo
plotgroupNo
propertiesNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations at all, the description carries the full burden, and it does substantial work: it discloses that run defaults to True, that running has a model precondition, and how path is resolved against the feature's filename properties. It also enumerates the return keys including 'ran', 'size' and 'exists', which tells the agent a file is written. It omits failure modes such as overwriting an existing file or tag collisions, keeping it from a 5.

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 purpose and the RF precondition are front-loaded before the argument list, and the Args/Returns structure is easy to scan. The prose is dense but each line carries information. The docstring-style formatting is slightly heavier than necessary for a tool description.

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?

For a six-parameter tool with no annotations and no output schema, the description covers the essentials: applicability, every parameter, the default for run, and the return payload shape. Remaining gaps are error and side-effect behavior, such as what happens when path is null or the target file exists, which would matter for a file-writing tool.

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

Parameters5/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 does: all six parameters are documented with meaning, not just names. It explains that path is matched against 'filename'/'touchstonefilename', gives concrete property examples like touchstoneversion and referenceimpedance, and clarifies that model None means the current model.

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?

The first line states a specific verb and resource: 'Create (optionally run) a Touchstone (S-parameter) export feature.' It also scopes the resource to RF S-parameter models, which separates it from generic exporters like export_geometry or export_mesh. It stops short of explicitly naming a sibling to prefer for non-RF exports, so it lands at 4 rather than 5.

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?

It gives a clear applicability rule: Touchstone export is only meaningful for RF models with S-parameters, creation works on any model, but running requires an RF model. That is actionable when-to-use guidance with an implicit when-not (non-RF models). It never points to an alternative tool for non-RF export cases, so it is clear context without explicit alternatives.

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

Deploy Server

Other Tools