Skip to main content
Glama

Plecs Simulate

plecs_simulate

Run PLECS simulations and parallel parameter sweeps, then return time-series data, per-signal summaries, or save results to a MatFile for analysis.

Instructions

Run a simulation (blocking).

options is the PLECS optStruct (ModelVars / SolverOpts / OutputFormat); pass a LIST of optStructs to let PLECS parallelize parameter sweeps. Only models with top-level Outports return data ({"Time": [...], "Values": [...]}; over JSON-RPC, Values is signals x time). save_to writes a MatFile result to disk. summary=true replaces the raw arrays with per-signal min/max/mean/p2p/rms. Results above max_points (default 20000) are written to the MCP output dir and returned as a summary. SolverOpts.Timeout is injected (default 600 s) so PLECS aborts on its own even if the client gives up.

Input Schema

NameRequiredDescriptionDefault
optionsNo
save_toNo
summaryNo
timeoutNo
overwriteNo
max_pointsNo
model_nameYes

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.1

TDQS

A3.7/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does substantial work: it declares the call is blocking, that only models with top-level Outports return data, the shape of the returned data, that save_to writes a MatFile, that oversized results are spilled to the MCP output dir, and that SolverOpts.Timeout is injected with a 600 s default so PLECS aborts on its own. Remaining gaps are ownership of the separate `timeout` parameter and the effect of `overwrite`.

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 blocking nature and the primary options contract are front-loaded, and the backticked parameter names make it scannable. It is information-dense but nearly every clause adds a distinct behavioral fact; only the return-shape sentence partially duplicates the output schema.

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 7-parameter simulation tool with no annotations this covers the high-risk surface: blocking semantics, output spilling, timeout injection, and data shape. Missing are the overwrite behavior for save_to and any error/failure reporting, which an agent would want before kicking off long simulations.

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 0% across 7 parameters, so the description must compensate and it does for options, save_to, summary, and max_points. It leaves `overwrite` completely unexplained and is ambiguous about the relationship between the top-level `timeout` parameter and the injected SolverOpts.Timeout, leaving two of seven parameters unclear.

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 opening 'Run a simulation (blocking)' gives a specific verb and resource, and the parenthetical 'blocking' implicitly separates it from asynchronous siblings such as plecs_submit/plecs_task. It never names those alternatives explicitly, so an agent must infer the routing, but the core purpose is unmistakable.

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?

Usage context is only implied: pass a list of optStructs for parameter sweeps, use summary=true for aggregates, and results over max_points get summarized. There is no explicit statement of when to prefer this over plecs_submit or plecs_task, nor any stated preconditions (e.g. validate/capture the model first).

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