Skip to main content
Glama

vi_run

Execute a LabVIEW VI with preset inputs and ordered front-panel actions, then read indicator values to test UI behavior or capture outputs.

Instructions

Run a VI and return its front-panel values afterwards.

inputs: {control label: value} set before running (clusters as lists in element order; enums by item name). outputs: labels to read back; default reads every top-level control and indicator. actions: operate the front panel while the VI runs, as a user would, in order: {"click": "Go"} press a button (works on latched buttons such as STOP) {"set": {"x": 21}} change controls; fires their Value Change events {"wait": 0.5} pause, in seconds {"read": ["y", "log"]} record values at this moment e.g. [{"set": {"x": 21}}, {"read": ["y"]}, {"click": "Go"}, {"click": "STOP"}] tests a UI end to end; the result's "actions" lists what each step did and read. A VI still running after timeout_s is aborted (typical for UI loops waiting on a Stop button). A modal dialog (a One Button Dialog, or LabVIEW's automatic error dialog for an unwired error in a VI that has automatic error handling on) blocks LabVIEW until someone answers it, and this call with it. VIs made by vi_create have automatic error handling off; in other VIs wire error outputs before running them. WARNING: executes code and may drive real hardware — only run VIs the user asked to run.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "path": "<path>"
    },
    "name": "vi_run"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathYes
inputsNo
actionsNo
outputsNo
timeout_sNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.40.1

TDQS

A4.6/5.0
Behavior5/5

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

With no annotations supplied, the description carries the full burden and does so well: it discloses that timeout_s aborts a still-running VI, that a modal dialog blocks LabVIEW and this call until answered, that automatic error handling differs for vi_create VIs, and that executing may drive real hardware. It also explains that {"set": ...} fires Value Change events and that click works on latched buttons like STOP — behavioral detail an agent could not infer from the schema.

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 purpose is front-loaded in one line, then organized into labeled inputs/outputs/actions blocks with a compact DSL spec and a single end-to-end example. It is on the long side, but nearly every line supplies information the agent would otherwise have to guess; the parenthetical about LabVIEW's automatic error dialog is the only slightly padded passage.

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 complex execution tool with no annotations and no output schema, the definition covers side effects, blocking hazards, timeout behavior, and the actions DSL. The return payload is only sketched ("the result's 'actions' lists what each step did and read"), so the exact shape of the front-panel values and action results is left partly implicit.

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: inputs are keyed by control label with clusters as ordered lists and enums by item name; actions are given a full step grammar with a worked example; outputs is described as labels to read back with a stated default; timeout_s is explained through its abort semantics. Only path is left implicit, and that is self-evident from the required-parameter position.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a specific verb+resource+outcome: "Run a VI and return its front-panel values afterwards." That single clause separates it from every sibling in the list (vi_create, vi_diff, vi_dump, vi_test, etc.), none of which execute a VI, so an agent can select it without opening the schema.

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?

Gives concrete when-to-use context ("tests a UI end to end", default reads every top-level control and indicator) and hard exclusions ("only run VIs the user asked to run", wire error outputs before running non-vi_create VIs). It never names a sibling as an alternative for a narrower case, so routing is clear but not explicitly comparative.

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