Skip to main content
Glama
COMSOL Multiphysics MCP Server

COMSOL Multiphysics MCP Server

by zixuanguo89

mesh_element_counts

Counts mesh elements per domain or boundary to verify which geometric entities are meshed and confirm that a simple geometry produced the expected element types.

Instructions

Element counts per geometric entity (domains for tets, boundaries for tris).

Useful to verify which domains/boundaries are meshed and whether a simple geometry was meshed as expected.

Args: mesh: mesh sequence tag (None = first). types: element types to count ("tet", "tri", "quad", "hex", "prism", "edg", "vtx"); None = all present types. max_entities: cap on reported entities per type (default 200). component: component tag (None = auto-detect). model: model name/tag (None = current model).

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

Input Schema

NameRequiredDescriptionDefault
meshNo
modelNo
typesNo
componentNo
max_entitiesNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.6/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full burden. It reveals useful fallback behavior (None = first mesh, None = auto-detect component, None = current model) and that output per type is capped, but never states explicitly that the call is read-only, has no side effects on the mesh, or what happens when nothing is meshed.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

One summary line with parenthetical clarification, one use-case sentence, then a scannable Args block. Nothing is padded, and the purpose is front-loaded ahead of the parameter detail.

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?

There is no output schema, so the description should convey the return shape, and it only implies it (counts per entity, capped by max_entities). It does not say what the response looks like or whether truncation past the 200-entity cap is flagged, which matters for an inspection tool an agent will read results from.

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 carry parameter meaning, and it largely does: every one of the five parameters is explained, including the full list of accepted element type strings and what None means for each. It does not clarify matching semantics for model/component tags, but the gap is small.

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 gives a specific verb and resource: element counts per geometric entity, with the domain/tet and boundary/tri mapping made explicit. It is clearly a counting/inspection tool, though it does not name the sibling it differs from (e.g. mesh_stats), so the distinction is inferred rather than stated.

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?

It states a concrete use case - verifying which domains/boundaries are meshed and whether a simple geometry meshed as expected - which tells an agent when the tool is relevant. There is no when-not guidance and no pointer to alternatives such as mesh_stats or catalog_mesh_features for other inspection needs.

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