Skip to main content
Glama

spawn_program

Start an allowed program by name in a session to get its PID, then wait for its window before inspecting it.

Instructions

Start one of the programs the person allowed this server to run, by its name, in a session; nothing else can run. The answer gives its pid. Then wait_for its window, by the program's name, before looking at it. If it doesn't come up, get_program_output says why.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
programYesIts name in the allow list
sessionYesIts name, from start_session

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.8.1

TDQS

A4.3/5.0
Behavior4/5

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

Annotations only declare readOnlyHint=false / destructiveHint=false; the description adds the allow-list restriction, the fact that a pid is returned, and a documented failure path. It does not cover lifecycle questions (can the same program be spawned twice, is the process tied to the session's lifetime), which keeps it short of a 5.

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?

Three sentences, front-loaded with the action, then follow-up tooling, then the failure path; every sentence earns its place. Minor awkwardness in the phrasing 'in a session' and the compressed final clause keeps it from a 5.

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 no output schema, the description correctly supplies the return value (pid) and the diagnostic route for failure, so an agent can call and follow up correctly. Missing edge cases such as an invalid session name or repeated spawns of the same program.

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 100% and both parameters carry their own descriptions ('Its name in the allow list', 'Its name, from start_session'). The prose only echoes 'by its name' and 'in a session', so the baseline 3 applies.

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 specific verb (start/spawn) and resource (an allow-listed program) plus the hard scope constraint that nothing outside the allow list can run. It also distinguishes itself from siblings by naming wait_for and get_program_output in their respective roles.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives an explicit sequence: spawn the program, then wait_for its window by name before inspecting it, and fall back to get_program_output if it fails to appear. Alternatives and their triggering conditions are stated rather than left to inference.

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