Skip to main content
Glama

Stop a background run

run_stop
DestructiveIdempotent

Stop a program launched by run_start and terminate its process group through the run's control FIFO; writes the final status and reports if the grace period expires.

Instructions

Stop a run_start run: the request goes through the run's control FIFO to the runner that owns it, which kills the program's process group and writes the final status. acknowledged=false means it did not finish within grace_s (its deadline still applies).

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": {
      "target": "<target>",
      "run_id": "<run_id>"
    },
    "name": "run_stop"
  }
}

Input Schema

NameRequiredDescriptionDefault
run_idYesrun_id returned by run_start (r- and 12 hex digits)
targetYesTarget name such as 'tb' (lowercase letters, digits, '-', '_'); must be inside the server allowlist
grace_sNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.0

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already declare destructive=true, idempotent=true and openWorld=false, yet the description still adds real value: the control-FIFO mechanism, that the runner's process group is killed, that a final status is written, and the meaning of acknowledged=false including that the deadline still applies. It stops short of covering failure modes or what happens if the run already exited.

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?

Two sentences, no filler, and the action plus mechanism are front-loaded before the acknowledgement caveat. The parenthetical is dense but each clause carries distinct information.

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?

With an output schema present, return values need not be explained, and the description still covers the mechanism and the acknowledged semantics. For a destructive, idempotent 3-parameter tool this is close to complete; only error/edge-case behavior is missing.

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 67% and run_id/target are already documented in the schema. The description adds meaning for grace_s (the acknowledgement window and that the deadline still applies), which the schema leaves undescribed, but gives no numeric or boundary guidance beyond the schema's min/max.

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 description opens with a specific verb and resource ('Stop a run_start run') and ties it back to the sibling that creates runs, so an agent can distinguish it from run_start/run_poll. It does not explicitly separate it from process_stop or target_stop, which is the remaining ambiguity.

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 is implied by the reference to run_start runs, but there is no explicit statement of when to choose this over process_stop, target_stop, or waiting via run_poll. No preconditions (permissions, run state) are stated beyond the target allowlist carried by the schema.

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