Skip to main content
Glama

run_for_duration

Runs an STM32 target freely for a set wall-clock duration, then halts it and returns final context plus optional expression captures for counters, telemetry, polling, and timing diagnostics.

Instructions

Runs the target freely for a wall-clock duration, halts it, and returns one structured report with final frame/context and optional expression captures. Useful for counters, telemetry buffers, polling loops, and timing-sensitive bus diagnostics without breakpoint perturbation.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
thenNoAction after duration (default halt).
sampleNoBest-effort low-rate debugger polling while running; does not halt the target.
captureNo
sessionNoOptional debug-session name. Omit for the default target.
duration_secYesSeconds to let the target run freely.
resume_afterNoResume execution after capture (default false).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.15.1

TDQS

A4.2/5.0
Behavior4/5

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

Annotations declare readOnlyHint=false and idempotentHint=false, and the description adds genuine context beyond them: it halts the target, produces one structured report, distinguishes 'best-effort low-rate polling while running' from post-halt 'capture', and notes the no-breakpoint-perturbation behavior. It omits failure/partial-capture behavior, so it isn't fully complete.

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?

Two tight sentences that front-load the core behavior and then the use case. No filler; every clause contributes (duration run, halt, structured report, capture, usage contexts).

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 6-param tool with nested objects and no output schema, the description usefully sketches the return value ('final frame/context and optional expression captures') and the run/halt/capture flow. It leaves the sampling/capture parameter interplay to the schema, which is reasonable but not exhaustive.

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 coverage is 83%, so the schema already carries most parameter meaning. The description only references 'optional expression captures' and the structured report, adding little to the schema's own descriptions of capture, sample, resume_after, and session. Baseline 3 applies for high-coverage schemas.

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?

States a precise verb+resource with full lifecycle: 'Runs the target freely for a wall-clock duration, halts it, and returns one structured report.' This clearly separates it from siblings like run_to_line, debug_until, run_and_wait, and continue_execution, since the duration-bounded free-run is the distinguishing scope.

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 usage contexts ('counters, telemetry buffers, polling loops, and timing-sensitive bus diagnostics') and a key selection rationale ('without breakpoint perturbation'). It does not, however, name when NOT to use it or point to specific alternatives such as run_and_wait or debug_until, so it stops short of a 5.

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